export default class Player {
    constructor() {
        this.inventory = [];
        this.currentRoom = "start";
        this.context = null;
    }

    addItem(id) {
        console.log(`Adding item ${id} to player inv`);
        this.inventory.push(id);
    }

    removeItem(id) {
        this.inventory = this.inventory.filter((item) => item != id);
    }

    getInventory() {
        return this.inventory.map((item) => this.context.getItem(item));
    }
}