Bläddra i källkod

Add second person (renamed from previous first person)

Everything described as 'first person' was really second person, so that has
been updated. Words can now be set to be objective, which is needed for first-person
pronouns to appear correctly
vintage
Fen Dweller 5 år sedan
förälder
incheckning
b35f6d9d5c
10 ändrade filer med 127 tillägg och 107 borttagningar
  1. +8
    -2
      src/components/Statblock.vue
  2. +12
    -12
      src/game/combat/actions.ts
  3. +1
    -1
      src/game/combat/effects.ts
  4. +10
    -10
      src/game/creatures/cafat.ts
  5. +1
    -1
      src/game/creatures/player.ts
  6. +27
    -27
      src/game/creatures/withers.ts
  7. +4
    -4
      src/game/creatures/wolf.ts
  8. +1
    -1
      src/game/entity.ts
  9. +15
    -5
      src/game/language.ts
  10. +48
    -44
      src/game/vore.ts

+ 8
- 2
src/components/Statblock.vue Visa fil

@@ -44,8 +44,9 @@
</div>
</div>
<div>Status: {{subject.status}}</div>
<button v-if="subject.perspective !== firstperson" @click.stop="subject.perspective = firstperson">First-person</button>
<button v-if="subject.perspective !== thirdperson" @click.stop="subject.perspective = thirdperson">Third-person</button>
<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>
<button class="if-not-selected" @click.stop="$emit('selectAlly')">Select ally as target</button>
</div>
</div>
@@ -63,6 +64,11 @@ import 'tippy.js/dist/tippy.css'
components: {
ContainerView
},
data () {
return {
POV: POV
}
},
methods: {
vigorColor (value: number, max: number) {
if (value * 5 <= max) {


+ 12
- 12
src/game/combat/actions.ts Visa fil

@@ -10,11 +10,11 @@ export class AttackAction extends Action {
protected test: StatTest

protected successLines: POVPairArgs<Entity, Entity, { damage: Damage }> = new POVPairArgs([
[[POV.First, POV.Third], (user, target, args) => new LogLine(
[[POV.Second, POV.Third], (user, target, args) => new LogLine(
`You ${this.verb} ${target.name} for `,
args.damage.renderShort()
)],
[[POV.Third, POV.First], (user, target, args) => new LogLine(
[[POV.Third, POV.Second], (user, target, args) => new LogLine(
`${user.name.capital} ${this.verb.singular} you for `,
args.damage.renderShort()
)],
@@ -25,8 +25,8 @@ export class AttackAction extends Action {
])

protected failLines: POVPair<Entity, Entity> = new POVPair([
[[POV.First, POV.Third], (user, target) => new LogLine(`You try to ${this.verb.present} ${target.name}, but you miss`)],
[[POV.Third, POV.First], (user, target) => new LogLine(`${user.name.capital} misses you`)],
[[POV.Second, POV.Third], (user, target) => new LogLine(`You try to ${this.verb.present} ${target.name}, but you miss`)],
[[POV.Third, POV.Second], (user, target) => new LogLine(`${user.name.capital} misses you`)],
[[POV.Third, POV.Third], (user, target) => new LogLine(`${user.name.capital} misses ${target.name}`)]
])

@@ -59,8 +59,8 @@ export class DevourAction extends Action {
private test: StatVigorTest

protected failLines: POVPairArgs<Entity, Entity, { container: Container }> = new POVPairArgs([
[[POV.First, POV.Third], (user, target, args) => new LogLine(`You fail to ${args.container.consumeVerb} ${target.name}`)],
[[POV.Third, POV.First], (user, target, args) => new LogLine(`${user.name.capital} tries to ${args.container.consumeVerb} you, but fails`)],
[[POV.Second, POV.Third], (user, target, args) => new LogLine(`You fail to ${args.container.consumeVerb} ${target.name}`)],
[[POV.Third, POV.Second], (user, target, args) => new LogLine(`${user.name.capital} tries to ${args.container.consumeVerb} you, but fails`)],
[[POV.Third, POV.Third], (user, target, args) => new LogLine(`${user.name.capital} unsuccessfully tries to ${args.container.consumeVerb} ${target.name}`)]
])

@@ -102,8 +102,8 @@ export class FeedAction extends Action {
private test: StatTest

protected failLines: POVPair<Entity, Entity> = new POVPair([
[[POV.First, POV.Third], (user, target) => new LogLine(`You fail to feed yourself to ${target.name}`)],
[[POV.Third, POV.First], (user, target) => new LogLine(`${user.name.capital} tries to feed ${user.pronouns.possessive} to you, but fails`)],
[[POV.Second, POV.Third], (user, target) => new LogLine(`You fail to feed yourself to ${target.name}`)],
[[POV.Third, POV.Second], (user, target) => new LogLine(`${user.name.capital} tries to feed ${user.pronouns.possessive} to you, but fails`)],
[[POV.Third, POV.Third], (user, target) => new LogLine(`${user.name.capital} unsuccessfully tries to feed ${user.pronouns.possessive} to ${target.name}`)]
])

@@ -142,8 +142,8 @@ export class StruggleAction extends Action {
private test: StatVigorTest

protected failLines: POVPair<Entity, Entity> = new POVPair([
[[POV.First, POV.Third], (user, target) => new LogLine(`You fail to escape from ${target.name}`)],
[[POV.Third, POV.First], (user, target) => new LogLine(`${user.name.capital} tries to escape from you, but fails`)],
[[POV.Second, POV.Third], (user, target) => new LogLine(`You fail to escape from ${target.name}`)],
[[POV.Third, POV.Second], (user, target) => new LogLine(`${user.name.capital} tries to escape from you, but fails`)],
[[POV.Third, POV.Third], (user, target) => new LogLine(`${user.name.capital} unsuccessfully struggles against ${target.name}`)]
])

@@ -250,8 +250,8 @@ export class ReleaseAction extends Action {

export class TransferAction extends Action {
lines: POVPairArgs<Entity, Entity, { from: Container; to: Container }> = new POVPairArgs([
[[POV.First, POV.Third], (user, target, args) => new LogLine(`You squeeze ${target.name} from your ${args.from.name} to your ${args.to.name}`)],
[[POV.Third, POV.First], (user, target, args) => new LogLine(`You're squeezed from ${user.name}'s ${args.from.name} to ${user.pronouns.possessive} ${args.to.name}`)],
[[POV.Second, POV.Third], (user, target, args) => new LogLine(`You squeeze ${target.name} from your ${args.from.name} to your ${args.to.name}`)],
[[POV.Third, POV.Second], (user, target, args) => new LogLine(`You're squeezed from ${user.name}'s ${args.from.name} to ${user.pronouns.possessive} ${args.to.name}`)],
[[POV.Third, POV.Third], (user, target, args) => new LogLine(`${user.name} sends ${target.name} from ${user.pronouns.possessive} ${args.from.name.all} to ${user.pronouns.possessive} ${args.to.name.all}`)]
])



+ 1
- 1
src/game/combat/effects.ts Visa fil

@@ -5,7 +5,7 @@ import { POVSolo } from '../language'

export class InstantKill implements Effect {
lines = new POVSolo<Creature>([
[[POV.First], (target: Creature) => new LogLine(`You're killed instantly! `, new FAElem('fas fa-skull'))],
[[POV.Second], (target: Creature) => new LogLine(`You're killed instantly! `, new FAElem('fas fa-skull'))],
[[POV.Third], (target: Creature) => new LogLine(`${target.name.capital} is killed instantly! `, new FAElem('fas fa-skull'))]
])



+ 10
- 10
src/game/creatures/cafat.ts Visa fil

@@ -8,11 +8,11 @@ import { InstantKill } from '../combat/effects'

class BellyCrushAction extends AttackAction {
successLines = new POVPairArgs<Entity, Entity, { damage: Damage }>([
[[POV.First, POV.Third], (user, target, args) => new CompositeLog(new LogLine(
[[POV.Second, POV.Third], (user, target, args) => new CompositeLog(new LogLine(
`You crush on ${target.name} with your belly for `,
args.damage.renderShort()
), new ImgElem('./media/cafat/images/belly-crush.webp'))],
[[POV.Third, POV.First], (user, target, args) => new CompositeLog(new LogLine(
[[POV.Third, POV.Second], (user, target, args) => new CompositeLog(new LogLine(
`${user.name.capital} crushes on you with ${user.pronouns.possessive} belly for `,
args.damage.renderShort()
), new ImgElem('./media/cafat/images/belly-crush.webp'))],
@@ -39,11 +39,11 @@ class BellyCrushAction extends AttackAction {

class BelchAction extends AttackAction {
successLines = new POVPairArgs<Entity, Entity, { damage: Damage }>([
[[POV.First, POV.Third], (user, target, args) => new CompositeLog(new LogLine(
[[POV.Second, POV.Third], (user, target, args) => new CompositeLog(new LogLine(
`You belch on ${target.name} for `,
args.damage.renderShort()
), new ImgElem('./media/cafat/images/belch.webp'))],
[[POV.Third, POV.First], (user, target, args) => new CompositeLog(new LogLine(
[[POV.Third, POV.Second], (user, target, args) => new CompositeLog(new LogLine(
`${user.name.capital} belches on you for `,
args.damage.renderShort()
), new ImgElem('./media/cafat/images/belch.webp'))],
@@ -62,8 +62,8 @@ class BelchAction extends AttackAction {

class CrushAction extends EatenAction {
lines: POVPair<Entity, Entity> = new POVPair([
[[POV.First, POV.Third], (user, target) => new LogLine(`You crush ${target.name} `)],
[[POV.Third, POV.First], (user) => new CompositeLog(new LogLine(`${user.name.capital} crushes you; ${user.pronouns.subjective} ${user.pronouns.isPlural ? 'belch' : 'belches'} as ${user.pronouns.possessive} gut lets out a fatal CRUNCH `), new ImgElem('./media/cafat/images/crunch.webp'))],
[[POV.Second, POV.Third], (user, target) => new LogLine(`You crush ${target.name} `)],
[[POV.Third, POV.Second], (user) => new CompositeLog(new LogLine(`${user.name.capital} crushes you; ${user.pronouns.subjective} ${user.pronouns.isPlural ? 'belch' : 'belches'} as ${user.pronouns.possessive} gut lets out a fatal CRUNCH `), new ImgElem('./media/cafat/images/crunch.webp'))],
[[POV.Third, POV.Third], (user, target) => new LogLine(`${user.name.capital} crushes ${target.name}; ${user.pronouns.subjective} ${user.pronouns.isPlural ? 'belch' : 'belches'} as ${user.pronouns.possessive} gut lets out a fatal CRUNCH `, new ImgElem('./media/cafat/images/crunch.webp'))]
])

@@ -110,8 +110,8 @@ export class Cafat extends Creature {
lowerStomach.name = new ImproperNoun("lower stomach", "lower stomachs").all

stomach.consumeLines = new POVPair([
[[POV.First, POV.Third], (user, target) => new LogLine(`You devour ${target.name}`)],
[[POV.Third, POV.First], (user) => new CompositeLog(new LogLine(`${user.name.capital} devours you`), new ImgElem('./media/cafat/images/stomach.webp'))],
[[POV.Second, POV.Third], (user, target) => new LogLine(`You devour ${target.name}`)],
[[POV.Third, POV.Second], (user) => new CompositeLog(new LogLine(`${user.name.capital} devours you`), new ImgElem('./media/cafat/images/stomach.webp'))],
[[POV.Third, POV.Third], (user, target) => new LogLine(`${user.name.capital} munches ${target.name.capital}`)]
])
const crush = new CrushAction(lowerStomach)
@@ -122,8 +122,8 @@ export class Cafat extends Creature {
const transfer = new TransferAction(stomach, lowerStomach)

transfer.lines = new POVPairArgs([
[[POV.First, POV.Third], (user, target, args) => new LogLine(`You squeeze ${target.name} from your ${args.from.name} to your ${args.to.name}`)],
[[POV.Third, POV.First], (user, target, args) => new CompositeLog(new LogLine(`You're squeezed from ${user.name}'s ${args.from.name} to ${user.pronouns.possessive} ${args.to.name}`), new ImgElem('./media/cafat/images/lower-stomach.webp'))],
[[POV.Second, POV.Third], (user, target, args) => new LogLine(`You squeeze ${target.name} from your ${args.from.name} to your ${args.to.name}`)],
[[POV.Third, POV.Second], (user, target, args) => new CompositeLog(new LogLine(`You're squeezed from ${user.name}'s ${args.from.name} to ${user.pronouns.possessive} ${args.to.name}`), new ImgElem('./media/cafat/images/lower-stomach.webp'))],
[[POV.Third, POV.Third], (user, target, args) => new LogLine(`${user.name} squeezes ${target.name} from ${user.pronouns.possessive} ${args.from.name} to ${user.pronouns.possessive} ${args.to.name}`)]
])
this.actions.push(transfer)


+ 1
- 1
src/game/creatures/player.ts Visa fil

@@ -16,6 +16,6 @@ export class Player extends Creature {
const bowels = new Bowels(this, 100, new Damage({ amount: 20, type: DamageType.Crush, target: Vigor.Health }))

this.containers.push(bowels)
this.perspective = POV.First
this.perspective = POV.Second
}
}

+ 27
- 27
src/game/creatures/withers.ts Visa fil

@@ -30,7 +30,7 @@ class LevelDrain extends Action {
const targetResult = target.takeDamage(damage)

return new LogLines(
new LogLine(`${user.name.capital.possessive} ${this.container.name} drains power from ${target.name}, siphoning `, damage.renderShort(), ` from ${target.pronouns.possessive} body!`),
new LogLine(`${user.name.capital.possessive} ${this.container.name} drains power from ${target.name.objective}, siphoning `, damage.renderShort(), ` from ${target.pronouns.possessive} body!`),
targetResult
)
}
@@ -52,8 +52,8 @@ class LevelDrain extends Action {
}
class HypnotizeAction extends Action {
lines = new POVPair<Creature, Creature>([
[[POV.First, POV.Third], (user, target) => new LogLine(`Your hypnotic gaze enthralls ${target.name}, putting ${target.pronouns.objective} under your control!`)],
[[POV.Third, POV.First], (user, target) => new LogLine(`${user.name.capital}'s hypnotic gaze enthralls you, putting you under ${user.pronouns.possessive} control!`)],
[[POV.Second, POV.Third], (user, target) => new LogLine(`Your hypnotic gaze enthralls ${target.name}, putting ${target.pronouns.objective} under your control!`)],
[[POV.Third, POV.Second], (user, target) => new LogLine(`${user.name.capital}'s hypnotic gaze enthralls you, putting you under ${user.pronouns.possessive} control!`)],
[[POV.Third, POV.Third], (user, target) => new LogLine(`${user.name.capital}'s hypnotic gaze enthralls ${target.name}, putting ${target.pronouns.objective} under ${user.pronouns.possessive} control!`)]
])

@@ -84,20 +84,20 @@ class MawContainer extends NormalContainer {
struggleVerb = new Verb('struggle', 'struggles', 'struggling', 'struggled')

consumeLines = new POVPair<Vore, Vore>([
[[POV.First, POV.Third], (user, target) => new LogLine(`You snatch ${target.name} up in your jaws`)],
[[POV.Third, POV.First], (user, target) => new LogLine(`${user.name.capital} snatches you up in ${user.pronouns.possessive} maw`)],
[[POV.Second, POV.Third], (user, target) => new LogLine(`You snatch ${target.name} up in your jaws`)],
[[POV.Third, POV.Second], (user, target) => new LogLine(`${user.name.capital} snatches you up in ${user.pronouns.possessive} maw`)],
[[POV.Third, POV.Third], (user, target) => new LogLine(`${user.name.capital} snatches ${target.name} up in ${user.pronouns.possessive} maw`)]
])

releaseLines = new POVPair([
[[POV.First, POV.Third], (user, target) => new LogLine(`You let out ${target.name}`)],
[[POV.Third, POV.First], (user, target) => new LogLine(`${user.name.capital} lets you out `)],
[[POV.Second, POV.Third], (user, target) => new LogLine(`You let out ${target.name}`)],
[[POV.Third, POV.Second], (user, target) => new LogLine(`${user.name.capital} lets you out `)],
[[POV.Third, POV.Third], (user, target) => new LogLine(`${user.name.capital} lets out ${target.name}`)]
])

struggleLines = new POVPair([
[[POV.First, POV.Third], (user, target) => new LogLine(`You claw your way free of ${target.name}`)],
[[POV.Third, POV.First], (user, target) => new LogLine(`${user.name.capital} forces ${user.pronouns.possessive} way free!`)],
[[POV.Second, POV.Third], (user, target) => new LogLine(`You claw your way free of ${target.name}`)],
[[POV.Third, POV.Second], (user, target) => new LogLine(`${user.name.capital} forces ${user.pronouns.possessive} way free!`)],
[[POV.Third, POV.Third], (user, target) => new LogLine(`${user.name.capital} escapes from ${target.name}`)]
])

@@ -110,8 +110,8 @@ class MawContainer extends NormalContainer {

class FlexToesAction extends GroupAction {
lines = new POVPairArgs<Creature, Creature, { damage: Damage }>([
[[POV.First, POV.Third], (user, target, args) => new LogLine(`Your toes crush ${target.name} for `, args.damage.renderShort(), ` damage!`)],
[[POV.Third, POV.First], (user, target, args) => new LogLine(`${user.name.capital}'s toes crush you for `, args.damage.renderShort(), ` damage!`)],
[[POV.Second, POV.Third], (user, target, args) => new LogLine(`Your toes crush ${target.name} for `, args.damage.renderShort(), ` damage!`)],
[[POV.Third, POV.Second], (user, target, args) => new LogLine(`${user.name.capital}'s toes crush you for `, args.damage.renderShort(), ` damage!`)],
[[POV.Third, POV.Third], (user, target, args) => new LogLine(`${user.name.capital}'s toes crush ${target.name} for `, args.damage.renderShort(), ` damage!`)]
])

@@ -138,20 +138,20 @@ class FlexToesAction extends GroupAction {

class BootContainer extends NormalContainer {
consumeLines = new POVPair<Vore, Vore>([
[[POV.First, POV.Third], (user, target) => new LogLine(`You stuff ${target.name} into your boot.`)],
[[POV.Third, POV.First], (user, target) => new LogLine(`${user.name.capital} stuffs you in ${user.pronouns.possessive} boot, pinning you between toes and insole.`)],
[[POV.Second, POV.Third], (user, target) => new LogLine(`You stuff ${target.name} into your boot.`)],
[[POV.Third, POV.Second], (user, target) => new LogLine(`${user.name.capital} stuffs you in ${user.pronouns.possessive} boot, pinning you between toes and insole.`)],
[[POV.Third, POV.Third], (user, target) => new LogLine(`${user.name.capital} stuffs ${target.name} in ${user.pronouns.possessive} boot.`)]
])

releaseLines = new POVPair([
[[POV.First, POV.Third], (user, target) => new LogLine(`You dump ${target.name} out from your boot.`)],
[[POV.Third, POV.First], (user, target) => new LogLine(`${user.name.capital} dumps you out from ${user.pronouns.possessive} boot.`)],
[[POV.Second, POV.Third], (user, target) => new LogLine(`You dump ${target.name} out from your boot.`)],
[[POV.Third, POV.Second], (user, target) => new LogLine(`${user.name.capital} dumps you out from ${user.pronouns.possessive} boot.`)],
[[POV.Third, POV.Third], (user, target) => new LogLine(`${user.name.capital} dumps ${target.name} out from ${user.pronouns.possessive} boot.`)]
])

struggleLines = new POVPair([
[[POV.First, POV.Third], (user, target) => new LogLine(`You slip out from ${target.name}'s boot.`)],
[[POV.Third, POV.First], (user, target) => new LogLine(`${user.name.capital} squeezes ${user.pronouns.possessive} way free of your footwear!`)],
[[POV.Second, POV.Third], (user, target) => new LogLine(`You slip out from ${target.name}'s boot.`)],
[[POV.Third, POV.Second], (user, target) => new LogLine(`${user.name.capital} squeezes ${user.pronouns.possessive} way free of your footwear!`)],
[[POV.Third, POV.Third], (user, target) => new LogLine(`${user.name.capital} escapes from ${target.name}'s boot.`)]
])

@@ -198,8 +198,8 @@ class BiteAction extends AttackAction {

class ChewAction extends GroupAction {
lines: POVPairArgs<Creature, Creature, { damage: Damage }> = new POVPairArgs([
[[POV.First, POV.Third], (user, target, args: { damage: Damage }) => new LogLine(`You chew on ${target.name} for `, args.damage.renderShort(), `!`)],
[[POV.Third, POV.First], (user, target, args: { damage: Damage }) => new LogLine(`${user.name.capital} chews on you for `, args.damage.renderShort(), `!`)],
[[POV.Second, POV.Third], (user, target, args: { damage: Damage }) => new LogLine(`You chew on ${target.name} for `, args.damage.renderShort(), `!`)],
[[POV.Third, POV.Second], (user, target, args: { damage: Damage }) => new LogLine(`${user.name.capital} chews on you for `, args.damage.renderShort(), `!`)],
[[POV.Third, POV.Third], (user, target, args: { damage: Damage }) => new LogLine(`${user.name.capital} chews on ${target.name} for `, args.damage.renderShort(), `!`)]
])

@@ -237,8 +237,8 @@ class ChewAction extends GroupAction {

class StompAction extends GroupAction {
lines: POVPair<Creature, Creature> = new POVPair([
[[POV.First, POV.Third], (user: Creature, target: Creature) => new LogLine(`You flatten ${target.name} under your foot!`)],
[[POV.Third, POV.First], (user: Creature) => new LogLine(`${user.name.capital} flattens you under ${user.pronouns.possessive} ${huge} foot!`)],
[[POV.Second, POV.Third], (user: Creature, target: Creature) => new LogLine(`You flatten ${target.name} under your foot!`)],
[[POV.Third, POV.Second], (user: Creature) => new LogLine(`${user.name.capital} flattens you under ${user.pronouns.possessive} ${huge} foot!`)],
[[POV.Third, POV.Third], (user: Creature, target: Creature) => new LogLine(`${user.name.capital} flattens ${target.name} under ${user.pronouns.possessive} ${huge} foot!`)]
])

@@ -265,8 +265,8 @@ class StompAction extends GroupAction {

class StompAllyAction extends Action {
lines: POVPair<Creature, Creature> = new POVPair([
[[POV.First, POV.Third], (user: Creature, target: Creature) => new LogLine(`You flatten ${target.name} under your boot!`)],
[[POV.Third, POV.First], (user: Creature) => new LogLine(`${user.name.capital} flattens you under ${user.pronouns.possessive} ${huge} boot!`)],
[[POV.Second, POV.Third], (user: Creature, target: Creature) => new LogLine(`You flatten ${target.name} under your boot!`)],
[[POV.Third, POV.Second], (user: Creature) => new LogLine(`${user.name.capital} flattens you under ${user.pronouns.possessive} ${huge} boot!`)],
[[POV.Third, POV.Third], (user: Creature, target: Creature) => new LogLine(`${user.name.capital} flattens ${target.name} under ${user.pronouns.possessive} ${huge} boot!`)]
])

@@ -369,14 +369,14 @@ export class Withers extends Creature {
))

stomach.tickLines = new POVPairArgs<Vore, Vore, { damage: Damage }>([
[[POV.First, POV.Third], (user, target, args) => new LogLine(`Your stomach ${Words.Churns.singular} ${target.name} for `, args.damage.renderShort())],
[[POV.Third, POV.First], (user, target, args) => new LogLine(`${user.name.capital}'s stomach ${Words.Churns.singular} you for `, args.damage.renderShort())],
[[POV.Second, POV.Third], (user, target, args) => new LogLine(`Your stomach ${Words.Churns.singular} ${target.name} for `, args.damage.renderShort())],
[[POV.Third, POV.Second], (user, target, args) => new LogLine(`${user.name.capital}'s stomach ${Words.Churns.singular} you for `, args.damage.renderShort())],
[[POV.Third, POV.Third], (user, target, args) => new LogLine(`${user.name.capital} ${Words.Churns.singular} ${target.name} for `, args.damage.renderShort())]
])

stomach.digestLines = new POVPair<Vore, Vore>([
[[POV.First, POV.Third], (user, target) => new LogLine(`Your stomach ${Words.Digests.singular} ${target.name}`)],
[[POV.Third, POV.First], (user, target) => new LogLine(`${user.name.capital}'s stomach ${Words.Digests.singular} you`)],
[[POV.Second, POV.Third], (user, target) => new LogLine(`Your stomach ${Words.Digests.singular} ${target.name}`)],
[[POV.Third, POV.Second], (user, target) => new LogLine(`${user.name.capital}'s stomach ${Words.Digests.singular} you`)],
[[POV.Third, POV.Third], (user, target) => new LogLine(`${target.name.capital}'s ${Words.Struggles.present} fades as the ${target.kind.all} is ${Words.Digests.past} by the ${user.kind.all}'s ${stomach.name}.`)]
])



+ 4
- 4
src/game/creatures/wolf.ts Visa fil

@@ -15,11 +15,11 @@ class BiteAction extends AttackAction {

class HypnoAction extends AttackAction {
protected successLines: POVPairArgs<Entity, Entity, { damage: Damage }> = new POVPairArgs([
[[POV.First, POV.Third], (user, target, args) => new LogLine(
[[POV.Second, POV.Third], (user, target, args) => new LogLine(
`You hypnotize ${target.name} for `,
args.damage.renderShort()
)],
[[POV.Third, POV.First], (user, target, args) => new LogLine(
[[POV.Third, POV.Second], (user, target, args) => new LogLine(
`${user.name.capital} hypnotizes you for `,
args.damage.renderShort()
)],
@@ -30,8 +30,8 @@ class HypnoAction extends AttackAction {
])

protected failLines: POVPair<Entity, Entity> = new POVPair([
[[POV.First, POV.Third], (user, target) => new LogLine(`You try to hypnotize ${target.name}, but you miss`)],
[[POV.Third, POV.First], (user, target) => new LogLine(`${user.name.capital} misses you`)],
[[POV.Second, POV.Third], (user, target) => new LogLine(`You try to hypnotize ${target.name}, but you miss`)],
[[POV.Third, POV.Second], (user, target) => new LogLine(`${user.name.capital} misses you`)],
[[POV.Third, POV.Third], (user, target) => new LogLine(`${target.name} misses ${target.name}`)]
])



+ 1
- 1
src/game/entity.ts Visa fil

@@ -4,7 +4,7 @@ import { LogEntry, LogLine } from './interface'
import { Vore, VoreContainer, VoreType, Container } from './vore'
import { Item } from './items'

export enum POV {First, Third}
export enum POV {First, Second, Third}

export interface Entity {
name: Noun;


+ 15
- 5
src/game/language.ts Visa fil

@@ -82,6 +82,7 @@ interface WordOptions {
vowel: VowelSound;
count: boolean;
possessive: boolean;
objective: boolean;
}

const emptyConfig: WordOptions = {
@@ -93,7 +94,8 @@ const emptyConfig: WordOptions = {
plural: false,
proper: false,
vowel: VowelSound.Default,
possessive: false
possessive: false,
objective: false
}

export type TextLike = { toString: () => string }
@@ -221,9 +223,9 @@ export abstract class Word {
return this.configure(opts) as this
}

get nonpossessive (): this {
get objective (): this {
const opts: WordOptions = Object.assign({}, this.opt)
opts.possessive = false
opts.objective = true
return this.configure(opts) as this
}
}
@@ -322,13 +324,13 @@ export class Noun extends Word {

export class ImproperNoun extends Noun {
constructor (singularNoun: string, pluralNoun: string = singularNoun, possessiveNoun: string = singularNoun + "'s") {
super(singularNoun, pluralNoun, null, { plural: false, allCaps: false, capital: false, proper: false, nounKind: NounKind.Specific, verbKind: VerbKind.Root, vowel: VowelSound.Default, count: true, possessive: false })
super(singularNoun, pluralNoun, null, { plural: false, allCaps: false, capital: false, proper: false, nounKind: NounKind.Specific, verbKind: VerbKind.Root, vowel: VowelSound.Default, count: true, possessive: false, objective: false })
}
}

export class ProperNoun extends Noun {
constructor (singularNoun: string) {
super(singularNoun, null, null, { plural: false, allCaps: false, capital: false, proper: true, nounKind: NounKind.Specific, verbKind: VerbKind.Root, vowel: VowelSound.Default, count: true, possessive: false })
super(singularNoun, null, null, { plural: false, allCaps: false, capital: false, proper: true, nounKind: NounKind.Specific, verbKind: VerbKind.Root, vowel: VowelSound.Default, count: true, possessive: false, objective: false })
}
}

@@ -435,6 +437,14 @@ export class PronounAsNoun extends Noun {
configure (opts: WordOptions): Word {
return new PronounAsNoun(this.pronouns, opts)
}

toString (): string {
if (this.options.objective) {
return new Noun(this.pronouns.objective, this.pronouns.objective, this.pronouns.possessive, this.options).toString()
} else {
return super.toString()
}
}
}

export const MalePronouns = new Pronoun({


+ 48
- 44
src/game/vore.ts Visa fil

@@ -1,7 +1,7 @@
import { Entity, Mortal, POV, Creature } from './entity'
import { Damage, DamageType, Stats, Actionable, Action, Vigor, VoreStats } from './combat'
import { LogLines, LogEntry, CompositeLog, LogLine } from './interface'
import { Noun, Pronoun, POVPair, POVPairArgs, ImproperNoun, POVSolo, TextLike, Verb, SecondPersonPronouns, PronounAsNoun } from './language'
import { Noun, Pronoun, POVPair, POVPairArgs, ImproperNoun, POVSolo, TextLike, Verb, SecondPersonPronouns, PronounAsNoun, FirstPersonPronouns } from './language'
import { DigestAction, DevourAction, ReleaseAction, StruggleAction } from './combat/actions'
import * as Words from './words'

@@ -22,6 +22,8 @@ export abstract class Vore implements Mortal {

get name (): Noun {
if (this.perspective === POV.First) {
return new PronounAsNoun(FirstPersonPronouns)
} else if (this.perspective === POV.Second) {
return new PronounAsNoun(SecondPersonPronouns)
} else {
return this.baseName
@@ -30,6 +32,8 @@ export abstract class Vore implements Mortal {

get pronouns (): Pronoun {
if (this.perspective === POV.First) {
return FirstPersonPronouns
} else if (this.perspective === POV.Second) {
return SecondPersonPronouns
} else {
return this.basePronouns
@@ -53,7 +57,7 @@ export abstract class Vore implements Mortal {
abstract otherContainers: Array<Container>;
destroy (): LogEntry {
const lines = new POVSolo<Vore>([
[[POV.First], (target: Vore) => new LogLine('You die!')],
[[POV.Second], (target: Vore) => new LogLine('You die!')],
[[POV.Third], (target: Vore) => new LogLine(`${target.name.capital} dies!`)]
])

@@ -268,44 +272,44 @@ export class Stomach extends NormalVoreContainer {
}

consumeLines = new POVPair<Vore, Vore>([
[[POV.First, POV.Third], (user, target) => new LogLine(`You devour ${target.name}`)],
[[POV.Third, POV.First], (user, target) => new LogLine(`${user.name.capital} munches you`)],
[[POV.Second, POV.Third], (user, target) => new LogLine(`You devour ${target.name}`)],
[[POV.Third, POV.Second], (user, target) => new LogLine(`${user.name.capital} munches you`)],
[[POV.Third, POV.Third], (user, target) => new LogLine(`${user.name.capital} munches ${target.name}`)]
])

releaseLines = new POVPair<Vore, Vore>([
[[POV.First, POV.Third], (user, target) => new LogLine(`You hork up ${target.name}`)],
[[POV.Third, POV.First], (user, target) => new LogLine(`${user.name.capital} horks you up`)],
[[POV.Second, POV.Third], (user, target) => new LogLine(`You hork up ${target.name}`)],
[[POV.Third, POV.Second], (user, target) => new LogLine(`${user.name.capital} horks you up`)],
[[POV.Third, POV.Third], (user, target) => new LogLine(`${user.name.capital} horks up ${target.name}`)]
])

struggleLines = new POVPair<Vore, Vore>([
[[POV.First, POV.Third], (user, target) => new LogLine(`You claw your way out of ${target.name}`)],
[[POV.Third, POV.First], (user, target) => new LogLine(`${user.name.capital} forces ${user.pronouns.possessive} way up your throat!`)],
[[POV.Second, POV.Third], (user, target) => new LogLine(`You claw your way out of ${target.name}`)],
[[POV.Third, POV.Second], (user, target) => new LogLine(`${user.name.capital} forces ${user.pronouns.possessive} way up your throat!`)],
[[POV.Third, POV.Third], (user, target) => new LogLine(`${user.name.capital} escapes from the gut of ${target.name}`)]
])

tickLines = new POVPairArgs<Vore, Vore, { damage: Damage }>([
[[POV.First, POV.Third], (user, target, args) => new LogLine(`Your stomach ${Words.Churns.singular} ${target.name} for `, args.damage.renderShort())],
[[POV.Third, POV.First], (user, target, args) => new LogLine(`${user.name.capital}'s stomach ${Words.Churns.singular} you for `, args.damage.renderShort())],
[[POV.Second, POV.Third], (user, target, args) => new LogLine(`Your stomach ${Words.Churns.singular} ${target.name} for `, args.damage.renderShort())],
[[POV.Third, POV.Second], (user, target, args) => new LogLine(`${user.name.capital}'s stomach ${Words.Churns.singular} you for `, args.damage.renderShort())],
[[POV.Third, POV.Third], (user, target, args) => new LogLine(`${user.name.capital} ${Words.Churns.singular} ${target.name} for `, args.damage.renderShort())]
])

digestLines = new POVPair<Vore, Vore>([
[[POV.First, POV.Third], (user, target) => new LogLine(`Your stomach ${Words.Digests.singular} ${target.name}`)],
[[POV.Third, POV.First], (user, target) => new LogLine(`${user.name.capital}'s stomach ${Words.Digests.singular} you`)],
[[POV.Second, POV.Third], (user, target) => new LogLine(`Your stomach ${Words.Digests.singular} ${target.name}`)],
[[POV.Third, POV.Second], (user, target) => new LogLine(`${user.name.capital}'s stomach ${Words.Digests.singular} you`)],
[[POV.Third, POV.Third], (user, target) => new LogLine(`${target.name.capital}'s ${Words.Struggles.present} fades as the ${target.kind.all} is ${Words.Digests.past} by the ${user.kind.all}'s ${this.name}.`)]
])

absorbLines = new POVPair<Vore, Vore>([
[[POV.First, POV.Third], (user, target) => new LogLine(`Your guts completely absorb ${target.name}`)],
[[POV.Third, POV.First], (user, target) => new LogLine(`${user.name.capital}'s guts soak you up like water in a sponge`)],
[[POV.Second, POV.Third], (user, target) => new LogLine(`Your guts completely absorb ${target.name}`)],
[[POV.Third, POV.Second], (user, target) => new LogLine(`${user.name.capital}'s guts soak you up like water in a sponge`)],
[[POV.Third, POV.Third], (user, target) => new LogLine(`${user.name.capital} finishes absorbing the remains of ${target.name}`)]
])

disposeLines = new POVPair<Vore, Vore>([
[[POV.First, POV.Third], (user, target) => new LogLine(`Your guts completely absorb ${target.name}`)],
[[POV.Third, POV.First], (user, target) => new LogLine(`${user.name.capital}'s guts soak you up like water in a sponge`)],
[[POV.Second, POV.Third], (user, target) => new LogLine(`Your guts completely absorb ${target.name}`)],
[[POV.Third, POV.Second], (user, target) => new LogLine(`${user.name.capital}'s guts soak you up like water in a sponge`)],
[[POV.Third, POV.Third], (user, target) => new LogLine(`${user.name.capital} finishes absorbing the remains of ${target.name}`)]
])

@@ -335,44 +339,44 @@ export class InnerStomach extends InnerContainer {
}

consumeLines = new POVPair([
[[POV.First, POV.Third], (user, target) => new LogLine(`You devour ${target.name}`)],
[[POV.Third, POV.First], (user, target) => new LogLine(`${user.name.capital} munches you`)],
[[POV.Second, POV.Third], (user, target) => new LogLine(`You devour ${target.name}`)],
[[POV.Third, POV.Second], (user, target) => new LogLine(`${user.name.capital} munches you`)],
[[POV.Third, POV.Third], (user, target) => new LogLine(`${user.name.capital} munches ${target.name.capital}`)]
])

releaseLines = new POVPair([
[[POV.First, POV.Third], (user, target) => new LogLine(`You hork up ${target.name}`)],
[[POV.Third, POV.First], (user, target) => new LogLine(`${user.name.capital} horks you up`)],
[[POV.Second, POV.Third], (user, target) => new LogLine(`You hork up ${target.name}`)],
[[POV.Third, POV.Second], (user, target) => new LogLine(`${user.name.capital} horks you up`)],
[[POV.Third, POV.Third], (user, target) => new LogLine(`${user.name.capital} horks up ${target.name.capital}`)]
])

struggleLines = new POVPair([
[[POV.First, POV.Third], (user, target) => new LogLine(`You claw your way out of ${target.name}`)],
[[POV.Third, POV.First], (user, target) => new LogLine(`${user.name.capital} forces ${user.pronouns.possessive} way up your throat!`)],
[[POV.Second, POV.Third], (user, target) => new LogLine(`You claw your way out of ${target.name}`)],
[[POV.Third, POV.Second], (user, target) => new LogLine(`${user.name.capital} forces ${user.pronouns.possessive} way up your throat!`)],
[[POV.Third, POV.Third], (user, target) => new LogLine(`${user.name.capital} escapes from the gut of ${target.name}`)]
])

tickLines = new POVPairArgs<Vore, Vore, { damage: Damage }>([
[[POV.First, POV.Third], (user, target, args) => new LogLine(`Your stomach gurgles ${target.name} for `, args.damage.renderShort())],
[[POV.Third, POV.First], (user, target, args) => new LogLine(`${user.name.capital}'s stomach churns you for `, args.damage.renderShort())],
[[POV.Second, POV.Third], (user, target, args) => new LogLine(`Your stomach gurgles ${target.name} for `, args.damage.renderShort())],
[[POV.Third, POV.Second], (user, target, args) => new LogLine(`${user.name.capital}'s stomach churns you for `, args.damage.renderShort())],
[[POV.Third, POV.Third], (user, target, args) => new LogLine(`${user.name.capital} churns ${target.name} for `, args.damage.renderShort())]
])

digestLines = new POVPair([
[[POV.First, POV.Third], (user, target) => new LogLine(`Your stomach overwhelms ${target.name}`)],
[[POV.Third, POV.First], (user, target) => new LogLine(`${user.name.capital}'s stomach finishes you off`)],
[[POV.Second, POV.Third], (user, target) => new LogLine(`Your stomach overwhelms ${target.name}`)],
[[POV.Third, POV.Second], (user, target) => new LogLine(`${user.name.capital}'s stomach finishes you off`)],
[[POV.Third, POV.Third], (user, target) => new LogLine(`${target.name.capital}'s squirms fade, overwhelmed by the stomach of ${user.name}`)]
])

absorbLines = new POVPair([
[[POV.First, POV.Third], (user, target) => new LogLine(`Your guts completely absorb ${target.name}`)],
[[POV.Third, POV.First], (user, target) => new LogLine(`${user.name.capital}'s guts soak you up like water in a sponge`)],
[[POV.Second, POV.Third], (user, target) => new LogLine(`Your guts completely absorb ${target.name}`)],
[[POV.Third, POV.Second], (user, target) => new LogLine(`${user.name.capital}'s guts soak you up like water in a sponge`)],
[[POV.Third, POV.Third], (user, target) => new LogLine(`${user.name.capital} finishes absorbing the remains of ${target.name}`)]
])

disposeLines = new POVPair([
[[POV.First, POV.Third], (user, target) => new LogLine(`Your guts completely absorb ${target.name}`)],
[[POV.Third, POV.First], (user, target) => new LogLine(`${user.name.capital}'s guts soak you up like water in a sponge`)],
[[POV.Second, POV.Third], (user, target) => new LogLine(`Your guts completely absorb ${target.name}`)],
[[POV.Third, POV.Second], (user, target) => new LogLine(`${user.name.capital}'s guts soak you up like water in a sponge`)],
[[POV.Third, POV.Third], (user, target) => new LogLine(`${user.name.capital} finishes absorbing the remains of ${target.name}`)]
])
}
@@ -383,44 +387,44 @@ export class Bowels extends NormalVoreContainer {
}

consumeLines = new POVPair([
[[POV.First, POV.Third], (user, target) => new LogLine(`You force ${target.name} into your bowels`)],
[[POV.Third, POV.First], (user, target) => new LogLine(`${user.name.capital} works you into ${user.pronouns.possessive} ass`)],
[[POV.Second, POV.Third], (user, target) => new LogLine(`You force ${target.name} into your bowels`)],
[[POV.Third, POV.Second], (user, target) => new LogLine(`${user.name.capital} works you into ${user.pronouns.possessive} ass`)],
[[POV.Third, POV.Third], (user, target) => new LogLine(`${user.name.capital} anal-vores ${target.name.capital}`)]
])

releaseLines = new POVPair([
[[POV.First, POV.Third], (user, target) => new LogLine(`You let out ${target.name}`)],
[[POV.Third, POV.First], (user, target) => new LogLine(`${user.name.capital} lets you out `)],
[[POV.Second, POV.Third], (user, target) => new LogLine(`You let out ${target.name}`)],
[[POV.Third, POV.Second], (user, target) => new LogLine(`${user.name.capital} lets you out `)],
[[POV.Third, POV.Third], (user, target) => new LogLine(`${user.name.capital} lets out ${target.name.capital}`)]
])

struggleLines = new POVPair([
[[POV.First, POV.Third], (user, target) => new LogLine(`You claw your way out of ${target.name}`)],
[[POV.Third, POV.First], (user, target) => new LogLine(`${user.name.capital} forces ${user.pronouns.possessive} way out your rump!`)],
[[POV.Second, POV.Third], (user, target) => new LogLine(`You claw your way out of ${target.name}`)],
[[POV.Third, POV.Second], (user, target) => new LogLine(`${user.name.capital} forces ${user.pronouns.possessive} way out your rump!`)],
[[POV.Third, POV.Third], (user, target) => new LogLine(`${user.name.capital} escapes from the bowels of ${target.name}`)]
])

tickLines = new POVPairArgs<Vore, Vore, { damage: Damage }>([
[[POV.First, POV.Third], (user, target, args) => new LogLine(`Your bowels gurgle ${target.name} for `, args.damage.renderShort())],
[[POV.Third, POV.First], (user, target, args) => new LogLine(`${user.name.capital}'s bowels churn you for `, args.damage.renderShort())],
[[POV.Second, POV.Third], (user, target, args) => new LogLine(`Your bowels gurgle ${target.name} for `, args.damage.renderShort())],
[[POV.Third, POV.Second], (user, target, args) => new LogLine(`${user.name.capital}'s bowels churn you for `, args.damage.renderShort())],
[[POV.Third, POV.Third], (user, target, args) => new LogLine(`${target.name.capital} churns ${user.name} for `, args.damage.renderShort())]
])

digestLines = new POVPair([
[[POV.First, POV.Third], (user, target) => new LogLine(`Your bowels overwhelm ${target.name}`)],
[[POV.Third, POV.First], (user, target) => new LogLine(`${user.name.capital}'s bowels finish you off`)],
[[POV.Second, POV.Third], (user, target) => new LogLine(`Your bowels overwhelm ${target.name}`)],
[[POV.Third, POV.Second], (user, target) => new LogLine(`${user.name.capital}'s bowels finish you off`)],
[[POV.Third, POV.Third], (user, target) => new LogLine(`${target.name.capital}'s squirms fade, overwhelmed by the bowels of ${user.name}`)]
])

absorbLines = new POVPair([
[[POV.First, POV.Third], (user, target) => new LogLine(`Your guts completely absorb ${target.name}`)],
[[POV.Third, POV.First], (user, target) => new LogLine(`${user.name.capital}'s guts soak you up like water in a sponge`)],
[[POV.Second, POV.Third], (user, target) => new LogLine(`Your guts completely absorb ${target.name}`)],
[[POV.Third, POV.Second], (user, target) => new LogLine(`${user.name.capital}'s guts soak you up like water in a sponge`)],
[[POV.Third, POV.Third], (user, target) => new LogLine(`${user.name.capital} finishes absorbing the remains of ${target.name}`)]
])

disposeLines = new POVPair([
[[POV.First, POV.Third], (user, target) => new LogLine(`Your guts completely absorb ${target.name}`)],
[[POV.Third, POV.First], (user, target) => new LogLine(`${user.name.capital}'s guts soak you up like water in a sponge`)],
[[POV.Second, POV.Third], (user, target) => new LogLine(`Your guts completely absorb ${target.name}`)],
[[POV.Third, POV.Second], (user, target) => new LogLine(`${user.name.capital}'s guts soak you up like water in a sponge`)],
[[POV.Third, POV.Third], (user, target) => new LogLine(`${user.name.capital} finishes absorbing the remains of ${target.name}`)]
])
}

Laddar…
Avbryt
Spara