Help with Script for game (Blocks that obey gravity)

codingkid01

Member
Hi, I am making a game for the byte off competition and i need help with a script for my game.
In my game, the player pushes crates that can be dropped onto enemies or used as a staircase. however, i cannot find a script that can do that. Does anyone know how i can do this? if so, it would be greatly appreciated. Thanks!
 

dale_coop

Moderator
Staff member
This is not simple to implement. And this doesn't exist in NESMaker... (until someone makes scripts + tutorial for that).
The solid background tiles, can not be moved. Only the objects... But because the hardware limitations, you can't have a lot of objects (sprite) at same time, on screen.
A solution would be en collision with the block tile to change the tile to an empty one and create an object at the exact same place (that would look exactly like the tile)... that you could push (that doesn't exist, so would need to be implemented too). Then when you stop pushing, it will be destroyed and change the background...?
A lot of work...
 

codingkid01

Member
I do think it is possible as im pretty sure there were movable blocks in the ledgend of zelda on nes, where you moved blocks out of the way, and also in donkey kong jr on the nes, you dropped fruits onto enemies, so maybe alternatively I could make the crates monsters that dont hurt you and every time the player collides with it it moves the monster in the direction of the player and when it hits a monster both monsters die.
 

dale_coop

Moderator
Staff member
I don't say it's not possible. I just want to say it's not implemented in NESMaker. So someone would have to code all that.
It would require some hours/days( weeks?).
But yeah, everything is doable in NESMaker... just need to code it if not implemented (yet) ;)
 

Ryusui

New member
It might be worthwhile to open up The Legend of Zelda or Super Mario Bros. 3 in FCEUX or other debugging emulator and see just how movable blocks are implemented in those games.

I'll admit, the very first thing that came to mind when I saw the thread title was SMB3's dreaded Donut Blocks - considering how they were often arranged in long rows, I imagine they were quite tricky to implement without causing massive amounts of flicker!
 
Top Bottom