Banner
Views: 858,772,628
Time:
13 users online: Abdu, brickblock369, Dark Prince, Dippy, Evernn, FYRE150, GammaSlap, isaix, KlonoA13Phill, Ralshi02, Ratkiller, Samuel Zuccati, SirMystic - Guests: 42 - Bots: 81 Users: 47,464 (2,238 active)
Latest: KlonoA13Phill
Tip: Read Lunar Magic's help file and SMW Central's FAQ, as they cover most of the basics of SMW hacking.Not logged in.
Uberasm code placement
Forum Index - SMW Hacking - SMW Hacking Help - Uberasm code placement
Pages: « 1 »
I am familiar with the uberasmtool, i know how to use it for the most part. I'm trying to insert Coin Outline which is an outline of a coin that turns into a coin, like in New Super Mario Bros Wii. The block was easy to insert, but the code for uberasm is this:
Code
; Please insert this code in your uberASM code folder.

!RAM = $7F8600

global_code:
		LDX #$EB		; 48 coin slots
		
	.loop	LDA !RAM,x		; If the timer is nonzero,
		BEQ .next
		
		DEC			; decrement timer.
		STA !RAM,x
		BNE .next		; If the timer turned to zero,
		
		REP #$20
		LDA !RAM+1,x		; Get X position,
		STA $9A
		LDA !RAM+3,x		; Get Y position,
		STA $98
		SEP #$20
		
		LDA #$06
		STA $9C
		JSL $00BEB0		; And create a coin
		
	.next	DEX #5			; Check the next slot
		CPX #$FB
		BNE .loop
		
		RTS 

All it says is put it in the code folder. I tried putting this code in the global code asm file, but it didn't do anything. Can someone help me figure out where this code is supposed to go?
Replace "global_code:" with "main:", and change the "RTS" with "RTL". Then, just insert it either as levelASM (if you only want it in certain levels) or as gamemode ASM, in gamemode 14 (if you want it for all levels).
thank you so much! :3

--------------------
who knew it would take 3 years for me to learn how to insert a custom block into lunar magic
Pages: « 1 »
Forum Index - SMW Hacking - SMW Hacking Help - Uberasm code placement

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

Copyright © 2005 - 2020 - 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