package org.project.location;

import org.project.entity.enemies.Enemy;

import java.util.ArrayList;

public class Location {

    private String name;

    private ArrayList<Enemy> enemies;

    private ArrayList<Location> connectedLocations;

    public Location(String name) {

        this.name = name;

        this.enemies = new ArrayList<>();
        this.connectedLocations = new ArrayList<>();
    }

    // add enemy to location
    public void addEnemy(Enemy enemy) {
        enemies.add(enemy);
    }

    // connect locations (for movement system)
    public void addLocation(Location location) {
        connectedLocations.add(location);
    }

    public String getName() {
        return name;
    }

    public ArrayList<Location> getLocations() {
        return connectedLocations;
    }

    public ArrayList<Enemy> getEnemies() {
        return enemies;
    }
}