mirror of
https://github.com/TerryCavanagh/VVVVVV.git
synced 2026-01-29 17:38:16 +03:00
Fix formatting and add an INBOUNDS_VEC
If `setactivitytext` was the last line in a script, the command would index the vector out of bounds. I also modified the formatting to keep consistent with the rest of the codebase.
This commit is contained in:
committed by
Misa Elizabeth Kai
parent
b15e25f106
commit
656941202a
@@ -1909,8 +1909,11 @@ void scriptclass::run(void)
|
||||
}
|
||||
else if (words[0] == "setactivitytext")
|
||||
{
|
||||
position++;
|
||||
obj.customactivitytext = commands[position];
|
||||
++position;
|
||||
if (INBOUNDS_VEC(position, commands))
|
||||
{
|
||||
obj.customactivitytext = commands[position];
|
||||
}
|
||||
}
|
||||
else if (words[0] == "createrescuedcrew")
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user