Skip to content

FirstPerspective (First-Person Roaming) ​

First-person ground-based roaming tool. For keyboard roaming, first click on the map to activate, then press W to move forward, S to move backward, A to move left, D to move right.

Constructor ​

ts
new ge3d.matter.FirstPerspective(options?): FirstPerspective

Parameters ​

ParameterTypeDefaultDescription
idString/Numberuuid()Object id identifier
enabledBooleantrueObject enabled state
speedNumber1.5Speed
rotateSpeedNumber-5Rotation speed
heightNumber10Height
maxPitchNumber88Maximum pitch angle (degrees)

Properties ​

PropertyTypeDescription
idanyObject id identifier
enabledanyObject enabled state
entityvoidRoaming object
offsetvoidRoaming offset value

Methods ​

start ​

Start roaming

ts
start(): void

stop ​

Stop roaming

ts
stop(): void

clear ​

Clear vector object data

ts
clear(): void

destroy ​

Destroy vector object data

ts
destroy(noDel?): void