• Just a reminder that providing specifics on, sharing links to, or naming websites where ROMs can be accessed is against the rules. If your post has any of this information it will be removed.
  • Ever thought it'd be cool to have your art, writing, or challenge runs featured on PokéCommunity? Click here for info - we'd love to spotlight your work!
  • It's time to vote for your favorite Pokémon Battle Revolution protagonist in our new weekly protagonist poll! Click here to cast your vote and let us know which PBR protagonist you like most.
  • 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.

Help with Healing-Script

  • 68
    Posts
    9
    Years
    Hello everyone,

    I'm pretty new to ASM and I need help with a Healing-Script that is activated everytime, when the Player steps on a specific tile.

    The script should work as follows:
    1. Player steps on a tile
    2. SetHealing-Place Hack is activated
    3. Player's Pokemon get healed (Fanfare + Black Screen)
    4. A small message is displayed that the Pokemon are healed
    5. End

    Here's my script:

    #dynamic 0xA30000

    #org @start
    lock

    setvar 0x5037 0x1903
    setvar 0x5038 0x5
    setvar 0x5039 0x6

    special 0x0
    fadescreen 0x1
    fanfare 0x0105
    waitfanfare 0x0
    pause 0x10
    fadescreen 0x0
    special 0x182

    msgbox @flowerheal 0x6

    release
    end

    #org @flowerheal
    = This Flower has a healing effect.\pYour injuries were healed.


    When I insert the script as follows, the Player is freezed when stepping on the tile.

    Thank you very much!

    Best regards,
    Xero3
     
    @Asith thank you very much :)

    I wasn't sure if I needed to assign a Var-Number in A-Map as there's no if-condition in my script.

    It now works, when stepping on the tile, but there seems to be an issue with the SetHealing-Place Hack:

    When entering the next map and losing there, the player gets warped to a map near Celadon City, not to Route 1 as intended.

    I checked the map- & bank-nr. and they are correct (Route 1 = 3.19 -> 0x1903). I used the SetHealing-Place hack 2 other times and there it worked.

    Do I need to add the Variable (4007) into the Script too?
     
    @Asith thank you very much :)

    I wasn't sure if I needed to assign a Var-Number in A-Map as there's no if-condition in my script.

    It now works, when stepping on the tile, but there seems to be an issue with the SetHealing-Place Hack:

    When entering the next map and losing there, the player gets warped to a map near Celadon City, not to Route 1 as intended.

    I checked the map- & bank-nr. and they are correct (Route 1 = 3.19 -> 0x1903). I used the SetHealing-Place hack 2 other times and there it worked.

    I'm not too familiar with the sethealingplace hack but it's likely that you have to convert the map numbers to Hex in the script. Map 3.19 should PROBABLY be 0x1303 (19 is 13 in Hex). The 0x1903 you used in your script when converted back into Decimal would give us map 3.25 - the erroneous map near Celadon you were talking about.

    Do I need to add the Variable (4007) into the Script too?
    The variable you assigned to the script tile in advance map? No - if you want this healing script to work forever you shouldn't change that variable ever. Essentially, you've told the game to run that script when the player walks on that tile as long as the variable 4007 is 0 (Var value in advance map). If you change the value, the game won't use that script tile (useful for turning off scripts!)

    Hope this helps :)
     
    @Asith thanks, it works now perfectly. I didn't knew that the map- and bank-nr. had to be converted into hex. The 2 times I already used the SetHealingPlace-Hack was with Maps that had small numbers like, 5.4 & 4.1. Those being the same in Hex.

    I was thinking the same thing about the Variable, but yeah I wasn't sure if that could resolve the problem, bc as of my current state, the variables Values don't change, so Lv.2 Scripts are always activated, which is not what I want only the script above should work forever. But I guess, that's a problem I'll resolve with my developer once his assignments were over.

    So thanks a lot for your help :) !!!
     
    how do I get the sethealing place hack to work? Ive even tried to replicate you script and the hack will now work. I have cfru and dpe.
     
    Back
    Top