Skip to content

Commit

Permalink
Add originating slot to bounce packets
Browse files Browse the repository at this point in the history
  • Loading branch information
NewSoupVi committed Aug 8, 2024
1 parent 6803c37 commit a315fe3
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions MultiServer.py
Original file line number Diff line number Diff line change
Expand Up @@ -1827,6 +1827,7 @@ async def process_client_cmd(ctx: Context, client: Client, args: dict):
slots = set(args.get("slots", []))
args["cmd"] = "Bounced"
msg = ctx.dumper([args])
msg["slot"] = client.slot

for bounceclient in ctx.endpoints:
if client.team == bounceclient.team and (ctx.games[bounceclient.slot] in games or
Expand Down
1 change: 1 addition & 0 deletions docs/network protocol.md
Original file line number Diff line number Diff line change
Expand Up @@ -223,6 +223,7 @@ Sent to clients after a client requested this message be sent to them, more info
| slots | list\[int\] | Optional. Player slot IDs that this message is targeting |
| tags | list\[str\] | Optional. Client [Tags](#Tags) this message is targeting |
| data | dict | The data in the [Bounce](#Bounce) package copied |
| slot | int | The slot that originally sent the Bounce package |

### InvalidPacket
Sent to clients if the server caught a problem with a packet. This only occurs for errors that are explicitly checked for.
Expand Down

0 comments on commit a315fe3

Please sign in to comment.