Class in reactor_objects_map.js

Game_Player

79 functions in 7 groups · hide internal

Everything here is tracked by Game Objects: the party, the map, its events.

Familiar territory. Game_Player keeps the RPG Maker MZ API, so existing MZ knowledge, tutorials and plugin code apply. Reactor's additions are marked with descriptions below.

Quick Reference

Setup & Creation 5

initialize() Sets up a new instance.
initMembers() Initializes the members.
setupForNewGame() Setup for new game.
makeEncounterCount() Makes the encounter count.
makeEncounterTroopId() Makes the encounter troop id.

Getting Information 4

getInputDirection() Gets the input direction.
getOnOffVehicle() Gets the on off vehicle.
getOnVehicle() Gets the on vehicle.
getOffVehicle() Gets the off vehicle.

Checks (True / False) 19

isStopping() Whether it is stopping.
isTransferring() Whether it is transferring.
isMapPassable() Whether it is map passable.
isInBoat() Whether it is in boat.
isInShip() Whether it is in ship.
isInAirship() Whether it is in airship.
isInVehicle() Whether it is in vehicle.
isNormal() Whether it is normal.
isDashing() Whether it is dashing.
isDebugThrough() Whether it is debug through.
isCollided() Whether it is collided.
canMove() Whether it can move.
isDiagonalMoveOn() Database › System 1 › Options › Diagonal movement (System.json "reactorDiagonalMove": true): two arrow keys h…
isDashButtonPressed() Whether it is dash button pressed.
canEncounter() Whether it can encounter.
canStartLocalEvents() Whether it can start local events.
isOnDamageFloor() Whether it is on damage floor.
areFollowersGathering() Whether they are followers gathering.
areFollowersGathered() Whether they are followers gathered.

Actions 15

