the-world-engine
Version:
three.js based, unity like game engine for browser
36 lines (35 loc) • 802 B
TypeScript
import { Component } from "../../hierarchy_object/Component";
/**
* enum for 4-directional movement
*/
export declare enum Direction {
Up = 0,
Down = 1,
Left = 2,
Right = 3
}
/**
* component that has direction information for movement
*
* this component is used for 2d grid-based game
*/
export declare class Directable extends Component {
private _direction;
private _isMoving;
/**
* looking direction
*/
get direction(): Direction;
/**
* looking direction
*/
protected set direction(direction: Direction);
/**
* if this component is moving this value will be true
*/
get isMoving(): boolean;
/**
* if this component is moving this value will be true
*/
protected set isMoving(isMoving: boolean);
}