Page 1 of 1

Error message regarding my ZSCRIPT cheats

Posted: Sun May 21, 2023 11:11 am
by AshHouswares
I'm getting this on bootup. What does this mean? Too many arguments? In what way?

Code: Select all

  Family 6, Model 140, Stepping 1
  Features: SSE2 SSE3 SSSE3 SSE4.1 SSE4.2 AVX AVX2 AVX512 F16C FMA3 BMI1 BMI2 HyperThreading
V_Init: allocate screen.
ST_Init: Init startup screen.
Checking cmd-line parameters...
S_InitData: Load sound definitions.
G_ParseMapInfo: Load map definitions.
Texman.Init: Init texture manager.
ParseTeamInfo: Load team definitions.
LoadActors: Load actor definitions.
Script error, "HorryefieingCircleMansion.ipk3:zscript/cheatcodes" line 85:
Too many arguments in call to CheatItems
For the record, this is the script its referring too...

Code: Select all

		if (e.name == "EV_CheatGod")
		{
			if (!(pmo.player.cheats & CF_GODMODE))
			{
				Console.Printf("Prepare to live.");
				pmo.player.cheats |= CF_GODMODE;
			}
			else
			{
				Console.Printf("Prepare to die.");
				pmo.player.cheats &= ~CF_GODMODE;
			}
		}
		else if (e.name == "EV_CheatGiveStuff")
		{
			Console.Printf("Fine. Ruin the fun. See if I care.");
			pmo.CheatGive("all", 0);
		}
		else if (e.name == "EV_CheatKeys")
		    Console.Printf("Here's some keys.");
			pmo.CheatItems("");
	}

Re: Error message regarding my ZSCRIPT cheats

Posted: Sun May 21, 2023 11:42 am
by Jarewill
Going by the error, you put too many arguments when you called the function CheatItems.
However I am not familiar with that function, if it's a custom one please post its full definition.
My only guess is to call the function without any arguments: pmo.CheatItems();