| @@ -60,6 +60,8 @@ | |||||
| <button @click.stop="subject.perspective = POV.First">1st</button> | <button @click.stop="subject.perspective = POV.First">1st</button> | ||||
| <button @click.stop="subject.perspective = POV.Second">2nd</button> | <button @click.stop="subject.perspective = POV.Second">2nd</button> | ||||
| <button @click.stop="subject.perspective = POV.Third">3rd</button> | <button @click.stop="subject.perspective = POV.Third">3rd</button> | ||||
| <button @click.stop="subject.ai = null">Human</button> | |||||
| <button @click.stop="subject.ai = makeAI()">AI</button> | |||||
| <button class="show-profile" @click="$emit('profile', subject)">Show profile</button> | <button class="show-profile" @click="$emit('profile', subject)">Show profile</button> | ||||
| </div> | </div> | ||||
| </div> | </div> | ||||
| @@ -73,6 +75,7 @@ import { Stats, Stat, StatIcons, StatDescs, Vigor, VigorIcons, VigorDescs, VoreS | |||||
| import ContainerView from '@/components/ContainerView.vue' | import ContainerView from '@/components/ContainerView.vue' | ||||
| import tippy, { delegate, createSingleton } from 'tippy.js' | import tippy, { delegate, createSingleton } from 'tippy.js' | ||||
| import 'tippy.js/dist/tippy.css' | import 'tippy.js/dist/tippy.css' | ||||
| import { VoreAI } from '@/game/ai' | |||||
| @Component({ | @Component({ | ||||
| components: { | components: { | ||||
| @@ -138,6 +141,10 @@ export default class Statblock extends Vue { | |||||
| }) | }) | ||||
| } | } | ||||
| makeAI () { | |||||
| return new VoreAI() | |||||
| } | |||||
| mounted () { | mounted () { | ||||
| const statEntries = Array.from(this.$el.querySelectorAll(".stat-entry")) | const statEntries = Array.from(this.$el.querySelectorAll(".stat-entry")) | ||||
| const name = Array.from(this.$el.querySelectorAll(".name")) | const name = Array.from(this.$el.querySelectorAll(".name")) | ||||
| @@ -430,6 +430,90 @@ export const Town = (): Place => { | |||||
| ) | ) | ||||
| ) | ) | ||||
| debug.choices.push( | |||||
| new Choice( | |||||
| "Boost agility", | |||||
| "More agility", | |||||
| (world, executor) => { | |||||
| executor.baseStats[Stat.Agility] += 5 | |||||
| executor.takeDamage(new Damage( | |||||
| { amount: 5, target: Stat.Agility, type: DamageType.Heal } | |||||
| )) | |||||
| return new LogLine(`You're stronger now`) | |||||
| } | |||||
| ) | |||||
| ) | |||||
| debug.choices.push( | |||||
| new Choice( | |||||
| "Boost charm", | |||||
| "More charm", | |||||
| (world, executor) => { | |||||
| executor.baseStats[Stat.Charm] += 5 | |||||
| executor.takeDamage(new Damage( | |||||
| { amount: 5, target: Stat.Charm, type: DamageType.Heal } | |||||
| )) | |||||
| return new LogLine(`You're stronger now`) | |||||
| } | |||||
| ) | |||||
| ) | |||||
| debug.choices.push( | |||||
| new Choice( | |||||
| "Boost power", | |||||
| "More power", | |||||
| (world, executor) => { | |||||
| executor.baseStats[Stat.Power] += 5 | |||||
| executor.takeDamage(new Damage( | |||||
| { amount: 5, target: Stat.Power, type: DamageType.Heal } | |||||
| )) | |||||
| return new LogLine(`You're stronger now`) | |||||
| } | |||||
| ) | |||||
| ) | |||||
| debug.choices.push( | |||||
| new Choice( | |||||
| "Boost reflexes", | |||||
| "More reflexes", | |||||
| (world, executor) => { | |||||
| executor.baseStats[Stat.Reflexes] += 5 | |||||
| executor.takeDamage(new Damage( | |||||
| { amount: 5, target: Stat.Reflexes, type: DamageType.Heal } | |||||
| )) | |||||
| return new LogLine(`You're stronger now`) | |||||
| } | |||||
| ) | |||||
| ) | |||||
| debug.choices.push( | |||||
| new Choice( | |||||
| "Boost toughness", | |||||
| "More toughness", | |||||
| (world, executor) => { | |||||
| executor.baseStats[Stat.Toughness] += 5 | |||||
| executor.takeDamage(new Damage( | |||||
| { amount: 5, target: Stat.Toughness, type: DamageType.Heal } | |||||
| )) | |||||
| return new LogLine(`You're stronger now`) | |||||
| } | |||||
| ) | |||||
| ) | |||||
| debug.choices.push( | |||||
| new Choice( | |||||
| "Boost willpower", | |||||
| "More willpower", | |||||
| (world, executor) => { | |||||
| executor.baseStats[Stat.Willpower] += 5 | |||||
| executor.takeDamage(new Damage( | |||||
| { amount: 5, target: Stat.Willpower, type: DamageType.Heal } | |||||
| )) | |||||
| return new LogLine(`You're stronger now`) | |||||
| } | |||||
| ) | |||||
| ) | |||||
| debug.choices.push( | debug.choices.push( | ||||
| new Choice( | new Choice( | ||||
| "Grow", | "Grow", | ||||