User Tag List

Results 1 to 5 of 5

Thread: Random Behaviour from 'int onSaveMapPic()'

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #3
    The Timelord
    QDB Manager
    ZC Developer

    Join Date
    Oct 2006
    Location
    Prydon Academy
    Posts
    1,396
    Mentioned
    112 Post(s)
    Tagged
    1 Thread(s)
    vBActivity - Stats
    Points
    4,767
    Level
    21
    vBActivity - Bars
    Lv. Percent
    70.16%
    Quote Originally Posted by Saffith View Post
    It's because of the call to loadscr(). It loads the screen to draw into tmpscr[1], which is where the screen being scrolled from is stored.
    That's presumably also why F5 is disabled in caves and item rooms - there, tmpscr[1] is the screen you return to.
    Oh, dear. Very well, I'll have a look at that and make some safer swap space in general for it. IDK why it was designed to share these resources at all. In fact, it seems as if it could just have locals, that exist until the function exits, but perhaps there's a reason that wasn't done, that I don't know about.

    ( I hadn't tracked back where else loadsxr() was used that might conflict. I did track back the palette setting functions, to ensure that it wasn't those, and then I was hit by this server nightmare. )

    I can't imagine that it writing to temp_buf, as it does, is safe, either, FWIW.

    TY Saffith.

    P.S. Do you think that either of these could be linked to it randomly pausing or triggering things? I'll look at loadscr() tomorrow, but I can't imagine that doing anything that'd pause the game, unless somehow for a frame it invalidates some ptr and doesn't know what to do with itself, but that'd usually just crash.

    If after safety-netting this, it still does it, I guess it's time for more robust debugging. Part of me wants to fix this to read cset2 values at the same time, because nothing does that properly. Nothing at all.

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