(Link to AcmlmWiki) Offline: thank ||bass
Register | Login
Views: 13,040,846
Main | Memberlist | Active users | Calendar | Chat | Online users
Ranks | FAQ | ACS | Stats | Color Chart | Search | Photo album
06-03-24 10:32 AM
0 users currently in SMW Hacking.
Acmlm's Board - I3 Archive - SMW Hacking - OW sprite question (about ghosts, specifically)
  
User name:
Password:
Reply:
 
Options: - -
Quik-Attach:
Preview for more options

Max size 1.00 MB, types: png, gif, jpg, txt, zip, rar, tar, gz, 7z, ace, mp3, ogg, mid, ips, bz2, lzh, psd

UserPost
SnifflySquirrel
Posts: 53/80
Thanks for finding that code, BMF. I'll have to double-check the event number I'm using, but this helps a lot. Thanks again.
BMF54123
Posts: 427/876
Well, I figured it out. The sprite checks to see if events 2B or 2E have been passed (both of which lead to the Ghost House in the original game), just as Smallhacker said.

Event flags are stored in a table at $1F02-$1F10. Each byte holds 8 flags. Bit 7 is the lowest-numbered event, while bit 0 is the highest (for example, at $1F03, bit 7 = event 08, bit 0 = event 0F). The Boo sprite first checks whether or not it's on a submap and in sprite slot C. If it is, it then loads $1F07 (events 28-2F), ANDs it with #$12 (00010010 = events 2B and 2E), and then branches if the result is not zero (i.e. one of the flags are set), which displays the sprite.

If you want to fix this, the event flag address ($1F07) is at $27F86, and the checked flags (#$12) are at $27F89. If you want the sprite to show up no matter what, change $27F8A to 80.
Smallhacker
Posts: 563/832
My experiments shows that all that matters is the event number. The ghost originally placed in Forest of Illusion only becomes visible when event 2B or 2E is activated. The level tile revealed or the ghost's coordinates or submap won't affect anything.
BMF54123
Posts: 426/876
Wow, I never even noticed that. Craaaaazy!

*BMF54123 X does a little digging
Alastor
Posts: 5598/8204
... Which is exactly what I said.
Mike O'Shay
Posts: 105/136
Ah. I see, now. My bad.

He's trying to do the exact opposite of what I'm trying to help him with, isn't he?
It's showing up and he doesn't want it to. *Sigh* Sorry, can't help you. *Leaves*
Kingpin
Posts: 306/709
Yeah, if that was his problem, that would work, but thats not his problem.
Mike O'Shay
Posts: 104/136
Sorry, I understood it as "I'm having trouble trying to get the ghost to appear around a tile that's not supposed to be shown yet, but the ghost won't appear until the tile appears."

I was just trying to suggest that it might work if he made an actual "revealed" ghost house made entirely of black pixels (The type that don't show up in the game), then he set it to change after the event that was supposed to "reveal" it appeared. I don't know WHY it's not showing up in his Forest, I was simply trying to provide a (probably not) possible solution.
Alastor
Posts: 5592/8204
I don't think you understood the question =/
Mike O'Shay
Posts: 103/136
Have you tried adding a new tile to the OW, which is an invisible ghost house? I mean one that would count as "Revealed", so the ghost would show up, but it wouldn't actually appear on the map?

If you do that, then you set a regular ghost house to appear after an event, it could work.
Alastor
Posts: 5585/8204
To my knowledge, that's pretty much impossible without coding it yourself. That ghost in that position may have been hardcoded to appear after a certain event.
SnifflySquirrel
Posts: 52/80
In the original Super Mario World, the submap ghost in the Forest of Illusion doesn't appear until the ghost house it floats around does. I'd like to accomplish this effect in my hack, but on the Valley of Bowser submap. (Also, the ghost isn't floating around a ghost house... it's supposed to be a super-secret level, so I'll just leave it at that.)

I experimented a little, and just placing a ghost around an unrevealed level tile doesn't work--the ghost will still show up before the tile is revealed, even if it's a ghost house. (I tried this on Yoshi's Island, in case you're curious.) I'm guessing there's an exception in the submap ghost code for the Forest of Illusion, but I don't even know where to start looking for that code.

So I guess my question is--does anyone here know anything about the overworld map's sprite code? Or whether there's a simpler way of doing what I'm trying to do?
Acmlm's Board - I3 Archive - SMW Hacking - OW sprite question (about ghosts, specifically)


ABII

Acmlmboard 1.92.999, 9/17/2006
©2000-2006 Acmlm, Emuz, Blades, Xkeeper

Page rendered in 0.012 seconds; used 352.58 kB (max 396.91 kB)