mirror of
https://github.com/MarioSpore/Grinch-AP.git
synced 2025-10-21 20:21:32 -06:00
Network: implement Bounce and Bounced
This commit is contained in:
@@ -43,6 +43,7 @@ These packets are are sent from the multiworld server to the client. They are no
|
||||
* [Print](#Print)
|
||||
* [PrintJSON](#PrintJSON)
|
||||
* [DataPackage](#DataPackage)
|
||||
* [Bounced](#Bounced)
|
||||
|
||||
### RoomInfo
|
||||
Sent to clients when they connect to an Archipelago server.
|
||||
@@ -148,6 +149,15 @@ Sent to clients to provide what is known as a 'data package' which contains info
|
||||
| ---- | ---- | ----- |
|
||||
| data | DataPackageObject | The data package as a JSON object. More details on its contents may be found at [Data Package Contents](#Data-Package-Contents) |
|
||||
|
||||
### Bounced
|
||||
Sent to clients after a client requested this message be sent to them, more info in the Bounce package.
|
||||
|
||||
#### Arguments
|
||||
| Name | Type | Notes |
|
||||
| ---- | ---- | ----- |
|
||||
| Any | Any | The data in the Bounce package copied |
|
||||
|
||||
|
||||
## (Client -> Server)
|
||||
These packets are sent purely from client to server. They are not accepted by clients.
|
||||
|
||||
@@ -158,6 +168,7 @@ These packets are sent purely from client to server. They are not accepted by cl
|
||||
* [StatusUpdate](#StatusUpdate)
|
||||
* [Say](#Say)
|
||||
* [GetDataPackage](#GetDataPackage)
|
||||
* [Bounce](#Bounce)
|
||||
|
||||
### Connect
|
||||
Sent by the client to initiate a connection to an Archipelago game session.
|
||||
@@ -220,6 +231,19 @@ Requests the data package from the server. Does not require client authenticatio
|
||||
| ------ | ----- | ------ |
|
||||
| exlusions | list[str] | Optional. If specified, will not send back the specified data. Such as, ["Factorio"] -> Datapackage without Factorio data.|
|
||||
|
||||
### Bounce
|
||||
Send this message to the server, tell it which clients should receive the message and
|
||||
the server will forward the message to all those targets to which any one requirement applies.
|
||||
|
||||
#### Arguments
|
||||
| Name | Type | Notes |
|
||||
| ------ | ----- | ------ |
|
||||
| games | list[str] | Optional. Game names that should receive this message |
|
||||
| slots | list[int] | Optional. Player IDs that should receive this message |
|
||||
| tags | list[str] | Optional. Client tags that should receive this message |
|
||||
| Any | Any | Any data you want to send |
|
||||
|
||||
|
||||
## Appendix
|
||||
### NetworkPlayer
|
||||
A list of objects. Each object denotes one player. Each object has four fields about the player, in this order: `team`, `slot`, `alias`, and `name`. `team` and `slot` are ints, `alias` and `name` are strs.
|
||||
|
Reference in New Issue
Block a user