📝 All Notetag, Comments, Conditional Branch and Movement Route commands

Green text: Commonly used          Yellow text: Optional

-----------------------------------------------------------------------------------------------

Notetags

Put in notetag section of events


<hp: value>
Setup a hp bar to the event
Case 1: <hp: 6>
             This event has 6 hp
Case 2: <hp: 6 - 10>
             This event has random hp from 6 - 10
Case 3: <hp: Ghost>
             This event get HP value from said enemy name from database. If parameter Gain EXP from Enemy is on, the whole party will also gain EXP when the enemy is defeated. The EXP value can be assigned in the database.
Case 4: <hp: actor, actor id> (like <hp: actor, 2>)
             This event get HP value from actor id 2

<hpy: x>
Adjust offset y of the event hp bar

<hpColor: hex code>
Change HP bar color for event
<hpColor: #00000>

<radius: x>
Adjust the radius that will show event hp bar when player is near the event

<hideHP>
Hide hp bar from the event, visually.

<dmg: value>
The damage this event will deal to others
Case 1: <dmg: 6>
             Deal 6 damage
Case 2: <dmg: 6 - 10>
             Deal a random number from the range 6 - 10
Case 3: <dmg: v[1]>
             Deal damage from variable id 1 value
Case 4: <dmg: Fireball>
             Deal formula damage from a skill in databases called Fireball
Case 5: <dmg: actor, actor id, parameter> (like <dmg: actor, 2, atk>)
             Deal damage using parameter Attack from actor id 2


<cooldown: x>
Damage over time effects that will continue after x frames have passed
<cooldown: 15> Event will return true for collision checking every 15 frames instead of just once

<hitbox: width, height, offset x, offset y>
Hitbox of this event. Every event has the default hitbox is 1, 1, 0, 0 unless otherwise
<hitbox: 2, 2> or <hitbox: 3, 5, 15, 30>

<hue: -180 to 180>
Hue the event, min -180, max 180

<sprite offset: x, y>
Offset the event's sprite. Only the sprite!

<exp: x - y>
When an enemy is defeated, gain EXP for the whole party. Only usable if parameter Gain EXP from Enemy is on. This is a manual method of <hp: enemy name> for those who doesn't want to use database.
<exp: 5> or <exp: 5 - 10>

<ignore>
Only usable for movement route moveToCloset, which to not move to events with this comment.

<pass>
Player can step on any event with this notetag regardless of where they're being placed.

<platform: size>
Transform the event into a platform. Characters stepping on platform will move along with it.
<platform>                 The platform has the size of 48 pixel
 <platform: 80>          80 pixel
-----------------------------------------------------------------------------------------------

Comments

Put in comment command of events (green text)


<passive: x, y, z, etc>   Support: Ids or Names
The common event ids that this event will call in parallel. It's like calling a common event in a parallel event but on another layer that isn't being affected by any commands inside that event.
<passive: 1, 2, 3, 4, 5> or <passive: Player Attack, Player Defend>

<skip collision>
The event will be ignored from collision checking on any page with this comment.

<stepping speed: x>
Adjust the walking animation speed of the event. The lower the number, the faster the animation plays. Best to use if you want some enemy to flap wings faster or something.
<stepping speed: 8>

<child of: x>   Support: player, event id, event name, event notetag
Make the event to be a child of another event/player. Child events are just regular events with attributes to move along with the player.
<child of: player>              Make event child of game player
<child of: 2>                      Make event child of event id 2
<child of: Demon>            Make event child of the nearest event with name Demon
<child of: <Demon>>       Make event child of the nearest event with notetag <Demon>

<child offset: x, y>
Adjust position of the child from the parent
<child offset: 50, 0>          Will move along with its parent but with 50 pixel to the right

<clickable: range (in tiles), default is 1>
Event with this comment can be activated via mouse click and only when the player is
within range
<clickable>              Display outline and can be triggered if player is within 1 tiles
<clickable: 3>          Display outline and can be triggered if player is within 3 tiles

-----------------------------------------------------------------------------------------------

Conditional Branch


HP(eventId)
Check the current HP of an event.
HP(1) > 0 or HP(this._eventId) <= 0

