Bloody stupid Variables

1
Now, I'm not normally a variables man. I don't like 'em. But the other day, I actually got them to work properly, to do what I wanted them to do. So I was feeling fairly chuffed and in a variable friendly kinda mood. So off I went and tried to use them again. I was then reminded of why I dislike variables so much.

http://tema_al_diablo.tripod.com/images//variables.txt

That's what happens whenever I try to use variables. I go from a nice, neat, Variable and Number setup to this weird, three setting thing, where my variable name is messed up (The variable here was input as Sinew Down), and it's added another, blank thing to the sexp. Obviously, FS2 has no idea what's going on, so the misison doesn't work. It happens the instant I save the mission, and there's no way to fix it short of deleting the entire event. Even if I replace it, then replace it again with the Modify variable thing, I Can't change from the default variable name, and it just reverts to this messed up setting thing as soon as I save anyway.

I remember having this for years, from Vanilla FS FREDding, so I'm assuming it's not a bug the SCPs caused., What I want to know is if there's a way to fix/avoid it, or if the SCP have fixed the bug for 3.6. If it's not a known bug, I'll report it to Mantis, when HLP goes back up, but if anyone else has experienced it, I'd like to know, so we can maybe figure out what causes it - it seems to hit me 90% of the time I use variables, but occasionally (as I said above) they do work for me, seemingly at random.

Oh, and for the record, I'll be able to get this misison done without 'em, I'll just need to do some much more complicated sexping. Which is good, as this variable bug has sent previous missions of mine to their untimely graves.
TI - Coming in 2011 - Promise!
:flag9:
"Everyone has to wear clothes, and if you don't, you get arrested!" - Mr. T

2
I remember getting this bug myself once. In that case since it occured early on I simply diteched the mission and FREDed it again.

This was ages ago using FRED2 and no mods so you're correct that it's not an SCP bug.


YOu could try creating a very basic mission in FRED with working variables and then compare the two in notepad so see if you can track down an errant flag (Who knows maybe fixing the mission in notepad will stop the problem coming back).

4
Meh. I sexped it. It wasn't as complex as I thought it'd be (Involved two transports, and if they were destroyed, or captured by the enemy (as opposed to the GTVA)) then the event fired. Fixed it up relatively simply, but it's still a piss off.
TI - Coming in 2011 - Promise!
:flag9:
"Everyone has to wear clothes, and if you don't, you get arrested!" - Mr. T

5
I discovered what the problem was. Apparently, variables can't have spaces in their names - if they do, FRED splits them onto separate lines in the event. As soon as you save the mission and reload it, FRED sees too many lines in the event and chokes (despite the fact that the variable itself is left intact in memory).

The easiest solution is to not use spaces. If you have a variable whose name consists of more than one word, simply use a hyphen instead of a space.
Fortunes of War
Deus Ex Machina

VWBB Survivor: 12/01-7/04, 130 posts
Post Reply

Return to “FreeSpace”