Banner
Views: 944,798,805
Time:
16 users online:  BeeKaay, DKR_02, Foreversmokin,  GlitchCat7, Miscalc, OnlySpaghettiCode, Paithus, Panik FLDV,  quietmason, RainbowShell, ShadowBoxer_Sandshrew, SJandCharlieTheCat, Skewer, SmokyShroom, UlticraftMTT, VLSkoot - Guests: 86 - Bots: 64 Users: 52,530 (2,022 active)
Latest: marlowe
Tip: Before asking for help on the forums, make sure you've tried to figure out the problem on your own first.
Not logged in.
UberASM HDMA Crash
Forum Index - SMW Hacking - SMW Hacking Help - ASM & Related Topics - UberASM HDMA Crash
Pages: « 1 » Link
So i put this code of the effect tool on the levelinit.asm. The asar patches asar_patch.asm sucessfully but when i go to test my ROM and go to my level the game crashes.
Help appreciated.

Code
levelinit64:
Init:
	; insert INIT code if applicable for the effect
   	REP #$20                  ;\  16 bit mode
   	LDA #$0000                ; | 
   	STA $4350                 ; | 
   	LDA #.BrightTable         ; | load high and low byte of table address
   	STA $4352                 ; | 
   	SEP #$20                  ; | back to 8 bit mode
   	LDA.b #.BrightTable>>16   ; | load bank byte of table address
   	STA $4354                 ; | 
   	LDA #$20                  ; | 
   	TSB $0D9F|!Base2           ; | enable HDMA channel 5
   	RTL                       ;/  

.BrightTable:                 ; 
   db $05 : db $00            ; 
   db $04 : db $01            ; 
   db $04 : db $02            ; 
   db $05 : db $03            ; 
   db $04 : db $04            ; 
   db $04 : db $05            ; 
   db $05 : db $06            ; 
   db $04 : db $07            ; 
   db $04 : db $08            ; 
   db $05 : db $09            ; 
   db $04 : db $0A            ; 
   db $04 : db $0B            ; 
   db $05 : db $0C            ; 
   db $07 : db $0D            ; 
   db $06 : db $0E            ; 
   db $71 : db $0F            ; 
   db $03 : db $0E            ; 
   db $04 : db $0D            ; 
   db $03 : db $0C            ; 
   db $04 : db $0B            ; 
   db $02 : db $0A            ; 
   db $03 : db $09            ; 
   db $02 : db $08            ; 
   db $03 : db $07            ; 
   db $02 : db $06            ; 
   db $03 : db $05            ; 
   db $02 : db $04            ; 
   db $03 : db $03            ; 
   db $03 : db $02            ; 
   db $02 : db $01            ; 
   db $02 : db $00            ; 
   db $00                     ; 
We typically use UberASM Tool rather than the patch. As a result, almost none of the codes we host are compatible with the patch version including HDMA codes generated by Effect Tool.

Nonetheless, you still can if you make a minor change: Replace the RTL to RTS and remove the Init: at line 2 since it isn't needed as well.
Originally posted by MarioFanGamer
We typically use UberASM Tool rather than the patch. As a result, almost none of the codes we host are compatible with the patch version including HDMA codes generated by Effect Tool.

Nonetheless, you still can if you make a minor change: Replace the RTL to RTS and remove the Init: at line 2 since it isn't needed as well.

Now it works on my ROM.Thanks for helping!
Pages: « 1 » Link
Forum Index - SMW Hacking - SMW Hacking Help - ASM & Related Topics - UberASM HDMA Crash

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