Feast 2.0!
Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.
 
 
 
 
 

104 строки
5.1 KiB

  1. import { Creature, POV, Entity } from '../entity'
  2. import { Stat, Damage, DamageType, TransferAction, Vigor, StatTest, FeedAction, DigestAction, EatenAction, AttackAction } from '../combat'
  3. import { ProperNoun, TheyPronouns, ImproperNoun, POVPair, FemalePronouns, POVPairArgs } from '../language'
  4. import { VoreType, Stomach, InnerStomach, Container } from '../vore'
  5. import { LogLine, LogLines, LogEntry, FAElem, CompositeLog, ImgElem } from '../interface'
  6. class BelchAction extends AttackAction {
  7. successLines = new POVPairArgs<Entity, Entity, { damage: Damage }>([
  8. [[POV.First, POV.Third], (user, target, args) => new CompositeLog(new LogLine(
  9. `You belch on ${target.name} for `,
  10. args.damage.renderShort()
  11. ), new ImgElem('./media/cafat/images/belch.webp'))],
  12. [[POV.Third, POV.First], (user, target, args) => new CompositeLog(new LogLine(
  13. `${user.name.capital} belches on you for `,
  14. args.damage.renderShort()
  15. ), new ImgElem('./media/cafat/images/belch.webp'))],
  16. [[POV.Third, POV.Third], (user, target, args) => new CompositeLog(new LogLine(
  17. `${user.name.capital} belches on ${target.name} for `,
  18. args.damage.renderShort()
  19. ), new ImgElem('./media/cafat/images/belch.webp'))]
  20. ])
  21. constructor (damage: Damage) {
  22. super(damage)
  23. this.name = 'Belch'
  24. }
  25. }
  26. class CrushAction extends EatenAction {
  27. lines: POVPair<Entity, Entity> = new POVPair([
  28. [[POV.First, POV.Third], (user, target) => new LogLine(`You crush ${target.name} `, new FAElem('fas fa-skull'))],
  29. [[POV.Third, POV.First], (user, target) => new CompositeLog(new LogLine(`${user.name.capital} crushes you; ${user.pronouns.subjective} belches as ${user.pronouns.possessive} gut lets out a fatal CRUNCH `, new FAElem('fas fa-skull')), new ImgElem('./media/cafat/images/crunch.webp'))],
  30. [[POV.Third, POV.Third], (user, target) => new LogLine(`${user.name.capital} crushes ${target.name}; ${user.pronouns.subjective} belches as ${user.pronouns.possessive} gut lets out a fatal CRUNCH `, new FAElem('fas fa-skull'))]
  31. ])
  32. private damage: Damage = new Damage(
  33. { amount: 99, type: DamageType.Crush, target: Vigor.Health }
  34. )
  35. constructor (container: Container) {
  36. super(container, "Crush", "Crush 'em!")
  37. }
  38. execute (user: Creature, target: Creature): LogEntry {
  39. target.takeDamage(this.damage)
  40. return this.lines.run(user, target)
  41. }
  42. }
  43. export class Cafat extends Creature {
  44. constructor () {
  45. super(new ProperNoun('Cafat'), [TheyPronouns, FemalePronouns][Math.floor(Math.random() * 2)], { [Stat.STR]: 30, [Stat.DEX]: 15, [Stat.CON]: 25 }, new Set([VoreType.Oral, VoreType.Anal]), new Set([VoreType.Oral, VoreType.Anal]), 150)
  46. this.vigors.Health = 200
  47. this.maxVigors.Health = 200
  48. this.vigors.Stamina = 250
  49. this.maxVigors.Stamina = 250
  50. this.vigors.Willpower = 150
  51. this.maxVigors.Willpower = 150
  52. const stomach = new Stomach(this, 100, new Damage(
  53. { amount: 20, type: DamageType.Acid, target: Vigor.Health },
  54. { amount: 10, type: DamageType.Crush, target: Vigor.Stamina },
  55. { amount: 10, type: DamageType.Dominance, target: Vigor.Willpower }
  56. ))
  57. stomach.name = new ImproperNoun("upper stomach", "upper stomachs").all
  58. this.containers.push(stomach)
  59. const lowerStomach = new InnerStomach(this, 100, new Damage(
  60. { amount: 40, type: DamageType.Acid, target: Vigor.Health },
  61. { amount: 20, type: DamageType.Crush, target: Vigor.Stamina },
  62. { amount: 20, type: DamageType.Dominance, target: Vigor.Willpower }
  63. ), stomach)
  64. lowerStomach.name = new ImproperNoun("lower stomach", "lower stomachs").all
  65. stomach.consumeLines = new POVPair([
  66. [[POV.First, POV.Third], (user, target) => new LogLines(`You devour ${target.name}`)],
  67. [[POV.Third, POV.First], (user, target) => new CompositeLog(new LogLines(`${user.name.capital} devours you`), new ImgElem('./media/cafat/images/stomach.webp'))],
  68. [[POV.Third, POV.Third], (user, target) => new LogLines(`${user.name.capital} munches ${target.name.capital}`)]
  69. ])
  70. const crush = new CrushAction(lowerStomach)
  71. lowerStomach.actions.push(crush)
  72. this.containers.push(lowerStomach)
  73. const transfer = new TransferAction(stomach, lowerStomach)
  74. transfer.lines = new POVPairArgs([
  75. [[POV.First, POV.Third], (user, target, args) => new LogLine(`You squeeze ${target.name} from your ${args.from.name} to your ${args.to.name}`)],
  76. [[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'))],
  77. [[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}`)]
  78. ])
  79. this.actions.push(transfer)
  80. this.actions.push(new TransferAction(lowerStomach, stomach))
  81. this.actions.push(new BelchAction(new Damage(
  82. { amount: 100, target: Vigor.Willpower, type: DamageType.Acid }
  83. )))
  84. this.otherActions.push(new FeedAction(stomach))
  85. }
  86. }