FilterToSmall,0,0,0,0,0,0 = In the "Load level" section, make the player small
Targets - Target of event
0 = Player
1+ = Type of sprite / block to target
Actions - Action the event performs on the target
0 = Invalid
1 = Death
1000+ = Activate custom event
Font type - Built-in font types for text functions
0 = ?
1 = Numbers only (the score font)
2 = Black, upper and lower case (the level name font)
3 = Blocky white, upper case only (font for everything else)
Example ShowText,0,50,50,3,0,Hi = Print "Hi" at 50,50 on the screen using font 3
Player IDs
0 = Invalid
1 = Demo
2 = Iris
3 = Peach
4 = Raocow
5 = Sheath
Example FilterToPlayer,0,5,1,0,0,0 = Player with ID 5 (sheath) becomes player ID 1 (demo)
Conditional
0 = Invalid
1 = Exists
2 = Does not exist
3 = On screen
4 = Off screen
(Note: There must be at least 1 NPC somewhere in the level or conditionals will not be checked)
Example IfNPC,31,2,0,1000,0,0 = If an NPC with ID 31 (31 = a key) does not exist, trigger event 1000. (must be at least 1 NPC somewhere though)
Data types - For advanced modification of data
"byte" = 1 byte unsigned data
"short" = 2 bytes unsigned data
"int" = 4 bytes unsigned data
"float" = 4 bytes float/decimal formatted data data
"double" = 8 bytes double precision float/decimal formatted data data
Example NPCMemSet,10,0x98,-3,0,0,double = All npcs of type 10 have their memory at 0x98 set to -3, formatted as an 8 byte double. (0x98 in an NPC object is the X Speed variable which is stored as a double)
- Format -
#n, where n is a Section/ID, mean all following commands will have that specifier
#-1
-- Statements for load level section --
#0
-- Statements for always section --
#5
-- Statements for section 5--
#1005
-- Statements for custom event 1005 --
#END
- FilterToSmall - x, x, x, x, Length, x
Player loses all powerups.
- FilterToBig - x, x, x, x, Length, x
Player loses all powerups higher than bigness.
- FilterToFire - x, x, x, x, Length, x
Player loses all powerups higher than fireballs.
- FilterMount - x, x, x, x, Length, x
Whatever the player is riding disappears.
- FilterReservePowerup - x, x, x, x, Length, x
The player's reserve powerup disappears.
- FilterPlayer - x, Filter ID, To ID, x, Length, x
If the player's character type is "Filter ID", they change to the character set in "To ID".
- SetHearts - x, Hearts, To ID, x, Length, x
Sets the player's hearts.
- HeartSystem - X display, Y display, Max hearts, x, Length, x
Activates a heart tracking system for players that use hearts. Allows for more than 3 hearts and displays the current heart count at X / Y on screen.
- InfiniteFlying - x, x, x, x, Length, x
Player's flight timer never decreases below 50 so long as this event is active.
- ShowText - x, X pos, Y pos, Font type, Length, String
Shows String on the screen, at coordinates Xpos and Y pos, with specified font type.
- ShowNPCLifeLeft - NPC ID, X pos, Y pos, Section, Length, Base health
Displays how much life the first match for "NPC ID" in "Section" has. Displays on the screen at coordinates X pos and Y pos. Supply the correct base health for the NPC so it can calculate the correct remaining life.
- Trigger - New section, Event, x, x, x, x
Activates an event by moving "Event" to "New section". The trigger itself expires afterwards.
- Timer - Target, Effect, Display?, Reset?, Length, x
Starts a timer that performs Effect on Target. Set "Display?" to 1 to display the timer in the top right. Set "Reset" to 1 and the timer will start over once it completes.
If "Effect" is 1000 or higher, the timer will behave like the Trigger command. It will trigger the corresponding custom event by placing it in the section specified by Target.
- IfNPC - NPC ID, Condition, To section, Event, Length, x
If "Condition" is true for NPC specified by "NPC ID", then custom event "Event" is triggered in "To section". IfNPC command expires itself after triggering.
- SetHits - NPC ID, Section, Damage, x, Length, x
The first NPC matching "NPC ID" in "Section" has its "hits taken" set to "Damage". Set to negative values to increase hits beyond normal.
- ForceFacing - NPC ID, Section, x, x, Length, x
All NPCs of NPC ID in Section always face the player.
- SFX - x, Sound ID, x, x, x, x
Plays specified sound. Expires itself afterwards.
- DebugPrint - x, x, x, x, Length, x
Prints event information for the level designer for diagnostic purposes.
- NPCMemSet - NPC ID, Offset, Value, x, Length, Data type
This is an advanced and dangerous command. It allows one to modify the data of any NPC that is alive in the level.
Any NPC of type NPC ID will have memory inside it at Offset set to Value. Value will be formatted according to "Data type".
Activates the special Heart system once the player picks up the Axe (NPC 178), and plays the ZeldaItemGet sound effect.
Infinite looping gimmick
#0
DebugPrint,0,0,0,0,0,0
Trigger,0,1000,0,0,0,0
// All enemies friendly
#1000
Timer,0,1001,1,0,200,0
NPCMemSet,-1,0x46,0xFFFF,0,200,short
ShowText,0,400,550,3,200,YAY!
// All enemies unfriendly
#1001
Timer,0,1000,1,0,200,0
NPCMemSet,-1,0x46,0x0000,0,200,short
ShowText,0,400,550,3,200,GRR!
#END
Starts the friendly enemy event, which calls the unfriendly enemy event when it ends, which calls the friendly enemy event again when that ends. Loops forever. Use DebugPrint when designing your code to be sure you didn't create some horrific infinite memory leak.