public GridTile getAdjacentTile(Action a) {
        GridTile newTile = null;
        try {
            if(a.equals(Action.UP)) {
                newTile = world.getTiles().get(getX()).get(getY()-1);
            }
            if(a.equals(Action.DOWN)) {
                newTile = world.getTiles().get(getX()).get(getY()+1);
            }
            if(a.equals(Action.LEFT)) {
                newTile = world.getTiles().get(getX()-1).get(getY());
            }
            if(a.equals(Action.RIGHT)) {
                newTile = world.getTiles().get(getX()+1).get(getY());
            }
        }catch(Exception ex) {
            newTile = curTile;
        }
        return newTile;
    }