Namespace in reactor_battle_presentation.js
P
59 public functions in 4 groups · show internal (_) functions
Quick Reference
Setup & Creation 12
| load() | Load. |
| installActionRules() | Victor Battle Motions vocabulary that imported sequences lean on: an action steps forward instead of walking… |
| installCommandWindowAnchor() | Install command window anchor. |
| installMogHudNames() | MOG_BattleHud's MZ port draws each actor's name on a bare Bitmap, which MZ starts in sans-serif (MV started i… |
| installPsychronicHud() | Install psychronic hud. |
| installPartyLimit() | Install party limit. |
| installBattlebackLoading() | Install battleback loading. |
| installRoomAnchors() | Install room anchors. |
| installSequenceAnimations() | Install sequence animations. |
| installGraphics() | Install graphics. |
| install() | Install. |
| createRoom() | Creates the room. |
Actions 4
| resetSlow() | Resets the slow. |
| requestGraphicMotion() | Requests the graphic motion. |
| clearBattlerLayers() | Pictures a battler state left on its sprite go at the end of the battle. |
| showRoomPass() | The view's pass sprite for a room on the game's context, inside holder: made when there is none, and again wh… |
Updating & Drawing 6
| updateGraphicBitmap() | Updates the graphic bitmap each frame. |
| updateGraphicFrame() | Updates the graphic frame each frame. |
| updateStates() | Updates the states each frame. |
| drawnInRoom() | A battler (or a room event) drawn by its battle room, as a picture or a model there, draws nothing of its own… |
| updateRoom() | Updates the room each frame. |
| drawsEveryRefresh() | Draws every refresh. |
Other 37
| warn() | Warn. |
| json() | Json. |
| sequence() | Sequence. |
| usesSheet() | Whether a battler is drawn from a character sheet (rows per facing) rather than a side-view sheet (mirrored t… |
| spriteYaw() | The way a battler faces, as a yaw: the pose of a running sequence, the last Face Direction it was given, else… |
| compatibility() | Compatibility. |
| gatherResultDisplay() | Of the log methods queued from from on, the popups and battler reactions (popupDamage, perform*) move ahead o… |
| enginePlugins() | A battle engine plugin that moves and draws the battlers itself keeps them: Reactor's battler states (entry,… |
| reachAlong() | How far a body's box (world units: a room tile x is world x + 0.5, its y world z + 0.5) reaches from to, its… |
| adapter() | Adapter. |
| sequenceVisuals() | Sequence visuals. |
| evalSequence() | A sequence's script: a condition, a formula or a Run Script step, with the user and a target in reach. |
| gameCue() | The steps that change game data, audio or the screen play the same wherever a sequence runs: the battle scene… |
| extendAdapter() | Extend adapter. |
| battlerScreenBox() | Where a battler stands on the screen: its foot point and the top of its picture, in canvas pixels. |
| anchorCommandWindow() | With BattlePresentation.json's "commandWindow": "battler", the actor command window stands above the actor wh… |
| roomScreenPosition() | Room screen position. |
| patchBattleCursors() | Patch battle cursors. |
| slowAllowed() | Only in a room on Cinematic Cuts, with the game's battle camera not off and its slow motion on, and never in… |
| slowMotion() | Slow motion. |
| timeScale() | How fast the battle runs: 1, or less in slow motion. |
| rampSlow() | One frame of the screen: the speed moves toward what is asked, and what is asked runs out. |
| mirrorSpriteLook() | Mirror sprite look. |
| publishRoomBounds() | Publish room bounds. |
| battlerIdentity() | Battler identity. |
| graphicFor() | Graphic for. |
| engineMotion() | The engine asks an undecided side-view actor for 'walk' and a decided one for 'wait': the idle bob of a side-… |
| authoredState() | Whether the project wrote a sequence for this battler's state (through its own binding, its class, or a state… |
| battlerState() | Battler state. |
| cancelStates() | Cancel states. |
| preloadBattleModels() | The models a battle may throw or hold, asked for before the fight so the first throw does not fly for its twe… |
| rebuildRoom() | The game canvas's context came back after a loss: the room is built again as at the start of the battle. |
| fallPose() | Fall pose. |
| liePose() | A room model amount of the way down (0 standing, 1 flat). |
| lieBillboard() | Where a flat picture is drawn in a room when it lies amount of the way down: turned onto its side, resting on… |
| roomSpriteRefresh() | Sprite._refresh for a sprite drawn by its battle room: the pivot its frame gives it, and no texture. |
| flushRoom() | The room's picture for the frame: rendered, its battlers' bounds published, copied onto the battle's sprite. |
Setup & Creation
load
static sourceP.load()
Load.
installActionRules
static sourceP.installActionRules()
Victor Battle Motions vocabulary that imported sequences lean on: an action steps forward instead of walking up when it is friendly, self, magical, or a ranged weapon attack (attack motion type missile).
installCommandWindowAnchor
static sourceP.installCommandWindowAnchor()
Install command window anchor.
installMogHudNames
static sourceP.installMogHudNames()
MOG_BattleHud's MZ port draws each actor's name on a bare Bitmap, which MZ starts in sans-serif (MV started it in the game font), so the name is the one label on the HUD in the wrong face.
Details
MOG_BattleHud's MZ port draws each actor's name on a bare Bitmap, which MZ starts in sans-serif (MV started it in the game font), so the name is the one label on the HUD in the wrong face. It also draws at one size, so a long name runs past its box. The name takes the game font and shrinks until it fits the layout box.
installPsychronicHud
static sourceP.installPsychronicHud()
Install psychronic hud.
installPartyLimit
static sourceP.installPartyLimit()
Install party limit.
installBattlebackLoading
static sourceP.installBattlebackLoading()
Install battleback loading.
installRoomAnchors
static sourceP.installRoomAnchors()
Install room anchors.
installSequenceAnimations
static sourceP.installSequenceAnimations()
Install sequence animations.
installGraphics
static sourceP.installGraphics()
Install graphics.
install
static sourceP.install()
Install.
createRoom
static sourceP.createRoom(scene,config,token)
Creates the room.
Actions
resetSlow
static sourceP.resetSlow()
Resets the slow.
requestGraphicMotion
static sourceP.requestGraphicMotion(sprite,name)
Requests the graphic motion.
clearBattlerLayers
static sourceP.clearBattlerLayers(ss)
Pictures a battler state left on its sprite go at the end of the battle.
showRoomPass
static sourceP.showRoomPass(holder,room)
The view's pass sprite for a room on the game's context, inside holder: made when there is none, and again when the view's passes were (a new render scale from Auto quality, a resize), as the map's own pass sprites are.
Updating & Drawing
updateGraphicBitmap
static sourceP.updateGraphicBitmap(sprite,graphic,kind)
Updates the graphic bitmap each frame.
updateGraphicFrame
static sourceP.updateGraphicFrame(sprite,graphic)
Updates the graphic frame each frame.
updateStates
static sourceP.updateStates(ss)
Updates the states each frame.
drawnInRoom
static sourceP.drawnInRoom(sprite)
A battler (or a room event) drawn by its battle room, as a picture or a model there, draws nothing of its own: its flat sprite holds the empty texture for good.
Details
A battler (or a room event) drawn by its battle room, as a picture or a model there, draws nothing of its own: its flat sprite holds the empty texture for good. Its frame changes every few updates (the motion's cells), and a sprite builds itself a new texture for each (Sprite._refresh); here a change only moves its pivot, as it would have, so nothing is made and nothing is left behind.
updateRoom
static sourceP.updateRoom(ss)
Updates the room each frame.
drawsEveryRefresh
static sourceP.drawsEveryRefresh()
Draws every refresh.
Other
warn
static sourceP.warn(message)
Warn.
json
static sourceP.json(file,optional=false)
Json.
sequence
static sourceP.sequence(subject,action)
Sequence.
usesSheet
static sourceP.usesSheet(sprite)
Whether a battler is drawn from a character sheet (rows per facing) rather than a side-view sheet (mirrored to turn).
spriteYaw
static sourceP.spriteYaw(sprite,target)
The way a battler faces, as a yaw: the pose of a running sequence, the last Face Direction it was given, else toward its opponents in flat battles (a party along the bottom looks up) or its side for sprite sheets.
compatibility
static sourceP.compatibility()
Compatibility.
gatherResultDisplay
static sourceP.gatherResultDisplay(methods,from)
Of the log methods queued from from on, the popups and battler reactions (popupDamage, perform*) move ahead of the lines and waits, each group in its own order.
enginePlugins
static sourceP.enginePlugins()
A battle engine plugin that moves and draws the battlers itself keeps them: Reactor's battler states (entry, idle, damage, victory...) stand aside for Victor's Battle Motions and the YEP and VisuStella battle cores, and its battler graphics for Victor's Battle Motions and Battler Graphic Setup.
reachAlong
static sourceP.reachAlong(box,from,to)
How far a body's box (world units: a room tile x is world x + 0.5, its y world z + 0.5) reaches from to, its battler's place, back along the line toward from: where that line leaves the box.
Details
How far a body's box (world units: a room tile x is world x + 0.5, its y world z + 0.5) reaches from
to, its battler's place, back along the line toward from: where that line leaves the box. 0 when they meet.
adapter
static sourceP.adapter(manager,subject,targets,stateOnly=false)
Adapter.
sequenceVisuals
static sourceP.sequenceVisuals({ss,room,subject,manager,targets})
Sequence visuals.
evalSequence
static sourceP.evalSequence(code,subject,target,action,statement=false)
A sequence's script: a condition, a formula or a Run Script step, with the user and a target in reach.
gameCue
static sourceP.gameCue(step,env)
The steps that change game data, audio or the screen play the same wherever a sequence runs: the battle scene and a battle on the map (reactor_fight_stage.js) both hand them here.
Details
The steps that change game data, audio or the screen play the same
wherever a sequence runs: the battle scene and a battle on the map
(reactor_fight_stage.js) both hand them here. env: the battlers the
step chose, the user, number (a step value as a number), feedback
(shows a battler's result), audioSaved (kept across the run's steps).
Answers null when the step is not one of them, else {ticket} with what
the sequence waits on, if anything.
extendAdapter
static sourceP.extendAdapter(adapter,env)
Extend adapter.
battlerScreenBox
static sourceP.battlerScreenBox(battler)
Where a battler stands on the screen: its foot point and the top of its picture, in canvas pixels.
Details
Where a battler stands on the screen: its foot point and the top of its picture, in canvas pixels. A model in a room is projected through the room's camera; a flat sprite is measured from its frame.
anchorCommandWindow
static sourceP.anchorCommandWindow(window)
With BattlePresentation.json's "commandWindow": "battler", the actor command window stands above the actor whose turn it is, in a flat battle or a 3D room, wherever a HUD plugin would have parked it.
Details
With BattlePresentation.json's "commandWindow": "battler", the actor command window stands above the actor whose turn it is, in a flat battle or a 3D room, wherever a HUD plugin would have parked it. Set after the window's own update, so a HUD that moves it every frame (MOG_BattleHud slides it to the actor's box) is overruled every frame.
roomScreenPosition
static sourceP.roomScreenPosition(sprite)
Room screen position.
patchBattleCursors
static sourceP.patchBattleCursors(spriteset)
Patch battle cursors.
slowAllowed
static sourceP.slowAllowed()
Only in a room on Cinematic Cuts, with the game's battle camera not off and its slow motion on, and never in a battle shared online (each player's game would fall out of step with the others).
slowMotion
static sourceP.slowMotion(scale,frames)
Slow motion.
timeScale
static sourceP.timeScale()
How fast the battle runs: 1, or less in slow motion.
Details
How fast the battle runs: 1, or less in slow motion. Eased, never a step.
rampSlow
static sourceP.rampSlow()
One frame of the screen: the speed moves toward what is asked, and what is asked runs out.
mirrorSpriteLook
static sourceP.mirrorSpriteLook(sprite,battler,record)
Mirror sprite look.
publishRoomBounds
static sourceP.publishRoomBounds(sprite,room,key)
Publish room bounds.
battlerIdentity
static sourceP.battlerIdentity(battler)
Battler identity.
graphicFor
static sourceP.graphicFor(battler)
Graphic for.
engineMotion
static sourceP.engineMotion(sprite,name)
The engine asks an undecided side-view actor for 'walk' and a decided one for 'wait': the idle bob of a side-view sheet.
Details
The engine asks an undecided side-view actor for 'walk' and a decided one for 'wait': the idle bob of a side-view sheet. On a character sheet those are the walk cycle, so a battler drawn from one stands still on them unless a sequence or battler state is the one asking.
authoredState
static sourceP.authoredState(battler,state)
Whether the project wrote a sequence for this battler's state (through its own binding, its class, or a state it is under).
battlerState
static sourceP.battlerState(battler,sprite)
Battler state.
cancelStates
static sourceP.cancelStates(ss)
Cancel states.
preloadBattleModels
static sourceP.preloadBattleModels()
The models a battle may throw or hold, asked for before the fight so the first throw does not fly for its twenty frames while a 10 MB model is still loading and never appears.
Details
The models a battle may throw or hold, asked for before the fight so the first throw does not fly for its twenty frames while a 10 MB model is still loading and never appears. Every model a sequence names outright, every party weapon's bound model, and the bound model of every skill and item the party can use; the loader caches templates, so a model is read once for the whole game.
rebuildRoom
static sourceP.rebuildRoom(scene)
The game canvas's context came back after a loss: the room is built again as at the start of the battle.
Details
The game canvas's context came back after a loss: the room is built again as at the start of the battle. A room carried over draws some of its world wrong on the new context.
fallPose
static sourceP.fallPose(room,key,battler)
Fall pose.
liePose
static sourceP.liePose(room,key,amount)
A room model amount of the way down (0 standing, 1 flat).
Details
A room model amount of the way down (0 standing, 1 flat). Asked after room.place, which stands it up each frame.
lieBillboard
static sourceP.lieBillboard(position,frame,tall,amount)
Where a flat picture is drawn in a room when it lies amount of the way down: turned onto its side, resting on the floor it stood on.
roomSpriteRefresh
static sourceP.roomSpriteRefresh()
Sprite._refresh for a sprite drawn by its battle room: the pivot its frame gives it, and no texture.
flushRoom
static sourceP.flushRoom(ss)
The room's picture for the frame: rendered, its battlers' bounds published, copied onto the battle's sprite.