mirror of
https://gitea.wildfiregames.com/0ad/0ad.git
synced 2026-06-21 04:26:27 +00:00
719f2d7967
1c0536bf08introduced a disableGraphics bool with a default value and relied on the default being reasonable except for the few needed cases.be93b31411introduced the replayLog argument with a default value and relied on the default being reasonable except for the few needed cases.5747619c39fixed a bug in that commit because the default value hadn't actually been considered to be correct for all CGame constructor calls and was wrong for two. By requiring callers to specify the value, authors are forced to establish thought which value is the correct one, as opposed to hoping that a default value will be good by default. As you can see in the diff, it also makes it easier to compare what values changed if they are always defined in the caller. Use CRenderer::IsInitialised() to determine if this is a non-visual CGame, for the purpose of removing less transparent proxy functions that are unneeded as long as there are about 30 other calls testing for CRenderer::IsInitialised() to determine if the Game should be rendered. Supersedes: * CGame constructor argument bool disableGraphics from1c0536bf08. * CGame::IsGraphicsDisabled() proxy froma533fff883to the proxy from1c0536bf08and two local nonVisual = args.Has("autostart-nonvisual") variables in GameSetup.cpp froma533fff883. Call the Renderer destructor instead of calling delete on the non-pointer (SAFE_DELETE would not be supported for instance). Started as a preparation for D2197, but actually independent. Differential Revision: https://code.wildfiregames.com/D2211 This was SVN commit r22785.