module.exports = { setup: function () { Room.prototype = _Room.prototype; } } class _Room extends Room { // Initialize the room object init() { // Initialize memory if (this.memory.state == undefined) this.memory.state = ROOMSTATE_NEUTRAL; // Start game when spawn is in neutral room make it the capital. if (this.controller.my && this.memory.state == ROOMSTATE_NEUTRAL) this.memory.state = ROOMSTATE_CAPITAL; } }