big steppy
Ви не можете вибрати більше 25 тем Теми мають розпочинатися з літери або цифри, можуть містити дефіси (-) і не повинні перевищувати 35 символів.
 
 
 

1417 рядки
38 KiB

  1. var strolling = false;
  2. var maxStomachDigest = 10;
  3. var maxBowelsDigest = 10;
  4. var unit = "metric";
  5. var numbers = "full";
  6. var verbose = true;
  7. var biome = "suburb";
  8. var newline = " ";
  9. victims = {};
  10. var macro =
  11. {
  12. "scaling": function(value, scale, factor) { return value * Math.pow(scale,factor); },
  13. "species": "crux",
  14. "color" : "blue",
  15. "baseHeight": 2.26,
  16. get height() { return this.scaling(this.baseHeight, this.scale, 1); },
  17. "baseMass": 135,
  18. get mass () { return this.scaling(this.baseMass, this.scale, 3); },
  19. "basePawArea": 0.1,
  20. get pawArea() { return this.scaling(this.basePawArea, this.scale, 2); },
  21. "baseAnalVoreArea": 0.1,
  22. get analVoreArea() { return this.scaling(this.baseAnalVoreArea, this.scale, 2); },
  23. "baseAssArea": 0.4,
  24. get assArea() { return this.scaling(this.baseAssArea * this.assScale, this.scale, 2); },
  25. "baseHandArea": 0.1,
  26. get handArea() { return this.scaling(this.baseHandArea, this.scale, 2); },
  27. "assScale": 1,
  28. "dickType": "canine",
  29. "baseDickLength": 0.3,
  30. "baseDickDiameter": 0.08,
  31. "dickDensity": 1000,
  32. "dickScale": 1,
  33. get dickLength() {
  34. factor = 1;
  35. if (!this.arousalEnabled || this.arousal < 25) {
  36. factor = 0.5;
  37. } else if (this.arousal < 75) {
  38. factor = 0.5 + (this.arousal - 25) / 10;
  39. }
  40. return this.scaling(this.baseDickLength * this.dickScale * factor, this.scale, 1);
  41. },
  42. get dickDiameter() {
  43. factor = 1;
  44. if (!this.arousalEnabled || this.arousal < 25) {
  45. factor = 0.5;
  46. } else if (this.arousal < 75) {
  47. factor = 0.5 + (this.arousal - 25) / 10;
  48. }
  49. return this.scaling(this.baseDickDiameter * this.dickScale * factor, this.scale, 1);
  50. },
  51. get dickGirth() {
  52. return Math.pow((this.dickDiameter/ 2),2) * Math.PI;
  53. },
  54. get dickArea() {
  55. return this.dickLength* this.dickDiameter* Math.PI / 2;
  56. },
  57. get dickVolume() {
  58. return this.dickLength* Math.pow(this.dickDiameter2,2) * Math.PI;
  59. },
  60. get dickMass() {
  61. return this.dickVolume* this.dickDensity;
  62. },
  63. "baseBallDiameter": 0.05,
  64. "ballDensity": 1000,
  65. "ballScale": 1,
  66. get ballDiameter() { return this.scaling(this.baseBallDiameter * this.ballScale, this.scale, 1); },
  67. get ballArea() { return 2 * Math.PI * Math.pow(this.ballDiameter/2, 2) },
  68. get ballVolume() {
  69. var radius = this.ballDiameter / 2;
  70. return 4/3 * Math.PI * Math.pow(radius,3);
  71. },
  72. get ballMass() {
  73. var volume = this.ballVolume;
  74. return volume * this.ballDensity;
  75. },
  76. "baseCumRatio": 1,
  77. "cumScale": 1,
  78. get cumVolume() {
  79. return this.dickGirth * this.baseCumRatio * this.cumScale + Math.max(0,this.cumStorage.amount - this.cumStorage.limit);
  80. },
  81. "baseVaginaLength": 0.1,
  82. "baseVaginaWidth": 0.05,
  83. "vaginaScale": 1,
  84. get vaginaLength() { return this.scaling(this.baseVaginaLength * this.vaginaScale, this.scale, 1); },
  85. get vaginaWidth() { return this.scaling(this.baseVaginaWidth * this.vaginaScale, this.scale, 1); },
  86. get vaginaArea() { return this.vaginaLength * this.vaginaWidth },
  87. get vaginaVolume() { return this.vaginaArea * this.vaginaWidth },
  88. "baseFemcumRatio": 1,
  89. "femcumScale": 1,
  90. get femcumVolume() {
  91. return this.vaginaArea * this.baseFemcumRatio * this.femcumScale + Math.max(0,this.femcumStorage.amount - this.femcumStorage.limit);
  92. },
  93. "baseBreastDiameter": 0.1,
  94. "breastScale": 1,
  95. "breastDensity": 1000,
  96. get breastDiameter() { return this.scaling(this.baseBreastDiameter * this.breastScale, this.scale, 1); },
  97. get breastArea() {
  98. return 2 * Math.PI * Math.pow(this.breastDiameter/2,2);
  99. },
  100. get breastVolume() {
  101. var radius = this.breastDiameter / 2;
  102. return 4/3 * Math.PI * Math.pow(radius,3);
  103. },
  104. get breastMass() {
  105. var volume = this.breastVolume;
  106. return volume * this.breastDensity;
  107. },
  108. "digest": function(owner,organ) {
  109. var count = Math.min(organ.contents.length, organ.maxDigest);
  110. var container = new Container();
  111. while (count > 0) {
  112. var victim = organ.contents.shift();
  113. if (victim.name != "Container")
  114. victim = new Container([victim]);
  115. container = container.merge(victim);
  116. --count;
  117. }
  118. var digested = container.sum();
  119. for (var key in victims[organ.name]) {
  120. if (victims[organ.name].hasOwnProperty(key) && digested.hasOwnProperty(key) ) {
  121. victims["digested"][key] += digested[key];
  122. victims[organ.name][key] -= digested[key];
  123. }
  124. }
  125. var line = organ.describeDigestion(container);
  126. organ.fill(this,container);
  127. var summary = summarize(container.sum());
  128. if (organ.contents.length > 0) {
  129. setTimeout(function() { owner.digest(owner,organ) }, 15000);
  130. }
  131. update([line,summary,newline]);
  132. },
  133. "stomach": {
  134. "name": "stomach",
  135. "feed": function(prey) {
  136. this.feedFunc(prey,this,this.owner);
  137. },
  138. "feedFunc": function(prey,self,owner) {
  139. if (self.contents.length == 0)
  140. setTimeout(function() { owner.digest(owner,self) }, 15000);
  141. this.contents.push(prey);
  142. },
  143. "describeDigestion": function(container) {
  144. return "Your stomach gurgles as it digests " + container.describe(false);
  145. },
  146. "fill": function(owner,container) {
  147. //no-op
  148. },
  149. "contents": [],
  150. "maxDigest": 5
  151. },
  152. "bowels": {
  153. "name" : "bowels",
  154. "feed": function(prey) {
  155. this.feedFunc(prey,this,this.owner);
  156. },
  157. "feedFunc": function(prey,self,owner) {
  158. if (self.contents.length == 0)
  159. setTimeout(function() { owner.digest(owner,self) }, 15000);
  160. this.contents.push(prey);
  161. },
  162. "describeDigestion" : function(container) {
  163. return "Your bowels churn as they absorb " + container.describe(false);
  164. },
  165. "fill": function(owner,container) {
  166. //no-op
  167. },
  168. "contents" : [],
  169. "maxDigest" : 3
  170. },
  171. "womb": {
  172. "name" : "womb",
  173. "feed": function(prey) {
  174. this.feedFunc(prey,this,this.owner);
  175. },
  176. "feedFunc": function(prey,self,owner) {
  177. if (self.contents.length == 0)
  178. setTimeout(function() { owner.digest(owner,self) }, 15000);
  179. this.contents.push(prey);
  180. },
  181. "describeDigestion" : function(container) {
  182. return "Your womb squeezes as it dissolves " + container.describe(false);
  183. },
  184. "fill": function(owner,container) {
  185. owner.femcumStorage.amount += container.sum_property("mass") / 1e3;
  186. },
  187. "contents" : [],
  188. "maxDigest" : 1
  189. },
  190. "balls": {
  191. "name" : "balls",
  192. "feed": function(prey) {
  193. this.feedFunc(prey,this,this.owner);
  194. },
  195. "feedFunc": function(prey,self,owner) {
  196. if (self.contents.length == 0)
  197. setTimeout(function() { owner.digest(owner,self) }, 15000);
  198. this.contents.push(prey);
  199. },
  200. "describeDigestion": function(container) {
  201. return "Your balls slosh as they transform " + container.describe(false) + " into cum";
  202. },
  203. "fill": function(owner,container) {
  204. owner.cumStorage.amount += container.sum_property("mass") / 1e3;
  205. },
  206. "contents" : [],
  207. "maxDigest" : 1
  208. },
  209. "init": function() {
  210. this.stomach.owner = this;
  211. this.bowels.owner = this;
  212. this.womb.owner = this;
  213. this.balls.owner = this;
  214. this.cumStorage.owner = this;
  215. this.femcumStorage.owner = this;
  216. if (this.maleParts)
  217. this.fillCum(this)
  218. if (this.femaleParts)
  219. this.fillFemcum(this)
  220. if (this.maleParts || this.femaleParts) {
  221. }
  222. },
  223. "maleParts": true,
  224. "femaleParts": true,
  225. "fillCum": function(self) {
  226. self.cumStorage.amount += self.cumScale * self.ballVolume / 120;
  227. if (self.cumStorage.amount > self.cumStorage.limit)
  228. self.arouse(10 * (self.cumStorage.amount / self.cumStorage.limit - 1));
  229. setTimeout(function () { self.fillCum(self) }, 1000);
  230. update();
  231. },
  232. "fillFemcum": function(self) {
  233. self.femcumStorage.amount += self.femcumScale * self.vaginaVolume / 120;
  234. if (self.femcumStorage.amount > self.femcumStorage.limit)
  235. self.arouse(10 * (self.femcumStorage.amount / self.femcumStorage.limit - 1));
  236. setTimeout(function () { self.fillFemcum(self) }, 1000);
  237. update();
  238. },
  239. "cumStorage": {
  240. "amount": 0,
  241. get limit() {
  242. return this.owner.ballVolume;
  243. }
  244. },
  245. "femcumStorage": {
  246. "amount": 0,
  247. get limit() {
  248. return this.owner.vaginaVolume;
  249. }
  250. },
  251. "orgasm": false,
  252. "arousalEnabled": true,
  253. "arousalFactor": 1,
  254. "arousal": 0,
  255. "arouse": function(amount) {
  256. if (!this.arousalEnabled)
  257. return;
  258. this.arousal += amount * this.arousalFactor;
  259. if (this.arousal >= 200) {
  260. this.arousal = 200;
  261. if (!this.orgasm) {
  262. this.orgasm = true;
  263. if (this.maleParts) {
  264. this.maleOrgasm(this);
  265. }
  266. if (this.femaleParts) {
  267. this.femaleOrgasm(this);
  268. }
  269. }
  270. }
  271. },
  272. "quench": function(amount) {
  273. if (!this.arousalEnabled)
  274. return;
  275. this.arousal -= amount;
  276. if (this.arousal <= 0) {
  277. this.arousal = 0;
  278. if (this.orgasm) {
  279. this.orgasm = false;
  280. }
  281. }
  282. },
  283. "quenchExcess": function(self) {
  284. if (self.arousalEnabled) {
  285. if (self.arousal > 100 && !self.orgasm) {
  286. self.arousal = Math.max(100,self.arousal-10);
  287. }
  288. }
  289. }
  290. "maleOrgasm": function(self) {
  291. if (!this.arousalEnabled)
  292. return;
  293. if (self.orgasm) {
  294. self.quench(10);
  295. var amount = Math.min(this.cumVolume, this.cumStorage.amount);
  296. this.cumStorage.amount -= amount;
  297. male_orgasm(amount);
  298. setTimeout(function() { self.maleOrgasm(self) }, 2000);
  299. }
  300. },
  301. "femaleOrgasm": function(self) {
  302. if (!this.arousalEnabled)
  303. return;
  304. if (this.orgasm) {
  305. this.quench(10);
  306. var amount = Math.min(this.femcumVolume, this.femcumStorage.amount);
  307. this.femcumStorage.amount -= amount;
  308. female_orgasm(amount);
  309. setTimeout(function() { self.femaleOrgasm(self) }, 2000);
  310. }
  311. },
  312. get description() {
  313. result = [];
  314. line = "You are a " + length(macro.height, unit, true) + " tall " + macro.species + ". You weigh " + mass(macro.mass, unit) + ".";
  315. result.push(line);
  316. if (this.maleParts) {
  317. state = "";
  318. if (!this.arousalEnabled) {
  319. state = "limp";
  320. } else if (this.orgasm) {
  321. state = "spurting";
  322. } else {
  323. if (this.arousal < 25) {
  324. state = "limp";
  325. } else if (this.arousal < 50) {
  326. state = "swelling";
  327. } else if (this.arousal < 75) {
  328. state = "erect";
  329. } else if (this.arousal < 100) {
  330. state = "erect, precum-oozing";
  331. }
  332. }
  333. line = "Your " + length(macro.dickLength, unit, true) + " long " + state + " " + macro.dickType + " cock hangs from your hips, with two " + mass(macro.ballMass, unit, true) + ", " + length(macro.ballDiameter, unit, true) + "-wide balls hanging beneath.";
  334. result.push(line);
  335. }
  336. if (this.femaleParts) {
  337. state = "";
  338. if (!this.arousalEnabled) {
  339. state = "unassuming";
  340. } else if (this.orgasm) {
  341. state = "gushing, quivering";
  342. } else {
  343. if (this.arousal < 25) {
  344. state = "unassuming";
  345. } else if (this.arousal < 50) {
  346. state = "moist";
  347. } else if (this.arousal < 75) {
  348. state = "glistening";
  349. } else if (this.arousal < 100) {
  350. state = "dripping";
  351. }
  352. }
  353. line = "Your glistening " + length(macro.vaginaLength, unit, true) + " long " + state + " slit is oozing between your legs."
  354. result.push(line);
  355. line = "You have two " + length(macro.breastDiameter, unit, true) + "-wide breasts that weigh " + mass(macro.breastMass, unit) + " apiece.";
  356. result.push(line);
  357. }
  358. return result;
  359. },
  360. "growthPoints": 0,
  361. "addGrowthPoints": function(mass) {
  362. this.growthPoints += Math.round(50 * mass / (this.scale*this.scale));
  363. },
  364. "scale": 3,
  365. }
  366. function look()
  367. {
  368. var desc = macro.description;
  369. var line2 = ""
  370. if (macro.height > 1e12)
  371. line2 = "You're pretty much everywhere at once.";
  372. else if (macro.height > 1e6)
  373. line2 = "You're standing...on pretty much everything at once.";
  374. else
  375. switch(biome) {
  376. case "rural": line2 = "You're standing amongst rural farmhouses and expansive ranches. Cattle are milling about at your feet."; break;
  377. case "suburb": line2 = "You're striding through the winding roads of a suburb."; break;
  378. case "city": line2 = "You're terrorizing the streets of a city. Heavy traffic, worsened by your rampage, is everywhere."; break;
  379. case "downtown": line2 = "You're lurking amongst the skyscrapers of downtown. The streets are packed, and the buildings are practically begging you to knock them over.";
  380. }
  381. desc = desc.concat([newline,line2,newline]);
  382. update(desc);
  383. }
  384. function get_living_prey(sum) {
  385. var total = 0;
  386. for (var key in sum) {
  387. if (sum.hasOwnProperty(key)) {
  388. if (key == "Person" || key == "Cow")
  389. total += sum[key];
  390. }
  391. }
  392. return total;
  393. }
  394. function toggle_auto()
  395. {
  396. strolling = !strolling;
  397. document.getElementById("button-stroll").innerHTML = "Status: " + (strolling ? "Strolling" : "Standing");
  398. if (strolling)
  399. update(["You start walking.",newline]);
  400. else
  401. update(["You stop walking.",newline]);
  402. }
  403. function change_location()
  404. {
  405. switch(biome) {
  406. case "suburb": biome = "city"; break;
  407. case "city": biome = "downtown"; break;
  408. case "downtown": biome = "rural"; break;
  409. case "rural": biome = "suburb"; break;
  410. }
  411. document.getElementById("button-location").innerHTML = "Location: " + biome.charAt(0).toUpperCase() + biome.slice(1);
  412. }
  413. function toggle_units()
  414. {
  415. switch(unit) {
  416. case "metric": unit = "customary"; break;
  417. case "customary": unit = "approx"; break;
  418. case "approx": unit = "metric"; break;
  419. }
  420. document.getElementById("button-units").innerHTML = "Units: " + unit.charAt(0).toUpperCase() + unit.slice(1);
  421. update();
  422. }
  423. function toggle_numbers() {
  424. switch(numbers) {
  425. case "full": numbers="prefix"; break;
  426. case "prefix": numbers="words"; break;
  427. case "words": numbers = "scientific"; break;
  428. case "scientific": numbers = "full"; break;
  429. }
  430. document.getElementById("button-numbers").innerHTML = "Numbers: " + numbers.charAt(0).toUpperCase() + numbers.slice(1);
  431. update();
  432. }
  433. function toggle_verbose()
  434. {
  435. verbose = !verbose;
  436. document.getElementById("button-verbose").innerHTML = "Descriptions: " + (verbose ? "Verbose" : "Simple");
  437. }
  438. function toggle_arousal()
  439. {
  440. macro.arousalEnabled = !macro.arousalEnabled;
  441. document.getElementById("button-arousal").innerHTML = (macro.arousalEnabled ? "Arousal On" : "Arousal Off");
  442. if (macro.arousalEnabled)
  443. document.getElementById("arousal").style.display = "block";
  444. else
  445. document.getElementById("arousal").style.display = "none";
  446. }
  447. function initVictims()
  448. {
  449. return {
  450. "Person": 0,
  451. "Cow": 0,
  452. "Car": 0,
  453. "Bus": 0,
  454. "Tram": 0,
  455. "Motorcycle": 0,
  456. "House": 0,
  457. "Barn": 0,
  458. "Small Skyscraper": 0,
  459. "Large Skyscraper": 0,
  460. "Train": 0,
  461. "Train Car": 0,
  462. "Parking Garage": 0,
  463. "Overpass": 0,
  464. "Town": 0,
  465. "City": 0,
  466. "Continent": 0,
  467. "Planet": 0,
  468. "Star": 0,
  469. "Solar System": 0,
  470. "Galaxy": 0
  471. };
  472. };
  473. // lists out total people
  474. function summarize(sum, fatal = true)
  475. {
  476. var count = get_living_prey(sum);
  477. return "<b>(" + count + " " + (fatal ? (count > 1 ? "kills" : "kill") : (count > 1 ? "prey" : "prey")) + ")</b>";
  478. }
  479. function getOnePrey(biome,area)
  480. {
  481. var potential = ["Person"];
  482. if (macro.height > 1e12)
  483. potential = ["Planet","Star","Solar System","Galaxy"];
  484. else if (macro.height > 1e6)
  485. potential = ["Town","City","Continent","Planet"];
  486. else
  487. switch(biome) {
  488. case "suburb": potential = ["Person", "Car", "Bus", "Train", "House"]; break;
  489. case "city": potential = ["Person", "Car", "Bus", "Train", "Tram", "House", "Parking Garage"]; break;
  490. case "downtown": potential = ["Person", "Car", "Bus", "Tram", "Small Skyscraper", "Large Skyscraper", "Parking Garage"]; break;
  491. case "rural": potential = ["Person", "Barn", "House", "Cow"]; break;
  492. }
  493. var potAreas = []
  494. potential.forEach(function (x) {
  495. potAreas.push([x,areas[x]]);
  496. });
  497. potAreas = potAreas.sort(function (x,y) {
  498. return y[1] - x[1];
  499. });
  500. for (var i=0; i<potAreas.length; i++) {
  501. x = potAreas[i];
  502. if (x[1] < area) {
  503. return new Container([new things[x[0]](1)]);
  504. }
  505. };
  506. return new Container([new Person(1)]);
  507. }
  508. function getPrey(region, area)
  509. {
  510. var weights = {"Person": 1};
  511. if (macro.height > 1e12) {
  512. weights = {
  513. "Planet": 1e-10,
  514. "Star": 1e-10,
  515. "Solar System": 1e-10,
  516. "Galaxy": 1e-10
  517. }
  518. }
  519. else if (macro.height > 1e6) {
  520. weights = {
  521. "Town": 0.1,
  522. "City": 0.05,
  523. "Continent": 0.005,
  524. "Planet": 0.0001
  525. }
  526. }
  527. else {
  528. switch(region)
  529. {
  530. case "rural": weights = {
  531. "Person": 0.05,
  532. "House": 0.01,
  533. "Barn": 0.01,
  534. "Cow": 0.2
  535. }; break;
  536. case "suburb": weights = {
  537. "Person": 0.5,
  538. "House": 0.5,
  539. "Car": 0.2,
  540. "Train": 0.1,
  541. "Bus": 0.1
  542. }; break;
  543. case "city": weights = {
  544. "Person": 0.5,
  545. "House": 0.2,
  546. "Car": 0.2,
  547. "Train": 0.1,
  548. "Bus": 0.1,
  549. "Tram": 0.1,
  550. "Parking Garage": 0.02
  551. }; break;
  552. case "downtown": weights = {
  553. "Person": 0.5,
  554. "Car": 0.3,
  555. "Bus": 0.15,
  556. "Tram": 0.1,
  557. "Parking Garage": 0.02,
  558. "Small Skyscraper": 0.4,
  559. "Large Skyscraper": 0.1
  560. }; break;
  561. }
  562. }
  563. return fill_area(area,weights);
  564. }
  565. function updateVictims(type,prey)
  566. {
  567. var sums = prey.sum();
  568. for (var key in sums) {
  569. if (sums.hasOwnProperty(key)) {
  570. victims[type][key] += sums[key];
  571. }
  572. }
  573. }
  574. function feed()
  575. {
  576. var area = macro.handArea;
  577. var prey = getPrey(biome, area);
  578. var line = describe("eat", prey, macro, verbose)
  579. var linesummary = summarize(prey.sum(), false);
  580. var people = get_living_prey(prey.sum());
  581. var sound = "";
  582. if (people == 0) {
  583. sound = "";
  584. } else if (people < 3) {
  585. sound = "Ulp.";
  586. } else if (people < 10) {
  587. sound = "Gulp.";
  588. } else if (people < 50) {
  589. sound = "Glrrp.";
  590. } else if (people < 500) {
  591. sound = "Glrrrpkh!";
  592. } else if (people < 5000) {
  593. sound = "GLRRKPKH!";
  594. } else {
  595. sound = "Oh the humanity!";
  596. }
  597. var preyMass = prey.sum_property("mass");
  598. macro.addGrowthPoints(preyMass);
  599. macro.stomach.feed(prey);
  600. macro.arouse(5);
  601. updateVictims("stomach",prey);
  602. update([sound,line,linesummary,newline]);
  603. }
  604. function stomp()
  605. {
  606. var area = macro.pawArea;
  607. var prey = getPrey(biome, area);
  608. var line = describe("stomp", prey, macro, verbose)
  609. var linesummary = summarize(prey.sum(), true);
  610. var people = get_living_prey(prey.sum());
  611. var sound = "Thump";
  612. if (people < 3) {
  613. sound = "Thump!";
  614. } else if (people < 10) {
  615. sound = "Squish!";
  616. } else if (people < 50) {
  617. sound = "Crunch!";
  618. } else if (people < 500) {
  619. sound = "CRUNCH!";
  620. } else if (people < 5000) {
  621. sound = "CRRUUUNCH!!";
  622. } else {
  623. sound = "Oh the humanity!";
  624. }
  625. var preyMass = prey.sum_property("mass");
  626. macro.addGrowthPoints(preyMass);
  627. macro.arouse(5);
  628. updateVictims("stomped",prey);
  629. update([sound,line,linesummary,newline]);
  630. }
  631. function anal_vore()
  632. {
  633. var area = macro.analVoreArea;
  634. var prey = getOnePrey(biome,area);
  635. area = macro.assArea;
  636. var crushed = getPrey(biome,area);
  637. var line1 = describe("anal-vore", prey, macro, verbose);
  638. var line1summary = summarize(prey.sum(), false);
  639. var line2 = describe("ass-crush", crushed, macro, verbose);
  640. var line2summary = summarize(crushed.sum(), true);
  641. var people = get_living_prey(prey.sum());
  642. var sound = "Shlp";
  643. if (people < 3) {
  644. sound = "Shlp.";
  645. } else if (people < 10) {
  646. sound = "Squelch.";
  647. } else if (people < 50) {
  648. sound = "Shlurrp.";
  649. } else if (people < 500) {
  650. sound = "SHLRP!";
  651. } else if (people < 5000) {
  652. sound = "SQLCH!!";
  653. } else {
  654. sound = "Oh the humanity!";
  655. }
  656. var people = get_living_prey(crushed.sum());
  657. var sound2 = "Thump";
  658. if (people < 3) {
  659. sound2 = "Thump!";
  660. } else if (people < 10) {
  661. sound2 = "Squish!";
  662. } else if (people < 50) {
  663. sound2 = "Crunch!";
  664. } else if (people < 500) {
  665. sound2 = "CRUNCH!";
  666. } else if (people < 5000) {
  667. sound2 = "CRRUUUNCH!!";
  668. } else {
  669. sound2 = "Oh the humanity!";
  670. }
  671. var preyMass = prey.sum_property("mass");
  672. var crushedMass = prey.sum_property("mass");
  673. macro.addGrowthPoints(preyMass);
  674. macro.addGrowthPoints(crushedMass);
  675. macro.bowels.feed(prey);
  676. macro.arouse(10);
  677. updateVictims("bowels",prey);
  678. updateVictims("stomped",crushed);
  679. update([sound,line1,line1summary,newline,sound2,line2,line2summary,newline]);
  680. }
  681. function breast_crush()
  682. {
  683. var area = macro.breastArea;
  684. var prey = getPrey(biome, area);
  685. var line = describe("breast-crush", prey, macro, verbose);
  686. var linesummary = summarize(prey.sum(), true);
  687. var people = get_living_prey(prey.sum());
  688. var sound = "Thump";
  689. if (people < 3) {
  690. sound = "Thump!";
  691. } else if (people < 10) {
  692. sound = "Squish!";
  693. } else if (people < 50) {
  694. sound = "Crunch!";
  695. } else if (people < 500) {
  696. sound = "CRUNCH!";
  697. } else if (people < 5000) {
  698. sound = "CRRUUUNCH!!";
  699. } else {
  700. sound = "Oh the humanity!";
  701. }
  702. var preyMass = prey.sum_property("mass");
  703. macro.addGrowthPoints(preyMass);
  704. macro.arouse(10);
  705. updateVictims("breasts",prey);
  706. update([sound,line,linesummary,newline]);
  707. }
  708. function unbirth()
  709. {
  710. var area = macro.vaginaArea;
  711. var prey = getPrey(biome, area);
  712. var line = describe("unbirth", prey, macro, verbose)
  713. var linesummary = summarize(prey.sum(), false);
  714. var people = get_living_prey(prey.sum());
  715. var sound = "";
  716. if (people < 3) {
  717. sound = "Shlp.";
  718. } else if (people < 10) {
  719. sound = "Squelch.";
  720. } else if (people < 50) {
  721. sound = "Shlurrp.";
  722. } else if (people < 500) {
  723. sound = "SHLRP!";
  724. } else if (people < 5000) {
  725. sound = "SQLCH!!";
  726. } else {
  727. sound = "Oh the humanity!";
  728. }
  729. var preyMass = prey.sum_property("mass");
  730. macro.addGrowthPoints(preyMass);
  731. macro.womb.feed(prey);
  732. macro.arouse(20);
  733. updateVictims("womb",prey);
  734. update([sound,line,linesummary,newline]);
  735. }
  736. function cockslap()
  737. {
  738. var area = macro.dickArea;
  739. var prey = getPrey(biome, area);
  740. var line = describe("cockslap", prey, macro, verbose)
  741. var linesummary = summarize(prey.sum(), true);
  742. var people = get_living_prey(prey.sum());
  743. var sound = "Thump";
  744. if (people < 3) {
  745. sound = "Thump!";
  746. } else if (people < 10) {
  747. sound = "Squish!";
  748. } else if (people < 50) {
  749. sound = "Crunch!";
  750. } else if (people < 500) {
  751. sound = "CRUNCH!";
  752. } else if (people < 5000) {
  753. sound = "CRRUUUNCH!!";
  754. } else {
  755. sound = "Oh the humanity!";
  756. }
  757. var preyMass = prey.sum_property("mass");
  758. macro.addGrowthPoints(preyMass);
  759. macro.arouse(15);
  760. updateVictims("cock",prey);
  761. update([sound,line,linesummary,newline]);
  762. }
  763. function cock_vore()
  764. {
  765. var area = macro.dickGirth;
  766. var prey = getPrey(biome, area);
  767. var line = describe("cock-vore", prey, macro, verbose)
  768. var linesummary = summarize(prey.sum(), false);
  769. var people = get_living_prey(prey.sum());
  770. var sound = "lp";
  771. if (people < 3) {
  772. sound = "Shlp.";
  773. } else if (people < 10) {
  774. sound = "Squelch.";
  775. } else if (people < 50) {
  776. sound = "Shlurrp.";
  777. } else if (people < 500) {
  778. sound = "SHLRP!";
  779. } else if (people < 5000) {
  780. sound = "SQLCH!!";
  781. } else {
  782. sound = "Oh the humanity!";
  783. }
  784. var preyMass = prey.sum_property("mass");
  785. macro.addGrowthPoints(preyMass);
  786. macro.balls.feed(prey);
  787. macro.arouse(20);
  788. updateVictims("balls",prey);
  789. update([sound,line,linesummary,newline]);
  790. }
  791. function ball_smother()
  792. {
  793. var area = macro.ballArea * 2;
  794. var prey = getPrey(biome, area);
  795. var line = describe("ball-smother", prey, macro, verbose)
  796. var linesummary = summarize(prey.sum(), true);
  797. var people = get_living_prey(prey.sum());
  798. var sound = "Thump";
  799. if (people < 3) {
  800. sound = "Thump!";
  801. } else if (people < 10) {
  802. sound = "Squish!";
  803. } else if (people < 50) {
  804. sound = "Smoosh!";
  805. } else if (people < 500) {
  806. sound = "SMOOSH!";
  807. } else if (people < 5000) {
  808. sound = "SMOOOOOSH!!";
  809. } else {
  810. sound = "Oh the humanity!";
  811. }
  812. var preyMass = prey.sum_property("mass");
  813. macro.addGrowthPoints(preyMass);
  814. macro.arouse(10);
  815. updateVictims("balls",prey);
  816. update([sound,line,linesummary,newline]);
  817. }
  818. function male_orgasm(vol)
  819. {
  820. var area = Math.pow(vol, 2/3);
  821. var prey = getPrey(biome, area);
  822. var line = describe("male-orgasm", prey, macro, verbose).replace("$VOLUME",volume(vol,unit,false))
  823. var linesummary = summarize(prey.sum(), true);
  824. var people = get_living_prey(prey.sum());
  825. var sound = "Spurt!";
  826. if (people < 3) {
  827. sound = "Spurt!";
  828. } else if (people < 10) {
  829. sound = "Sploosh!";
  830. } else if (people < 50) {
  831. sound = "Sploooooosh!";
  832. } else if (people < 500) {
  833. sound = "SPLOOSH!";
  834. } else if (people < 5000) {
  835. sound = "SPLOOOOOOOOOOSH!!";
  836. } else {
  837. sound = "Oh the humanity!";
  838. }
  839. var preyMass = prey.sum_property("mass");
  840. macro.addGrowthPoints(preyMass);
  841. updateVictims("splooged",prey);
  842. update([sound,line,linesummary,newline]);
  843. }
  844. function female_orgasm(vol)
  845. {
  846. var area = Math.pow(vol, 2/3);
  847. var prey = getPrey(biome, area);
  848. var line = describe("female-orgasm", prey, macro, verbose).replace("$VOLUME",volume(vol,unit,false));
  849. var linesummary = summarize(prey.sum(), true);
  850. var people = get_living_prey(prey.sum());
  851. var sound = "Spurt!";
  852. if (people < 3) {
  853. sound = "Spurt!";
  854. } else if (people < 10) {
  855. sound = "Sploosh!";
  856. } else if (people < 50) {
  857. sound = "Sploooooosh!";
  858. } else if (people < 500) {
  859. sound = "SPLOOSH!";
  860. } else if (people < 5000) {
  861. sound = "SPLOOOOOOOOOOSH!!";
  862. } else {
  863. sound = "Oh the humanity!";
  864. }
  865. var preyMass = prey.sum_property("mass");
  866. macro.addGrowthPoints(preyMass);
  867. updateVictims("splooged",prey);
  868. update([sound,line,linesummary,newline]);
  869. }
  870. function transformNumbers(line)
  871. {
  872. return line.toString().replace(/[0-9]+(\.[0-9]+)?(e\+[0-9]+)?/g, function(text) { return number(text, numbers); });
  873. }
  874. function update(lines = [])
  875. {
  876. var log = document.getElementById("log");
  877. lines.forEach(function (x) {
  878. var line = document.createElement('div');
  879. line.innerHTML = transformNumbers(x);
  880. log.appendChild(line);
  881. });
  882. if (lines.length > 0)
  883. log.scrollTop = log.scrollHeight;
  884. document.getElementById("height").innerHTML = "Height: " + transformNumbers(length(macro.height, unit));
  885. document.getElementById("mass").innerHTML = "Mass: " + transformNumbers(mass(macro.mass, unit));
  886. document.getElementById("growth-points").innerHTML = "Growth Points:" + macro.growthPoints;
  887. document.getElementById("arousal").innerHTML = "Arousal: " + round(macro.arousal,0) + "%";
  888. document.getElementById("cum").innerHTML = "Cum: " + transformNumbers(volume(macro.cumStorage.amount,unit,false))
  889. document.getElementById("cumPercent").innerHTML = Math.round(macro.cumStorage.amount / macro.cumStorage.limit * 100) + "%";
  890. document.getElementById("femcum").innerHTML = "Femcum: " + transformNumbers(volume(macro.femcumStorage.amount,unit,false));
  891. document.getElementById("femcumPercent").innerHTML = Math.round(macro.femcumStorage.amount / macro.femcumStorage.limit * 100) + "%";
  892. for (var type in victims) {
  893. if (victims.hasOwnProperty(type)) {
  894. for (var key in victims[type]){
  895. if (victims[type].hasOwnProperty(key) && victims[type][key] > 0) {
  896. document.getElementById("stat-" + key).style.display = "table-row";
  897. document.getElementById("stat-" + type + "-" + key).innerHTML = number(victims[type][key],numbers);
  898. }
  899. }
  900. }
  901. }
  902. }
  903. function pick_move()
  904. {
  905. if (!strolling) {
  906. setTimeout(pick_move, 1500 * Math.sqrt(macro.scale));
  907. return;
  908. }
  909. var choice = Math.random();
  910. if (choice < 0.2) {
  911. anal_vore();
  912. } else if (choice < 0.6) {
  913. stomp();
  914. } else {
  915. feed();
  916. }
  917. setTimeout(pick_move, 1500 * Math.sqrt(macro.scale));
  918. }
  919. function grow_pick(times) {
  920. if (document.getElementById("part-body").checked == true) {
  921. grow(times);
  922. }
  923. else if (document.getElementById("part-ass").checked == true) {
  924. grow_ass(times);
  925. }
  926. else if (document.getElementById("part-dick").checked == true) {
  927. grow_dick(times);
  928. }
  929. else if (document.getElementById("part-balls").checked == true) {
  930. grow_balls(times);
  931. }
  932. else if (document.getElementById("part-breasts").checked == true) {
  933. grow_breasts(times);
  934. }
  935. else if (document.getElementById("part-vagina").checked == true) {
  936. grow_vagina(times);
  937. }
  938. }
  939. function grow(times=1)
  940. {
  941. if (macro.growthPoints < 100 * times) {
  942. update(["You don't feel like growing right now."]);
  943. return;
  944. }
  945. macro.growthPoints -= 100 * times;
  946. var oldHeight = macro.height;
  947. var oldMass = macro.mass;
  948. macro.scale *= Math.pow(1.02,times);
  949. var newHeight = macro.height;
  950. var newMass = macro.mass;
  951. var heightDelta = newHeight - oldHeight;
  952. var massDelta = newMass - oldMass;
  953. var heightStr = length(heightDelta, unit);
  954. var massStr = mass(massDelta, unit);
  955. update(["Power surges through you as you grow " + heightStr + " taller and gain " + massStr + " of mass",newline]);
  956. }
  957. function grow_dick(times=1)
  958. {
  959. if (macro.growthPoints < 10 * times) {
  960. update(["You don't feel like growing right now."]);
  961. return;
  962. }
  963. macro.growthPoints -= 10 * times;
  964. var oldLength = macro.dickLength;
  965. var oldMass = macro.dickMass;
  966. macro.dickScale = Math.pow(macro.dickScale * macro.dickScale + 1.02*times, 1/2) ;
  967. var lengthDelta = macro.dickLength - oldLength;
  968. var massDelta = macro.dickMass - oldMass;
  969. update(["Power surges through you as your " + macro.dickType + " cock grows " + length(lengthDelta, unit, false) + " longer and gains " + mass(massDelta, unit, false) + " of mass",newline]);
  970. }
  971. function grow_balls(times=1)
  972. {
  973. if (macro.growthPoints < 10 * times) {
  974. update(["You don't feel like growing right now."]);
  975. return;
  976. }
  977. macro.growthPoints -= 10 * times;
  978. var oldDiameter = macro.ballDiameter;
  979. var oldMass = macro.ballMass;
  980. macro.ballScale = Math.pow(macro.ballScale * macro.ballScale + 1.02*times, 1/2) ;
  981. var diameterDelta = macro.ballDiameter - oldDiameter;
  982. var massDelta = macro.ballMass - oldMass;
  983. update(["Power surges through you as your balls swell by " + length(diameterDelta, unit, false) + ", gaining " + mass(massDelta, unit, false) + " of mass apiece",newline]);
  984. }
  985. function grow_breasts(times=1)
  986. {
  987. if (macro.growthPoints < 10 * times) {
  988. update(["You don't feel like growing right now."]);
  989. return;
  990. }
  991. macro.growthPoints -= 10 * times;
  992. var oldDiameter = macro.breastDiameter;
  993. var oldMass = macro.breastMass;
  994. macro.breastScale = Math.pow(macro.breastScale * macro.breastScale + 1.02*times, 1/2) ;
  995. var diameterDelta = macro.breastDiameter - oldDiameter;
  996. var massDelta = macro.breastMass - oldMass;
  997. update(["Power surges through you as your breasts swell by " + length(diameterDelta, unit, false) + ", gaining " + mass(massDelta, unit, false) + " of mass apiece",newline]);
  998. }
  999. function grow_vagina(times=1)
  1000. {
  1001. if (macro.growthPoints < 10 * times) {
  1002. update(["You don't feel like growing right now."]);
  1003. return;
  1004. }
  1005. macro.growthPoints -= 10 * times;
  1006. var oldLength = macro.vaginaLength;
  1007. macro.vaginaScale = Math.pow(macro.vaginaScale * macro.vaginaScale + 1.02*times, 1/2) ;
  1008. var lengthDelta = macro.vaginaLength - oldLength;
  1009. update(["Power surges through you as your moist slit expands by by " + length(lengthDelta, unit, false),newline]);
  1010. }
  1011. function grow_ass(times=1)
  1012. {
  1013. if (macro.growthPoints < 10 * times) {
  1014. update(["You don't feel like growing right now."]);
  1015. return;
  1016. }
  1017. macro.growthPoints -= 10 * times;
  1018. var oldDiameter = Math.pow(macro.assArea,1/2);
  1019. macro.assScale = Math.pow(macro.assScale * macro.assScale + 1.02*times, 1/2) ;
  1020. var diameterDelta = Math.pow(macro.assArea,1/2) - oldDiameter;
  1021. update(["Power surges through you as your ass swells by " + length(diameterDelta, unit, false),newline]);
  1022. }
  1023. function grow_lots()
  1024. {
  1025. var oldHeight = macro.height;
  1026. var oldMass = macro.mass;
  1027. macro.scale *= 100;
  1028. var newHeight = macro.height;
  1029. var newMass = macro.mass;
  1030. var heightDelta = newHeight - oldHeight;
  1031. var massDelta = newMass - oldMass;
  1032. var heightStr = length(heightDelta, unit);
  1033. var massStr = mass(massDelta, unit);
  1034. update(["Power surges through you as you grow " + heightStr + " taller and gain " + massStr + " of mass",newline]);
  1035. }
  1036. function preset(name) {
  1037. switch(name){
  1038. case "Fen":
  1039. macro.species = "crux";
  1040. macro.baseHeight = 2.2606;
  1041. macro.baseMass = 124.738;
  1042. break;
  1043. case "Renard":
  1044. macro.species = "fox";
  1045. macro.baseHeight = 1.549;
  1046. macro.baseMass = 83.9;
  1047. case "Vulpes":
  1048. macro.species = "fox";
  1049. macro.baseHeight = 20000;
  1050. macro.baseMass = 180591661866272;
  1051. }
  1052. }
  1053. function startGame(e) {
  1054. form = document.forms.namedItem("custom-species-form");
  1055. for (var i=0; i<form.length; i++) {
  1056. if (form[i].value != "") {
  1057. if (form[i].type == "text")
  1058. macro[form[i].name] = form[i].value;
  1059. else if (form[i].type == "number")
  1060. macro[form[i].name] = parseFloat(form[i].value);
  1061. else if (form[i].type == "checkbox") {
  1062. macro[form[i].name] = form[i].checked;
  1063. }
  1064. }
  1065. }
  1066. document.getElementById("log-area").style.display = 'inline';
  1067. document.getElementById("option-panel").style.display = 'none';
  1068. document.getElementById("action-panel").style.display = 'flex';
  1069. victimTypes = ["stomped","digested","stomach","bowels"];
  1070. if (macro.maleParts) {
  1071. victimTypes = victimTypes.concat(["cock","balls"]);
  1072. } else {
  1073. document.getElementById("button-cockslap").style.display = 'none';
  1074. document.getElementById("button-cock_vore").style.display = 'none';
  1075. document.getElementById("button-ball_smother").style.display = 'none';
  1076. document.getElementById("cum").style.display = 'none';
  1077. document.querySelector("#part-balls+label").style.display = 'none';
  1078. document.querySelector("#part-dick+label").style.display = 'none';
  1079. }
  1080. if (macro.femaleParts) {
  1081. victimTypes = victimTypes.concat(["breasts"],["womb"]);
  1082. } else {
  1083. document.getElementById("button-breast_crush").style.display = 'none';
  1084. document.getElementById("button-unbirth").style.display = 'none';
  1085. document.getElementById("femcum").style.display = 'none';
  1086. document.querySelector("#part-breasts+label").style.display = 'none';
  1087. document.querySelector("#part-vagina+label").style.display = 'none';
  1088. }
  1089. if (macro.maleParts || macro.femaleParts) {
  1090. victimTypes.push("splooged");
  1091. }
  1092. var table = document.getElementById("victim-table");
  1093. var tr = document.createElement('tr');
  1094. var th = document.createElement('th');
  1095. th.innerHTML = "Method";
  1096. tr.appendChild(th);
  1097. for (var i = 0; i < victimTypes.length; i++) {
  1098. var th = document.createElement('th');
  1099. th.classList.add("victim-table-cell");
  1100. th.innerHTML = victimTypes[i].charAt(0).toUpperCase() + victimTypes[i].slice(1);
  1101. tr.appendChild(th);
  1102. }
  1103. table.appendChild(tr);
  1104. for (var key in things) {
  1105. if (things.hasOwnProperty(key) && key != "Container") {
  1106. var tr = document.createElement('tr');
  1107. tr.id = "stat-" + key;
  1108. tr.style.display = "none";
  1109. var th = document.createElement('th');
  1110. th.innerHTML = key;
  1111. tr.appendChild(th);
  1112. for (var i = 0; i < victimTypes.length; i++) {
  1113. var th = document.createElement('th');
  1114. th.innerHTML = 0;
  1115. th.id = "stat-" + victimTypes[i] + "-" + key;
  1116. tr.appendChild(th);
  1117. }
  1118. table.appendChild(tr);
  1119. }
  1120. }
  1121. document.getElementById("button-arousal").innerHTML = (macro.arousalEnabled ? "Arousal On" : "Arousal Off");
  1122. if (!macro.arousalEnabled)
  1123. document.getElementById("arousal").style.display = "none";
  1124. //var species = document.getElementById("option-species").value;
  1125. //var re = /^[a-zA-Z\- ]+$/;
  1126. // tricksy tricksy players
  1127. //if (re.test(species)) {
  1128. // macro.species = species;
  1129. //}
  1130. macro.init();
  1131. update();
  1132. document.getElementById("stat-container").style.display = 'flex';
  1133. }
  1134. window.addEventListener('load', function(event) {
  1135. victims["stomped"] = initVictims();
  1136. victims["digested"] = initVictims();
  1137. victims["stomach"] = initVictims();
  1138. victims["bowels"] = initVictims();
  1139. victims["breasts"] = initVictims();
  1140. victims["womb"] = initVictims();
  1141. victims["cock"] = initVictims();
  1142. victims["balls"] = initVictims();
  1143. victims["smothered"] = initVictims();
  1144. victims["splooged"] = initVictims();
  1145. document.getElementById("button-look").addEventListener("click",look);
  1146. document.getElementById("button-feed").addEventListener("click",feed);
  1147. document.getElementById("button-stomp").addEventListener("click",stomp);
  1148. document.getElementById("button-breast_crush").addEventListener("click",breast_crush);
  1149. document.getElementById("button-unbirth").addEventListener("click",unbirth);
  1150. document.getElementById("button-cockslap").addEventListener("click",cockslap);
  1151. document.getElementById("button-cock_vore").addEventListener("click",cock_vore);
  1152. document.getElementById("button-ball_smother").addEventListener("click",ball_smother);
  1153. document.getElementById("button-anal_vore").addEventListener("click",anal_vore);
  1154. document.getElementById("button-stroll").addEventListener("click",toggle_auto);
  1155. document.getElementById("button-location").addEventListener("click",change_location);
  1156. document.getElementById("button-numbers").addEventListener("click",toggle_numbers);
  1157. document.getElementById("button-units").addEventListener("click",toggle_units);
  1158. document.getElementById("button-verbose").addEventListener("click",toggle_verbose);
  1159. document.getElementById("button-arousal").addEventListener("click",toggle_arousal);
  1160. document.getElementById("button-grow-lots").addEventListener("click",grow_lots);
  1161. document.getElementById("button-amount-1").addEventListener("click",function() { grow_pick(1); });
  1162. document.getElementById("button-amount-5").addEventListener("click",function() { grow_pick(5); });
  1163. document.getElementById("button-amount-10").addEventListener("click",function() { grow_pick(10); });
  1164. document.getElementById("button-amount-20").addEventListener("click",function() { grow_pick(20); });
  1165. document.getElementById("button-amount-50").addEventListener("click",function() { grow_pick(50); });
  1166. document.getElementById("button-amount-100").addEventListener("click",function() { grow_pick(100); });
  1167. document.getElementById("button-start").addEventListener("click",startGame);
  1168. setTimeout(pick_move, 2000);
  1169. });