• Our software update is now concluded. You will need to reset your password to log in. In order to do this, you will have to click "Log in" in the top right corner and then "Forgot your password?".
  • Welcome to PokéCommunity! Register now and join one of the best fan communities on the 'net to talk Pokémon and more! We are not affiliated with The Pokémon Company or Nintendo.

[Other] Hide Sprite

23
Posts
9
Years
  • Hello, I've got a problem :|

    I'm trying to keep my sprite hidden until a flag is active. But I can't figure out how to do it.

    What I want to do:
    Sprite is hidden until the flag is activated. (PROBLEM)
    Once active I want the sprite to become visible.
    I then want to battle it, after the battle I want to clear the flag so it becomes invisible again.



    My only problem is having the sprite invisible before the flag is activated.



    Thanks in advanced!
     

    Joexv

    ManMadeOfGouda joexv.github.io
    1,037
    Posts
    11
    Years
  • In an earlier script set a free flag, and make sure that the sprite's person ID is set as the flag.
    Then in whatever script you need him to be shown in, simply clear the flag and if its on the same map, then use a showsprite command.

    But as far as I know, you can't have a sprite hidden until a flag is set, only after its set will it be hidden.

    Hopefully that made sense.
     
    23
    Posts
    9
    Years
  • I assigned this to a script tile at the beginning of the map.

    #dynamic 0x800000

    #org @start

    checkflag 0x1452
    if 0x1 goto @SHOWCHICKEN
    hidesprite 0x9
    release
    end

    #org @SHOWCHICKEN
    showsprite 0x9
    release
    end



    So thank you very much.
     
    1,344
    Posts
    14
    Years
    • Seen Dec 10, 2021
    extend the safe flags?
    I've been using 1200-1500 this whole time for my rom hack because I thought that there should be nothing in them to clash.

    Those flags don't exist, what you're doing by using them is overwriting other memory areas in the ROM. It might appear to work but behind the scenes you're likely slowly breaking the game. Here's a document on safe flags/vars if you're interested.
     

    destinedjagold

    You can contact me in PC's discord server...
    8,593
    Posts
    16
    Years
    • Seen Dec 23, 2023
    Alternatively, you can use a level script in the map to move that NPC away from sight until a certain event is completed.
     
    Back
    Top