|
|
|
@@ -88,6 +88,11 @@ export const Newtown = (): Place => { |
|
|
|
"Town street north of the Town square" |
|
|
|
) |
|
|
|
|
|
|
|
const northTownShop = new Place( |
|
|
|
new ProperNoun("North Town Shop"), |
|
|
|
"A shop for your impulsive buying needs" |
|
|
|
) |
|
|
|
|
|
|
|
const eastTownStreet = new Place( |
|
|
|
new ProperNoun("East Town Street"), |
|
|
|
"Town street east of the Town square" |
|
|
|
@@ -187,6 +192,58 @@ export const Newtown = (): Place => { |
|
|
|
) |
|
|
|
) |
|
|
|
|
|
|
|
townSquare.choices.push( |
|
|
|
new Choice( |
|
|
|
"Eat someone", |
|
|
|
"Slurp", |
|
|
|
(world, executor) => { |
|
|
|
const snack = new Human(new ProperNoun(["Snack", "Treat", "Tasty", "Dinner", "Appetizer"][Math.floor(Math.random() * 5)]), [MalePronouns, FemalePronouns, TheyPronouns][Math.floor(Math.random() * 3)]) |
|
|
|
snack.applyEffect(new SurrenderEffect()) |
|
|
|
const options = executor.validActions(snack).filter(action => action instanceof DevourAction) |
|
|
|
return options[Math.floor(options.length * Math.random())].execute(executor, snack) |
|
|
|
} |
|
|
|
) |
|
|
|
) |
|
|
|
|
|
|
|
townSquare.choices.push( |
|
|
|
new Choice( |
|
|
|
"Fight someone", |
|
|
|
"Ow", |
|
|
|
(world) => { |
|
|
|
const enemy = new Human(new ProperNoun("Nerd"), TheyPronouns) |
|
|
|
enemy.side = Side.Monsters |
|
|
|
enemy.ai = new VoreAI(enemy) |
|
|
|
enemy.equip(new Items.Sword(), Items.EquipmentSlot.MainHand) |
|
|
|
enemy.addPerk(new DeliciousPerk()) |
|
|
|
const encounter = new Encounter( |
|
|
|
{ |
|
|
|
name: "Fight some tasty nerd", |
|
|
|
intro: () => new LogLine(`You find some nerd to fight.`) |
|
|
|
}, |
|
|
|
[world.player, enemy].concat(world.party) |
|
|
|
) |
|
|
|
world.encounter = encounter |
|
|
|
return nilLog |
|
|
|
} |
|
|
|
) |
|
|
|
) |
|
|
|
|
|
|
|
townSquare.choices.push( |
|
|
|
new Choice( |
|
|
|
"Recruit someone", |
|
|
|
"Not ow", |
|
|
|
(world) => { |
|
|
|
const ally = new Human(new ProperNoun("Ally"), TheyPronouns) |
|
|
|
ally.side = Side.Heroes |
|
|
|
ally.ai = new VoreAI(ally) |
|
|
|
ally.equip(new Items.Sword(), Items.EquipmentSlot.MainHand) |
|
|
|
world.party.push(ally) |
|
|
|
|
|
|
|
return new LogLine(`You recruit a nerd`) |
|
|
|
} |
|
|
|
) |
|
|
|
) |
|
|
|
|
|
|
|
debug.choices.push( |
|
|
|
new Choice( |
|
|
|
"Cut stats", |
|
|
|
|