Jump to content

CTD script problem


Recommended Posts

So I have this quest script that crashes to desktop every time I come near an object that calls a getdistance check on me which runs through the quest script. Any ideas why this is happening? I can't seem to find what is causing the crash

 

scn CRBankBreakInScript

short QuestUnlockstate
short BankRobbed

short checkloanonce
short checkvaultonce
short checkaccountonce

short Robberywaittime

short chestevidence
short myvaultchecked

Begin GameMode

if chestevidence == 0
if CRBankJobChest.getdistance player <= 50
	setstage CRBankBreakIn 12
	set chestevidence to 1
endif
endif

if myvaultchecked == 0
if CRMyVaultMark.getdistance player <= 50
	Messagebox "Well seems like my vault was ransacked as well, no surprise there, but now it's personal"
	set myvaultchecked to 1
endif
endif


if checkloanonce == 0
if CRloanrepaid == 1
	set questunlockstate to questunlockstate + 1
	set checkloanonce to 1
endif
endif

if checkvaultonce == 0
if CRaccountopen == 1
	set questunlockstate to questunlockstate + 1
	set checkvaultonce to 1
endif
endif

if checkaccountonce == 0
if CRaccountopened == 1
	set questunlockstate to questunlockstate + 1
	set checkaccountonce to 1
endif
endif

if questunlockstate >= 2
if Bankrobbed == 0
	set robberywaittime to gamedayspassed
	set bankrobbed to 1
endif

if bankrobbed == 1
	if gamedayspassed == robberywaittime + 10
		; enable alternate vault area and Madras Gerebaldi
		CRMadrasREF.enable
		CRSgtFerdinandREF.enable
		CRBankPortal.disable
		CRBankRobbedPortal.enable
		set bankrobbed to 2
	endif
endif
endif

end

Link to comment
Share on other sites

  • Recently Browsing   0 members

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