Class in reactor_battle_room.js

BattleRoomView

115 public functions in 5 groups · show internal (_) functions

A Battle Room.

Quick Reference

Setup & Creation 9

constructor() Sets up a new instance.
build() Build.
prepareMotions() Prepare motions.
attachmentQuaternion() The hand (or named bone) an attachment names, as a frame: its world orientation and the forearm's direction (…
attachmentWorld() Attachment world.
attachmentFrame() The hand's world orientation for a held step on a battler, or null when it is not held in a hand.
attachmentPoint() Attachment point.
ensureShadow() Ensure shadow.
buildMapMedia() Build map media.

Getting Information 1

pick() Pick.

Actions 18

addModel() Adds the model.
place() Place.
startDissolve() Ash and Ember for a model: the Collapse Effect trait's dissolves, which in a flat battle cut the sprite's bit…
remove() Remove.
releaseTarget() The view's guest pass, let go with the room.
releaseContext() three has driven the context: it forgets, and on the shared context PIXI does too.
beginCinematicAction() Begin cinematic action.
setCinematicFocus() Where the action is this frame, told by the running sequence: points in room tiles with a weight (a projectil…
startRecoil() Starts a hit recoil on a battler, away from a point in room tiles (the attacker), else straight back from its…
applyRecoil() Applies the recoil.
endCinematicAction() Ends the cinematic action.
restorePace() After the draw: everything blendPace moved, back where the game put it, its matrices with it.
applyMediaCorners() Battle previews also run in the editor, without the game media manager.
playMedia() Plays the media.
stopMedia() Stops the media.
playAnimation() Plays the animation.
stopEffect() Stops the effect.
dispose() Dispose.

Updating & Drawing 9

updateShadow() Updates the shadow each frame.
updateDissolve() Advance one model's dissolve: the wave front eats the model, the shards' clock runs, and at the end the model…
render() Render.
drawPaced() The room's picture on the game's context, at this refresh's moment.
drawsBetween() Whether the room is drawn again on a refresh that ran no update (the game's own context, frames not rounded t…
renderBetween() A refresh with no update: the same update's picture, at this refresh's moment.
updateMapMediaPlane() Updates the map media plane each frame.
updateMedia() Updates the media each frame.
updateEffects() Updates the effects each frame.

Other 78

light() Light.
billboard() A flat picture standing in the room: frame of source (a canvas), height tiles tall.
pictureStamp() How many times bitmap has been drawn on since it was first asked about (every Bitmap draw tells its texture t…
partEndWorld() The far end of a carved part along its own length (a gun's muzzle), in the room, carrying the part's current…
reachArm() Bends an arm so its hand lands on a point (two-bone reach in the room): the upper arm turns so the elbow sits…
holdAim() Holds a shown weapon the way its step asks: aimed, the shooting arm reaches down the line to the target so th…
holdHeld() Holds a shown weapon for this frame, in order: the aiming arm reaches (bending the arm), the hand's point is…
heldTipPoint() Where a held model's tip (a muzzle, a blade point) is, in room tiles, or null.
holdBoth() The other hand takes the held thing a little way out along it, as far as an arm reaches.
sequenceBillboard() Sequence billboard.
shadowTexture() A soft disc of shade under a battler, the way the engine draws one under a side-view actor.
wantsShadow() Wants shadow.
DISSOLVE() Dissolve.
surfaceShards() Points on the model's surface, area-weighted over its triangles (skinned meshes read as posed), each coloured…
fragmentGeometry() The model's surface as a field of loose triangles: glass, not grit.
fragmentMaterial() The fragments' material: each shard turns about its own middle, is thrown out from the model's, and falls.
surfaceColour() The colour of a spot on a triangle: texture pixel when readable, times material colour and vertex colour.
texturePixels() A texture's pixels through a canvas, read once per texture; null where there is no document or the image cann…
shardMaterial() The shard material: each point runs its own clock from its release, drifts up and curls, shrinks and fades; s…
resize() Resize.
passSprite() On the shared context: what PIXI shows the room with, the view's own pass sprite (its small target enlarged a…
passGeneration() Pass generation.
passSize() The pixels the room's picture is drawn at: its own size on its own canvas; on the game's context the view's p…
cinematicEnabled() Cinematic enabled.
cinematicMove() The next shot begins, from the picture shown now.
eyeOf() The eye of a camera state, in room tiles (x, y on the floor, z up).
cinematicArrive() How a move begun by cinematicMove reaches target, its first pose: the frames it takes (0 is a cut) and its cu…
SWOOP_IN() Frames for the move down from the overview and back up to it: the least, and the most for the longest way (as…
SWOOP_OUT() Swoop out.
SWOOP_MOST() Swoop most.
EASE_ARC() Between two close shots: a turn up to this many degrees is eased across, a wider one is a cut.
JUMP_REACH() A cut to a shot this near the one shown (tiles between what they look at, degrees between where they stand) i…
JUMP_ARC() Jump arc.
CUT_APART() Frames a shot is held before another cut may follow it; a nearer one eases over CUT_EASE frames.
CUT_EASE() Cut ease.
CUT_LINGER() Frames the last shot of an action stays up after the action ends, before the cut back to the overview.
distanceInsideRoom() The farthest the eye can stand back along a shot's yaw and pitch before it leaves the room, so a cut never lo…
EYE_CEILING() Eye ceiling.
CLOCK_MOST() The most updates one picture moves the room's clock by (SceneManager.MAX_UPDATES).
CAMERA_FOLLOW() How many frames behind its goal a cinematic shot follows (a critically damped spring: it starts and stops mov…
damp() One frame of that spring: state.x follows target (arrays), tau frames behind (ReactorFight.Camera.damp).
eyeBlockers() World boxes of everything a cut must not look through, cached for the shot.
aimTurn() Degrees a carved part must turn about its up axis to point at a room position.
aimTurnOf() The turn, in degrees about its up axis, that points a model's part at a place (tiles); a map unit's model is…
recoilOffset() A hit knocks a model back along the line from whoever hit it, then it springs forward past home and settles:…
modelHeight() How tall a battler's model stands in the room, in tiles (a tank's size is its length, not its height).
focusHeight() Focus height.
focusSize() What a shot of a battler has to hold: how tall it stands and how much floor it covers, in tiles, from the mod…
cinematicImpact() Cinematic impact.
cinematicKill() A target died of this action's hit: the hit shot closes in on it (the battle slows meanwhile: ReactorBattlePr…
KILL_PUSH() How much nearer the hit shot stands on a kill, as a share of its distance.
overShoulder() The actor's shot before the hit, over its shoulder: the eye behind the actor and off to one side, at about it…
OVER_LEAST() Tiles between an actor and who it aims at under which the shot is of the actor alone.
HIT_HOLD() Frames the hit shot stays after the last hit landed; the rest of the action (the walk home) is watched from t…
cinematicBlend() Cinematic blend.
cinematicCamera() Cinematic camera.
cameraState() Camera state.
aim() Aim.
followCamera() Follow camera.
project() Project.
boxOf() A battler's box in the room.
bounds() Bounds.
pacedNow() Whether refreshes come faster than updates, so a picture between two updates has somewhere to go.
PACE_EASE() Updates over which the picture goes from the updates' own moment to the paced one and back (FramePacing.EASE_…
PACE_CAMERA_JUMP() Past these in one update the camera cut (tiles, radians) or a thing was put elsewhere (tiles): drawn where it…
PACE_CAMERA_TURN() Pace camera turn.
PACE_JUMP() Pace jump.
capturePace() Once an update, when everything is posed: where the camera and every node of every model and picture stand, b…
blendPace() Everything that moved in the last update, put alpha of the way from where it stood before it.
paceSet() Pace set.
fireRuleEffects() A rule's timed effects (a muzzle flash at the cannon, a sound) fire once each as the action clock passes them.
effectActive() Effect active.
propAction() Prop action.
claimShadows() Whether this room draws the shared shadow rows this frame (the map's own, see Reactor3D.prepareWorldFrame).
roomAmbient() The map's ambient as the map shows it now: an AmbientLight command's ease included.
roomLights() Room lights.
queueEffect() Queue effect.
cueUnit() Tiles an effect unit takes for a battle animation starting at world: what makes it as many pixels as on the b…

Setup & Creation

constructor

constructor source
new BattleRoomView(map, tileset, settings, assets)

Sets up a new instance.

build

method source
BattleRoomView.prototype.async build()

Build.

prepareMotions

static source
BattleRoomView.static prepareMotions(record)

Prepare motions.

attachmentQuaternion

static source
BattleRoomView.static attachmentQuaternion(record, attachment, boneName)

The hand (or named bone) an attachment names, as a frame: its world orientation and the forearm's direction (from the joint above it to it, in the room), or null for an offset or a carved part.

attachmentWorld

static source
BattleRoomView.static attachmentWorld(record, attachment, boneName, mode)

Attachment world.

attachmentFrame

method source
BattleRoomView.prototype.attachmentFrame(key, step)

The hand's world orientation for a held step on a battler, or null when it is not held in a hand.

attachmentPoint

method source
BattleRoomView.prototype.attachmentPoint(key, step, pose)

Attachment point.

ensureShadow

method source
BattleRoomView.prototype.ensureShadow(key, record)

Ensure shadow.

buildMapMedia

method source
BattleRoomView.prototype.buildMapMedia()

Build map media.

Getting Information

pick

method source
BattleRoomView.prototype.pick(x,y,height=0)

Pick.

Actions

addModel

method source
BattleRoomView.prototype.async addModel(key, spec, position)

Adds the model.

place

method source
BattleRoomView.prototype.place(key, position)

Place.

startDissolve

method source
BattleRoomView.prototype.startDissolve(key, presetName)

Ash and Ember for a model: the Collapse Effect trait's dissolves, which in a flat battle cut the sprite's bitmap into shards.

Details

Ash and Ember for a model: the Collapse Effect trait's dissolves, which in a flat battle cut the sprite's bitmap into shards. Here the model's surface is sampled into shards coloured from its own textures and released on a wave from the feet up, each drifting, curling, shrinking and fading, while the model itself is eaten from the feet up behind them. Ember tints the shards towards fire and adds additive sparks. Returns how many frames it lasts, or 0 when the key has no drawn model; the caller keeps the engine's collapse running that long so the battle waits for it.

remove

method source
BattleRoomView.prototype.remove(key)

Remove.

releaseTarget

method source
BattleRoomView.prototype.releaseTarget()

The view's guest pass, let go with the room.

releaseContext

method source
BattleRoomView.prototype.releaseContext()

three has driven the context: it forgets, and on the shared context PIXI does too.

beginCinematicAction

method source
BattleRoomView.prototype.beginCinematicAction(user,targets)

Begin cinematic action.

setCinematicFocus

method source
BattleRoomView.prototype.setCinematicFocus(points,{yawOffset,hold=3}={})

Where the action is this frame, told by the running sequence: points in room tiles with a weight (a projectile in flight counts double, so the camera rides with it while its target stays in frame) and, for a battler, its room key so its height sizes the shot.

Details

Where the action is this frame, told by the running sequence: points in room tiles with a weight (a projectile in flight counts double, so the camera rides with it while its target stays in frame) and, for a battler, its room key so its height sizes the shot. The report holds for a few frames; without one the shot falls back to user/targets.

startRecoil

method source
BattleRoomView.prototype.startRecoil(key, from)

Starts a hit recoil on a battler, away from a point in room tiles (the attacker), else straight back from its facing.

applyRecoil

method source
BattleRoomView.prototype.applyRecoil(record)

Applies the recoil.

endCinematicAction

method source
BattleRoomView.prototype.endCinematicAction()

Ends the cinematic action.

restorePace

method source
BattleRoomView.prototype.restorePace()

After the draw: everything blendPace moved, back where the game put it, its matrices with it.

applyMediaCorners

method source
BattleRoomView.prototype.applyMediaCorners(geometry,corners,width,height)

Battle previews also run in the editor, without the game media manager.

playMedia

method source
BattleRoomView.prototype.playMedia(media)

Plays the media.

stopMedia

method source
BattleRoomView.prototype.stopMedia(media)

Stops the media.

playAnimation

method source
BattleRoomView.prototype.playAnimation(key,animationId,transform={})

Plays the animation.

stopEffect

method source
BattleRoomView.prototype.stopEffect(play)

Stops the effect.

dispose

method source
BattleRoomView.prototype.dispose()

Dispose.

Updating & Drawing

updateShadow

method source
BattleRoomView.prototype.updateShadow(record)

Updates the shadow each frame.

updateDissolve

method source
BattleRoomView.prototype.updateDissolve(record)

Advance one model's dissolve: the wave front eats the model, the shards' clock runs, and at the end the model is gone and the shards are freed.

render

method source
BattleRoomView.prototype.render()

Render.

drawPaced

method source
BattleRoomView.prototype.drawPaced()

The room's picture on the game's context, at this refresh's moment.

Details

The room's picture on the game's context, at this refresh's moment. Where the screen refreshes faster than the game updates (pacedNow), the camera and everything the room places are drawn between where the update before last left them and where the last did (Graphics.FramePacing.alphaNow, as a map's models are), and put back at once: the game's own places, project and bounds are never the blended ones. Effects, flat shadows' rows, reflections and the pictures over the room move with the updates.

drawsBetween

method source
BattleRoomView.prototype.drawsBetween()

Whether the room is drawn again on a refresh that ran no update (the game's own context, frames not rounded to 60).

renderBetween

method source
BattleRoomView.prototype.renderBetween()

A refresh with no update: the same update's picture, at this refresh's moment.

Details

A refresh with no update: the same update's picture, at this refresh's moment. Poses, lights and shadows are the update's.

updateMapMediaPlane

method source
BattleRoomView.prototype.updateMapMediaPlane(media, surface)

Updates the map media plane each frame.

updateMedia

method source
BattleRoomView.prototype.updateMedia(record)

Updates the media each frame.

updateEffects

method source
BattleRoomView.prototype.updateEffects()

Updates the effects each frame.

Other

light

method source
BattleRoomView.prototype.light(object)

Light.

billboard

method source
BattleRoomView.prototype.billboard(key, source, frame, position, height = 2, bitmap = null)

A flat picture standing in the room: frame of source (a canvas), height tiles tall.

Details

A flat picture standing in the room: frame of source (a canvas), height tiles tall. Its pixels are copied and sent to the graphics card only when it is another picture: another frame, another canvas, or, with the bitmap the canvas belongs to, that bitmap drawn on since (pictureStamp). Without one it is copied every call.

pictureStamp

static source
BattleRoomView.static pictureStamp(bitmap)

How many times bitmap has been drawn on since it was first asked about (every Bitmap draw tells its texture to update), or -1 when that cannot be known (no bitmap).

Details

How many times bitmap has been drawn on since it was first asked about (every Bitmap draw tells its texture to update), or -1 when that cannot be known (no bitmap). A new texture under the bitmap (its canvas made from its image) counts as a change.

partEndWorld

static source
BattleRoomView.static partEndWorld(record, partName)

The far end of a carved part along its own length (a gun's muzzle), in the room, carrying the part's current pose: the part's forward is from the pivot of the part around it to its own pivot, and its geometry's furthest point along that is the end.

reachArm

method source
BattleRoomView.prototype.reachArm(key, side, target, {down=.5}={})

Bends an arm so its hand lands on a point (two-bone reach in the room): the upper arm turns so the elbow sits on the shoulder-to- point line, off toward where it already bends and downward, then the forearm turns to the point.

Details

Bends an arm so its hand lands on a point (two-bone reach in the room): the upper arm turns so the elbow sits on the shoulder-to- point line, off toward where it already bends and downward, then the forearm turns to the point. Works on the joints the pose rules already move, after them, for this frame.

holdAim

method source
BattleRoomView.prototype.holdAim(ownerKey, heldKey, step, at)

Holds a shown weapon the way its step asks: aimed, the shooting arm reaches down the line to the target so the barrel (laid along that line) points at it and the stock sits back by the shoulder; the answer is the hand frame to place the item with.

holdHeld

method source
BattleRoomView.prototype.holdHeld(ownerKey, heldKey, step, ownerPose, at, placement)

Holds a shown weapon for this frame, in order: the aiming arm reaches (bending the arm), the hand's point is read from the bent arm, the item is placed there in the hand's frame, then the other hand takes it.

Details

Holds a shown weapon for this frame, in order: the aiming arm reaches (bending the arm), the hand's point is read from the bent arm, the item is placed there in the hand's frame, then the other hand takes it. Returns the hand point in room tiles.

heldTipPoint

method source
BattleRoomView.prototype.heldTipPoint(heldKey)

Where a held model's tip (a muzzle, a blade point) is, in room tiles, or null.

holdBoth

method source
BattleRoomView.prototype.holdBoth(ownerKey, heldKey, step)

The other hand takes the held thing a little way out along it, as far as an arm reaches.

sequenceBillboard

method source
BattleRoomView.prototype.sequenceBillboard(key,source,frame,point,step={})

Sequence billboard.

shadowTexture

static source
BattleRoomView.static shadowTexture()

A soft disc of shade under a battler, the way the engine draws one under a side-view actor.

Details

A soft disc of shade under a battler, the way the engine draws one under a side-view actor. The room draws with its own renderer, which the map's shadow atlas does not serve, so this is the shadow a battler gets: on the floor beneath its feet, smaller and fainter the higher it jumps, gone when the battler is. Props and thrown things cast none; the flat 2D layout draws none.

wantsShadow

static source
BattleRoomView.static wantsShadow(key, settings)

Wants shadow.

DISSOLVE

static source
BattleRoomView.static get DISSOLVE()

Dissolve.

surfaceShards

static source
BattleRoomView.static surfaceShards(object, count, T)

Points on the model's surface, area-weighted over its triangles (skinned meshes read as posed), each coloured from the material's texture at that spot when its pixels can be read, else from the material's colour times any vertex colour.

Details

Points on the model's surface, area-weighted over its triangles (skinned meshes read as posed), each coloured from the material's texture at that spot when its pixels can be read, else from the material's colour times any vertex colour. World space.

fragmentGeometry

static source
BattleRoomView.static fragmentGeometry(shards, size, T, spinRate = .22)

The model's surface as a field of loose triangles: glass, not grit.

Details

The model's surface as a field of loose triangles: glass, not grit.

A point sprite is a screen-aligned square however it is masked, which reads as specks; a shard of glass has to be a real polygon that tumbles. Each fragment is three vertices cut in the tangent plane of the surface at a sampled point, at irregular angles and radii so no two are the same shape, carrying the middle it turns about, the axis it turns on and the colour the model wears there.

fragmentMaterial

static source
BattleRoomView.static fragmentMaterial(T, preset, centre, roomUniforms, floor)

The fragments' material: each shard turns about its own middle, is thrown out from the model's, and falls.

surfaceColour

static source
BattleRoomView.static surfaceColour(tri, r0, r1, r2, T)

The colour of a spot on a triangle: texture pixel when readable, times material colour and vertex colour.

texturePixels

static source
BattleRoomView.static texturePixels(texture)

A texture's pixels through a canvas, read once per texture; null where there is no document or the image cannot be drawn.

shardMaterial

static source
BattleRoomView.static shardMaterial(T, preset, sparks, centre)

The shard material: each point runs its own clock from its release, drifts up and curls, shrinks and fades; sparks are the additive kind.

resize

method source
BattleRoomView.prototype.resize(width,height)

Resize.

passSprite

method source
BattleRoomView.prototype.passSprite(width=this.width,height=this.height)

On the shared context: what PIXI shows the room with, the view's own pass sprite (its small target enlarged and sharpened as the map's passes are), laid over width by height.

Details

On the shared context: what PIXI shows the room with, the view's own pass sprite (its small target enlarged and sharpened as the map's passes are), laid over width by height. Made again by the caller when the view's passes are (passGeneration changes: a new render scale, a resize).

passGeneration

method source
BattleRoomView.prototype.passGeneration()

Pass generation.

passSize

method source
BattleRoomView.prototype.passSize()

The pixels the room's picture is drawn at: its own size on its own canvas; on the game's context the view's pass (the screen at the view's render scale).

Details

The pixels the room's picture is drawn at: its own size on its own canvas; on the game's context the view's pass (the screen at the view's render scale). What is sized in pixels follows it: an effect's own picture, a dissolve's points.

cinematicEnabled

method source
BattleRoomView.prototype.cinematicEnabled()

Cinematic enabled.

cinematicMove

method source
BattleRoomView.prototype.cinematicMove(kind)

The next shot begins, from the picture shown now.

Details

The next shot begins, from the picture shown now. How it gets there is settled when the new shot's first pose is known (cinematicArrive), as a film would:

'in' an action opens. From the overview the camera swoops down to the actor (SWOOP_IN frames or more for a long way); from another close shot it eases across when that is a short turn, and cuts when it would have to swing round the room. 'cut' the hit. A cut, unless the new shot is nearly the one shown (the camera rode in with a runner and is already on the target): a cut of a few tiles and under JUMP_ARC degrees reads as a skipped frame, so that is an ease too. A cut moments after another is an ease, so three pictures never flash by in a row. 'out' back to the saved overview: the camera pulls up and away over SWOOP_OUT frames or more.

(Every one of these was a cut until 2026-11-13: three a action, an action every second or two.)

eyeOf

static source
BattleRoomView.static eyeOf(c)

The eye of a camera state, in room tiles (x, y on the floor, z up).

cinematicArrive

method source
BattleRoomView.prototype.cinematicArrive(transition,target)

How a move begun by cinematicMove reaches target, its first pose: the frames it takes (0 is a cut) and its curve.

SWOOP_IN

static source
BattleRoomView.static get SWOOP_IN()

Frames for the move down from the overview and back up to it: the least, and the most for the longest way (as a battle on the map: ReactorFight.Camera.SWOOP_IN).

SWOOP_OUT

static source
BattleRoomView.static get SWOOP_OUT()

Swoop out.

SWOOP_MOST

static source
BattleRoomView.static get SWOOP_MOST()

Swoop most.

EASE_ARC

static source
BattleRoomView.static get EASE_ARC()

Between two close shots: a turn up to this many degrees is eased across, a wider one is a cut.

JUMP_REACH

static source
BattleRoomView.static get JUMP_REACH()

A cut to a shot this near the one shown (tiles between what they look at, degrees between where they stand) is an ease instead.

JUMP_ARC

static source
BattleRoomView.static get JUMP_ARC()

Jump arc.

CUT_APART

static source
BattleRoomView.static get CUT_APART()

Frames a shot is held before another cut may follow it; a nearer one eases over CUT_EASE frames.

CUT_EASE

static source
BattleRoomView.static get CUT_EASE()

Cut ease.

CUT_LINGER

static source
BattleRoomView.static get CUT_LINGER()

Frames the last shot of an action stays up after the action ends, before the cut back to the overview.

distanceInsideRoom

method source
BattleRoomView.prototype.distanceInsideRoom(c)

The farthest the eye can stand back along a shot's yaw and pitch before it leaves the room, so a cut never looks in from behind a wall.

EYE_CEILING

static source
BattleRoomView.static get EYE_CEILING()

Eye ceiling.

CLOCK_MOST

static source
BattleRoomView.static get CLOCK_MOST()

The most updates one picture moves the room's clock by (SceneManager.MAX_UPDATES).

CAMERA_FOLLOW

static source
BattleRoomView.static get CAMERA_FOLLOW()

How many frames behind its goal a cinematic shot follows (a critically damped spring: it starts and stops moving gently).

damp

static source
BattleRoomView.static damp(state,target,tau)

One frame of that spring: state.x follows target (arrays), tau frames behind (ReactorFight.Camera.damp).

Details

One frame of that spring: state.x follows target (arrays), tau frames behind (ReactorFight.Camera.damp).

eyeBlockers

method source
BattleRoomView.prototype.eyeBlockers()

World boxes of everything a cut must not look through, cached for the shot.

aimTurn

method source
BattleRoomView.prototype.aimTurn(key,partName,at)

Degrees a carved part must turn about its up axis to point at a room position.

Details

Degrees a carved part must turn about its up axis to point at a room position. The part's rest forward is the line from its pivot to the pivot of the part nested inside it (a turret's gun), else the model's own forward; both are taken from the live object, so the answer holds whatever way the battler faces or the file leans.

aimTurnOf

static source
BattleRoomView.static aimTurnOf(record,partName,at)

The turn, in degrees about its up axis, that points a model's part at a place (tiles); a map unit's model is measured the same way (reactor_fight_stage.js).

recoilOffset

static source
BattleRoomView.static recoilOffset(t, size=2)

A hit knocks a model back along the line from whoever hit it, then it springs forward past home and settles: the offset in tiles for a frame of the recoil, or null once it is over.

Details

A hit knocks a model back along the line from whoever hit it, then it springs forward past home and settles: the offset in tiles for a frame of the recoil, or null once it is over. Big models move less.

modelHeight

method source
BattleRoomView.prototype.modelHeight(key)

How tall a battler's model stands in the room, in tiles (a tank's size is its length, not its height).

focusHeight

method source
BattleRoomView.prototype.focusHeight(record)

Focus height.

focusSize

method source
BattleRoomView.prototype.focusSize(record)

What a shot of a battler has to hold: how tall it stands and how much floor it covers, in tiles, from the model as it is posed.

Details

What a shot of a battler has to hold: how tall it stands and how much floor it covers, in tiles, from the model as it is posed. (Its size in the database is its longest side: a tank's length, which framed a tank as though it were as tall as it is long, from under the ceiling.)

cinematicImpact

method source
BattleRoomView.prototype.cinematicImpact()

Cinematic impact.

cinematicKill

method source
BattleRoomView.prototype.cinematicKill()

A target died of this action's hit: the hit shot closes in on it (the battle slows meanwhile: ReactorBattlePresentation.slowMotion).

KILL_PUSH

static source
BattleRoomView.static get KILL_PUSH()

How much nearer the hit shot stands on a kill, as a share of its distance.

overShoulder

method source
BattleRoomView.prototype.overShoulder(base,shot,user,age)

The actor's shot before the hit, over its shoulder: the eye behind the actor and off to one side, at about its head, looking at who it aims at, so the actor stands large at one edge of the picture and its target down the line (owner, 2026-11-13: as XCOM frames a shot).

Details

The actor's shot before the hit, over its shoulder: the eye behind the actor and off to one side, at about its head, looking at who it aims at, so the actor stands large at one edge of the picture and its target down the line (owner, 2026-11-13: as XCOM frames a shot). It drifts a little further out as it holds. Null where that cannot be: nobody else to aim at, the target right against the actor, or no room behind the actor on either side (a wall, a prop); the shot of the actor alone is used then, as before.

OVER_LEAST

static source
BattleRoomView.static get OVER_LEAST()

Tiles between an actor and who it aims at under which the shot is of the actor alone.

HIT_HOLD

static source
BattleRoomView.static get HIT_HOLD()

Frames the hit shot stays after the last hit landed; the rest of the action (the walk home) is watched from the overview.

cinematicBlend

method source
BattleRoomView.prototype.cinematicBlend(target)

Cinematic blend.

cinematicCamera

method source
BattleRoomView.prototype.cinematicCamera(base)

Cinematic camera.

cameraState

method source
BattleRoomView.prototype.cameraState()

Camera state.

aim

method source
BattleRoomView.prototype.aim()

Aim.

followCamera

method source
BattleRoomView.prototype.followCamera(target)

Follow camera.

project

method source
BattleRoomView.prototype.project(position)

Project.

boxOf

method source
BattleRoomView.prototype.boxOf(record)

A battler's box in the room.

Details

A battler's box in the room. A skinned model's is measured from the pose it stands in, a few times a second, and carried with the model between: its rest geometry lies wherever its file left it (a point at the feet for a rig scaled by its armature), which put a target cursor and a window that follows the actor at the feet.

bounds

method source
BattleRoomView.prototype.bounds(key)

Bounds.

pacedNow

method source
BattleRoomView.prototype.pacedNow()

Whether refreshes come faster than updates, so a picture between two updates has somewhere to go.

PACE_EASE

static source
BattleRoomView.static get PACE_EASE()

Updates over which the picture goes from the updates' own moment to the paced one and back (FramePacing.EASE_FRAMES).

PACE_CAMERA_JUMP

static source
BattleRoomView.static get PACE_CAMERA_JUMP()

Past these in one update the camera cut (tiles, radians) or a thing was put elsewhere (tiles): drawn where it is.

PACE_CAMERA_TURN

static source
BattleRoomView.static get PACE_CAMERA_TURN()

Pace camera turn.

PACE_JUMP

static source
BattleRoomView.static get PACE_JUMP()

Pace jump.

capturePace

method source
BattleRoomView.prototype.capturePace()

Once an update, when everything is posed: where the camera and every node of every model and picture stand, beside where they stood an update ago.

Details

Once an update, when everything is posed: where the camera and every node of every model and picture stand, beside where they stood an update ago. A thing new this update, or whose parts changed, has no place before.

blendPace

method source
BattleRoomView.prototype.blendPace(alpha)

Everything that moved in the last update, put alpha of the way from where it stood before it.

Details

Everything that moved in the last update, put alpha of the way from where it stood before it. True when anything was.

paceSet

static source
BattleRoomView.static paceSet(node,prev,live,k,alpha)

Pace set.

fireRuleEffects

method source
BattleRoomView.prototype.fireRuleEffects(record,action)

A rule's timed effects (a muzzle flash at the cannon, a sound) fire once each as the action clock passes them.

effectActive

method source
BattleRoomView.prototype.effectActive(record,effect)

Effect active.

propAction

method source
BattleRoomView.prototype.propAction(record)

Prop action.

claimShadows

method source
BattleRoomView.prototype.claimShadows()

Whether this room draws the shared shadow rows this frame (the map's own, see Reactor3D.prepareWorldFrame).

Details

Whether this room draws the shared shadow rows this frame (the map's own, see Reactor3D.prepareWorldFrame). Its lit programs follow: on a change they are compiled again, the others' uniforms never reused.

roomAmbient

method source
BattleRoomView.prototype.roomAmbient()

The map's ambient as the map shows it now: an AmbientLight command's ease included.

roomLights

method source
BattleRoomView.prototype.roomLights()

Room lights.

queueEffect

method source
BattleRoomView.prototype.queueEffect(id,owner,effect,transient=false)

Queue effect.

cueUnit

method source
BattleRoomView.prototype.cueUnit(world)

Tiles an effect unit takes for a battle animation starting at world: what makes it as many pixels as on the battle screen (2048 * h / (h + 40960) a unit on a screen h pixels tall), from how big a tile is drawn there by the room's camera now.