Banner
Views: 873,853,806
Time:
37 users online: AmperSam, AppleBoy54321, bandicoot, buggy789, codfish1002, Dark Prince, Flamesofshadow, FrozenQuills, Hayashi Neru, imamelia, Insanit,  JamesD28, jardeson01, K3fka, LadiesMan217, Mario is the best, mateochips,  Meirdent, Mirann, Mr. MS, MuMu, ninj,  NopeContest, OrangeBronzeDaisy, Pancake001, Potions315,  shovda, Skye, slopcore, SuperMarioDs64, Teaser, TheSorrow,  ThirdWall, TypeII_Mound, UTF, XtremeI, YMM - Guests: 65 - Bots: 73 Users: 48,668 (2,413 active)
Latest: RetroYuuki
Winter C3 2021 Content Spotlight
Rykon-V73's "Layer 3 BG Conversions"!
Not logged in.
Explosion code for sprite and how insert this...
Forum Index - SMW Hacking - SMW Hacking Help - ASM & Related Topics - Explosion code for sprite and how insert this...
Pages: « 1 » Link
Anybody know the bob-omb explosion code and the place for insert the code for sprite??
This code should be what you need:

Code
	
Explode:
        LDA #$0D	;/
	STA $9E,x	;\ Sprite = Bob-omb.
	LDA #$08	;/
	STA $14C8,x	;\ Set status for new sprite.
	JSL $07F7D2	;/ Reset sprite tables (sprite becomes bob-omb)..
	LDA #$01	;\ .. and flag explosion status.
	STA $1534,x	;/
	LDA #$40	;\ Time for explosion.
	STA $1540,x
	LDA #$09	;\
	STA $1DFC	;/ Sound effect.
	LDA #$1B
	STA $167A,x
        RTS


Just place it wherever you want the sprite to explode. Or you could call the routine using JSR Explode.
Quote

LDA #$01 ; State to load
STA $14C8,x
LDA #$74 ; Sprite number
STA $9E,x
JSL $07F7D2


Basically that. Change the sprite number to that of the bob-omb and the state to that of exploding, which I think is #$08.

EDIT: ninji'd

--------------------

And the code when is contect with solid object??
LDA $1588,x
BNE NotTouchingAnything

*this code runs when the sprite is touching something solid*

NotTouchingAnything:


--------------------


 
I have read this thread, but i don`t know...

which is the Bob-Omb Explosion routine, without insert it in a sprite?



--------------------
Building New Layout, Please wait warmly.

Current Touhou Rankset Character Favorite Spellcard:
Thunderous Yell "Scolding From a Traditional Old Man"

If you Like Touhou and want to give your opinion on a little something I'm making, see this poll!

I Fell Alive Again!
Pages: « 1 » Link
Forum Index - SMW Hacking - SMW Hacking Help - ASM & Related Topics - Explosion code for sprite and how insert this...

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

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


Menu

Follow Us On

  • YouTube
  • Twitch
  • Twitter

Affiliates

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