News:

Don't forget to visit the main site! There's lots of helpful docs, patches, and more!

Main Menu

New types of bombable blocks

Started by Odb718, January 13, 2017, 06:02:57 PM

Previous topic - Next topic

Odb718

I've been trying to find a way to get 2 new bombable blocks.
Messing around with the new structure and structure editor in Editroid, I've been making odd blocks and testing them out.
One cool feature I've found is the combination of Solid and shootable blocks can actually have different effects.

I've made 2 unique blocks. I'm not sure if any other hack has these or not.
the first block
12 8D
14 8F
can not be broken from the right side, and is shootable/bombable from the right. When it respawns, it becomes, I believe,
8C 8D
8E 8F

I took it a step further and made
12 8D
12 8D
It worked exactly the same and respawned the same. If 12, and 8C-8F looked identical, you'd have a new block for one tile.

Once the block respawns it can be shot from both sides. So it's an excellent 1 way door. Once you exit the room and reenter the 1 way aspect returns. Wave beam gets around these blocks. It'd be perfect to allow the player to SEE Wave Beam early but make it unreachable. Once obtained you could blast away the blockade.

One way you could use these blocks as a type of block found in Super Metroid would be to make a fall through-esq block
You could set the block up to be
8C 8D
12 13
Being able to bomb thru, but reentry to the room wouldn't allow you to get back up. Starting from below wouldn't allow you to get through. If you made the space small enough wave beam wouldn't be usable.


Flower mentioned to me in another thread that block
7C 7D
7E 7F
could be destroyed and it wouldn't spawn again. Testing this out in my Samus.nes never worked. I could never destroy it. After working on this experiment it seems like this block has a hidden attribute that may be able to be exploited.
This effect only happens in Brinstar!

What happens is, when the game is first loaded the block is able to be destroyed. Once Samus goes down an elevator it looses that ability and becomes a permanent block. This effect doesn't seem to happen in any of the other areas. Going from Brinstar to Kraid, back to Brinstar stops the effect there, going back down to Kraid the block there still can be destroyed. Going from Norfair, to Ridley, to Norfair, to Ridley has no effect on the blocks in either of those areas.
If you go from Norfair to Brinstar the block is unbreakable in Brinstar. Same thing Tourain>Brinstar. 

You could use this block as a No Going Back block. However, there's a work-around for even that. If you Start+UpA and reload Brinstar, the block can be destroyed again.

I may load up Cheat Engine and try to find the pointer or code responsible for this behavior.

If anyone knows how to get other behaviors from blocks, post them here.
We could make this a collection of different tricks and techniques.





snarfblam

There is a table that defines how each breakable block will reform. (Why they didn't just grab this info from the original block before it breaks, I don't know.) I took a quick look the other day and couldn't locate it, but I do know it's in the level data banks (a separate table for each area). Basically, if a breakable block isn't reforming the way you wanted, it's because it's not listed in the table. I'll try to remember and take a closer look later on when I have time, see if I can dig it up.

Odb718

#2
So using cheat engine, I've found the address that lets me lock it, or destroy it.
0277012C is the offset.
bomb blastable = 16711936  No Blast = 285148672
are the values for 4Byte Big Endian.

And for a base to go off of,
0294F1D8 = missiles.
027701BF = Energy 10 slot
027701BE = Energy 1  slot

Do you think you'd be able to fix this bug?
Do you think it'd be possible to use this bug in other things?
Like if you got a power up, could it lock the blocks? Even on a reset/reload?

---- ----
JACKPOT SNARFBLAM! JACKPOT! Get it... 777 posts. JAaaaaackpot. lol


----
I'm using Cheat Engine, My Samus.nes, and Nestopia. I'll try to test these values on vanilla Metroid now.
On vanilla Metroid the block's destroy number was
0271012C
028EF1D8 = missiles
027101BF = energy 10s slot
027101BE = Energy's 1 slot

The starting value that let me break the block was different. But my lock out value worked. I reset to my original breakable value, and I could break the block.

Odb718

With Snarf's guidance I figured out how to edit the block to be breakable once you come back from other areas.
It's a pretty simple edit with FCEUX.
RUN FCEUX AS ADMINISTRATOR! Mine messed up without it.

Open the game, Pause it.
Debug>Debugger
in SeekTo box put D651
You should see something like
0F:D651:A4 74     LDY $0074 = #$FF
at
0F:D65B:C9 80     CMP #$80
Click on the left to bring up the inline assembler box. Just the gray area at the line.
type
CMP #$70
and press enter to get the code to go in the box below. Hit apply.

At this point you'll be able to test inside your hack by unpausing and playing. All of the line 70-7F will be shootable once you come back to brinstar. I've only changed mine from CMP #$80 to CMP #7C which is the last block. The other 3 blocks are just weird, but hey, you might find something to do with them.

to Save it once you know it works,
Debug > hex editor
View >Rom file
File>Save Rom As

Let me know if it works or you have problems