Ejemplo n.º 1
0
        public List <BattleAction> getRangedAttackActionList(int x, int y)
        {
            List <BattleAction> actionList = new List <BattleAction>();

            actionList.Add(new BattleAction()
            {
                character = ActiveCharacter, targetTile = board.getTileFromLocation(x, y), actionType = BattleActionType.RangedAttack
            });
            return(actionList);
        }
Ejemplo n.º 2
0
        //iterates over the path find and moves single spaces
        public static void moveToPlayer(GameCharacter enemy, GameCharacter target, Board board)
        {
            var pointList = PathFind.Pathfind(board, enemy.x, enemy.y, target.x, target.y);

            foreach (var p in pointList)
            {
                board.MoveCharacter(enemy, board.getTileFromLocation(p.x, p.y));
            }
        }
Ejemplo n.º 3
0
 //iterates over the path find and moves single spaces
 public static void moveToPlayer(GameCharacter enemy, GameCharacter target, Board board)
 {
     var pointList = PathFind.Pathfind(board, enemy.x, enemy.y, target.x, target.y);
     foreach(var p in pointList)
     {
         
         board.MoveCharacter(enemy, board.getTileFromLocation(p.x, p.y));
           
        
     }
 }