General FreeSpace > FreeSpace & FreeSpace Open Support

FS Picky About Variables

(1/1)

Trivial Psychic:
So I've been playing through various TBP campaigns, and have been thoroughly enjoying the Fortune Hunters.  I've been playing on latest Nightly builds, but when I get to the 4th mission in 2261 (the "0" mission doesn't count), I get a "Failed to Load" error.  I ran a debug build and got the following error, enhanced slightly from the better details provided by the error message FRED gave me:

Error in mission event "Explosions Random":Not a Number

Warning: Not a number.

In sexpression: ( every-time-argument
   ( random-multiple-of
      "exp04.eff"
      "exp06.eff"
      "exp20.eff"
      "exp05.eff"
      "P_moon4"
      "P_moon4"
      "P_moon4"
   )
   ( true )
   ( modify-variable
      @bank[0]
      ( rand-multiple 0 359 )
   )
   ( modify-variable
      @heading[0]
      ( rand-multiple 0 359 )
   )
   ( modify-variable
      @Pitch[0]
      ( rand-multiple 0 359 )
   )
   ( modify-variable
      @eff[<Default Value>]
      <argument>
   )
   ( modify-variable
      @Size[15]
      ( rand-multiple 8 26 )
[...]
(Error appears to be: <argument>)
File: missionparse.cpp
Line: 6117

From the looks of it, it doesn't like <argument> as a number.  I looked up the variable "@eff" and it's a string variable so it shouldn't be complaining anyway.  I did a check through earlier Nightlies and found that this bug (assuming it is) was introduced in time for the October 30th build.  The Oct. 28th build doesn't complain.

0rph3u5:
I think, that's an old FRED bug with the modify-variables SEXP saving the modification for string variables wrongly (it has been fixed) - the fix for a mission saved incorrectly like that, is to add quotation marks manually to the SEXP via text editor, and then the mission should work correctly again

EDIT: That's how modify-variable applied to string variable should look like

--- Code: ---      ( modify-variable
         "@Loadout_G3S2[MX-50]"
         "<argument>"
      )

--- End code ---

Navigation

[0] Message Index

Go to full version