Banner
Views: 853,627,426
Time:
32 users online: ademhania, AmperSam,  Anorakun, chickaDEE Magazine, Dan Drigues, diego2007, Dispace, ExONightZ, FineTunedBenjo, Freitasth, Hayashi Neru, heyitsgalaxycreeper, ideka13,  JamesD28, JupiHornet,  KevinM, kiki79250, Koop the Koopa, Kusrry, Mega, msQED, Phyll, Raymondsze, RPG Hacker, Sariel, SF - The Dark Warrior, Sping bot, Starrypop, TruffledToad, Von Fahrenheit, xamexer, Zidan3 - Guests: 72 - Bots: 49 Users: 47,101 (2,501 active)
Latest: Imposter-ST
Tip: The multiple midpoints patch can also be used to move a level's normal midpoint.Not logged in.
Custon coins help
Forum Index - SMW Hacking - SMW Hacking Help - Custon coins help
Pages: « 1 »
Hi, I'm currently trying to make a level where if you collect an special amount of special coins you would be teleport
I tried to use Iceguy's coin block but it's affected by the regular coins since it uses the coin count, so I imagined that the Special Coin from PatPatPat could be used to the purpose of teleporting?
or even the block.asm from Koopster'sCoin Hunt Pack
If someone knows how to make that possible I would apreciate very much
Oh yeah, I made that thing.
You can use CustomCoin.asm from my pack, in conjunction with this UberASM code if you adapt it in the following manner:

Code
main:
    LDX.b #!sprite_slots-1
  - LDA !14C8,x
    BNE .ret
    DEX
    BPL -

Change these lines to:

Code
!Coins = 30
!EmptyRAM = 79

main:
	LDA $!EmptyRAM
	CMP #!Coins
	BCC .ret

Fill the defines as you did in the block and it should be good.

--------------------
Twitter
Oh wait I'm stupid. You don't need UberASM for this, you can just edit CustomCoin.asm. Find these lines:

Code
	LDA #$01	;\Play "coin" SFX. Go http://smwc.me/t/6665 to
	STA $1DFC	;/find other SFX values so you can customize it

Right below them and before the RTL, put this:

Code
	REP #$20
	LDA #!Level|(((!Water<<3)|(1<<2)|(!Secondary<<1))<<8)
	%teleport()

And put those defines at the top of the block:

Code
!Level = $0103	;level to teleport to
!Secondary = 0	;set to 1 if secondary exit
!Water = 0	;set to 1 if secondary exit is a water level

Let me know if this works.

--------------------
Twitter
Originally posted by Koopster
Oh wait I'm stupid. You don't need UberASM for this, you can just edit CustomCoin.asm. Find these lines:

Code
	LDA #$01	;\Play "coin" SFX. Go http://smwc.me/t/6665 to
	STA $1DFC	;/find other SFX values so you can customize it

Right below them and before the RTL, put this:

Code
	REP #$20
	LDA #!Level|(((!Water<<3)|(1<<2)|(!Secondary<<1))<<8)
	%teleport()

And put those defines at the top of the block:

Code
!Level = $0103	;level to teleport to
!Secondary = 0	;set to 1 if secondary exit
!Water = 0	;set to 1 if secondary exit is a water level

Let me know if this works.


Thanks for your help, it worked perfectly! thit was exactly what I needed!
Pages: « 1 »
Forum Index - SMW Hacking - SMW Hacking Help - Custon coins help

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