Skip to content

Commit

Permalink
the fog is coming. run
Browse files Browse the repository at this point in the history
  • Loading branch information
MegAmi24 committed Aug 2, 2023
1 parent 916c6b6 commit 2acf349
Showing 1 changed file with 54 additions and 12 deletions.
66 changes: 54 additions & 12 deletions RSDKv4/Script.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1092,8 +1092,15 @@ void CheckAliasText(char *text)
{
if (FindStringToken(text, "publicalias", 1) == 0) {
#if !RETRO_USE_ORIGINAL_CODE
if (scriptValueListCount >= SCRIPT_VAR_COUNT)
PrintLog("WARNING: SCRIPT VALUE COUNT ABOVE MAXIMUM");
if (scriptValueListCount >= SCRIPT_VAR_COUNT) {
SetupTextMenu(&gameMenu[0], 0);
AddTextMenuEntry(&gameMenu[0], "SCRIPT PARSING FAILED");
AddTextMenuEntry(&gameMenu[0], " ");
AddTextMenuEntry(&gameMenu[0], "TOO MANY ALIASES, STATIC");
AddTextMenuEntry(&gameMenu[0], "VALUES, AND TABLES");
Engine.gameMode = ENGINE_SCRIPTERROR;
return;
}
#endif

ScriptVariableInfo *variable = &scriptValueList[scriptValueListCount];
Expand Down Expand Up @@ -1136,8 +1143,15 @@ void CheckAliasText(char *text)
}
else if (FindStringToken(text, "privatealias", 1) == 0) {
#if !RETRO_USE_ORIGINAL_CODE
if (scriptValueListCount >= SCRIPT_VAR_COUNT)
PrintLog("WARNING: SCRIPT VALUE COUNT ABOVE MAXIMUM");
if (scriptValueListCount >= SCRIPT_VAR_COUNT) {
SetupTextMenu(&gameMenu[0], 0);
AddTextMenuEntry(&gameMenu[0], "SCRIPT PARSING FAILED");
AddTextMenuEntry(&gameMenu[0], " ");
AddTextMenuEntry(&gameMenu[0], "TOO MANY ALIASES, STATIC");
AddTextMenuEntry(&gameMenu[0], "VALUES, AND TABLES");
Engine.gameMode = ENGINE_SCRIPTERROR;
return;
}
#endif

ScriptVariableInfo *variable = &scriptValueList[scriptValueListCount];
Expand Down Expand Up @@ -1183,8 +1197,15 @@ void CheckStaticText(char *text)
{
if (FindStringToken(text, "publicvalue", 1) == 0) {
#if !RETRO_USE_ORIGINAL_CODE
if (scriptValueListCount >= SCRIPT_VAR_COUNT)
PrintLog("WARNING: SCRIPT VALUE COUNT ABOVE MAXIMUM");
if (scriptValueListCount >= SCRIPT_VAR_COUNT) {
SetupTextMenu(&gameMenu[0], 0);
AddTextMenuEntry(&gameMenu[0], "SCRIPT PARSING FAILED");
AddTextMenuEntry(&gameMenu[0], " ");
AddTextMenuEntry(&gameMenu[0], "TOO MANY ALIASES, STATIC");
AddTextMenuEntry(&gameMenu[0], "VALUES, AND TABLES");
Engine.gameMode = ENGINE_SCRIPTERROR;
return;
}
#endif

ScriptVariableInfo *variable = &scriptValueList[scriptValueListCount];
Expand Down Expand Up @@ -1235,8 +1256,15 @@ void CheckStaticText(char *text)
}
else if (FindStringToken(text, "privatevalue", 1) == 0) {
#if !RETRO_USE_ORIGINAL_CODE
if (scriptValueListCount >= SCRIPT_VAR_COUNT)
PrintLog("WARNING: SCRIPT VALUE COUNT ABOVE MAXIMUM");
if (scriptValueListCount >= SCRIPT_VAR_COUNT) {
SetupTextMenu(&gameMenu[0], 0);
AddTextMenuEntry(&gameMenu[0], "SCRIPT PARSING FAILED");
AddTextMenuEntry(&gameMenu[0], " ");
AddTextMenuEntry(&gameMenu[0], "TOO MANY ALIASES, STATIC");
AddTextMenuEntry(&gameMenu[0], "VALUES, AND TABLES");
Engine.gameMode = ENGINE_SCRIPTERROR;
return;
}
#endif

ScriptVariableInfo *variable = &scriptValueList[scriptValueListCount];
Expand Down Expand Up @@ -1292,8 +1320,15 @@ bool CheckTableText(char *text)

if (FindStringToken(text, "publictable", 1) == 0) {
#if !RETRO_USE_ORIGINAL_CODE
if (scriptValueListCount >= SCRIPT_VAR_COUNT)
PrintLog("WARNING: SCRIPT VALUE COUNT ABOVE MAXIMUM");
if (scriptValueListCount >= SCRIPT_VAR_COUNT) {
SetupTextMenu(&gameMenu[0], 0);
AddTextMenuEntry(&gameMenu[0], "SCRIPT PARSING FAILED");
AddTextMenuEntry(&gameMenu[0], " ");
AddTextMenuEntry(&gameMenu[0], "TOO MANY ALIASES, STATIC");
AddTextMenuEntry(&gameMenu[0], "VALUES, AND TABLES");
Engine.gameMode = ENGINE_SCRIPTERROR;
return false;
}
#endif

ScriptVariableInfo *variable = &scriptValueList[scriptValueListCount];
Expand Down Expand Up @@ -1361,8 +1396,15 @@ bool CheckTableText(char *text)
}
else if (FindStringToken(text, "privatetable", 1) == 0) {
#if !RETRO_USE_ORIGINAL_CODE
if (scriptValueListCount >= SCRIPT_VAR_COUNT)
PrintLog("WARNING: SCRIPT VALUE COUNT ABOVE MAXIMUM");
if (scriptValueListCount >= SCRIPT_VAR_COUNT) {
SetupTextMenu(&gameMenu[0], 0);
AddTextMenuEntry(&gameMenu[0], "SCRIPT PARSING FAILED");
AddTextMenuEntry(&gameMenu[0], " ");
AddTextMenuEntry(&gameMenu[0], "TOO MANY ALIASES, STATIC");
AddTextMenuEntry(&gameMenu[0], "VALUES, AND TABLES");
Engine.gameMode = ENGINE_SCRIPTERROR;
return false;
}
#endif

ScriptVariableInfo *variable = &scriptValueList[scriptValueListCount];
Expand Down

0 comments on commit 2acf349

Please sign in to comment.