hpDecreased(eventId)
Check if the event just got its HP decreased
hpDecreased(this._eventId)

gotHit(eventId)
Check if the event just received damaged
gotHit(this._eventId)

checkCollide(source, target, cooldown)
Check collision between events or the player. The hitbox is determined with notetag <hitbox> above
Case 1: checkCollide(this._eventId, 'player')
             Return true once if this event collides with player.
Case 2: checkCollide(this._eventId, 'player', 8)
             Return true if this event collided with player every 8 frames.
Case 3: checkCollide(this._eventId, '<player bullet>')
             Return true once if this event collided with any events with notetag <player bullet>.
Case 4: checkCollide(this._eventId, ['<player bullet>', '<player fireball>'])
             Return true once if this event collides with any events with notetags above once.
Case 5: checkCollide('player', ['<player bullet>', '<player fireball>'])
             Return true once if player collides with any events with notetags above once.
Case 6: checkCollide(this._eventId, '<overTimeAttack>', 'cooldown')
             Return true if this event collided with an event with said notetag every x frames. X will be read from notetag <cooldown: x> from event with notetag <overTimeAttack>
Case 7: checkCollide(this._eventId, 'region 1')
             Return true if this event collided with region id 1
Case 8: checkCollide(this._eventId, 'impassable B')
             Return true if this event collided with an impassable tile within tileset B
Case 9: checkCollide(this._eventId, 'impassable ABCD')
             Return true if this event collided with an impassable tile within tilesets ABCD

checkRange(source, range, target, eyes direction, exception)
Check range from source to target, like a detection system
Case 1: checkRange(this._eventId, 7, 'player')
             Return true if this event is within 7 tiles from the player
Case 2: checkRange(this._eventId, 7, '<enemy>')
             Return true if this event is within 7 tiles from any event with notetag <enemy>
Case 3: checkRange('player', 7, '<enemy>')
             Return true if the player is within 7 tiles from any event with notetag <enemy>
Case 4: checkRange(this._eventId, 7, '<enemy>', 90)
             Same as case 2 but will only check from the eye direction of source in 90-degree vision cone
Case 5: checkRange(this._eventId, 7, '<enemy>', 90, '<friendly>')
             Same as case 5 but if the <enemy> event also has notetag <friendly>, it'll return false regardless.
             Said event with the current page with comment <detectable> will start return true again.

checkSound(source, max volume, range)
Check if there's any sound playing from other events around source event within x range.
checkSound(this._eventId, 50, 6)
Any sound above 50 volume playing from other events within 6 tiles compared to the current event will return the condition to true

localVariable(eventId, var name (if exists))
Check local variable of an event.
Case 1: localVariable(this._eventId) >= 5
Return true if default local variable of this event is >=5
Case 2: localVariable(this._eventId, 'fire')
Return true if a local variable named 'fire' of this event is >=5
Case 3: localVariable(this._eventId) == "haha"
Return true if default local variable of this event is haha
Case 4: localVariable(this._eventId, 'fire') == "haha"
Return true if a local variable named 'fire' of this event is haha

eventLocalVariable(eventId*, expression, var name (default var is 'default'), direction )
Check the local variable of other events that share the same position (like below the foot) of the eventId*.
Case 1: eventLocalVariable(this._eventId, '>=5')
Return true if default local variable of other events that are below this event is >=5
Case 2: eventLocalVariable('player', '>=5', 'fire')
Return true if local variable named 'fire' of other events that are below player is >=5
Case 3: eventLocalVariable('<bullet>', 'haha')
Return true if default local variable of other events that are below events with notetag <bullet> is haha
Case 4: eventLocalVariable(this._eventId, 'haha', 'fire')
Return true if local variable named 'fire' of other events that are below this event is haha
Case 5: eventLocalVariable(this._eventId, 'haha', 'fire', 'front')
Same as case 3 but instead of checking from current position of current event, it checks the tile in front of the current event (1 tile)
Case 6: eventLocalVariable(this._eventId, 'haha', 'fire', 'behind')
Same as case 5 but it checks the tile behind instead (1 tile)

