I save the .j file. I import the .j back into the file. I go test. I get .j file error.
I'm thinking it's something to do with "CheatsEnabled" being an array. I don't know much about using globals, but is there a way in globals to show that it is an array?
Or is there any other thing that makes it crash?
Thanks in advance.
Re: Imported .j getting errors.
Posted: December 6th, 2009, 11:28 am
by Bushido
That's not really a cheatpack, xD. The commands are missing, nothing is triggered. It's useless.
Re: Imported .j getting errors.
Posted: December 6th, 2009, 7:32 pm
by Ken
Both problems are in your globals. CheatsEnabled should be declared as "boolean array CheatsEnabled", and have a function that runs on map initialization to set all indexes (1-12) to false.
And also, Enabled should be declared as "trigger gg_trg_Enabled=null".
Re: Imported .j getting errors.
Posted: December 7th, 2009, 10:44 am
by Manstie
FatherSpace wrote:Both problems are in your globals. CheatsEnabled should be declared as "boolean array CheatsEnabled", and have a function that runs on map initialization to set all indexes (1-12) to false.
And also, Enabled should be declared as "trigger gg_trg_Enabled=null".
Okay. Thank you! By the way, aren't boolean always false until set otherwise? FFS! Not working... I give up... Can you look over the triggers again to see whats wrong? Yes, I did change the globals. I'm using the MPQ editor from http://deprotect.nathanmx.com/ , will it make a difference?
Tupac Shakur wrote:That's not really a cheatpack, xD. The commands are missing, nothing is triggered. It's useless.
It's not meant to be a cheat pack SO FAR. I was just posting my activation string as an example of what I place into the .j file to cheat the map. The cheats will be added later.
Re: Imported .j getting errors.
Posted: December 7th, 2009, 4:27 pm
by Ken
Oh, I think I may have forgotten to mention... In the trigger actions, you're trying to set udg_CheatsEnabled, when it's declared without the udg_ prefix.
Also, do you have a call to the init from function main, or somewhere that runs on map initialization?