-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Gh 692 allow client to toggle bots #693
Merged
Merged
Changes from all commits
Commits
Show all changes
15 commits
Select commit
Hold shift + click to select a range
067e014
wip
Nico-Sanchez 1bf332a
Add new ToggleZone protobuff message
Nico-Sanchez 709899b
Handle new :toggle_zone message in GameSocketHandler
Nico-Sanchez 9f11491
Refactor zone messages in game updater to perform toggle zone behavior
Nico-Sanchez 01f7a96
Merge remote-tracking branch 'origin/main' into gh-687-allow-client-t…
Nico-Sanchez 05cb548
wip
Nico-Sanchez c7fecce
Add new ToggleZone client and bots server messages
Nico-Sanchez 149aa2b
Add server_toggle_zone broadcast message handlers in game updater
Nico-Sanchez 2081dc7
Handle new server_toggle_bots message in bots manager to freeze bots …
Nico-Sanchez 1b0ed60
Decode client_toggle_bots messages to trigger server_toggle_bots broa…
Nico-Sanchez 80b635b
Group server and client toggle bots to single message ToggleBots
Nico-Sanchez 194bc75
Delete messages.proto newline
Nico-Sanchez ebee129
Delete IO.inspect/2 call
Nico-Sanchez ac65648
Delete testing purposes key in game state
Nico-Sanchez 743612f
Merge remote-tracking branch 'origin/main' into gh-692-allow-client-t…
Nico-Sanchez File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is this message broadcasted to the clients? The only difference turning on or off the bots makes to them is received through the
GameState
message, they don't handle this message in any way.Client PR for reference: [GH-1831] Add toggle bots button
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The bots are clients as well. Said so, the bots ARE handling that message to change its state.
You can check it in
apps/bot_manager/lib/game_socket_handler.ex
Also, remember the bots are deployed in a different server than where the backend runs (arena), so we need to send the message somehow (I use this broadcast for that)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great, that makes sense!