localPercentage(eventId, percentage)
Check local percentage of an event. It's similar to when you set a variable from range 1 ~ 50 or something and the result will be given randomly from 1 - 50. Local percentage helps you to not having to do all that.
Case 1: localPercentage(this._eventId, 50)
50% chance this condition will return true
Case 2: localPercentage(this._eventId, 20)
20% chance this condition will return true

inViewport(eventId, extra buffer (default is 5))
A useful conditional that is mostly used for performance optimization. It'll return true if events are on screen and will return false if it's offscreen.
Case 1: inViewport(this._eventId)
Check the viewport with an extra 5 pixels offscreen (for a smoother transition)
Case 2: inViewport(this._eventId, 48)
Check the viewport with an extra 48 pixels offscreen

checkLevelUp()
Return true when party leader has just leveled up

equippedWeapon(id or name, slot (default is 1))
Check if the player is equipping a weapon using its id or name
Case 1: equippedWeapon(1)
Check if player is equipping weapon id 1 in slot 1
Case 2: equippedWeapon(1, 2)
Check if player is equipping weapon id 1 in slot 2
Case 3: equippedWeapon('Long Sword')
Check if player is equipping weapon Long Sword in slot 1

equippedWeaponType(id or name, slot (default is 1))
Check if the player is equipping a weapon type using its id or name
Case 1: equippedWeaponType(1)
Check if player is equipping weapon type id 1 in slot 1
Case 2: equippedWeaponType(1, 2)
Check if player is equipping weapon type id 1 in slot 2
Case 3: equippedWeaponType('Sword')
Check if player is equipping weapon type Sword in slot 1

equippedWeaponNotetag(notetag, slot (default is 1))
Return the value from the notetag of equipped weapon
Example: Your weapon has notetag <capacity: 10> or <element: fire>
equippedWeaponNotetag('capacity') or ('element') will return 10 or fire
equippedWeaponNotetag('capacity', 2) will return the same but for weapon in slot 2
Case 1: equippedWeaponNotetag('capacity') >= 7
Case 2: equippedWeaponNotetag('element') == 'fire'

amount(type, id or name)
Return the amount of item/weapon/armor that the player possesses.
amount('item', 1)                                  Get the amount of item id 1
amount('armor', 'Heavy Armor')         Get the amount of Heavy Armor
amount('weapon', 5)                            Get the amount of weapon id 5

notetag(eventId, notetag) or notetag(notetag)
A versatile conditional branch that will either check if an event has a certain notetag or an event with a certain notetag exists on map, or to check if there's an event with notetag x at the location of another eventId/player.
Case 1: notetag('<enemy>')
True if there's an event with notetag <enemy> on map
Case 2: notetag(this._eventId, '<enemy>')
True if the current event has notetag <enemy>
Case 3: notetag('<crop>', this._eventId)
True if an event with notetag <crop> is at the same position of current event
Case 4: notetag('<flower>', '<crop>')
True if an event with notetag <flower> is at the same position as an event with notetag <crop>
Case 5: notetag('<crop>', 'player')
True if an event with notetag <crop> is at the same position as the player

partyLeader(id or name)
Return true if party leader matches
partyLeader(1) or partyLeader('Reid')

inFrontIsImpassable(EventId)
Return true if in front of eventId is an impassable tile or impassable events
EventId can be: 'player', this._eventId, a number

onPlatform(eventId)
Return true if eventId is standing on a platform event (event with notetag <platform>)
Case 1: onPlatform('this')
True if current event is on a platform
Case 2: onPlatform('player')
True if player is on a platform
Case 3: onPlatform('<enemy>')
True if an event with notetag <enemy> is on a platform

playerStartedJump()
Return true if player just started jumping

playerJumping()
Return true if player is in mid air/still jumping

playerLanded()
Return true if player just landed/finished jumping

checkGamepad()
Return true if a gamepad is connected

isRightStickPushed()
Return true if right stick of gamepad is being pushed

Input.isTriggered/Pressed('left/right click')
Return true if left or right click is clicked or being pressed
Requires Hendrix Keyboard Gamepad plugin

-----------------------------------------------------------------------------------------------

Script Call


