Views: 959,719,074
21 users online:  Anorakun, autisticsceptile1993, BootaNoBijuu, buggy789, codfish1002, fialhenz, Infinity, Julintendo,  K.T.B., Koopster, l337f00l, Lmao, Lsh0426, Mr. MS, Oskise, Rykon-V73, scratch, Sokobansolver, StackDino, Waluigi69, Wuzzy - Guests: 42 - Bots: 146 Users: 53,128 (2,225 active)
Latest: Waluigi69
Tip: If you place a moon, midpoint, or dragon coin through Map16, it will always respawn whenever you reenter that sublevel. It will not respawn if you add it through the Add Objects/Extended Objects window.
Not logged in.
"ender chest v3" by GreenHammerBro
Forum Index - Valley of Bowser - Moderation Questions - Blocks - "ender chest v3" by GreenHammerBro
Pages: « 1 » Link

File Nameender chest v3
Submitted:2014-06-21 04:39:55 PM by GreenHammerBro
Act As:130
Includes GFX:No
Description:Inspired from Minecraft.

This block, when a kicked sprite comes contact (hit the side or bottom) with it, will "disappear" into the block, after this, if mario hits the bottom, will release the sprite that has been "stored".

During the sprite being stored within the block, all Ender chest blocks will contain the sprite that has been stored until mario releases them. (just like minecraft).

To have it carry to another level, use any freeram address that doesn't reset on level load.

This is useful for puzzles to avoid "item babysitting" since mario doesn't have to carry it all around the level. And for levels that uses "no carrying pass" blocks.

-can only carry one item at a time
-sorta like a ? block that you hit the bottom

Note: read the readme for more info before using.
It uses two bytes for each flag.
Every level/sublevel that has the ender chest should have the same sprite index graphics in each so the sprite's graphics doesn't glitch in other levels.

Doesn't work properly with custom sprites, so don't have carryable custom sprites in the area.

see readme for changes
Downloads:Permanent Link

Removal Reason:
While it seems you've got the stun timer to work just fine, there seems to be mayor problems when using springboards or P-switches with this.
P-switches are spawned as a yellow-ish switch with the bottom of a silver P-switch and regardless of x-position, it's always a blue P-switch that spawns.
Storing and respawning a springboard works fine in and for itself, but it messes up other sprites that are respawned from the block. The become partially invisible.
Short Video Here (if you need it, please download it, I won't host it forever)

Minor Stuff:
Just some things that I found while flying over your code. Those aren't removal reasons but I just thought I'd point them out:

	BRA return1

There is no point in using a BRA when you just jump to an RTL you can just use the RTL instead. It takes up 1 byte less and also you save the cycles for the branching.

	LDA !freeram_flag	;\if nothing inside block
	BEQ wrong_sound_short	;/play wrong sound (only to bottom offset)
	LDA #$02		;\play a "hit a ? block" sound
	STA $1DFC		;/
	LDA !freeram_flag	;\if able to unstun sprites
	CMP #$01		;|
	BEQ able_to_unstun	;/go to stun timer included spawner
	CMP #$02		;\otherwise go to empty shell spawner
	BEQ empty_shell		;/

You litterly check for every possible value of !freeram_flag. Given that only 0, 1 and 2 are possible, you don't really need to check for the last one, as, if it's neither 0 nor 1, it has to be 2.
In this case for example, you can just remove the CMP #$01 : BEQ able_to_unstun because if CMP #$02 doesn't branch, the code will run into that routine anyway, and since you already checked for 0 and 2, what remains is...?

Anime statistic on MyAnimeList:
400 animes completed ✓
6000 episodes completed ✓
100 Days completed ✓
... what even am I doing with my life?
Pages: « 1 » Link
Forum Index - Valley of Bowser - Moderation Questions - Blocks - "ender chest v3" by GreenHammerBro

The purpose of this site is not to distribute copyrighted material, but to honor one of our favourite games.

Copyright © 2005 - 2022 - SMW Central
Legal Information - Privacy Policy - Link To Us


Follow Us On

  • YouTube
  • Twitch
  • Twitter


  • Super Mario Bros. X Community
  • Mario Fan Games Galaxy
  • sm64romhacks