HomeWildfire Games

Move most cinematic path simulation data and control from the graphics class to…

Description

Move most cinematic path simulation data and control from the graphics class to the simulation component and solve the hash mimatch in non-visual replay.

Move graphics code to smaller helper functions UpdateSessionVisibility, UpdateSilhouettesVisibility and DrawPaths.
Remove the hotkey TODO code which should be implemented differently.
Mark voids as const.

Differential Revision: https://code.wildfiregames.com/D271
Patch By: Vladislav

Event Timeline

leper raised a concern with this commit.Apr 29 2017, 6:32 PM
leper added a subscriber: leper.

Breaks the build. See D385.

This commit now has outstanding concerns.Apr 29 2017, 6:32 PM
elexis requested verification of this commit.Apr 29 2017, 8:39 PM
This commit now requires verification by auditors.Apr 29 2017, 8:39 PM
leper accepted this commit.May 1 2017, 1:51 AM
All concerns with this commit have now been addressed.May 1 2017, 1:51 AM
Sandarac raised a concern with this commit.Jun 1 2017, 11:20 PM
Sandarac added a subscriber: Sandarac.

This commit seems to be the one that broke two hotkeys, see D584.

This commit now has outstanding concerns.Jun 1 2017, 11:20 PM
leper resigned from this commit.Jun 10 2017, 6:18 PM
elexis added inline comments.Jun 12 2017, 3:39 PM
/ps/trunk/source/graphics/CinemaManager.cpp
107

Besides not considering these two hotkeys, breaking those is also a consequence of the design flaw from rP17594 desribed here.

Several ways to address this have been discussed with Vladislav at the time of the review of this diff and after the concern was raised:

  • Doing it as before and only toggling at the begin and end of a cinematic path. (Still overwrites the user config).
  • Saving the hotkey toggle states in the config or some other C++ variable. (Still bad hardcoding of an XML GUI object and of a hotkey in a C++ graphics component)

But since developers and modders should be able to deal with the cinematics in arbitrary ways and
because the C++ code should be as agnostic of hotkeys as possible (for the same reason),
the JS code itself should decide when and where it hides something based on the fact whether a path is playing or not. Patch incoming.

elexis requested verification of this commit.Jun 28 2017, 3:04 PM
This commit now requires verification by auditors.Jun 28 2017, 3:04 PM
Sandarac resigned from this commit.Jun 30 2017, 3:44 PM
This commit no longer requires audit.Jun 30 2017, 3:44 PM