User Tag List

Results 1 to 5 of 5

Thread: [2.51+] Fix Bitmaps Persisting?

  1. #1
    Mad, Mad, Author ZoriaRPG's Avatar
    Join Date
    Oct 2006
    Location
    Prydon Academy
    Posts
    750
    Mentioned
    67 Post(s)
    Tagged
    1 Thread(s)
    vBActivity - Stats
    Points
    2,895
    Level
    17
    vBActivity - Bars
    Lv. Percent
    46.37%
    Daily Activity
    0%
    Weekly Activity
    31.23%
    Monthly Activity
    40.94%

    [2.51+] Fix Bitmaps Persisting?

    This is a 'should be do it' type of question, and debatable.

    At present, when you exit a quest (but not ZC), any bitmaps in memory are not cleared. This means that the next quest to load can potentially draw these bitmaps, and unintentionally.

    Say that quest A had written to b itmap 1, and quest B tries to write to bitmap1, and draw it tot he screen. Whatever datum was written to it by quest A, persists, and will be written by quest B. That is, unless the quest author knows to clear them first with Init and OnContinue.

    As far as I know, no quest has used this as a 'feature', and I have warned several scritpers against [I]ever[I] doing this, and I believe we should do something about it.

    Clearly, the simplest solution is to wipe all bitmaps on quest load. IDK how this will affect user-generated bitmaps either. I think those will be destroyed on quest exist, but only @Gleeok can answer that, as he wrote those.

    Another solution, is to allow the user to statically save user bitmaps with the quest file. This would be ideal, but I do not know if it is practical. Then, system bitmaps (stock 2.50 bitmap pointers) can be wiped, but the user can stills ave some bitmaps perpetually. This would speed up complex draws that occur regularly, so that they need on be set up one time. They could even be set up in such a way that they are embedded in the quest, but likely they will need to be in the .sav file.

    The third option, is to do nothing, which may well result in bizarre quest bugs in the future. I feel this is a bad idea.

    Whichever we choose, we need to determine of the behaviour that we change carries backward--this meaning, if it only affects quests on 2.51+, or if it also affects 2.50 quests. There is a very small chance of a backward-compatibility concern with wiping bitmaps, and again, I know of no quest that uses this bug/oversight for any kind of speed advantage, Obviously, whatever we do, we need only clear stuff when the quest fully exits, not merely on retry/continue. Clearing on those, IMO, would be a bad idea, as there is no reason that the quest author shouldn't prefabricate bitmaps to use on retry/continue.

    What are all of your thoughts on this matter?


    Script Headers: RPG.zh ( v. a0.97.1 ) ( RPG.zh Thread ) | stdArguments.zh (v.6.9.9/1) | | Timers.zh (v.1.5)
    ZScript | ZC Dev | ZC 2.53 | Alucard's: stdCombos.zh (v1.1) | stdWeapons.zh | particles.z
    All of the code that I create and publish here is free for use, modification and distribution under the GPL v2.0.

  2. #2
    Developer ZC Developer
    Gleeok's Avatar
    Join Date
    Apr 2007
    Posts
    4,594
    Mentioned
    202 Post(s)
    Tagged
    8 Thread(s)
    vBActivity - Stats
    Points
    12,085
    Level
    32
    vBActivity - Bars
    Lv. Percent
    30.23%
    Daily Activity
    79.14%
    Weekly Activity
    48.7%
    Monthly Activity
    33.49%
    I'm pretty sure I already fixed it, along with some other stuff. I just haven't committed anything yet, or maybe I did and it got deleted, idk, I can't remember yesterday right now.

    I definitely won't save them to the quest file though; I know we already had this discussion.
    This post contains the official Gleeok™ seal of approval. Look for these and other posts in an area near you.

  3. #3
    Administrator DarkDragon's Avatar
    Join Date
    Oct 2001
    Posts
    6,105
    Mentioned
    40 Post(s)
    Tagged
    0 Thread(s)
    vBActivity - Stats
    Points
    10,501
    Level
    30
    vBActivity - Bars
    Lv. Percent
    44.46%
    Daily Activity
    0%
    Weekly Activity
    90.82%
    Monthly Activity
    39.65%
    Data leaking from one quest to the next is obviously a bug. The bitmaps should be wiped (sounds like gleeok did this already).

  4. #4
    Developer ZC Developer
    Gleeok's Avatar
    Join Date
    Apr 2007
    Posts
    4,594
    Mentioned
    202 Post(s)
    Tagged
    8 Thread(s)
    vBActivity - Stats
    Points
    12,085
    Level
    32
    vBActivity - Bars
    Lv. Percent
    30.23%
    Daily Activity
    79.14%
    Weekly Activity
    48.7%
    Monthly Activity
    33.49%
    I was putting stuff off until after the holidays, but now I've been sick all week.
    This post contains the official Gleeok™ seal of approval. Look for these and other posts in an area near you.

  5. #5
    Ara? Mitsukara's Avatar
    Join Date
    Jul 2000
    Location
    -15 penalty to all intuit direction checks
    Age
    28
    Posts
    3,920
    Mentioned
    8 Post(s)
    Tagged
    0 Thread(s)
    vBActivity - Stats
    Points
    3,361
    Level
    18
    vBActivity - Bars
    Lv. Percent
    64.08%
    Daily Activity
    0%
    Weekly Activity
    0.41%
    Monthly Activity
    1.13%
    One thing this made me think of that could be kinda cool, would be if you could deliberately save a small external file in a quest via scripts (Like saving a .txt file mid-play from ZC, basically) and then load such files in another quest- maybe even have the external file contain a readable variable array that either quest can read/write from. That would be a really cool way to set up things like Oracles-esque linked games, or weird instructions for sequels or connected reactive storylines that track how you did things, etc.

    I realize that's a little off-topic from the subject of clearing bitmaps, but, it might be neat to have a deliberate way to carry data from one quest to another, and this is what made me think of it.

    The Legend of Zelda: The Inverse Mirror supporter

    Behold, ye Banner of Gannons! Behold the power of regional changes and despair!

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