Local variables, or any varibles for that matter

Discuss the creation and scripting of new fan-made games and mods for the Fallout series of games.
Post Reply
User avatar
Foot Soldier
SDF!
SDF!
Posts: 5
Joined: Thu Oct 14, 2004 8:02 pm

Local variables, or any varibles for that matter

Post by Foot Soldier »

I can not get any saved varibles to work. I have tried LVARs, MVARs, and GVARs.

I tried using the existing value, LVAR_Herebefore. I used the functions like I saw other scripts, set_local_var(LVAR_Herebefore, 1); But then I tested it and it does not change the value.

In the scripts it uses these all the times and they seem to work, how come they don't for me?

For map variables, I used the FSE map variable thing, had the .gam file, the .h file included, and it still would not work. The value was set as 0 in the .gam file, and remained 0 no matter what I did.

Do local variables work for you? Any tricks to get them to work?


Also, how do local varibles work? Im guessing that the #define LVAR_ is just for a refrence number, and somewhere is a list of values that are saved? If this is so, what are 1, 2, and 3 reserved for? All the ones I see seem to be 0, 4, 5, etc...

Incase you guys are just as clueless about this as I am, I will keep looking for the answers, and report back if i get anything done.
User avatar
ColJack
Vault Scion
Vault Scion
Posts: 175
Joined: Sat Apr 19, 2003 8:01 pm
Contact:

Post by ColJack »

are you trying thr script out in the game or the mapper?
because the mapper doesn't deal with variables in scripts very well.. unless you change the line in the mapper2.cfg that says "run_mapper_as_game" to 1..
it's something to do with it not setting up the variables properly...

the #define just defines the text lable LVAR_xxx as the number you set.

i think the number of lvars for a script need to be set in the scripts.lst file
Our Host!
Post Reply