Update worker game server updater to prefix eventbus events with 'game_', make Window handle worker's game server updater events

This commit is contained in:
2026-10-13 23:34:58 -05:00
parent 82ec837569
commit 7160b2eba9
2 changed files with 34 additions and 2 deletions

View File

@@ -136,12 +136,12 @@ module W3DHubLauncher
else # add
@game_servers << game_server
end
broadcast(hash["type"].to_sym, data: hash["data"])
broadcast(:"game_#{hash["type"]}", data: hash["data"])
when "server_removed"
game_server = @game_servers.find { |s| s.id == hash["data"]["id"] }
@game_servers.delete(game_server) if game_server
broadcast(hash["type"].to_sym, data: hash["data"]["id"])
broadcast(:"game_#{hash["type"]}", data: hash["data"])
when "server_details"
# TODO