Banner
Views: 785,244,307
Time:
6 users online: 7 Up, Adriel_Isaque, ni-pah,  RussianMan, rvx, westslasher2 - Guests: 32 - Bots: 198 Users: 41,056 (1,541 active)
Latest: TylerL
Tip: You can draw more event tiles under the default Layer 2 Event tiles on the overworld for custom use!Not logged in.
Details for Password System
UberASM Repository - Password System
File Name: Password System
Added:
Authors: Nowieso
Type: Level
Includes GFX: No
Includes Hijack: No
Featured: No
Description: With this code, you can easily create a unique password system for your level. Set 1-10 inputs that have to be done in the correct order and one of these things will happen:

-Kill the player
-Hurt the player
-Give the player 1-UP(s)
-Give the player a Power-UP
-Give the player some coins
-Give the player Star-Power
-End the level (normal exit)
-End the level (secret exit), triggers the keyhole animation
-Spawn a sprite
-Change ON/OFF Switch state
-Activate P-Switch
-Teleport to current screen exit
-Teleport the player to the overworld, no event triggered
-Teleport the player to a different overworld position

Every option is very customizable, so make sure to change the defines in the asm file.
Tags: input, lorom, on off, p-switch, password, sa-1, sprite spawn, teleport
Rating: No rating
Download: Download - 4.11 KiB
34 downloads
Screenshots
Previous 
 Next
simon.caio
Great! thank you!
Posted by: simon.caio - | Link
KKevinM
Tested with: LM 3.04, UberASMTool 1.4, SA-1 1.32, Snes9x 1.6. The code works well and it has a lot of interesting options, so accepted.
I found a couple of small issues that would be nice to fix in an update: when enabling the PSwitch option, the song doesn't change. Also, for the silver PSwitch, you need to add a "JSL $02B9BD" to turn all the on-screen sprites to silver coins.

Besides that, it would be nice to make an update to optimize the code (it's not a major issue, but it could also be a useful exercise for you :P). Right now you've encoded the different inputs with separate defines, so there's no room for expansion and there's a lot of duplicate code to check all the different inputs. A much compact (and faster, probably) way to do this could be to encode the inputs in a table (that could be expanded beyond 10 entries), so you wouldn't need to check !freeRAM for each possible value and jump to the different (but basically identical) subsections: you could just use the same code, pulling the correct value from the table using !freeRAM as the index.
Posted by:  KKevinM - | Link

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

Copyright © 2005 - 2019 - SMW Central
Legal Information - Privacy Policy - Link To Us


Total queries: 7

Menu

Follow Us On

  • YouTube
  • Twitch
  • Twitter

Affiliates

  • Talkhaus
  • SMBX Community
  • GTx0
  • Super Luigi Bros
  • ROMhacking.net
  • MFGG
  • Gaming Reinvented