From 6eba7cead244ed22a77981abf38123f2b42bc435 Mon Sep 17 00:00:00 2001 From: Fen Dweller Date: Sun, 18 Feb 2018 14:52:21 -0500 Subject: [PATCH] Added Trams, cuz --- game.js | 5 +++-- recursive-macro.js | 37 +++++++++++++++++++++++++++++++++++++ 2 files changed, 40 insertions(+), 2 deletions(-) diff --git a/game.js b/game.js index 36a3a1f..3e59db5 100644 --- a/game.js +++ b/game.js @@ -19,6 +19,7 @@ function initVictims() "Person": 0, "Car": 0, "Bus": 0, + "Tram": 0, "Motorcycle": 0, "House": 0, "Train": 0, @@ -38,7 +39,7 @@ var bowels = [] function getOnePrey(area) { - var potential = ["Person", "Car", "Bus", "House", "Train", "Parking Garage"]; + var potential = ["Person", "Car", "Bus", "Tram", "House", "Train", "Parking Garage"]; var potAreas = [] @@ -69,7 +70,7 @@ function getPrey(region, area) function suburbPrey(area) { - return fill_area(area, {"Person": 0.5, "House": 0.5, "Car": 0.2}); + return fill_area(area, {"Person": 0.5, "House": 0.5, "Car": 0.2, "Tram": 0.1, "Bus": 0.1}); } function updateVictims(type,prey) diff --git a/recursive-macro.js b/recursive-macro.js index d93b9f3..4061b16 100644 --- a/recursive-macro.js +++ b/recursive-macro.js @@ -6,6 +6,7 @@ var things = "Empty Car": EmptyCar, "Car": Car, "Bus": Bus, + "Tram": Tram, "Motorcycle": Motorcycle, "House": House, "Train": Train, @@ -19,6 +20,7 @@ var areas = "Person": 3, "Car": 4, "Bus": 12, + "Tram": 20, "Motorcycle": 2, "House": 1000, "Train": 10000, @@ -417,6 +419,41 @@ function Bus(count = 1) { } } +function Tram(count = 1) { + this.name = "Bus"; + + copy_defaults(this,new DefaultEntity()); + this.count = count; + this.contents = {}; + + var amount = distribution(40,60,count); + this.contents.person = new Person(amount); + + this.describeOne = function(verbose=true) { + adjective = random_desc(["rusty","weathered"], (verbose ? 0.3 : 0)); + color = random_desc(["blue","brown","gray"], (verbose ? 1 : 0)); + type = random_desc(["tram"]); + return "a " + merge_desc([adjective,color,type]); + } + + this.describe = function() { + if (this.count <= 3) { + list = []; + for (var i = 0; i < this.count; i++) { + list.push(this.describeOne(this.count < 2)); + } + return merge_things(list) + " with " + this.contents.person.describe() + " inside"; + } else { + return this.count + " trams with " + this.contents.person.describe() + " inside"; + } + } + + + this.anal_vore = function() { + return "You slide " + this.describe() + " up your tight ass"; + } +} + function Motorcycle(count = 1) { this.name = "Motorcycle";