• 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.
  • Our friends from the Johto Times are hosting a favorite Pokémon poll - and we'd love for you to participate! Click here for information on how to vote for your favorites!
  • Serena, Kris, Dawn, Red - which Pokémon protagonist is your favorite? Let us know by voting in our grand final favorite protagonist poll!
  • PokéCommunity supports the Stop Killing Games movement. If you're a resident of the UK or EU, consider signing one of the petitions to stop publishers from destroying games. Click here for more information!
  • 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.

[Map/Script] Need help with boulder-pushing puzzle

  • 1
    Posts
    5
    Years
    • Seen May 31, 2020
    Hello everyone,

    I'm kinda new to rom hacking, but I do have a background in programming and reverse engineering (classical 8086 processors, I still have to delve into gameboy asm).

    I'm working on a rom hack for a personal project and wanted to implement a boulder-pushing puzzle similar to sokoban: what I have is a room with X boulders, and at the end of the room there is a pit exactly X tiles long and 1 tile wide. The player needs to push each boulder into the pit: everytime a boulder is pushed on a pit tile, that pit tile becomes a regular floor tile (and the boulder vanishes). When the player pushes all X boulders he will be able to walk past to the end of the puzzle.

    Spawning the boulder and pusing it is ez pie. I have a couple of issues that come to my mind:

    1. The "pit" tile should be marked as Impassable to the player, but I should still be able to push a boulder into it aka it should not block the boulder
    2. How and when do I check when the player has pushed a boulder into it? Can I put an event script on the tile just preceding the pit tile and that triggers when the player walks onto it, and checks whether there is a boulder on the next tile (the pit tile)?

    If you have any already existing example of this I'll gladly take a look, otherwise I could use some ideas :)

    Cheers
     
    Back
    Top