HomeWildfire Games

Implement session event subscription system and rewrite TopPanel…

Description

Implement session event subscription system and rewrite TopPanel, PlayerViewControl, GameSpeed, Pausing, ObjectivesDialog to use object orientation, refs #5387.

New controller classes: PlayerViewControl, PauseControl, GameSpeedControl
New viewer classes: ObjectivesDialog, PauseOverlay, FollowPlayer, TopPanel (BuildLabel, CivIcon, CounterManager, CounterPopulation, CounterResource refs rP21071/D1113, GameSpeedButton, ObjectivesDialogButton)

New events: SimulationUpdate, EntitySelectionChange, ViewedPlayerChange, PreViewedPlayerChangeHandler, PlayerIDChange, PlayersInit, PlayersFinished, Pause, DiplomacyColorsChange, HotkeyChange, refs #2604
Improves GUI onSimuationUpdate performance without selected entities by allegedly 30%.

Delete misleading dead code resign command from leaveGame and rename to endGame. The command is not sent via network (see rP14732) nor processed in simulation, because the Game instance is deleted immediately thereafter, introduced in rP8234, refs rP14772, rP17548, rP18441.
Remove explicitResume 0 value from rP17423 and rP20644 which should have been a false if defined, and is equivalent to the default.
Restore fast forwarding option from rP20577/D595 for developers changing the perspective to observer or player following rP21149.
Add pausing for the delete dialog missing following rP10194.

Differential Revision: https://code.wildfiregames.com/D2378

Event Timeline

elexis added inline comments.Oct 30 2019, 2:45 PM
/ps/trunk/binaries/data/mods/public/gui/session/menu.js
386

Defect: This line prevented pause for non-hosting observers using the hotkey, was removed without replacement.