Ejemplo n.º 1
0
    // Creates an empty tile, sets its location, adds a box collider
    public void Initialize(GameBoard gameBoard, float xLocation, float yLocation, float zLocation)
    {
        SetLocation(xLocation, yLocation, zLocation);
        this.gameBoard = gameBoard;
        this.gameObject.AddComponent(typeof(BoxCollider));
        graphicRenderer = GetComponent <Renderer>();
        observers.Add(gameBoard);

        states       = new TileStatesFactory(this);
        currentState = states.tileIdle;
    }
Ejemplo n.º 2
0
 public TileAwaitingMove(EmptyTile tile, TileStatesFactory stateGenerator)
 {
     this.tile = tile;
     states    = stateGenerator;
 }
Ejemplo n.º 3
0
 public TileIdle(Tileable tile, TileStatesFactory stateGenerator)
 {
     this.tile = tile;
     states    = stateGenerator;
 }
Ejemplo n.º 4
0
 public CursorOnHighlightedTile(Tileable tile, TileStatesFactory stateGenerator)
 {
     this.tile = tile;
     states    = stateGenerator;
 }
Ejemplo n.º 5
0
 public TileHighlighted(Tileable tile, TileStatesFactory stateGenerator)
 {
     this.tile = tile;
     states    = stateGenerator;
 }