clearTransferInfo() Clears the transfer info.
leaveByBorder() A step off the map on a side with a neighboring map (the map's Beyond the Border) goes on into that map.
leaveByLevel() A map can have a map under it and a map over it (Beyond the Border > Above and Below: surround.levels).
requestMapReload() Requests the map reload.
fadeType() Fade type.
performTransfer() Plays the transfer effect.
executeEncounter() Runs the encounter.
startMapEvent() Starts the map event.
moveByInput() Move by input.
executeMove() Runs the move.
moveStraight() Move straight.
moveDiagonally() Move diagonally.
jump() Jump.
showFollowers() Shows the followers.
hideFollowers() Hides the followers.

Events, Commands & Input 6

triggerAction() Trigger action.
triggerButtonAction() Trigger button action.
triggerTouchAction() Trigger touch action.
triggerTouchActionD1() Trigger touch action d1.
triggerTouchActionD2() Trigger touch action d2.
triggerTouchActionD3() Trigger touch action d3.

Updating & Drawing 9

refresh() Refresh.
update() Update.
updateDashing() Updates the dashing each frame.
updateScroll() Updates the scroll each frame.
updateVehicle() Updates the vehicle each frame.
updateVehicleGetOn() Updates the vehicle get on each frame.
updateVehicleGetOff() Updates the vehicle get off each frame.
updateNonmoving() Updates the nonmoving each frame.
updateEncounterCount() Updates the encounter count each frame.

Other 21

followers() Followers.
reserveTransfer() Reserve transfer.
arriveByLevel() Arrived from the map over or under: at the height it had, in this map's own measure, and still moving as it w…
arriveThroughLevel() Passed into the map over or under without a break: everyone is where they were, in the entered map's own tile…
borderCrossingTile() Arrived over a border without a break: the party is where it was, in the entered map's own tiles.
arriveByBorder() Arrive by border.
borderArrivalTile() Border arrival tile.
newMapId() New map id.
vehicle() Vehicle.
centerX() Center x.
centerY() Center y.
center() Center.
locate() Locate.
increaseSteps() Increase steps.
meetsEncounterConditions() Meets encounter conditions.
encounterProgressValue() Encounter progress value.
checkEventTriggerHere() Check event trigger here.
checkEventTriggerThere() Check event trigger there.
checkEventTriggerTouch() Check event trigger touch.
forceMoveForward() Force move forward.
gatherFollowers() Gather followers.

Setup & Creation

initialize

method source
Game_Player.prototype.initialize()

Sets up a new instance. (Same as the RPG Maker MZ method of this name.)

initMembers

method source
Game_Player.prototype.initMembers()

Initializes the members. (Same as the RPG Maker MZ method of this name.)

setupForNewGame

method source
Game_Player.prototype.setupForNewGame()

Setup for new game. (Same as the RPG Maker MZ method of this name.)

makeEncounterCount

method source
Game_Player.prototype.makeEncounterCount()

Makes the encounter count. (Same as the RPG Maker MZ method of this name.)

makeEncounterTroopId

method source
Game_Player.prototype.makeEncounterTroopId()

Makes the encounter troop id. (Same as the RPG Maker MZ method of this name.)

Getting Information

getInputDirection

method source
Game_Player.prototype.getInputDirection()

Gets the input direction. (Same as the RPG Maker MZ method of this name.)

getOnOffVehicle

method source
Game_Player.prototype.getOnOffVehicle()

Gets the on off vehicle. (Same as the RPG Maker MZ method of this name.)

getOnVehicle

method source
Game_Player.prototype.getOnVehicle()

Gets the on vehicle. (Same as the RPG Maker MZ method of this name.)

getOffVehicle

method source
Game_Player.prototype.getOffVehicle()

Gets the off vehicle. (Same as the RPG Maker MZ method of this name.)

Checks (True / False)

isStopping

method source
Game_Player.prototype.isStopping()

Whether it is stopping. (Same as the RPG Maker MZ method of this name.)

isTransferring

method source
Game_Player.prototype.isTransferring()

Whether it is transferring. (Same as the RPG Maker MZ method of this name.)

isMapPassable

method source
Game_Player.prototype.isMapPassable(x, y, d)

Whether it is map passable. (Same as the RPG Maker MZ method of this name.)

isInBoat

method source
Game_Player.prototype.isInBoat()

Whether it is in boat. (Same as the RPG Maker MZ method of this name.)

isInShip

method source
Game_Player.prototype.isInShip()

Whether it is in ship. (Same as the RPG Maker MZ method of this name.)

isInAirship

method source
Game_Player.prototype.isInAirship()

Whether it is in airship. (Same as the RPG Maker MZ method of this name.)

isInVehicle

method source
Game_Player.prototype.isInVehicle()

Whether it is in vehicle. (Same as the RPG Maker MZ method of this name.)

isNormal

method source
Game_Player.prototype.isNormal()

Whether it is normal. (Same as the RPG Maker MZ method of this name.)

isDashing

method source
Game_Player.prototype.isDashing()

Whether it is dashing. (Same as the RPG Maker MZ method of this name.)

isDebugThrough

method source
Game_Player.prototype.isDebugThrough()

Whether it is debug through. (Same as the RPG Maker MZ method of this name.)

isCollided

method source
Game_Player.prototype.isCollided(x, y)

Whether it is collided. (Same as the RPG Maker MZ method of this name.)

canMove

method source
Game_Player.prototype.canMove()

Whether it can move. (Same as the RPG Maker MZ method of this name.)

isDiagonalMoveOn

method source
Game_Player.prototype.isDiagonalMoveOn()

Database › System 1 › Options › Diagonal movement (System.json "reactorDiagonalMove": true): two arrow keys held together walk diagonally.

Details

Database › System 1 › Options › Diagonal movement (System.json "reactorDiagonalMove": true): two arrow keys held together walk diagonally. A project without the key walks in four directions, as it always did.

isDashButtonPressed

method source
Game_Player.prototype.isDashButtonPressed()

Whether it is dash button pressed. (Same as the RPG Maker MZ method of this name.)

canEncounter

method source
Game_Player.prototype.canEncounter()

Whether it can encounter. (Same as the RPG Maker MZ method of this name.)

canStartLocalEvents

method source
Game_Player.prototype.canStartLocalEvents()

Whether it can start local events. (Same as the RPG Maker MZ method of this name.)

isOnDamageFloor

method source
Game_Player.prototype.isOnDamageFloor()

Whether it is on damage floor. (Same as the RPG Maker MZ method of this name.)

areFollowersGathering

method source
Game_Player.prototype.areFollowersGathering()

Whether they are followers gathering. (Same as the RPG Maker MZ method of this name.)

areFollowersGathered

method source
Game_Player.prototype.areFollowersGathered()

Whether they are followers gathered. (Same as the RPG Maker MZ method of this name.)

Actions

clearTransferInfo

method source
Game_Player.prototype.clearTransferInfo()

Clears the transfer info. (Same as the RPG Maker MZ method of this name.)

leaveByBorder

method source
Game_Player.prototype.leaveByBorder(d, reach)

A step off the map on a side with a neighboring map (the map's Beyond the Border) goes on into that map.

Details

A step off the map on a side with a neighboring map (the map's Beyond the Border) goes on into that map. The arrival tile is found once that map is loaded: only then is its size known.

leaveByLevel

method source
Game_Player.prototype.leaveByLevel()

A map can have a map under it and a map over it (Beyond the Border > Above and Below: surround.levels).

Details

A map can have a map under it and a map over it (Beyond the Border > Above and Below: surround.levels). A player whose height passes the middle of the gap between the two (through an opening: a little under the upper map's ground, Reactor3D.levelMiddle) goes on in the other map, at the same place and height, still falling or climbing as it was: down a pit dug deep enough, up a ladder or a stair that reaches high enough. Without a break once that map stands built through an opening (Reactor3D.Levels); else with a fade.

requestMapReload

method source
Game_Player.prototype.requestMapReload()

Requests the map reload. (Same as the RPG Maker MZ method of this name.)

fadeType

method source
Game_Player.prototype.fadeType()

Fade type. (Same as the RPG Maker MZ method of this name.)

performTransfer

method source
Game_Player.prototype.performTransfer()

Plays the transfer effect. (Same as the RPG Maker MZ method of this name.)

executeEncounter

method source
Game_Player.prototype.executeEncounter()

Runs the encounter. (Same as the RPG Maker MZ method of this name.)

startMapEvent

method source
Game_Player.prototype.startMapEvent(x, y, triggers, normal)

Starts the map event. (Same as the RPG Maker MZ method of this name.)

moveByInput

method source
Game_Player.prototype.moveByInput()

Move by input. (Same as the RPG Maker MZ method of this name.)

executeMove

method source
Game_Player.prototype.executeMove(direction)

Runs the move. (Same as the RPG Maker MZ method of this name.)

moveStraight

method source
Game_Player.prototype.moveStraight(d)

Move straight. (Same as the RPG Maker MZ method of this name.)

moveDiagonally

method source
Game_Player.prototype.moveDiagonally(horz, vert)

Move diagonally. (Same as the RPG Maker MZ method of this name.)

jump

method source
Game_Player.prototype.jump(xPlus, yPlus)

Jump. (Same as the RPG Maker MZ method of this name.)

showFollowers

method source
Game_Player.prototype.showFollowers()

Shows the followers. (Same as the RPG Maker MZ method of this name.)

hideFollowers

method source
Game_Player.prototype.hideFollowers()

Hides the followers. (Same as the RPG Maker MZ method of this name.)

Events, Commands & Input

triggerAction

method source
Game_Player.prototype.triggerAction()

Trigger action. (Same as the RPG Maker MZ method of this name.)

triggerButtonAction

method source
Game_Player.prototype.triggerButtonAction()

Trigger button action. (Same as the RPG Maker MZ method of this name.)

triggerTouchAction

method source
Game_Player.prototype.triggerTouchAction()

Trigger touch action. (Same as the RPG Maker MZ method of this name.)

triggerTouchActionD1

method source
Game_Player.prototype.triggerTouchActionD1(x1, y1)

Trigger touch action d1. (Same as the RPG Maker MZ method of this name.)

triggerTouchActionD2

method source
Game_Player.prototype.triggerTouchActionD2(x2, y2)

Trigger touch action d2. (Same as the RPG Maker MZ method of this name.)

triggerTouchActionD3

method source
Game_Player.prototype.triggerTouchActionD3(x2, y2)

Trigger touch action d3. (Same as the RPG Maker MZ method of this name.)

Updating & Drawing

refresh

method source
Game_Player.prototype.refresh()

Refresh. (Same as the RPG Maker MZ method of this name.)

update

method source
Game_Player.prototype.update(sceneActive)

Update. (Same as the RPG Maker MZ method of this name.)

updateDashing

method source
Game_Player.prototype.updateDashing()

Updates the dashing each frame. (Same as the RPG Maker MZ method of this name.)

updateScroll

method source
Game_Player.prototype.updateScroll(lastScrolledX, lastScrolledY)

Updates the scroll each frame. (Same as the RPG Maker MZ method of this name.)

updateVehicle

method source
Game_Player.prototype.updateVehicle()

Updates the vehicle each frame. (Same as the RPG Maker MZ method of this name.)

updateVehicleGetOn

method source
Game_Player.prototype.updateVehicleGetOn()

Updates the vehicle get on each frame. (Same as the RPG Maker MZ method of this name.)

updateVehicleGetOff

method source
Game_Player.prototype.updateVehicleGetOff()

Updates the vehicle get off each frame. (Same as the RPG Maker MZ method of this name.)

updateNonmoving

method source
Game_Player.prototype.updateNonmoving(wasMoving, sceneActive)

Updates the nonmoving each frame. (Same as the RPG Maker MZ method of this name.)

updateEncounterCount

method source
Game_Player.prototype.updateEncounterCount()

Updates the encounter count each frame. (Same as the RPG Maker MZ method of this name.)

Other

followers

method source
Game_Player.prototype.followers()

Followers. (Same as the RPG Maker MZ method of this name.)

reserveTransfer

method source
Game_Player.prototype.reserveTransfer(mapId, x, y, d, fadeType)

Reserve transfer. (Same as the RPG Maker MZ method of this name.)

arriveByLevel

method source
Game_Player.prototype.arriveByLevel(level)

Arrived from the map over or under: at the height it had, in this map's own measure, and still moving as it was.

Details

Arrived from the map over or under: at the height it had, in this map's own measure, and still moving as it was. Under a floor here (it climbed up where nothing is dug), the ground takes it as a landing does.

arriveThroughLevel

method source
Game_Player.prototype.arriveThroughLevel(level)

Passed into the map over or under without a break: everyone is where they were, in the entered map's own tiles and heights.

Details

Passed into the map over or under without a break: everyone is where they were, in the entered map's own tiles and heights. Nobody is gathered onto the leader: the followers come after it by the way it went.

borderCrossingTile

method source
Game_Player.prototype.borderCrossingTile(exit, width, height)

Arrived over a border without a break: the party is where it was, in the entered map's own tiles.

Details

Arrived over a border without a break: the party is where it was, in the entered map's own tiles. The leader stands on tile and comes to it from where it stood; nobody is gathered onto the leader. The tile over a border crossed without a break: the very place the leader was in, in the entered map's tiles, held to the map. No tile is found for it: there is no step aside.

arriveByBorder

method source
Game_Player.prototype.arriveByBorder(exit, tile)

Arrive by border. (Same as the RPG Maker MZ method of this name.)

borderArrivalTile

method source
Game_Player.prototype.borderArrivalTile(exit)

Border arrival tile. (Same as the RPG Maker MZ method of this name.)

newMapId

method source
Game_Player.prototype.newMapId()

New map id. (Same as the RPG Maker MZ method of this name.)

vehicle

method source
Game_Player.prototype.vehicle()

Vehicle. (Same as the RPG Maker MZ method of this name.)

centerX

method source
Game_Player.prototype.centerX()

Center x. (Same as the RPG Maker MZ method of this name.)

centerY

method source
Game_Player.prototype.centerY()

Center y. (Same as the RPG Maker MZ method of this name.)

center

method source
Game_Player.prototype.center(x, y)

Center. (Same as the RPG Maker MZ method of this name.)

locate

method source
Game_Player.prototype.locate(x, y)

Locate. (Same as the RPG Maker MZ method of this name.)

increaseSteps

method source
Game_Player.prototype.increaseSteps()

Increase steps. (Same as the RPG Maker MZ method of this name.)

meetsEncounterConditions

method source
Game_Player.prototype.meetsEncounterConditions(encounter)

Meets encounter conditions. (Same as the RPG Maker MZ method of this name.)

encounterProgressValue

method source
Game_Player.prototype.encounterProgressValue()

Encounter progress value. (Same as the RPG Maker MZ method of this name.)

checkEventTriggerHere

method source
Game_Player.prototype.checkEventTriggerHere(triggers)

Check event trigger here. (Same as the RPG Maker MZ method of this name.)

checkEventTriggerThere

method source
Game_Player.prototype.checkEventTriggerThere(triggers)

Check event trigger there. (Same as the RPG Maker MZ method of this name.)

checkEventTriggerTouch

method source
Game_Player.prototype.checkEventTriggerTouch(x, y)

Check event trigger touch. (Same as the RPG Maker MZ method of this name.)

forceMoveForward

method source
Game_Player.prototype.forceMoveForward()

Force move forward. (Same as the RPG Maker MZ method of this name.)

gatherFollowers

method source
Game_Player.prototype.gatherFollowers()

Gather followers. (Same as the RPG Maker MZ method of this name.)