User Tag List

Page 1 of 2 1 2 LastLast
Results 1 to 10 of 11

Thread: Screen registers (D[])

  1. #1
    Lynel
    ZC Developer
    pkmnfrk's Avatar
    Join Date
    Jan 2004
    Location
    Toronto
    Age
    37
    Posts
    1,248
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    vBActivity - Stats
    Points
    3,142
    Level
    18
    vBActivity - Bars
    Lv. Percent
    10.46%

    Screen registers (D[])

    Are the Screen->D[0] etc. registers saved in a save game? Or, rather, should they be?

    In my testing, they aren't. This is a problem, as there's currently no other way to persist arbitrary variables across game sessions.

    Like, right now, I'm writing a script to control water levels, a la the Water Temple. I thought it would be a nice touch if the water level was saved in a save game, and the only way I thought to do that was to stick the water level in the first screen's D[0] register. But, when I load it up while testing, it's always 0.
    Tale of the Cave - a web comic - Updates Monday, Wednesday, Friday
    ZC Tutorials - Tutorials and Script Library - Updated July 30, 2008
    ZeldaGuard - Corruption in my save files? It's more likely than you think!
    I do script requests!

  2. #2
    Administrator DarkDragon's Avatar
    Join Date
    Oct 2001
    Posts
    6,228
    Mentioned
    70 Post(s)
    Tagged
    0 Thread(s)
    vBActivity - Stats
    Points
    11,028
    Level
    31
    vBActivity - Bars
    Lv. Percent
    8.46%

    Re: Screen registers (D[])

    I think global variables are the only ones which are saved across sessions.

  3. #3
    Lynel
    ZC Developer
    pkmnfrk's Avatar
    Join Date
    Jan 2004
    Location
    Toronto
    Age
    37
    Posts
    1,248
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    vBActivity - Stats
    Points
    3,142
    Level
    18
    vBActivity - Bars
    Lv. Percent
    10.46%

    Re: Screen registers (D[])

    Wait, globals ARE saved?

    ...

    Durrrr. I feel stoopid
    Tale of the Cave - a web comic - Updates Monday, Wednesday, Friday
    ZC Tutorials - Tutorials and Script Library - Updated July 30, 2008
    ZeldaGuard - Corruption in my save files? It's more likely than you think!
    I do script requests!

  4. #4
    Administrator DarkDragon's Avatar
    Join Date
    Oct 2001
    Posts
    6,228
    Mentioned
    70 Post(s)
    Tagged
    0 Thread(s)
    vBActivity - Stats
    Points
    11,028
    Level
    31
    vBActivity - Bars
    Lv. Percent
    8.46%

    Re: Screen registers (D[])

    That's what I remember from discussions with jman quite a while ago - don't trust me on this point until you've tried it out

  5. #5
    Lynel
    ZC Developer
    pkmnfrk's Avatar
    Join Date
    Jan 2004
    Location
    Toronto
    Age
    37
    Posts
    1,248
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    vBActivity - Stats
    Points
    3,142
    Level
    18
    vBActivity - Bars
    Lv. Percent
    10.46%

    Re: Screen registers (D[])

    Well, as it turns out, I hate you forever for lying to me in a malicious manner! They don't save:

    http://zctut.com/test.zip (it's up)

    (it's a QSU since winzip does a better job than ZQuest at compression, and I hate dial-up)

    I also included the script I'm trying to write. It's a bit arcane, how it works, but it does work.

    Except, if you save, and come back, the level state will be back to the default, no matter what state it's in.

    Now, if globals SHOULD be saved, then it's a bug, no?
    Tale of the Cave - a web comic - Updates Monday, Wednesday, Friday
    ZC Tutorials - Tutorials and Script Library - Updated July 30, 2008
    ZeldaGuard - Corruption in my save files? It's more likely than you think!
    I do script requests!

  6. #6
    Administrator DarkDragon's Avatar
    Join Date
    Oct 2001
    Posts
    6,228
    Mentioned
    70 Post(s)
    Tagged
    0 Thread(s)
    vBActivity - Stats
    Points
    11,028
    Level
    31
    vBActivity - Bars
    Lv. Percent
    8.46%

    Re: Screen registers (D[])

    Yes, but I'm worried about old quest compatibility. If someone can confirm that they're indeed suppose to save, go ahead and post a report.

  7. #7
    Octorok Dan Furst's Avatar
    Join Date
    Oct 2005
    Age
    39
    Posts
    368
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    vBActivity - Stats
    Points
    1,501
    Level
    13
    vBActivity - Bars
    Lv. Percent
    9.45%

    Re: Screen registers (D[])

    I have no idea what they were supposed to do, but here's an idea.

    It might sound a little weird, but, what if you introduced a new type declaration called "saved" ?

    You would use it like this:

    saved int a;
    saved bool b;

    This way, old scripts can continue to function normally, and new scripts can use global variables that persist through saves.

    Or am I crazy?

  8. #8
    Administrator DarkDragon's Avatar
    Join Date
    Oct 2001
    Posts
    6,228
    Mentioned
    70 Post(s)
    Tagged
    0 Thread(s)
    vBActivity - Stats
    Points
    11,028
    Level
    31
    vBActivity - Bars
    Lv. Percent
    8.46%

    Re: Screen registers (D[])

    Yes, that would be entirely possible, though I think it needs to wait until post-2.5.

  9. #9
    Lynel
    ZC Developer
    pkmnfrk's Avatar
    Join Date
    Jan 2004
    Location
    Toronto
    Age
    37
    Posts
    1,248
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    vBActivity - Stats
    Points
    3,142
    Level
    18
    vBActivity - Bars
    Lv. Percent
    10.46%

    Re: Screen registers (D[])

    Just out of curiosity, how close are we to 2.5? (Since I know you don't get asked this nearly enough)
    Tale of the Cave - a web comic - Updates Monday, Wednesday, Friday
    ZC Tutorials - Tutorials and Script Library - Updated July 30, 2008
    ZeldaGuard - Corruption in my save files? It's more likely than you think!
    I do script requests!

  10. #10
    Administrator DarkDragon's Avatar
    Join Date
    Oct 2001
    Posts
    6,228
    Mentioned
    70 Post(s)
    Tagged
    0 Thread(s)
    vBActivity - Stats
    Points
    11,028
    Level
    31
    vBActivity - Bars
    Lv. Percent
    8.46%

    Re: Screen registers (D[])

    2.50 will be released "when it's done."
    We don't want a repeat of 2.10.

    I personally have no idea how close we are; every time it seems the bug reports are dying done, a new batch get reported.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
About us
Armageddon Games is a game development group founded in 1997. We are extremely passionate about our work and our inspirations are mostly drawn from games of the 8-bit and 16-bit era.
Social