![]() |
OW Sprite Disappearing
Hi! I'm having an issue with an OW sprite disappearing when I leave the map and then re-enter. I actually have 2 OW sprites, I set the flag for one of them at the beginning of the game, so they're hidden. After some dialogue, I have this:
hidesprite 0x1 setflag 0x202 'flag is assigned to sprite 0x1 clearflag 0x203 'flag is assigned to sprite 0x2 showsprite 0x2 Which works great, my new sprite is there, old sprite is gone. When I leave the map however and then re-enter, both sprites are gone. I assumed once the flag was cleared it would be fine. Any ideas? What am I missing here? |
Try using two showsprites - that's what I do, just to be safe, and it always shows the sprite correctly =)
so; hidesprite 0x1 setflag 0x202 showsprite 0x2 clearflag 0x203 showsprite 0x2 Try that! =) |
Quote:
|
Are you sure the map doesn't have a level script to hide person 0x2?
|
hidesprite 0x1
setflag 0x202 showsprite 0x3 clearflag 0x203 showsprite 0x3 Maybe you are using event n° and not people n° so the 0x2 will be 0x3. But normally your original script is good. |
Thanks everyone. I figured it out. I probably should have mentioned that I was using a variable to set the flag, which apparently doesn't work. Although I'm not sure why it wouldn't... Doesn't this make sense?
setvar 0x40F6 0x200 setvar 0x40F7 0x201 hidesprite 0x1 setflag 0x40F7 showsprite 0x3 clearflag 0x40F6 showsprite 0x3 |
Quote:
To control visibility, you need to assign the Person event's Person ID in Advance Map to be the flag that, when set, will hide them. For example, to hide this Person event: http://i.imgur.com/2T1X0Xe.png You would need to put the following in a script: hidesprite 0x1 setflag 0x2A1 And, to show it, you'd do: clearflag 0x2A1 showsprite 0x1 Also I'm not sure why it's been suggested to use the showsprite command twice; you only need to use it once, after the flag has been cleared. I hope that helps. I'd recommend reading through this document to get a better understanding on the distinction between flags and variables and how to safely use them. |
| All times are GMT -8. The time now is 2:24 AM. |
![]()
© 2002 - 2018 The PokéCommunity™, pokecommunity.com.
Pokémon characters and images belong to The Pokémon Company International and Nintendo. This website is in no way affiliated with or endorsed by Nintendo, Creatures, GAMEFREAK, The Pokémon Company or The Pokémon Company International. We just love Pokémon.
All forum styles, their images (unless noted otherwise) and site designs are © 2002 - 2016 The PokéCommunity / PokéCommunity.com.
PokéCommunity™ is a trademark of The PokéCommunity. All rights reserved. Sponsor advertisements do not imply our endorsement of that product or service. User generated content remains the property of its creator.
Acknowledgements
Use of PokéCommunity Assets
vB Optimise by DragonByte Technologies Ltd © 2023.