Docs: add missed JSONMessagePart types
This commit is contained in:
parent
0992087e9a
commit
520e5feefb
|
@ -280,11 +280,10 @@ class Hint(typing.NamedTuple):
|
|||
add_json_text(parts, self.entrance, type="entrance_name")
|
||||
else:
|
||||
add_json_text(parts, "'s World")
|
||||
add_json_text(parts, ". ")
|
||||
if self.found:
|
||||
add_json_text(parts, ". ")
|
||||
add_json_text(parts, "(found)", type="color", color="green")
|
||||
else:
|
||||
add_json_text(parts, ". ")
|
||||
add_json_text(parts, "(not found)", type="color", color="red")
|
||||
|
||||
return {"cmd": "PrintJSON", "data": parts, "type": "Hint",
|
||||
|
|
|
@ -349,12 +349,21 @@ class JSONMessagePart(TypedDict):
|
|||
|
||||
`type` is used to denote the intent of the message part. This can be used to indicate special information which may be rendered differently depending on client. How these types are displayed in Archipelago's ALttP client is not the end-all be-all. Other clients may choose to interpret and display these messages differently.
|
||||
Possible values for `type` include:
|
||||
* player_id
|
||||
* item_id
|
||||
* location_id
|
||||
* entrance_name
|
||||
|
||||
`color` is used to denote a console color to display the message part with. This is limited to console colors due to backwards compatibility needs with games such as ALttP. Although background colors as well as foreground colors are listed, only one may be applied to a [JSONMessagePart](#JSONMessagePart) at a time.
|
||||
| Name | Notes |
|
||||
| ---- | ----- |
|
||||
| text | Regular text content |
|
||||
| player_id | player ID of someone on your team, should be resolved to Player Name |
|
||||
| player_name | Player Name, could be a player within a multiplayer game or from another team, not ID resolvable |
|
||||
| item_id | Item ID, should be resolved to Item Name |
|
||||
| item_name | Item Name, not currently used over network, but supported by reference Clients. |
|
||||
| location_id | Location ID, should be resolved to Location Name |
|
||||
| location_name |Location Name, not currently used over network, but supported by reference Clients. |
|
||||
| entrance_name | Entrance Name. No ID mapping exists. |
|
||||
| color | Regular text that should be colored. Only `type` that will contain `color` data. |
|
||||
|
||||
|
||||
`color` is used to denote a console color to display the message part with and is only send if the `type` is `color`. This is limited to console colors due to backwards compatibility needs with games such as ALttP. Although background colors as well as foreground colors are listed, only one may be applied to a [JSONMessagePart](#JSONMessagePart) at a time.
|
||||
|
||||
Color options:
|
||||
* bold
|
||||
|
|
Loading…
Reference in New Issue