import { Component, ComponentNames, Sprite } from ".";
import { Direction } from "../interfaces";

export class FacingDirection extends Component {
  public readonly directionSprites: Map<Direction, Sprite>;
  public currentDirection: Direction;

  constructor(currentDirection: Direction = Direction.NONE) {
    super(ComponentNames.FacingDirection);

    this.currentDirection = currentDirection;
    this.directionSprites = new Map<Direction, Sprite>();
  }

  public setDirection(direction: Direction) {
    this.currentDirection = direction;
  }
}
