@woosh/meep-engine
Version:
Pure JavaScript game engine. Fully featured and production ready.
46 lines (32 loc) • 1.06 kB
TypeScript
import Vector1 from "../../../../core/geom/Vector1";
import {PathFollowerFlags} from "./PathFollowerFlags";
export default class PathFollower {
/**
* Movement speed along the path in world units per second
*/
readonly speed: Vector1
/**
*
* Speed at which path follower can adjust rotation in Rad/s
*/
readonly rotationSpeed: Vector1
/**
*
* Absolute position along the path
*/
position: number
flags: number
/**
*
* Maximum distance that the follower can move along the path in a single step
*/
maxMoveDistance: number
public setFlag(flag: PathFollowerFlags | number): void
public clearFlag(flag: PathFollowerFlags | number): void
public writeFlag(flag: PathFollowerFlags | number, value: boolean): void
public getFlag(flag: PathFollowerFlags | number): boolean
public toJSON(): any
public fromJSON(json: any): void
static typeName: string
static fromJSON(json: any): PathFollower
}