I was working on a prototype scene that needed a bridge and noticing a few things. Some videos demonstrate the player going under the bridge or on it using events or a tileset change for the bridge.
I wanted to see if I could get an event to hang with the player as well in the case of moving items across the bridge (as demonstrated) or if there were enemies/npcs that walk below/on the bridge as well (possible mechanic for later).
What started as a prototype became a rabbit hole of digging through the code and finding out more about priority, tileset flags, and tile IDs.
Currently, here is what I have.
Custom Bridge code (script calls at the moment, will create functions/common events for it when finalized) using tileset and manipulating priority/Z. Also, demonstrating a push and pull mechanic with a button (sphere) or without (snowball) being prompted to move or pickup the events.
It may not seem like much, but the differences here are:
- Only events controlling the tileset - the bridge is not made up of many events and the tileset does not change (the code does, but the tileset remains)
- You can move events under and over the bridge
- You only interact with events on the bridge when you are on it, or off the bridge when you are off it
- You can leave events on the higher tile
- You can target specific tiles and change their configuration
Took me a while to get it all organized, but it is definitely worth it. Now, I can have "enemies" below me and they won't interfere, or vice versa.
Currently working on:
- getting better interaction priority-level separation (allowing only characters on the same priority to interact without always using a conditional statement)
- tileset priority and direction limits affecting certain events only without using "through" setting (still working on this, assuming it is currently possible for me at the moment)
The scene demonstrates a bridge with over/under action, push/pull mechanic with button interaction, push mechanic with movement only (no initial button press to interact), and tile/data changes with a global map reset.
Also, I threw in Chrono Trigger's End of Time because... it fits and I was inspired to keep working through the code when I was listening to it, haha. I'll likely compose my own bgm for this if I end up using this prototype scene for a project.
Thanks!
I wanted to see if I could get an event to hang with the player as well in the case of moving items across the bridge (as demonstrated) or if there were enemies/npcs that walk below/on the bridge as well (possible mechanic for later).
What started as a prototype became a rabbit hole of digging through the code and finding out more about priority, tileset flags, and tile IDs.
Currently, here is what I have.
Custom Bridge code (script calls at the moment, will create functions/common events for it when finalized) using tileset and manipulating priority/Z. Also, demonstrating a push and pull mechanic with a button (sphere) or without (snowball) being prompted to move or pickup the events.
It may not seem like much, but the differences here are:
- Only events controlling the tileset - the bridge is not made up of many events and the tileset does not change (the code does, but the tileset remains)
- You can move events under and over the bridge
- You only interact with events on the bridge when you are on it, or off the bridge when you are off it
- You can leave events on the higher tile
- You can target specific tiles and change their configuration
Took me a while to get it all organized, but it is definitely worth it. Now, I can have "enemies" below me and they won't interfere, or vice versa.
Currently working on:
- getting better interaction priority-level separation (allowing only characters on the same priority to interact without always using a conditional statement)
- tileset priority and direction limits affecting certain events only without using "through" setting (still working on this, assuming it is currently possible for me at the moment)
The scene demonstrates a bridge with over/under action, push/pull mechanic with button interaction, push mechanic with movement only (no initial button press to interact), and tile/data changes with a global map reset.
Also, I threw in Chrono Trigger's End of Time because... it fits and I was inspired to keep working through the code when I was listening to it, haha. I'll likely compose my own bgm for this if I end up using this prototype scene for a project.
Thanks!