Jump to content

GECK script: Demands Messagebox variable, why?


anandus

Recommended Posts

I'm making a little script which grants perks based on ability.

It's freely based on an existing mod "Skill based perks" (but then for DLC).

 

When reaching a certain (skill) level, the script grants a perk and gives the player a message through the messagebox.

But for some reason GECK want me to add a variable (sometimes two) to the messagebox. It also thinks the message is a script.

 

I'm using the latest GECK and the beta GECK Power 14 (to see why my script wouldn't save).

 

Here's the code:

ScriptName XSpecialPerksHHSCRIPT

int xLEVEL

int xEXPLOSIVES
int xGUNS
int xSURVIVAL	

begin GameMode

set xLEVEL to player.GetLevel

set xGUNS to player.GetPermAV Guns
set xEXPLOSIVES to player.GetPermAV Explosives
set xSURVIVAL to player.GetPermAV Survival

;-----------------------------------------------------------------------LEVEL9

if xLEVEL >= 9

	if xGUNS >= 54
		if xEXPLOSIVES >= 24
			if player.HasPerk NVDLC02Grunt == 0
				player.AddPerk NVDLC02Grunt
				ShowMessage XSpecialPerksHHMSG001
			endif
		endif
	elseif xSURVIVAL >= 84
		if player.HasPerk NVDLC02HomeOnTheRange == 0
				player.AddPerk NVDLC02HomeOnTheRange
				ShowMessage XSpecialPerksHHMSG002
		elseif player.HasPerk NVDLC02TribalWisdom == 0
				player.AddPerk NVDLC02TribalWisdom
				ShowMessage XSpecialPerksHHMSG003
		endif
	endif

endif

;------------------------------------------------------------------------
end

 

And here's a screenshot of the GECK with the error: Here

Link to comment
Share on other sites

Open your MessageBox. Look for a % delete the entire series of characters between that and the next space. Do this for all message boxes. Edited by Glenstorm
Link to comment
Share on other sites

Open your MessageBox. Look for a % delete the entire series of characters between that and the next space. Do this for all message boxes.

Thanks! That was the problem indeed!

Sort of makes sense now I think of it :)

 

Problem solved!

Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...