Banner
The Overworld Design Contest ends in
11 DAYS, 3 HOURS AND 17 SECONDS
Views: 904,613,334
Time:
18 users online: 00frank, Azula16, BlueToad, Darkbloom, Heraga, imamelia, Infinity, JohnCartoonist, kaigem, KungFuFurby,  MarioFanGamer, Nanny_Skeksis, Overcrow03, PuffleDreemurr, Rammy, TheDutchLuigi, TheMorganah, Vic Rattlehead - Guests: 49 - Bots: 77 Users: 50,716 (2,110 active)
Latest: JohnCartoonist
Tip: This thread contains data you might find helpful when coding.
Not logged in.
Breack blocks Bug
Forum Index - SMW Hacking - SMW Hacking Help - ASM & Related Topics - Breack blocks Bug
Pages: « 1 » Link
i have the next error with my next sprite:

Video

i am using the next code :

Code
DestroyX: db $00,$0E,$00,$0E
DestroyY: db $00,$00,$0E,$0E
	
romper:

	LDA $13
	AND #$03
	STA $157C,x
	
	LDA $157C,x
	TAY 
	
	LDA $E4,x 		;\
	CLC
	ADC DestroyX,y
	BCS conIncR
	AND #$F0 	;| Update the position
	STA $9A 		;| of the block
	LDA $14E0,x 		;| so it doesn't shatter
	STA $9B 		;| where the players at
	JMP sRomper:
conIncR:
	AND #$F0 	;| Update the position
	STA $9A 		;| of the block
	LDA $14E0,x 		;| so it doesn't shatter
	INC A
	STA $9B 		;| where the players at
sRomper:
	LDA $D8,x 		;|
	CLC
	SBC DestroyY,y
	AND #$F0 	;|
	STA $98 		;|
	LDA $14D4,x 		;|
	STA $99 		;/
	
	LDA #$01                ;
	STA $9C
	LDY #$00
	JSL $00BEB0
	
	LDA $1588,x
	BEQ finRomper
	PHB
	LDA #$02
	PHA
	PLB
	LDA #$00 	;set to 0 for normal explosion, 1 for rainbow (throw blocks)
	JSL $028663 	;breaking effect
	PLB
	
finRomper:
	RTS
RTS


how can i fix this?
------------------------------------------------------

Youtube
Twitter
SMWControlLibX GitHub
My Discord Server
Originally posted by anonimzwx

LDA #$01
STA $9C


Probably not it, but its worth trying, change the #$01 to #$02.
i tried this.
------------------------------------------------------

Youtube
Twitter
SMWControlLibX GitHub
My Discord Server
fixed
------------------------------------------------------

Youtube
Twitter
SMWControlLibX GitHub
My Discord Server
May I ask how? The similar things I've seen in the past were annoying as hell to fix.
if you divide your codes in sub routines is easier fix the bugs. But always there are bugs that are hard to fix.

i found the bug in the graphic routine, for some reason the RAM 192C provokes the bug. I replace this ram and works.
------------------------------------------------------

Youtube
Twitter
SMWControlLibX GitHub
My Discord Server
Pages: « 1 » Link
Forum Index - SMW Hacking - SMW Hacking Help - ASM & Related Topics - Breack blocks Bug

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