mirror of
https://github.com/TerryCavanagh/VVVVVV.git
synced 2026-01-30 18:04:09 +03:00
Use enums for swngame
This replaces the swngame int variable with a named enum and enforces strict typechecking on it. Strict typechecking is okay here as the swngame variable is not part of the API surface of the game in any way and is completely internal. And just to make things clear, I've added a SWN_NONE enum to use for initialization, because previously it was being initialized to 0, even though 0 was the Gravitron.
This commit is contained in:
@@ -2009,7 +2009,8 @@ void Graphics::drawentity(const int i, const int yoff)
|
||||
case 5: //Horizontal Line
|
||||
{
|
||||
int oldw = obj.entities[i].w;
|
||||
if ((game.swngame == 3 || kludgeswnlinewidth) && obj.getlineat(84 - 32) == i)
|
||||
if ((game.swngame == SWN_START_GRAVITRON_STEP_2 || kludgeswnlinewidth)
|
||||
&& obj.getlineat(84 - 32) == i)
|
||||
{
|
||||
oldw -= 24;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user