You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: content/docs/components/dispatch.md
+20Lines changed: 20 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -132,6 +132,26 @@ dispatch.setComputed({
132
132
```
133
133
`getComputed` and `setComputed` are both nearly identical in how they are called, taking a character id and a property with the name of the computed property you wish to get or set, and an array of string args. Both methods return a promise that resolves with the computed value.
134
134
135
+
## getAvailableCharacters
136
+
```typescript
137
+
dispatch.getAvailableCharacters(): Promise<{
138
+
[id:string]: {
139
+
id:string;
140
+
name:string;
141
+
avatar:string;
142
+
permissions:"view"|"edit";
143
+
characterType:string;
144
+
description:string;
145
+
customMeta1:string;
146
+
customMeta2:string;
147
+
customMeta3:string;
148
+
statusmarkers:string;
149
+
tags:string;
150
+
}
151
+
}>
152
+
```
153
+
`getAvailableCharacters` returns a list of all characters available to the current player. It returns the characters' metadata, as well as the player's permission level (`view` or `edit`).
0 commit comments