Are named variables converted to indexed variables like in O

Post » Tue Jun 19, 2012 11:32 pm

Ok so in Oblivion, if you added new variables and shoved one into the middle of some previously defined and utilized variables, it screwed everything up. In other words when you compiled the script, the named vars would just be reduced to indexed number holders. Example:

short FredsAge
Short FredsHealth
short FredsMagicka

Then you come back and decide Fred needs some gold so you add FredsGold and shove it into the 2rd position:

short FredsAge
short FredsGold
Short FredsHealth
short FredsMagicka

By doing this and if you had a save game, FredsGold would hold the value that FredsHealth had, FredsHealth is now whatever FredsMagicka was, and Fredsmagicka would be 0 (because its in a new position that is 0 by default).

Does Skyrim keep indexes on the variables, or can you alphabetize them and insert new variables in the middle of things without messing up your savegames?
User avatar
GabiiE Liiziiouz
 
Posts: 3360
Joined: Mon Jan 22, 2007 3:20 am

Post » Tue Jun 19, 2012 11:37 pm

They aren't indexed anymore, they are stored and http://www.creationkit.com/Persistence_%28Papyrus%29 with the name you declared them with.
User avatar
maddison
 
Posts: 3498
Joined: Sat Mar 10, 2007 9:22 pm

Post » Wed Jun 20, 2012 6:17 am

This documentation is probably more useful: http://www.creationkit.com/Save_File_Notes_(Papyrus)#Properties_and_Script_Variables

Cipscis
User avatar
Jah Allen
 
Posts: 3444
Joined: Wed Jan 24, 2007 2:09 am

Post » Wed Jun 20, 2012 1:13 am

Awesomeness. Thanks!
User avatar
Jesus Sanchez
 
Posts: 3455
Joined: Sun Oct 21, 2007 11:15 am


Return to V - Skyrim