浏览代码

Fix AI names

vintage
Fen Dweller 5 年前
父节点
当前提交
e70a0ad3bd
共有 2 个文件被更改,包括 2 次插入7 次删除
  1. +2
    -3
      src/components/Statblock.vue
  2. +0
    -4
      src/game/vore.ts

+ 2
- 3
src/components/Statblock.vue 查看文件

@@ -60,7 +60,7 @@
<button v-if="subject.perspective === POV.Third" @click.stop="subject.perspective = POV.Second">Second-person</button>
<button v-if="subject.perspective === POV.First" @click.stop="subject.perspective = POV.Third">Third-person</button>
<button v-if="subject.perspective === POV.Second" @click.stop="subject.perspective = POV.First">First-person</button>
<select @change="subject.ai = new ais[$event.target.selectedIndex]()">
<select @change="subject.ai = ais[$event.target.selectedIndex]">
<option v-for="(ai, index) in ais" :key="'ai-' + index">{{ ai.name }}</option>
</select>
</div>
@@ -82,10 +82,9 @@ import 'tippy.js/dist/tippy.css'
ContainerView
},
data () {
console.log([NoAI, RandomAI])
return {
POV: POV,
ais: [NoAI, RandomAI]
ais: [new NoAI(), new RandomAI()]
}
},
methods: {


+ 0
- 4
src/game/vore.ts 查看文件

@@ -304,11 +304,8 @@ export abstract class NormalVoreContainer extends NormalContainer implements Vor
0
)

console.log(damageTotal)

const massStolen = Math.min(damageTotal / 100, prey.voreStats.Mass)

console.log(massStolen)
prey.voreStats.Mass -= massStolen
this.owner.voreStats.Mass += massStolen

@@ -322,7 +319,6 @@ export abstract class NormalVoreContainer extends NormalContainer implements Vor
const digestedEntries = this.digest(justDigested)
const absorbedEntries = this.absorb(justAbsorbed)

console.log(this.digested, this.absorbed)
this.contents = this.contents.filter(prey => {
return prey.vigors[Vigor.Health] > 0
})


正在加载...
取消
保存