1
0
mirror of https://github.com/TerryCavanagh/VVVVVV.git synced 2024-06-29 07:58:30 +02:00

Add braces to case 12 custom level loading

I do this because we declare-and-initialize some variables in the case.
This isn't strictly necessary, since there's no cross-initialization
errors since it's the last case in the switch, but I'd just like to be
future-proof.
This commit is contained in:
Misa 2020-07-09 02:58:16 -07:00 committed by Ethan Lee
parent 71a989707e
commit 2646642664

View File

@ -1611,6 +1611,7 @@ void mapclass::loadlevel(int rx, int ry)
#endif #endif
#if !defined(NO_CUSTOM_LEVELS) #if !defined(NO_CUSTOM_LEVELS)
case 12: //Custom level case 12: //Custom level
{
const int curlevel = rx-100 + (ry-100) * ed.maxwidth; const int curlevel = rx-100 + (ry-100) * ed.maxwidth;
const edlevelclass* room_ptr = NULL; const edlevelclass* room_ptr = NULL;
if (!INBOUNDS_ARR(curlevel, ed.level)) if (!INBOUNDS_ARR(curlevel, ed.level))
@ -1818,6 +1819,7 @@ void mapclass::loadlevel(int rx, int ry)
//do the appear/remove roomname here //do the appear/remove roomname here
break; break;
}
#endif #endif
} }
//The room's loaded: now we fill out damage blocks based on the tiles. //The room's loaded: now we fill out damage blocks based on the tiles.