Register | Login
Views: 19364387
Main | Memberlist | Active users | ACS | Commons | Calendar | Online users
Ranks | FAQ | Color Chart | Photo album | IRC Chat
11-02-05 12:59 PM
1 user currently in Super Mario World hacking: labmaster | 3 guests
Acmlm's Board - I2 Archive - Super Mario World hacking - The shell of doom! [ASM issue]
  
User name:
Password:
Reply:
 

UserPost
HyperLamer
Posts: 291/8210
A modified version of SnesASM by Kenny9000, which unlike the original, doesn't add the 512-byte header and pad to 32K. (Don't suppose it's an assembler bug?)
Smallhacker
Posts: 82/2273
Hmm... Not related to the issue, but what compiler are you using? The one you're using looks pretty easy to use.
(Right now, I'm using a hex editor and a 65c816 reference file when programming in ASM. )
BMF98567
Posts: 102/1261
Did you already try tracing the code? Just set a breakpoint on the code's starting address right before the shell hits it, let it snap a few times until the shell hits, then find the crash point from there. Easy.
HyperLamer
Posts: 281/8210

;Super Mario World Custom Block
;Only lets certain types of shells by
;Note: All offsets except sprite hits should be set to -1, else the code may become confused.
;Description format: [Shell colours that can pass]/[Can other sprites pass?]

;Green/No 0
JSR getshelltype
BEQ solid ;Don't let non-shells thru
CMP #1
BNE solid
RTS

;Red/No 10
JSR getshelltype
BEQ solid
CMP #2
BNE solid
RTS

;Blue/No 20
JSR getshelltype
BEQ solid
CMP #3
BNE solid
RTS

;Yellow/No 30
JSR getshelltype
BEQ solid
CMP #4
BNE solid
RTS

;Green/Yes 40
JSR getshelltype
CMP #1
BNE solid
RTS

;Red/Yes 48
JSR getshelltype
CMP #2
BNE solid
RTS

;Blue/Yes 56
JSR getshelltype
CMP #3
BNE solid
RTS

;Yellow/Yes 64
JSR getshelltype
CMP #4
BNE solid
RTS

;Returns type of shell in A (00=Not a shell, 01=Green, 02=Red, 03=Blue, 04=Yellow)
getshelltype:
LDA $14C8,X
CMP #9
BEQ isshell
CMP #$A
BEQ isshell
notshell: LDA #0
RTS

;Sprite is a shell
isshell: LDA $9E,X ;Get sprite type
SBC #$D9
RTS

;Make block solid
solid: LDA #$30
STA $1693
LDY #$01
RTS


So... Who here can tell my why this darn thing crashes when smucked with a shell?
Acmlm's Board - I2 Archive - Super Mario World hacking - The shell of doom! [ASM issue]


ABII


AcmlmBoard vl.ol (11-01-05)
© 2000-2005 Acmlm, Emuz, et al



Page rendered in 0.009 seconds.