equippedWeaponDmg(slot (default is 1))
Return the attack value of weapon from database
Case 1: equippedWeaponDmg()
Return attack value of weapon that is equipped in slot 1
Case 2: equippedWeaponDmg(2)
Return attack value of weapon that is equipped in slot 2

equippedWeaponParam(param, slot (default is 1))
Return a value from a param of weapon in database
Case 1: equippedWeaponParam('atk')
Get Attack value of equipped weapon from slot 1
Case 2: equippedWeaponParam('def', 2)
Get Defense value of equipped weapon from slot 2

damage(this._eventId)
Return the damage from notetag <dmg: x-y> of the event just collided

sucking(eventId, notetag, range, speedboost)
Suck events to a character
sucking(this._eventId, '<enemy>', 8>
Suck all events with notetag <enemy> within 8 tiles to current event
sucking(this._eventId, '<enemy>', 8, 7>
Suck all events with notetag <enemy> within 8 tiles to current event with speed boost of 7
sucking('player', '<enemy>', 8>
Same but will suck to player instead

localVar(event id, var name)
Return the value of local variable of an event.
localVar(this._eventId) or localVar(this._eventId, 'fire')

-----------------------------------------------------------------------------------------------

Movement Route

Call these script in a Set Movement Route command

selfSwitch(letter, true/false)
Same as Control Self Switch but you can call this in Movement Route.
selfSwitch('A', true) or selfSwitch('B', false) 

dash(distance)
Move the player to the direction he's moving. Why use this instead of Move Forward? Because this supports 360 degrees and in pixel so it's compatible with Joystick. Move Foward only support one direction. Distance: The faster the walking speed of the player, the further the player moves.
dash(3) 

turnToward(target, force direction, max distance (tiles))
Turn the character direction to the target.
turnToward('cursor')                     Turn character to mouse cursor position
turnToward('right stick')                Turn character to gamepad right stick direction
turnToward('mouse or gamepad')  Auto choose cursor or rightstick if gamepad is connected
turnToward(2)                               Turn character to event id 2
turnToward('<enemy>')                Turn character to nearby event with notetag <enemy>
turnToward('<enemy>', false, 7)  Same as above but won't turn to events that are out of distance
turnToward('cursor', true)             Direction Fix the character when calling this command and only this command can change the direction of the character despite it being locked. Can be unlocked with the command Direction Fixed OFF. In the demo, I used this for gun shooting.

rotateTo(x, y)
A versatile command that will rotate the character (360 degrees) to a target. Best for projectiles.
Case 1: rotateTo('cursor')
Rotate the character to mouse cursor
Case 2: rotateTo('right stick')
Rotate the character to gamepad right stick
Case 3: rotateTo('mouse or gamepad')
Auto-choose cursor or right stick if gamepad is connected
Case 4: rotateTo('player moving direction')
Rotate the character to the player moving direction
Case 5: rotateTo(15, 30)
Rotate the character to map coordination x15 y30
Case 6: rotateTo(1)
Rotate the character to event id 1
Case 7: rotateTo('<enemy>', 7)
Rotate the character to any event with notetag <enemy> within 7 tiles distance
Case 8: rotateTo('player')
Rotate the character to the game player

jumpToNearby(max distance, jump on another event (true/false))
Jump the character to nearby positions from its current position. I use it for loots dropping from monsters or from a chest.
jumpToNearby(3)                            Jump to nearby tiles within 3 tiles distance, not on events
jumpToNearby(3, true)                   Same but will jump on other events if they're in the way

jumpTo(x, y)
A versatile command that will jump the character to a target
Case 1: jumpTo(5)
Jump the character to event Id 5
Case 2: jumpTo(15, 30)
Jump the character to map coordination x15, y30
Case 3: jumpTo('player')
Jump the character to game player
Case 4: jumpTo('player', 5)
Jump the character to game player but limit up to 5 tiles
Case 5: jumpTo('forward', 3)
Jump the character forward from where it's currently facing by 3 tiles.
Case 6: jumpTo('backward', 3)
Jump the character backward from where it's currently facing by 3 tiles.
Case 7: jumpTo('away', 3)
Jump the character away from the game player by 3 tiles
Case 8: jumpTo('<enemy>', 3)
Jump the character to the nearby event with notetag <enemy> within 3 tiles distance
Case 9: jumpTo('<enemy>')
Same as case 7 but jump to the nearest <enemy> event

moveToPosition(x, y, rotate along(true/false))
A versatile command that will move the character to a target in pixel (requires DotMoveSystem)
Case 1: moveToPosition(15, 30)
Move the character to map coordination x15, y30
Case 2: moveToPosition('cursor')
Move the character to mouse cursor position
Case 3: moveToPosition('right stick')
Move the character to gamepad right stick direction
Case 4: moveToPosition('mouse or gamepad')
Auto-choose cursor or right stick if gamepad is connected
Case 5: moveToPosition('forward')
Move the character to wherever it's facing (support 360 degrees). Best for projectiles.
Case 6: moveToPosition('player')
Move the character to game player position
Case 6: moveToPosition('player pixel', 'player pixel')
Move the character to game player position but in pixel, not tile
Case 7: moveToPosition('player pixel - 0.5', 'player pixel + 6')
Move the character to game player position in pixel but with additional x - 0.5 tile and y + 6 tiles
Case 8: moveToPosition('<enemy>')
Move the character to nearby event with notetag <enemy>
Case 9: moveToPosition('comment: crop')
Move the character to an event that its page has comment crop
Cast 10: All above but with rotate along = true like moveToPosition('cursor', true)
Move the character to target and also rotate the character along the path. Best for projectiles.


moveToClosest(target, perfect pathfinding?, wait till finish?, exception)
Move the character to a target grid-based, support pathfinding.
Case 1: moveToClosest('player')
Move the character to game player
Case 2: moveToClosest('<enemy>')
Move the character to nearby event with notetag <enemy>
Case 3: moveToClosest('<enemy>', true)
Same as case 2 but with perfect pathfinding, automatically avoid obstacles. Best for ground characters.
Case 4: moveToClosest('<enemy>', true, true)
Same as case 3 but instead of move one step per command, with just this one command it'll move until it reaches its destination.
Case 5: moveToClosest('<enemy>', true, true, '<friendly>')
Same as case 4 but if the event <enemy> also has a notetag <friendly> then it won't chase said event. It'll only chase events with only <enemy> notetag.

teleportTo(x, min distance, max distance)
A versatile command that will teleport the character to a target
Case 1: teleportTo(15, 30)
Teleport the character to map coordination x15, y30
Case 2: teleportTo('player')
Teleport the character to the player position
Case 3: teleportTo('<enemy>')
Teleport the character to a nearby event with notetag <enemy>
Case 4: teleportTo('<enemy>', 3)
Teleport the character to a nearby event with notetag <enemy> that is outside a minimum distance of 3 tiles
Case 5: teleportTo('<enemy>', 3, 7)
Teleport the character to a nearby event with notetag <enemy> that is outside a minimum distance of 3 tiles but won't be further than 7 tiles
Case 6: teleportTo('forward', 5)
Teleport the player forward by 5 tiles from the direction he's heading. Won't teleport to impassable tiles.
Case 7: teleportTo('forward', 5, 'A3 A4 B')
Teleport the player forward by 5 tiles from the direction he's heading. Will teleport anywhere passable except impassable tiles from tileset A3, A4 and B.


shareDirection(target)
Make the character have the same direction as the target
Case 1: shareDirection('player')
Share the same direction of game player
Case 2: shareDirection(15)
Share the same direction of event id 15
Case 3: shareDirection('<enemy>')
Share the same direction of a nearby event with notetag <enemy>

setMoveSpeed(number)
By default, RPG Maker only supports max speed of 6. With this, you can break that limit.
setMoveSpeed(8)

-----------------------------------------------------------------------------------------------

Additional Features


self switch X
If an event with a page has a switch named self switch X, that switch becomes a self-switch of that page. This feature is to break the limitation of having only 4 self switches A B C D
5 RPG Maker Action Combat Manual: 📝 All Notetag, Comments, Conditional Branch and Movement Route commands Green text: Commonly used            Yellow text:  Optional ------------------------------------------------------------------------------...
< >