Your browser lacks required capabilities. Please upgrade it or switch to another to continue.
Loading…
<<nobr>>
/*<span id="datetime">
Day $day, Time $time<<if $time lt 10>>0<</if>>:00<br><br>
</span>
*/
/*
<table id="meters">
<td><<foodMeter>></td>
</table>
*/
<table id="meters">
<td><<farmMeter>></td>
</table>
<table id="meters">
<td><<guardMeter>></td>
</table>
<table id="meters">
<td><<buildMeter>></td>
</table>
<table id="meters">
<td><<researchMeter>></td>
</table>
<table id="meters">
<td><<huntMeter>></td>
</table>
<table id="meters">
<td><<scavengingMeter>></td>
</table>
<</nobr>>
<<foodMeter>>
<<starveMeter>>
<<set $eating to 0, $maxEating to 500>>
<<set $farming to 0, $maxFarming to 350>>
<<set $guarding to 0, $maxGuarding to 450>>
<<set $building to 0, $maxBuilding to 525>>
<<set $researching to 0, $maxResearching to 700>>
<<set $hunting to 0, $maxHunting to 660>>
<<set $scavenging to 0, $maxScavenging to 550>>
<<set $starving to 0, $maxStarving to 200>>
/*
<<set $day = 1>><<set $time = 0>>
<<set $tCounter = 0>>
*/
<<set $myAttack = 10>>
<<set $myDefense = 10>>
<<set $critical = 0>>
<<set $maxSurvivors = 50>>
<<set $startSurv = 10>>
<<set $survivors = $startSurv>>
<<set $scavengers = 0>>
<<set $builders = 0>>
<<set $guards = 0>>
<<set $farmers = 0>>
<<set $hunters = 0>>
<<set $researchers = 0>>
<<set $idleSurv = $survivors>>
<<set $noneIdle = false>>
<<set $myHappiness = 65>>
<<set $myFood = $survivors*5>>
<<set $myDefense = 50>>
<<set $myDamage = 1>>
<<set $zombieCure = 0>><<set $oldCure = 0>>
<<set $zombiesKilled = 0>>
<<set $farmHarvest = 2>>
<<set $maxFarmHarvest = 5>>
<<set $farmPro = 1>>
<<harvestInc>>
<<harvestUpgrade>>
<<set $myMsg1 = "">>
<<set $myMsg2 = "">>
<<set $myMsg3 = "">>
<<set $myMsg4 = "">>
<<set $myMsg5 = "">>
<<set $curDate1 = "">>
<<set $curDate2 = "">>
<<set $curDate3 = "">>
<<set $curDate4 = "">>
<<set $curDate5 = "">>
<<set $dietPlan = 2>>
<<set $pauseGame = true>>
<<set $decimalPlacesFood = 2>>
<<set $decimalPlacesHappy = 2>>
<<set $decimalPlacesCure = 2>>
<<set $totalFound = 0>>
<<set $hideMessages = false>>
<<set $fortImprovement = 3>>
<<set $tunnel = 0>>
<<set $buildArray = ["Build Fortifications (+"+$fortImprovement+"% Defenses)",
"Work on Escape Tunnel (Avoids Horde)",
"Build Research Lab to Find Zombie Cure"]>>
<<set $researchArray = ["Research Zombie Weaknesses",
"Research Defense Improvements",
"Research Radio Tower Building",
"Research Farm Production Improvements"]>>
<<set $cureAvailable = false>>
<<set $randomEvent = 0>>
<<set $eatCounter = 0>>
<<set $radioTower = false>>
<<set $batteriesFound = false>>
<<set $gameOver = false>>
<<set $winner = false>>
<<set $numArray = [0,1,2,3,4,5]>>
<<set $zombiesCaptured = 0>>
<<set $zombieGroup = 10>>
<<set $groupCanAttack = false>>
<<set $groupAttacks = 20>>
<<set $massiveHorde = 2>>
<<set $escapeKilled = 0>>
<<set _temp = random(1,3)>>
<<if _temp eq 1>>
<<set $rallyPoint = "Fire Station">>
<<elseif _temp eq 2>>
<<set $rallyPoint = "Police Station">>
<<else>>
<<set $rallyPoint = "Mall">>
<</if>>
<<set $tempZombieCure = 0>>
<<set $researchLab eq false>>
<<set $weakMsg = 1>>
<<set $fingerPhil = false>>
<<set $tvChannel = "HGTV">>
//METERS//
<<newmeter 'eating' 1>>
<<sizing '220px'>>
<<label '$eating%'>>
<</newmeter>>
<<newmeter 'farming' 1>>
<<sizing '220px'>>
<<label '$farming%'>>
<</newmeter>>
<<newmeter 'guarding' 1>>
<<sizing '220px'>>
<<label '$guarding%'>>
<</newmeter>>
<<newmeter 'building' 1>>
<<sizing '220px'>>
<<label '$building%'>>
<</newmeter>>
<<newmeter 'researching' 1>>
<<sizing '220px'>>
<<label '$researching%'>>
<</newmeter>>
<<newmeter 'hunting' 1>>
<<sizing '220px'>>
<<label '$hunting%'>>
<</newmeter>>
<<newmeter 'scavenging' 1>>
<<sizing '220px'>>
<<label '$scavenging%'>>
<</newmeter>>//////////////////////// HUD ////////////////////////
<<widget "showHUD">><<nobr>>
<table id="hud">
<tr>
<td colspan = 3>
<span id="survivors">
<font size = 5 color = midnightblue>''$survivors SURVIVORS'' </font><<if $idleSurv gt 0>><font color = yellow>($idleSurv idle)</font><<else>><font color = midnightblue>($idleSurv idle)</font><</if>></span>
</td>
<td colspan = 2>
<font size = 5 color = midnightblue>''INVENTORY / STATS''</font>
</td>
</tr>
<td><font color = midnightblue>
Farmers
</font></td>
<td>
<font size = 2><<button "-">><<if $farmers-1 gte 0>>
<<set $farmers -= 1>><<set $idleSurv += 1>>
<<adjustIdle>><</if>>
<<replace "#farmers">><<if $farmers gt 0>>
<font color = pink>$farmers
</font><<else>>$farmers<</if>>
<</replace>><</button>></font>
<font size = 4 font color = "#8B1A51">
<span id="farmers"><<if $farmers gt 0>>
<font color = pink>$farmers</font><<else>>$farmers
<</if>></span></font>
<font size = 2><<button "+">>
<<if $farmers+1 lte $maxSurvivors && $idleSurv gt 0>>
<<set $farmers += 1>><<set $idleSurv -= 1>>
<<adjustIdle>>
<</if>>
<<replace "#farmers">><<if $farmers gt 0>>
<font color = pink>$farmers
</font><<else>>$farmers<</if>>
<</replace>><</button>></font>
</td>
<td style="text-align:left">
<<if $farmHarvest neq $maxFarmHarvest>>
<<listbox "$farmerTask" autoselect>>
<<option $farmOpt1 1>>
<<option $farmOpt2 2>>
<</listbox>>
<<else>>
<<listbox "$farmerTask" autoselect>>
<<option $farmOpt1 1>>
<</listbox>>
<</if>>
</td>
<td>
<font color = midnightblue>''//Food//''</font>
</td>
<td>
<span id="myfood"><font color = "#8B1A51"><b>
<<print $myFood.toFixed($decimalPlacesFood)>></b>
</font>
</span>
</td>
<tr>
<td><font color = midnightblue>
Guards
</font></td>
<td>
<font size = 2><<button "-">><<if $guards-1 gte 0>>
<<set $guards -= 1>><<set $idleSurv += 1>>
<<adjustIdle>><</if>>
<<replace "#guards">><<if $guards gt 0>>
<font color = pink>$guards
</font><<else>>$guards<</if>>
<</replace>><</button>></font>
<font size = 4 font color = "#8B1A51">
<span id="guards"><<if $guards gt 0>>
<font color = pink>$guards</font><<else>>$guards
<</if>></span></font>
<font size = 2><<button "+">>
<<if $guards+1 lte $maxSurvivors && $idleSurv gt 0>>
<<set $guards += 1>><<set $idleSurv -= 1>>
<<adjustIdle>>
<</if>>
<<replace "#guards">><<if $guards gt 0>>
<font color = pink>$guards
</font><<else>>$guards<</if>>
<</replace>><</button>></font>
</td>
<td style="text-align:left">
<<listbox "$guardTask" autoselect>>
<<option "Patrol Perimeter (Protects & Inc Happiness)" 1>>
<<option "Train Marksmanship (Inc Damage)" 2>>
<</listbox>>
</td>
<td>
<font color = midnightblue>''//Damage//''</font>
</td>
<td>
<span id="damage">
<font color = "#8B1A51"><b>
<<print $myDamage.toFixed(2)+"x">></b></font>
</span>
</td>
</tr>
<tr>
<td><font color = midnightblue>
Builders
</font></td>
<td>
<font size = 2><<button "-">><<if $builders-1 gte 0>>
<<set $builders -= 1>><<set $idleSurv += 1>>
<<adjustIdle>><</if>>
<<replace "#builders">><<if $builders gt 0>>
<font color = pink>$builders
</font><<else>>$builders<</if>>
<</replace>><</button>></font>
<font size = 4 font color = "#8B1A51">
<span id="builders"><<if $builders gt 0>>
<font color = pink>$builders</font><<else>>$builders
<</if>></span></font>
<font size = 2><<button "+">>
<<if $builders+1 lte $maxSurvivors && $idleSurv gt 0>>
<<set $builders += 1>><<set $idleSurv -= 1>>
<<adjustIdle>>
<</if>>
<<replace "#builders">><<if $builders gt 0>>
<font color = pink>$builders
</font><<else>>$builders<</if>>
<</replace>><</button>></font>
</td>
<td style="text-align:left">
<<listbox "$builderTask" autoselect>>
<<optionsfrom $buildArray>>
<</listbox>>
</td>
<td>
<font color = midnightblue>''//Compound Defenses//''</font>
</td>
<td>
<span id="myDefenses">
<font color = "#8B1A51">''$myDefense''%</font>
</span>
</td>
</tr>
<tr>
<td><font color = midnightblue>
Researchers
</font></td>
<td>
<font size = 2><<button "-">><<if $researchers-1 gte 0>>
<<set $researchers -= 1>><<set $idleSurv += 1>>
<<adjustIdle>><</if>>
<<replace "#researchers">><<if $researchers gt 0>>
<font color = pink>$researchers
</font><<else>>$researchers<</if>>
<</replace>><</button>></font>
<font size = 4 font color = "#8B1A51">
<span id="researchers"><<if $researchers gt 0>>
<font color = pink>$researchers</font><<else>>$researchers
<</if>></span></font>
<font size = 2><<button "+">>
<<if $researchers+1 lte $maxSurvivors && $idleSurv gt 0>>
<<set $researchers += 1>><<set $idleSurv -= 1>>
<<adjustIdle>>
<</if>>
<<replace "#researchers">><<if $researchers gt 0>>
<font color = pink>$researchers
</font><<else>>$researchers<</if>>
<</replace>><</button>></font>
</td>
<td style="text-align:left">
<<listbox "$researchTask" autoselect>>
<<optionsfrom $researchArray>>
<</listbox>>
</td>
<td>
<font color = midnightblue>''//Zombie Cure Researched//''</font>
</td>
<td>
<span id="mycure"><font color = "#8B1A51"><b>
<<print $zombieCure.toFixed($decimalPlacesCure)+"%">></b>
</font>
</span>
</td>
</tr>
<tr>
<td><font color = midnightblue>
Hunters
</font></td>
<td>
<font size = 2><<button "-">><<if $hunters-1 gte 0>>
<<set $hunters -= 1>><<set $idleSurv += 1>>
<<adjustIdle>><</if>>
<<replace "#hunters">><<if $hunters gt 0>>
<font color = pink>$hunters
</font><<else>>$hunters<</if>>
<</replace>><</button>></font>
<font size = 4 font color = "#8B1A51">
<span id="hunters"><<if $hunters gt 0>>
<font color = pink>$hunters</font><<else>>$hunters
<</if>></span></font>
<font size = 2><<button "+">>
<<if $hunters+1 lte $maxSurvivors && $idleSurv gt 0>>
<<set $hunters += 1>><<set $idleSurv -= 1>>
<<adjustIdle>>
<</if>>
<<replace "#hunters">><<if $hunters gt 0>>
<font color = pink>$hunters
</font><<else>>$hunters<</if>>
<</replace>><</button>></font>
</td>
<td style="text-align:left">
<<listbox "$hunterTask" autoselect>>
<<option "Hunt nearby Zombies" 1>>
<<option "Hunt for Food" 2>>
<<option "Hunt for nearby Survivors" 3>>
<<option "Capture nearby Zombies for Research" 4>>
<</listbox>>
</td>
<td>
<font color = midnightblue>''//# Zombies Captured//''</font>
</td>
<td>
<span id="captured">
<font color = "#8B1A51">''$zombiesCaptured''</font>
</span>
</td>
</tr>
<tr>
<td><font color = midnightblue>
Scavengers
</font></td>
<td>
<font size = 2><<button "-">><<if $scavengers-1 gte 0>>
<<set $scavengers -= 1>><<set $idleSurv += 1>>
<<adjustIdle>><</if>>
<<replace "#scavengers">><<if $scavengers gt 0>>
<font color = pink>$scavengers
</font><<else>>$scavengers<</if>>
<</replace>><</button>></font>
<font size = 4 font color = "#8B1A51">
<span id="scavengers"><<if $scavengers gt 0>>
<font color = pink>$scavengers</font><<else>>$scavengers
<</if>></span></font>
<font size = 2><<button "+">>
<<if $scavengers+1 lte $maxSurvivors && $idleSurv gt 0>>
<<set $scavengers += 1>><<set $idleSurv -= 1>>
<<adjustIdle>>
<</if>>
<<replace "#scavengers">><<if $scavengers gt 0>>
<font color = pink>$scavengers
</font><<else>>$scavengers<</if>>
<</replace>><</button>></font>
</td>
<td style="text-align:left">
<<listbox "$scavengerTask" autoselect>>
<<option "Focus on Finding Food" 1>>
<<option "Focus on Finding Survivors" 2>>
<<option "Focus on Finding Guns & Unique Items" 3>>
<</listbox>>
</td>
<td>
<font color = midnightblue>''//HAPPINESS//''</font>
</td>
<td>
<span id="happiness">
<<if $myHappiness gte 50>>
<font color = "#8B1A51"><b>
<<print $myHappiness.toFixed($decimalPlacesHappy)+"%">>
</b></font>
<<else>>
<font color = yellow>
<<print $myHappiness.toFixed($decimalPlacesHappy)+"%">>
</font>
<</if>>
</span>
</td>
</tr>
</table>
<</nobr>><<if $hideMessages eq false>><span id="msg5"><<if $curDate5 neq "">><font color = orange>[ $curDate5 ]</font> $myMsg5<<else>> $myMsg5<</if>></span>
<span id="msg4"><<if $curDate4 neq "">><font color = orange>[ $curDate4 ]</font> $myMsg4<<else>> $myMsg4<</if>></span>
<span id="msg3"><<if $curDate3 neq "">><font color = orange>[ $curDate3 ]</font> $myMsg3<<else>> $myMsg3<</if>></span>
<span id="msg2"><<if $curDate2 neq "">><font color = orange>[ $curDate2 ]</font> $myMsg2<<else>> $myMsg2<</if>></span>
<span id="msg1"><<if $curDate1 neq "">><font color = orange>[ $curDate1 ]</font> $myMsg1<<else>> $myMsg1<</if>></span>
<</if>>
<</widget>>
//////////////////////// ADJUST IDLE ////////////////////////
<<widget adjustIdle>>
<<nobr>>
<<adjustSurvivors>>
<<replace "#farmlabel">>
<<if $farmers eq 1>>
<font color = hotpink>$farmers FARMER</font>
<<else>>
<font color = hotpink>$farmers FARMERS</font>
<</if>>
<</replace>>
<<replace "#guardlabel">>
<<if $guards eq 1>>
<font color = hotpink>$guards GUARD</font>
<<else>>
<font color = hotpink>$guards GUARDS</font>
<</if>>
<</replace>>
<<replace "#buildlabel">>
<<if $builders eq 1>>
<font color = hotpink>$builders BUILDER</font>
<<else>>
<font color = hotpink>$builders BUILDERS</font>
<</if>>
<</replace>>
<<replace "#researchlabel">>
<<if $researchers eq 1>>
<font color = hotpink>$researchers RESEARCHERS</font>
<<else>>
<font color = hotpink>$researchers RESEARCHERS</font>
<</if>>
<</replace>>
<<replace "#huntlabel">>
<<if $hunters eq 1>>
<font color = hotpink>$hunters HUNTER</font>
<<else>>
<font color = hotpink>$hunters HUNTERS</font>
<</if>>
<</replace>>
<<replace "#scavenglabel">>
<<if $scavengers eq 1>>
<font color = hotpink>$scavengers SCAVENGER</font>
<<else>>
<font color = hotpink>$scavengers SCAVENGERS</font>
<</if>>
<</replace>>
<</nobr>>
<</widget>>
//////////////////////// STARVING! ////////////////////////
<<widget starveMeter>>
<<nobr>>
<<set $starveRepeat = $maxStarving + 'ms'>>
<<silently>>
<<repeat $starveRepeat>>
<<if $pauseGame eq false and $gameOver eq false>>
<<if $myFood eq 0>>
<<set $starving += 1>>
<<if $dietPlan neq 1>>
<<set $dietPlan = 1>>
<<set $myMsg = "You lower the food rationing to
1 food/day">>
<<displayMessage>>
<</if>>
<<if $starving eq 1>>
<<set $myMsg = "Your people are starving!">>
<<displayMessage>>
<<elseif $starving eq $maxStarving>>
/* Survivor leaves/dies */
<<removeSurv>>
<<set $starving = 0>>
<</if>>
<</if>>
<</if>>
<</repeat>>
<</silently>>
<</nobr>>
<</widget>>
//////////////////////// FOOD METER ////////////////////////
<<widget foodMeter>>
<<nobr>>
<<set $eatRepeat = $maxEating + 'ms'>>
<<silently>>
<<repeat $eatRepeat>>
<<if $pauseGame eq false and $gameOver eq false>>
<<set $eatCounter += 1>>
<<set $advMin = 0>>
<<set $advMax = 2>>
<<if !($eatCounter%50)>>
<<if $myHappiness lt (25-($skillAdj*5))>>
<<set $advMin = 3>>
<<set $advMax = 6>>
<<elseif $myHappiness lt (50-($skillAdj*5))>>
<<set $advMin = 2>>
<<set $advMax = 5>>
<<elseif $myHappiness lt (65-($skillAdj*5))>>
<<set $advMin = 1>>
<<set $advMax = 4>>
<<elseif $myHappiness lt (80-($skillAdj*5))>>
<<set $advMin = 1>>
<<set $advMax = 3>>
<<elseif $myHappiness lt (90-($skillAdj*5))>>
<<set $advMax = 3>>
<</if>>
<<set $hordeAdvance = random($advMin,$advMax)>>
<<set $massiveHorde += $hordeAdvance>>
<<if $massiveHorde gt 100>>
<<set $massiveHorde = 100>>
<</if>>
<<if $hordeAdvance gt 0>>
<<massiveMessage>>
<<updateMassive>>
<</if>>
<</if>>
<<if $eatCounter gte $maxEating>>
<<set $eatCounter = 0>>
/*
<<set $hordeAdvance = random(8,12)>>
<<set $massiveHorde += $hordeAdvance>>
<<if $massiveHorde gt 100>>
<<set $massiveHorde = 100>>
<</if>>
<<massiveMessage>>
<<updateMassive>>
*/
<<set $group = random(2,5-$skillAdj)>>
<<set $zombieGroup += $group>>
<<if $zombieGroup gte $groupAttacks>>
<<set $groupCanAttack = true>>
<<elseif $massiveHorde neq 100>>
<<set $groupCanAttack = false>>
<<switch $group>>
<<case 1>>
<<set $myMsg = "A group of around
10 to 20 zombies are slowly approaching
not too far away.">>
<<case 2>>
<<set $myMsg = "There seems to be more
zombies than usual mingling around
your compound.">>
<<default>>
<<set $myMsg = "A small group of zombies
are gathering just outside your compound.">>
<</switch>>
<<displayMessage>>
<</if>>
<</if>>
<<set $myFood -= ($dietPlan/$maxEating)*$survivors>>
<<updateMyFood>>
<<updateMyHappiness>>
/*<<updateMyCure>>*/
<<updateCureProgress>>
<<gameEvent>>
/*<<dayAndTime>>*/
<</if>>
<</repeat>>
<</silently>>
<</nobr>>
<</widget>>
//////////////////////// FARM METER ////////////////////////
<<widget farmMeter>>
<<nobr>>
<span id="farmlabel">
<font color = hotpink>$farmers FARMERS</font>
</span>
<<showmeter 'farming' `_farming / _maxFarming`>>
<<updatemeter 'farming' `$farming / $maxFarming`>>
<span id="farm"></span>
<<set $farmRepeat = $maxFarming + 'ms'>>
<<silently>>
<<repeat $farmRepeat>>
<<replace "#farm">><<if $farmerTask eq 1>>
Growing Food<<else>>Improving Farm Production<</if>>
<</replace>>
<<if $pauseGame eq false and $gameOver eq false>>
<<set $farming += $farmers>>
<<if $farming gte $maxFarming>>
<<updatemeter 'farming' `$farming / $maxFarming`>>
<<set $farming = $farming - $maxFarming>>
<<if $farmerTask eq 1>>
<<set $myFood += $farmHarvest>>
<<set $myMsg = "You just harvested "+
$farmHarvest + " food from farms!">>
<<displayMessage>>
<<elseif $farmerTask eq 2>>
<<harvestInc>>
<<goto `passage()`>>
<</if>>
<<else>>
<<updatemeter 'farming' `$farming / $maxFarming`>>
<</if>>
<</if>>
<</repeat>>
<</silently>>
<</nobr>>
<</widget>>
//////////////////////// GUARD METER ////////////////////////
<<widget guardMeter>>
<<nobr>>
<span id="guardlabel">
<font color = hotpink>$guards GUARDS</font>
</span>
<<showmeter 'guarding' `_guarding / _maxGuarding`>>
<<updatemeter 'guarding' `$guarding / $maxGuarding`>>
<span id="guard"></span>
<<set $guardRepeat = $maxGuarding + 'ms'>>
<<silently>>
<<repeat $guardRepeat>>
<<replace "#guard">><<if $guardTask eq 1>>
Guarding Compound<<else>>Marksmanship Training<</if>>
<</replace>>
<<if $pauseGame eq false and $gameOver eq false>>
<<set $guarding += $guards>>
<<if $guarding gte $maxGuarding>>
<<updatemeter 'guarding' `$guarding / $maxGuarding`>>
<<set $guarding = $guarding - $maxGuarding>>
<<if $guardTask eq 1>>
<<if $myHappiness gte 100>>
<<set $myMsg = "Your guards are
defending from zombie attacks and
keeping up morale!">>
<<displayMessage>>
<<else>>
<<guardingMessage>>
<<set $myHappiness += random(1,3+$skillAdj)>>
<</if>>
<<elseif $guardTask eq 2>>
<<set $myMsg = "After some marksmanship
training by those on guard duty, your
guards are now a better shot!">>
<<displayMessage>>
<<set $myDamage += random(1+$skillAdj,3)/10>>
<<updateDamage>>
<</if>>
<<else>>
<<updatemeter 'guarding' `$guarding / $maxGuarding`>>
<</if>>
<</if>>
<</repeat>>
<</silently>>
<</nobr>>
<</widget>>
//////////////////////// BUILD METER ////////////////////////
<<widget buildMeter>>
<<nobr>>
<span id="buildlabel">
<font color = hotpink>$builders BUILDERS</font>
</span>
<<showmeter 'building' `_building / _maxBuilding`>>
<<updatemeter 'building' `$building / $maxBuilding`>>
<span id="build"></span>
<<set $buildRepeat = $maxBuilding + 'ms'>>
<<silently>>
<<repeat $buildRepeat>>
<<replace "#build">>
<<if $builderTask eq $buildArray[0]>>
Fortifying Compound
<<elseif $builderTask eq
"Build Research Lab to Find Zombie Cure">>
Building Research Lab
<<elseif $builderTask eq
"Build Radio Tower (Recruit Survivors)">>
Building Radio Tower
<<else>>
Working on Escape Tunnel
<</if>>
<</replace>>
<<if $pauseGame eq false and $gameOver eq false>>
<<set $building += $builders>>
<<if $building gte $maxBuilding>>
<<updatemeter 'building' `$building / $maxBuilding`>>
<<set $building = $building - $maxBuilding>>
<<if $builderTask eq $buildArray[0]>>
<<if $myDefense lt (100-$fortImprovement)>>
<<set $myDefense += $fortImprovement>>
<<else>>
<<set $myDefense = 100>>
<</if>>
<<updateDefense>>
<<if $myDefense gt 70 and $myDefense lt 100>>
<<set $myMsg = "Builders finished
improving compound fortifications!
That should improve happiness
around here.">>
<<elseif $myDefense lte 70>>
<<set $myMsg = "Builders finished
improving compound fortifications!">>
<<else>>
<<set $myMsg =
"Fortifications at 100%!">>
<</if>>
<<displayMessage>>
<<if $myDefense eq 100>>
<<set $builderTask = $buildArray[1]>>
<<set $myMsg = "Since fortifications are at 100%, your builders switch tasks!">>
<<goto `passage()`>>
<<displayMessage>>
<</if>>
<<elseif $builderTask eq
"Build Research Lab to Find Zombie Cure">>
<<if $cureAvailable eq false>>
<<set $buildArray.delete(
"Build Research Lab to Find Zombie Cure")>>
<<set $cureAvailable = true>>
<<set $researchLab = true>>
<<set $researchArray.push
("Research Zombie Cure")>>
<<set $myMsg = "Your builders switch
to new a task....">>
<<goto `passage()`>>
<<displayMessage>>
<<set $builderTask = $buildArray[1]>>
<<else>>
<<set $tunnel += 1>>
<<set $myMsg = "Builders just
completed a section of the escape
tunnel!">>
<<displayMessage>>
<</if>>
<<elseif $builderTask eq
"Build Radio Tower (Recruit Survivors)">>
<<set $radioTower = true>>
<<set $myMsg = "Builders just
completed building the Radio Tower! You
should go check it out!">>
<<displayMessage>>
<<set $myMsg = "With the Radio Tower
complete, your builders switch tasks.">>
<<displayMessage>>
<<set $buildArray.delete(
"Build Radio Tower (Recruit Survivors)")>>
<<set $builderTask = $buildArray[1]>>
<<goto `passage()`>>
<<elseif $builderTask eq
"Work on Escape Tunnel (Avoids Horde)">>
<<set $tunnel += 1>>
<<tunnelMessage>>
<<goto `passage()`>>
<</if>>
<<else>>
<<updatemeter 'building' `$building / $maxBuilding`>>
<</if>>
<</if>>
<</repeat>>
<</silently>>
<</nobr>>
<</widget>>
//////////////////////// RESEARCH METER ////////////////////////
<<widget researchMeter>>
<<nobr>>
<span id="researchlabel">
<font color = hotpink>$researchers RESEARCHERS</font>
</span>
<<showmeter 'researching' `_researching / _maxResearching`>>
<<updatemeter 'researching' `$researching / $maxResearching`>>
<span id="research"></span>
<<set $researchRepeat = $maxResearching + 'ms'>>
<<silently>>
<<repeat $researchRepeat>>
<<updateMyCure>>
<<replace "#research">>
<<if $researchTask eq "Research Zombie Weaknesses">>
Researching Weaknesses
<<elseif $researchTask eq
"Research Defense Improvements">>
Researching Defense
<<elseif $researchTask eq
"Research Zombie Cure">>
Researching Zombie Cure
<<elseif $researchTask eq
"Research Radio Tower Building">>
Researching Radio Tower
<<else>>
On Farm Improvement
<</if>>
<</replace>>
<<if $pauseGame eq false and $gameOver eq false>>
<<set $researching += $researchers>>
<<if $researching gte $maxResearching>>
<<updatemeter 'researching' `$researching / $maxResearching`>>
<<set $researching = $researching - $maxResearching>>
/*<<replace "#research">>Researching Upgrade<</replace>>*/
<<if $researchTask eq
"Research Zombie Weaknesses">>
<<set $critical += .5>>
<<weaknessMsg>>
<<displayMessage>>
<<elseif $researchTask eq
"Research Defense Improvements">>
<<set $fortImprovement += 1>>
<<if $fortImprovement lte 5>>
<<fortImprovements>>
<<set $myMsg = "Research Complete.
Your builders can now
increase your defenses by "
+$fortImprovement+"%">>
<<displayMessage>>
<</if>>
<<if $fortImprovement eq 5>>
<<set $researchArray.deleteAt(1)>>
<<set $researchTask = $researchArray[0]>>
<<set $myMsg = "You reach maximum
defensive improvements and so your
researchers switch tasks.">>
<<displayMessage>>
<</if>>
<<goto `passage()`>>
<<elseif $researchTask eq
"Research Zombie Cure">>
<<set $zombieCure += $tempZombieCure>>
<<if $zombieCure lt 100>>
<<cureMessage>>
<<set $zombieCure += .5>>
<</if>>
<<if $zombieCure gte 100>>
<<set $zombieCure = 100>>
<<set $gameOver = true>>
<<set $winner = true>>
<<set $myMsg = "Your researchers solved
the Zombie cure!">>
<<displayMessage>>
<<goto "winGame">>
<</if>>
<<replace "#mycure">>
<font color = "#8B1A51"><b>
<<print
$zombieCure.toFixed($decimalPlacesCure)+"%">></b>
</font>
<</replace>>
<<elseif $researchTask eq
"Research Radio Tower Building">>
<<set $buildArray.push(
"Build Radio Tower (Recruit Survivors)")>>
<<set $myMsg = "Your builders now know how
to contruct a radio tower! Your researchers
switch tasks.">>
<<set $researchArray.delete(
"Research Radio Tower Building")>>
<<goto `passage()`>>
<<displayMessage>>
<<elseif $researchTask eq
"Research Farm Production Improvements">>
<<set $maxFarmHarvest += 1>>
<<set $farmPro = 1>>
<<harvestUpgrade>>
<<set $myMsg = "Research complete.
Your max farm harvest production is now
"+$maxFarmHarvest+".">>
<<displayMessage>>
<<if $maxFarmHarvest eq 10>>
<<set $researchArray.delete(
"Research Farm Production Improvements")>>
<<set $myMsg = "Your researchers are unable
to improve farm production any further.
Your researchers switch tasks.">>
<<displayMessage>>
<<set $researchTask = $researchArray[0]>>
<</if>>
<<goto `passage()`>>
<</if>>
<<set $tempZombieCure = 0>>
<<else>>
<<updatemeter 'researching' `$researching / $maxResearching`>>
<</if>>
<</if>>
<</repeat>>
<</silently>>
<</nobr>>
<</widget>>
//////////////////////// HUNT METER ////////////////////////
<<widget huntMeter>>
<<nobr>>
<span id="huntlabel">
<font color = hotpink>$hunters HUNTERS</font>
</span>
<<showmeter 'hunting' `_hunting / _maxHunting`>>
<<updatemeter 'hunting' `$hunting / $maxHunting`>>
<span id="hunt"></span>
<<set $huntRepeat = $maxHunting + 'ms'>>
<<silently>>
<<repeat $huntRepeat>>
<<replace "#hunt">>
<<if $hunterTask eq 1>>
Out Hunting Zombies
<<elseif $hunterTask eq 2>>
Hunting for Food
<<elseif $hunterTask eq 3>>
Looking for Survivors
<<else>>
Out Capturing Zombies
<</if>>
<</replace>>
<<if $pauseGame eq false and $gameOver eq false>>
<<set $hunting += $hunters>>
<<if $hunting gte $maxHunting>>
<<updatemeter 'hunting' `$hunting / $maxHunting`>>
<<set $hunting = $hunting - $maxHunting>>
/*<<replace "#hunt">>Out Hunting<</replace>>*/
<<if $hunterTask eq 1>>
<<set _temp = Math.round(random(2,5+$skillAdj)
* $myDamage)>>
<<set $zombiesKilled += _temp>>
<<shrinkGroup _temp>>
<<set $myMsg = "Hunters killed "+ _temp + " zombies while out hunting!">>
<<displayMessage>>
/*<<updateKilled>>*/
<<elseif $hunterTask eq 2>>
/*<<set _temp = 1 +
Math.round(random(($survivors/3),
($survivors*.8)))>>*/
<<happyBonus>>
<<set _temp = Math.round(random(0,$survivors/5) +
1 + random(1,4) + random(2,4) + $happyBonus)>>
<<set $myFood += _temp>>
<<set $myMsg = "Hunters brought back some meat
after a good hunt! ("+_temp+" food)">>
<<displayMessage>>
<<elseif $hunterTask eq 3>>
<<happyBonus>>
<<set $survivorsFound = 1+$happyBonus>>
<<if ($survivorsFound + $survivors)
gt $maxSurvivors>>
<<set $survivorsFound =
$maxSurvivors - $survivors>>
<</if>>
<<if $survivorsFound gt 0>>
<<set $survivors += $survivorsFound>>
<<set $idleSurv += $survivorsFound>>
<<set $totalFound += $survivorsFound>>
<<adjustSurvivors>>
<<set $myMsg = "Hunters came across "+ $survivorsFound + " survivor(s) and convinced
them to join your group!">>
<<else>>
<<set $myMsg = "Hunters were unable to
find any survivors to recruit.">>
<</if>>
<<displayMessage>>
<<elseif $hunterTask eq 4>>
<<set _captured = random(1,3)>>
<<if _captured gt 1>>
<<set _temp = "s and brought them">>
<<else>>
<<set _temp = " and brought it">>
<</if>>
<<set $zombiesCaptured += _captured>>
<<set $myMsg = "Hunters captured "+_captured+
" nearby zombie"+_temp+" back for research
purposes.">>
<<displayMessage>>
<<updateCaptured>>
<</if>>
<<else>>
<<updatemeter 'hunting' `$hunting / $maxHunting`>>
<</if>>
<</if>>
<</repeat>>
<</silently>>
<</nobr>>
<</widget>>
//////////////////////// SCAVENGING METER ////////////////////////
<<widget scavengingMeter>>
<<nobr>>
<span id="scavenglabel">
<font color = hotpink>$scavengers SCAVENGERS</font>
</span>
<<showmeter 'scavenging' `_scavenging / _maxScavenging`>>
<<updatemeter 'scavenging' `$scavenging / $maxScavenging`>>
<span id="scaveng"></span>
<<set $scavengRepeat = $maxScavenging + 'ms'>>
<<silently>>
<<repeat $scavengRepeat>>
<<replace "#scaveng">>
<<if $scavengerTask eq 1>>
Scavenging for Food
<<elseif $scavengerTask eq 2>>
Looking for Survivors
<<else>>
Scavenging for Guns/Items
<</if>>
<</replace>>
<<if $pauseGame eq false and $gameOver eq false>>
<<set $scavenging += $scavengers>>
<<if $scavenging gte $maxScavenging>>
<<updatemeter 'scavenging' `$scavenging / $maxScavenging`>>
<<set $scavenging = $scavenging - $maxScavenging>>
/*<<replace "#scaveng">>Out Scavenging<</replace>>*/
<<if $scavengerTask eq 1>>
/*<<set _tempFound = 2 +
Math.round(random(($survivors/3),
($survivors*.7)))>>*/
<<happyBonus>>
<<set _tempFound = Math.round(random(0,$survivors/5) + random(2,4) + random(2,4) +$happyBonus)>>
<<set $myFood += _tempFound>>
<<set $myMsg = "Scavengers found "+ _tempFound + " food while out scavenging!">>
<<displayMessage>>
<<elseif $scavengerTask eq 2>>
<<happyBonus>>
<<set $survivorsFound = 1+$happyBonus>>
<<if ($survivorsFound + $survivors)
gt $maxSurvivors>>
<<set $survivorsFound =
$maxSurvivors - $survivors>>
<</if>>
<<if $survivorsFound gt 0>>
<<set $survivors += $survivorsFound>>
<<set $idleSurv += $survivorsFound>>
<<set $totalFound += $survivorsFound>>
<<adjustSurvivors>>
<<set $myMsg = "Scavengers convinced "+ $survivorsFound + " survivor(s) to join
your group!">>
<<else>>
<<set $myMsg = "Scavengers were unable to
find any survivors to recruit.">>
<</if>>
<<displayMessage>>
<<elseif $scavengerTask eq 3>>
<<if random(0,(9-$skillAdj)) eq 0>>
<<foundUniqueItem>>
<<else>>
<<set $weaponsFound = .1 +
random($survivors/2,$survivors+2)>>
<<set $myMsg = "Scavengers returned with a
handful of guns and ammo. Your Damage stat has
increased!">>
<<set $myDamage += $weaponsFound/75>>
<<updateDamage>>
<</if>>
<<displayMessage>>
<</if>>
<<else>>
<<updatemeter 'scavenging' `$scavenging / $maxScavenging`>>
<</if>>
<</if>>
<</repeat>>
<</silently>>
<</nobr>>
<</widget>>
/////////////////////// WEAKNESS MESSAGE //////////////////////
<<widget weaknessMsg>><<nobr>>
<<switch $weakMsg>>
<<case 1>>
<<set $myMsg = "Researchers have discovered
shooting the zombies in the kneecaps will
slow them down!">>
<<case 2>>
<<set $myMsg = "Researchers have discovered
shooting zombies in the head will
keep them down!">>
<<case 3>>
<<set $myMsg = "Researchers have discovered
zombies are attracted to loud noises!">>
<<case 4>>
<<set $myMsg = "Researchers have discovered
zombies are hungry for human flesh!">>
<<case 5>>
<<set $myMsg = "Researchers have discovered
zombies cannot be reasoned with!">>
<<default>>
<<set $myMsg = "Researchers are more and more confident that we don't
want to become a zombie!!!">>
<</switch>>
<<set $weakMsg += 1>>
<</nobr>><</widget>>
//////////////////////// FOUND UNIQUE ITEM ////////////////////////
<<widget foundUniqueItem>><<nobr>>
<<if $batteriesFound eq false>>
<<set $batteriesFound = true>>
<<set $myMsg = "Your returning scavengers found some batteries for the guard tower radio!">>
<<else>>
<<set $weaponsFound = 2 + random($survivors/2,$survivors+2)>>
<<set $myMsg = "Scavengers returned with a
ton of guns and ammo! Your Damage stat has increased!">>
<<set $myDamage += $weaponsFound/50>>
<<updateDamage>>
<</if>>
<</nobr>><</widget>>
//////////////////////// UPDATE DAMAGE ////////////////////////
<<widget updateDamage>><<nobr>>
<<replace "#damage">>
<font color = "#8B1A51"><b>
<<print $myDamage.toFixed(2)+"x">></b></font>
<</replace>>
<</nobr>><</widget>>
//////////////////////// UPDATE CAPTURED ////////////////////////
<<widget updateCaptured>><<nobr>>
<<replace "#captured">>
<font color = "#8B1A51">''$zombiesCaptured''</font>
<</replace>>
<</nobr>><</widget>>
//////////////////////// UPDATE DEFENSE ////////////////////////
<<widget updateDefense>><<nobr>>
<<replace "#myDefenses">>
<font color = "#8B1A51">''$myDefense''%</font>
<</replace>>
<<checkForDefeat>>
<</nobr>><</widget>>
//////////////////////// CHECK FOR DEFEAT ////////////////////////
<<widget checkForDefeat>><<nobr>>
<<if $myDefense lte 0>>
<<set $gameOver = true>>
<<set $myMsg = "Your compound defenses have failed! Zombies have overran your compound!">>
<<displayMessage>>
<<goto "lostDefense">>
<<elseif $survivors eq 0>>
<<set $gameOver = true>>
<<set $myMsg = "With no more survivors around, you decide to
venture outside the compound...bad decision!">>
<<displayMessage>>
<<goto "lostSurvivors">>
<<elseif $massiveHorde eq 100>>
<<set $gameOver = true>>
<<set $myMsg = "The massive horde has arrived and is tearing your compound apart piece by piece!">>
<<displayMessage>>
<<set $myDefense = 0>>
<<goto "lostDefense">>
<</if>>
<</nobr>><</widget>>
//////////////////////// HARVEST AMT ////////////////////////
<<widget harvestInc>>
<<if $farmHarvest lt $maxFarmHarvest>>
<<set $farmHarvest += 1>>
<<set $myMsg = "Your farmers just improved farm production. You are now able to farm "+$farmHarvest + " food from farms!">>
<<displayMessage>>
<</if>>
<<if $farmHarvest eq $maxFarmHarvest>>
<<set $farmPro = 0>>
<<harvestUpgrade>>
<<set $myMsg = "With your farms at max production, your farmers switch to harvesting.">>
<<displayMessage>>
<<set $farmerTask = 1>>
<</if>>
<<set $farmOpt1 = "Harvest +"+$farmHarvest+" Food">>
<</widget>>
//////////////////////// HARVEST UPGRADE ////////////////////////
<<widget harvestUpgrade>>
<<set $farmOpt2 = "Increase +"+$farmPro+" Farm Production (Max is "+$maxFarmHarvest+")">>
<</widget>>
/////////////////////// FORTIFICATIONS UPGRADE ////////////////////////
<<widget fortImprovements>>
<<set $buildArray[0] = "Build Fortifications (+"+$fortImprovement+"% Defenses)">>
<</widget>>
/////////////////////// RESEARCH LAB UPGRADE ////////////////////////
<<widget researchLab>>
<<set $buildOpt2 = "Build Research Lab to Find Zombie Cure">>
<</widget>>
//////////////////////// ADJUST SURVIVORS ////////////////////////
<<widget adjustSurvivors>><<nobr>>
<<replace "#survivors">>
<font size = 5 color = midnightblue>''$survivors SURVIVORS'' </font><<if $idleSurv gt 0>><font color = yellow>($idleSurv idle)</font><<else>><font color = midnightblue>($idleSurv idle)</font><</if>>
<</replace>>
<<if $idleSurv eq 0 and $noneIdle eq false>>
<<welcomeMsg3>>
<<set $noneIdle = true>>
<</if>>
<</nobr>><</widget>>
//////////////////////// CUR DATE ////////////////////////
<<widget curDate>><<nobr>>
<<set $curDate = new Date(Date.now())>>
<<set $curDate = $curDate.toLocaleString("en-US", { hour: "numeric", minute: "2-digit", second: "2-digit" } )>>
<</nobr>><</widget>>
//////////////////////// DISPLAY MESSAGE ////////////////////////
<<widget displayMessage>><<nobr>>
<<curDate>>
<<if $hideMessages eq false>>
<<replace "#msg5">><<if $curDate4 neq "">><font color = orange>[ $curDate4 ]</font> $myMsg4<<else>> $myMsg4<</if>><</replace>>
<<replace "#msg4">><<if $curDate3 neq "">><font color = orange>[ $curDate3 ]</font> $myMsg3<<else>> $myMsg3<</if>><</replace>>
<<replace "#msg3">><<if $curDate2 neq "">><font color = orange>[ $curDate2 ]</font> $myMsg2<<else>> $myMsg2<</if>><</replace>>
<<replace "#msg2">><<if $curDate1 neq "">><font color = orange>[ $curDate1 ]</font> $myMsg1<<else>> $myMsg1<</if>><</replace>>
<<replace "#msg1">><<if $curDate neq "">><font color = orange>[ $curDate ]</font> $myMsg<<else>> $myMsg<</if>><</replace>>
<<set $myMsg5 = $myMsg4>>
<<set $myMsg4 = $myMsg3>>
<<set $myMsg3 = $myMsg2>>
<<set $myMsg2 = $myMsg1>>
<<set $myMsg1 = $myMsg>>
<<set $curDate5 = $curDate4>>
<<set $curDate4 = $curDate3>>
<<set $curDate3 = $curDate2>>
<<set $curDate2 = $curDate1>>
<<set $curDate1 = $curDate>>
<</if>>
<</nobr>><</widget>>
//////////////////////// SPAN FOOD LABEL ////////////////////////
<<widget spanFoodLabel>><<nobr>>
<<replace "#foodlabel">>
<font color = hotpink>$survivors CONSUMING FOOD</font>
<</replace>>
<</nobr>><</widget>>
//////////////////////// UPDATE FOOD AMT ////////////////////////
<<widget updateMyFood>><<nobr>>
<<if $myFood lte 0>>
<<set $myFood = 0>>
<</if>>
<<replace "#myfood">>
<<if $myFood < ($survivors*2)>>
<font color = yellow>
<<print $myFood.toFixed($decimalPlacesFood)>>
</font>
<<else>>
<font color = "#8B1A51"><b>
<<print $myFood.toFixed($decimalPlacesFood)>></b>
</font>
<</if>>
<</replace>>
<</nobr>><</widget>>
//////////////////////// UPDATE CURE AMT ////////////////////////
<<widget updateMyCure>><<nobr>>
<<if $zombieCure eq 0>>
<<set $tempZombieCure += random(0,$zombiesCaptured)/100 +
((random(0,1)/(50*($tempZombieCure+1))) * $researchers)>>
<<else>>
<<set $tempZombieCure +=
(random(0,$zombiesCaptured+1+$skillAdj)/(50*($zombieCure+1)))
* $researchers>>
<</if>>
<<updateCureProgress>>
<</nobr>><</widget>>
//////////////////////// WELCOME MESSAGE 0 ////////////////////////
<<widget welcomeMsg0>><<nobr>>
<<set $myMsg = "A massive zombie horde spotted in the distance from the guard tower is moving this way!">>
<<displayMessage>>
<</nobr>><</widget>>
//////////////////////// WELCOME MESSAGE 1 ////////////////////////
<<widget welcomeMsg1>><<nobr>>
<<set $myMsg = "You have "+ $idleSurv + " idle survivors. They consume just as much food as busy survivors. Assign them a task!">>
<<displayMessage>>
<</nobr>><</widget>>
//////////////////////// WELCOME MESSAGE 2 ////////////////////////
<<widget welcomeMsg2>><<nobr>>
<<set $myMsg = "Explosions and gun shots ring out in the background. Zombies are everywhere!">>
<<displayMessage>>
<</nobr>><</widget>>
//////////////////////// WELCOME MESSAGE 3 ////////////////////////
<<widget welcomeMsg3>><<nobr>>
<<set $myMsg = "Excellent! Everyone in your group has been assigned a task.">>
<<displayMessage>>
<</nobr>><</widget>>
//////////////////////// FOOD DECIMAL PLACES ////////////////////////
<<widget setFoodDecimalPlaces>><<nobr>>
Display how many decimal places in FOOD...
<label><<radiobutton "$decimalPlacesFood" 0 `$decimalPlacesFood is 0 ? 'checked' : ''`>> 0</label>
<label><<radiobutton "$decimalPlacesFood" 1 `$decimalPlacesFood is 1 ? 'checked' : ''`>> 1</label>
<label><<radiobutton "$decimalPlacesFood" 2 `$decimalPlacesFood is 2 ? 'checked' : ''`>> 2</label>
<</nobr>><</widget>>
//////////////////////HAPPINESS DECIMAL PLACES ////////////////////////
<<widget setHappinessDecimalPlaces>><<nobr>>
Display how many decimal places in HAPPINESS...
<label><<radiobutton "$decimalPlacesHappy" 0 `$decimalPlacesHappy is 0 ? 'checked' : ''`>> 0</label>
<label><<radiobutton "$decimalPlacesHappy" 1 `$decimalPlacesHappy is 1 ? 'checked' : ''`>> 1</label>
<label><<radiobutton "$decimalPlacesHappy" 2 `$decimalPlacesHappy is 2 ? 'checked' : ''`>> 2</label>
<</nobr>><</widget>>
//////////////////////CURE DECIMAL PLACES ////////////////////////
<<widget setCureDecimalPlaces>><<nobr>>
Display how many decimal places in ZOMBIE CURE...
<label><<radiobutton "$decimalPlacesCure" 0 `$decimalPlacesCure is 0 ? 'checked' : ''`>> 0</label>
<label><<radiobutton "$decimalPlacesCure" 1 `$decimalPlacesCure is 1 ? 'checked' : ''`>> 1</label>
<label><<radiobutton "$decimalPlacesCure" 2 `$decimalPlacesCure is 2 ? 'checked' : ''`>> 2</label>
<</nobr>><</widget>>
//////////////////////// DIET PLAN ////////////////////////
<<widget setDietPlan>><<nobr>>
<u>Ration FOOD</u><br>
<label><<radiobutton "$dietPlan" 1 `$dietPlan is 1 ? 'checked' : ''`>> 1/day</label>
<label><<radiobutton "$dietPlan" 2 `$dietPlan is 2 ? 'checked' : ''`>> 2/day</label>
<label><<radiobutton "$dietPlan" 3 `$dietPlan is 3 ? 'checked' : ''`>> 3/day</label>
<</nobr>><</widget>>
//////////////////////// HAPPINESS ////////////////////////
<<widget updateMyHappiness>><<nobr>>
<<if $dietPlan lt 2>>
<<set $myHappiness -= ($dietPlan/$maxEating)*$survivors>>
<<elseif $dietPlan gt 2>>
<<set $myHappiness += (($dietPlan/$maxEating)*$survivors)/2>>
<</if>>
<<if $myDefense gt 85 and $myDefense lte 100>>
<<set $myHappiness += .02>>
<<elseif $myDefense gt 70>>
<<set $myHappiness += .01>>
<<elseif $myDefense lt 15>>
<<set $myHappiness -= .03>>
<<elseif $myDefense lt 30>>
<<set $myHappiness -= .02>>
<<elseif $myDefense lt 50>>
<<set $myHappiness -= .01>>
<</if>>
<<if $myFood lt ($survivors*(1-$skillAdj))>>
<<set $myHappiness -= .07>>
<<elseif $myFood lt ($survivors*(2-$skillAdj))>>
<<set $myHappiness -= .04>>
<<elseif $myFood gt ($survivors*(5-$skillAdj))>>
<<set $myHappiness += .05>>
<<elseif $myFood gt ($survivors*(4-$skillAdj))>>
<<set $myHappiness += .02>>
<</if>>
<<if $guardTask eq 1>>
<<set $myHappiness += $guards * .01>>
<<elseif $guardTask eq 2>>
<<set $myDamage += (random(0,10)/(3000*$myDamage)) * $guards>>
<<updateDamage>>
<</if>>
<<if $groupCanAttack eq true>>
<<set $myHappiness -= .01>>
<<set $myHappiness += $skillAdj/100>>
<</if>>
<<if $myDamage gt 4>>
<<set $myHappiness += .02>>
<<elseif $myDamage gt 2>>
<<set $myHappiness += .01>>
<</if>>
<<if $myHappiness gt 100>>
<<set $myHappiness = 100>>
<<elseif $myHappiness lt 0>>
<<set $myHappiness = 0>>
<</if>>
<<replace "#happiness">>
<<if $myHappiness gte 50>>
<font color = "#8B1A51"><b>
<<print $myHappiness.toFixed($decimalPlacesHappy)+"%">>
</b></font>
<<else>>
<font color = yellow>
<<print $myHappiness.toFixed($decimalPlacesHappy)+"%">>
</font>
<</if>>
<</replace>>
<</nobr>><</widget>>
//////////////////////// MESSAGES TOGGLE ////////////////////////
<<widget setMessages>><<nobr>>
<<if $hideMessages eq false>>
Game Messages are turned ON
<<button "Hide Messages">>
<<set $hideMessages = true>>
<<replace "#msg5">>""<</replace>>
<<replace "#msg4">>""<</replace>>
<<replace "#msg3">>""<</replace>>
<<replace "#msg2">>""<</replace>>
<<replace "#msg1">>""<</replace>>
<<goto `passage()`>>
<</button>>
<<else>>
Game Messages are turned OFF
<<button "Show Messages">>
<<set $hideMessages = false>>
<<goto `passage()`>>
<</button>>
<</if>>
<</nobr>><</widget>>
//////////////////////// DAY & TIME ////////////////////////
<<widget dayAndTime>><<nobr>>
<<set $tCounter += 1>>
<<if $tCounter eq 2>>
<<set $time += 1>>
<<set $tCounter = 0>>
<</if>>
<<if $time eq 24>>
<<set $day += 1>>
<<set $time = 0>>
<</if>>
/*
<<replace "#datetime">>
Day $day, Time <<if $time lt 10>>0$time:00<<else>>$time:00
<</if>><br><br>
<</replace>>
*/
<</nobr>><</widget>>
//////////////////////// GAME EVENTS ////////////////////////
<<widget gameEvent>><<nobr>>
<<if $randomEvent eq 0>>
<<set $randomEvent = random(100,$maxEating)>>
<</if>>
<<if $eatCounter eq $randomEvent>>
<<set _rEvent = random(1,13)>>
<<switch _rEvent>>
<<case 1>> ////////// SURVIVOR JOINS ///////////
<<if $survivors lt $maxSurvivors>>
<<newSurvivor>>
<</if>>
<<case 2>> ////////// SMALL ZOMBIE HORDE ATTACKS?! ///////////
<<if $groupCanAttack eq true>>
<<set _tempDamage = random(8,15)>>
<<set $myMsg = "A large group of zombies just attacked your compound! They did "+_tempDamage+"% damage to your defenses!">>
<<set $myDefense -= _tempDamage>>
<<displayMessage>>
<<updateDefense>>
<<else>>
<<set _tempDamage = random(1,3)>>
<<set $myMsg = "Zombies just attacked your compound! They did "+_tempDamage+"% damage to your defenses!">>
<<set $myDefense -= _tempDamage>>
<<displayMessage>>
<<updateDefense>>
<</if>>
<<case 3>> ////////// SURVIVOR MAY JOIN ///////////
<<if $myDefense gte 50 and $myHappiness gte 50 and $myFood gte ($survivors*2)>>
<<newSurvivor>>
<<else>>
<<if $myDefense lt 50>>
<<set _fail = "they didn't think your defenses were good enough.">>
<<elseif $myHappiness lt 50>>
<<set _fail = "they saw how unhappy your people were.">>
<<else>>
<<set _fail = "it looked like your were running low on food.">>
<</if>>
<<set $myMsg = "A new survivor came by and then left because "+_fail>>
<<displayMessage>>
<</if>>
<<case 4>> ////////// HUNTER ATTACKED! ///////////
<<if $hunters gt 0>>
<<set _tempDamage = $myDamage*random(1,10)>>
<<if _tempDamage lte (3+$skillAdj)>>
/// Hunter Dies ///
<<set $myMsg = "A hunter was bitten by a zombie and lost while outside the compound unfortunately.">>
<<removeHunter>>
<<adjustLostSurv>>
<<else>>
/// Hunter Survives close call ///
<<set $myMsg = "A hunter was nearly bitten by a zombie while outside the compound. Close call.">>
<<displayMessage>>
<</if>>
<</if>>
<<case 5>> ////////// SCAVENGER ATTACKED! ///////////
<<if $scavengers gt 0>>
<<set _tempDamage = $myDamage*random(1,10)>>
<<if _tempDamage lte (5+$skillAdj)>>
/// Scavenger Dies ///
<<set $myMsg = "A scavenger was attacked by a zombie and unfortunately succumbed to their wound.">>
<<removeScavenger>>
<<adjustLostSurv>>
<<else>>
/// Scavenger Survives close call ///
<<set $myMsg = "A scavenger was attacked by a zombie, but managed to get away unscathed. Close call.">>
<<displayMessage>>
<</if>>
<</if>>
<<case 6>> ////// UPDATE HORDE LIMIT & ZOMBIES ATTACK! //////
<<updateHordeLimit>>
<<set _tempDamage = random(3-$skillAdj,7-$skillAdj)>>
<<set $myMsg = "Zombies just attacked your compound! They did "+_tempDamage+"% damage to your defenses!">>
<<set $myDefense -= _tempDamage>>
<<displayMessage>>
<<updateDefense>>
<<case 7>> ////// FOOD SPOILS //////
<<set _spoil = Math.round(random(1,$survivors/2))>>
<<if _spoil lt 1>><<set _spoil = 1>><</if>>
<<set $myFood -= _spoil>>
<<updateMyFood>>
<<set $myMsg = "You discover that "+_spoil+" food items spoiled and had to be thrown out!">>
<<displayMessage>>
<<case 8>> ////// UPDATE ZOMBIE HORDE ATTACK LIMIT //////
<<updateHordeLimit>>
<<case 9>> ////////// SMALL ZOMBIE HORDE ATTACKS?! ///////////
<<if $groupCanAttack eq true>>
<<set _tempDamage = random(10,$zombieGroup)>>
<<set $myMsg = "A large group of zombies just attacked your compound! They did "+_tempDamage+"% damage to your defenses!">>
<<set $myDefense -= _tempDamage>>
<<displayMessage>>
<<updateDefense>>
<<else>>
<<set _tempDamage = random(2,5)>>
<<set $myMsg = "Zombies just attacked your compound! They did "+_tempDamage+"% damage to your defenses!">>
<<set $myDefense -= _tempDamage>>
<<displayMessage>>
<<updateDefense>>
<</if>>
<<case 10>> //////// 1 Radio Tower Recruit > 50 Happy ////////
<<if $radioTower eq true and $survivors lt $maxSurvivors
and $myHappiness gt 50>>
<<newSurvivor>>
<<elseif $myHappiness lte 50 and $survivors lt $maxSurvivors >>
<<setMsg = "A new survivor heard your radio tower message, but didn't join due to your happiness level.">>
<<displayMessage>>
<</if>>
<<case 11>> //////// 1 Radio Tower Recruit > 50 Happy ///////
<<if $radioTower eq true and $survivors lt $maxSurvivors
and $myHappiness gt 50>>
<<newSurvivor>>
<<elseif $myHappiness lte 50 and $survivors lt $maxSurvivors >>
<<setMsg = "A new survivor heard your radio tower message, but didn't join due to your happiness level.">>
<<displayMessage>>
<</if>>
<<default>> //////// GUARDS CAN PREVENT DEF DAMAGE ////////
<<set _tempDamage = Math.round(5-($guards*$myDamage))>>
<<if $guards gt 0 and $guardTask eq 1>>
<<if _tempDamage lte 0>>
<<set $myMsg = "Zombies were approaching walls. Luckily your guards on duty took them out!">>
<<shrinkGroup random(1,$guards)>>
<<else>>
<<set $myMsg = "Guards engaged zombies at the compound walls! Zombies did "+_tempDamage+"% damage to your defenses!">>
<<set $myDefense -= _tempDamage>>
<<shrinkGroup 1>>
<<displayMessage>>
<<updateDefense>>
<</if>>
<<elseif $guards gt 0>>
<<set _tempDamage = random(2,4)>>
<<set $myMsg = "While your guards were training their markmanship, zombies did "+_tempDamage+"% damage to your walls!">>
<<set $myDefense -= _tempDamage>>
<<displayMessage>>
<<updateDefense>>
<<else>> ///// NO GUARDS ON DUTY /////
<<set _tempDamage = random(5,9)>>
<<set $myMsg = "Zombies just attacked your compound! They did "+_tempDamage+"% damage to your defenses!">>
<<set $myDefense -= _tempDamage>>
<<displayMessage>>
<<updateDefense>>
<</if>>
<</switch>>
<<set $randomEvent = 0>>
<</if>>
<</nobr>><</widget>>
//////////////////////// UPDATE HORDE LIMIT ////////////////////////
<<widget updateHordeLimit>><<nobr>>
<<set $groupAttacks -= 1>>
<<if $groupAttacks lt 15>>
<<set $groupAttacks = 15>>
<</if>>
<</nobr>><</widget>>
//////////////////////// NEW SURVIVOR JOINED ////////////////////////
<<widget newSurvivor>><<nobr>>
<<if $survivors lt $maxSurvivors>>
<<set $survivorsFound = 1>>
<<set $survivors += $survivorsFound>>
<<set $idleSurv += $survivorsFound>>//REMOVE FOR AUTO ASSIGN //
<<set $totalFound += $survivorsFound>>
<<if $radioTower eq true>>
<<set $myMsg = "A survivor heard your radio tower message
and asked to join your group. You accepted.">>
<<else>>
<<set $myMsg = "A survivor came across your compound
and asked to join your group. You accepted.">>
<</if>>
<<displayMessage>>
/*<<assignIdle>>*/ //// AUTO ASSIGN NEW SURVIVORS ////
<<adjustIdle>>
<<else>>
<<set $myMsg = "A survivor came across your compound,
but you have no more room. They turned away.">>
<<displayMessage>>
<</if>>
<</nobr>><</widget>>
//////////////////////// ASSIGN IDLE ////////////////////////
<<widget assignIdle>><</nobr>>
<<set _tempIdle = random(1,6)>>
<<switch _tempIdle>>
<<case 1>>
<<set $farmers += 1>>
<<set $myMsg = "You assign the recently joined survivor to the Farmers.">>
<<replace "#farmers">><font color = pink>$farmers</font>
<</replace>>
<<case 2>>
<<set $guards += 1>>
<<set $myMsg = "You assign the recently joined survivor to the Guards.">>
<<replace "#guards">><font color = pink>$guards</font>
<</replace>>
<<case 3>>
<<set $builders += 1>>
<<set $myMsg = "You assign the recently joined survivor to the Builders.">>
<<replace "#builders">><font color = pink>$builders</font>
<</replace>>
<<case 4>>
<<set $researchers += 1>>
<<set $myMsg = "You assign the recently joined survivor to the Researchersers.">>
<<replace "#researchers">><font color = pink>$researchers</font>
<</replace>>
<<case 5>>
<<set $hunters += 1>>
<<set $myMsg = "You assign the recently joined survivor to the Hunters.">>
<<replace "#hunters">><font color = pink>$hunters</font>
<</replace>>
<<default>>
<<set $scavengers += 1>>
<<set $myMsg = "You assign the recently joined survivor to the Scavengers.">>
<<replace "#scavengers">><font color = pink>$scavengerss</font>
<</replace>>
<</switch>>
<<displayMessage>>
<<goto `passage()`>>
<</nobr>><</widget>>
//////////////////////// REMOVE SURVIVOR ////////////////////////
<<widget removeSurv>><<nobr>>
<<set $numArray.shuffle()>>
<<set _survArray = []>>
<<set _survArray[0] = $farmers>>
<<set _survArray[1] = $guards>>
<<set _survArray[2] = $builders>>
<<set _survArray[3] = $researchers>>
<<set _survArray[4] = $hunters>>
<<set _survArray[5] = $scavengers>>
<<if _survArray[$numArray[0]] gt 0>>
<<set _remove = $numArray[0]>>
<<elseif _survArray[$numArray[1]] gt 0>>
<<set _remove = $numArray[1]>>
<<elseif _survArray[$numArray[2]] gt 0>>
<<set _remove = $numArray[2]>>
<<elseif _survArray[$numArray[3]] gt 0>>
<<set _remove = $numArray[3]>>
<<elseif _survArray[$numArray[4]] gt 0>>
<<set _remove = $numArray[4]>>
<<elseif _survArray[$numArray[5]] gt 0>>
<<set _remove = $numArray[5]>>
<</if>>
<<switch _remove>>
<<case 0>>
<<set $myMsg = "A farmer decided to leave due to lack of food.">>
<<removeFarmer>>
<<case 1>>
<<set $myMsg = "A guard decided to leave due to lack of food.">>
<<removeGuard>>
<<case 2>>
<<set $myMsg = "A builder decided to leave due to lack of food.">>
<<removeBuilder>>
<<case 3>>
<<set $myMsg = "A researcher decided to leave due to lack of food.">>
<<removeResearcher>>
<<case 4>>
<<set $myMsg = "A hunter decided to leave due to lack of food.">>
<<removeHunter>>
<<case 5>>
<<set $myMsg = "A scavenger decided to leave due to lack of food.">>
<<removeScavenger>>
<</switch>>
<<adjustLostSurv>>
<</nobr>><</widget>>
//////////////////////// REMOVE FARMER ////////////////////////
<<widget removeFarmer>><<nobr>>
<<set $farmers -= 1>>
<<replace "#farmers">><<if $farmers gt 0>>
<font color = pink>$farmers
</font><<else>>$farmers<</if>>
<</replace>>
<</nobr>><</widget>>
//////////////////////// REMOVE GUARD ////////////////////////
<<widget removeGuard>><<nobr>>
<<set $guards -= 1>>
<<replace "#guards">><<if $guards gt 0>>
<font color = pink>$guards
</font><<else>>$guards<</if>>
<</replace>>
<</nobr>><</widget>>
//////////////////////// REMOVE BUILDER ////////////////////////
<<widget removeBuilder>><<nobr>>
<<set $builders -= 1>>
<<replace "#builders">><<if $builders gt 0>>
<font color = pink>$builders
</font><<else>>$builders<</if>>
<</replace>>
<</nobr>><</widget>>
//////////////////////// REMOVE RESEARCHER ////////////////////////
<<widget removeResearcher>><<nobr>>
<<set $researchers -= 1>>
<<replace "#researchers">><<if $researchers gt 0>>
<font color = pink>$researchers
</font><<else>>$researchers<</if>>
<</replace>>
<</nobr>><</widget>>
//////////////////////// REMOVE HUNTER ////////////////////////
<<widget removeHunter>><<nobr>>
<<set $hunters -= 1>>
<<replace "#hunters">><<if $hunters gt 0>>
<font color = pink>$hunters
</font><<else>>$hunters<</if>>
<</replace>>
<</nobr>><</widget>>
//////////////////////// REMOVE SCAVENGER ////////////////////////
<<widget removeScavenger>><<nobr>>
<<set $scavengers -= 1>>
<<replace "#scavengers">><<if $scavengers gt 0>>
<font color = pink>$scavengers
</font><<else>>$scavengers<</if>>
<</replace>>
<</nobr>><</widget>>
//////////////////////// ADJUST LOST SURV ////////////////////////
<<widget adjustLostSurv>><<nobr>>
<<set $survivors -= 1>>
<<displayMessage>>
<<adjustIdle>>
<<goto `passage()`>>
<<checkForDefeat>>
<</nobr>><</widget>>
//////////////////////// CURE MESSAGE ////////////////////////
<<widget cureMessage>><<nobr>>
<<set $curCure = $zombieCure>>
<<set _ranNum = random(0,1)>>
<<if $curCure gt ($oldCure+5)>>
<<set $oldCure = $curCure>>
<<set _liquorArray = ["Patron", "Jose Cuervo", "Fireball",
"Bacardi", "Grey Goose", "Absolut", "Johnnie Walker", "Smirnoff",
"Captain Morgan", "Baileys", "Crown Royal", "Jack Daniels",
"Jim Beam"]>>
<<set _liquorArray.shuffle()>>
<<set $myMsg = "Researchers closer to cure! We now know it's not "+random(2,5)+" parts "+_liquorArray[0]+" and "+random(2,5)+" parts "+_liquorArray[1]+".">>
<<displayMessage>>
<<elseif _ranNum eq 1>>
<<set $myMsg = "Researchers requesting zombies to be captured for cure testing purposes.">>
<<displayMessage>>
<</if>>
<</nobr>><</widget>>
//////////////////////// GUARDING MESSAGE ////////////////////////
<<widget guardingMessage>><<nobr>>
<<set $myMsg = "Everyone feels a
little happier seeing guards on duty!">>
<<displayMessage>>
<</nobr>><</widget>>
//////////////////////// SHRINK GROUP ////////////////////////
<<widget shrinkGroup _num>><<nobr>>
<<if $zombieGroup gt 10>>
<<set $zombieGroup -= _num>>
<<if $zombieGroup lt 10>>
<<set $zombieGroup = 10>>
<</if>>
<</if>>
<</nobr>><</widget>>
//////////////////////// SHOW CURE PROGRESS //////////////////////////
<<widget cureProgress>><<nobr>>
<span id ="cureprogress"><<if $researchers gt 0>>If your $researchers researchers work on the cure, they could gain an additional
<<print (.5+$tempZombieCure).toFixed($decimalPlacesCure)+"%">>
towards solving the cure!<<else>>Assign some researchers to work on the zombie cure!<</if>>
</span>
<</nobr>><</widget>>
/////////////////////// UPDATE CURE PROGRESS ////////////////////////
<<widget updateCureProgress>><<nobr>>
<<replace "#cureprogress">>
<<if $researchers gt 0>>If your $researchers researchers work on the cure, they could gain an additional <<print(.5+$tempZombieCure).toFixed($decimalPlacesCure)+"%">>
towards solving the cure!<<else>>Assign some researchers to work on the zombie cure!<</if>>
<</replace>>
<</nobr>><</widget>>
//////////////////////// MASSIVE HORDE PROGESS ////////////////////////
<<widget massiveHorde>><<nobr>>
The horde is approaching your compound!
<span id ="massive"><<if $massiveHorde lt 10>>Luckily, the massive zombie horde is only <<else>>The massive zombie horde is <</if>>
<font color = yellow>
$massiveHorde%</font> the way here from where it was first spotted!</span>
<</nobr>><</widget>>
/////////////////////// MASSIVE HORDE MESSAGE ////////////////////////
<<widget massiveMessage>><<nobr>>
<<if $massiveHorde eq 100>>
<<checkForDefeat>>
<<elseif !($massiveHorde % 10)>>
<<set $myMsg = "Reports are that the approaching massive horde is $massiveHorde% the way here already!">>
<<displayMessage>>
<<elseif random(1,7) eq 1>>
<<set $myMsg = "We need to find a zombie cure or dig a long escape tunnel before this massive horde arrives!">>
<<displayMessage>>
<</if>>
<</nobr>><</widget>>
/////////////////////// UPDATE MASSIVE MESSAGE ////////////////////////
<<widget updateMassive>><<nobr>>
<<replace "#massive">>
<<if $massiveHorde lt 10>>Luckily, the massive zombie horde is only <<else>>The massive zombie horde is <</if>><font color = yellow>
$massiveHorde%</font> the way here from where it was first spotted!
<</replace>>
<</nobr>><</widget>>
/////////////////////// HAPPY BONUS ////////////////////////
<<widget happyBonus>><<nobr>>
<<set $happyBonus = random(random(0,1),(random(1,2)))>>
<<if $myHappiness gt 90 and $happyBonus lt 2>>
<<set $happyBonus += 1>>
<<elseif $myHappiness lt 25>>
<<set $happyBonus = 0>>
<<elseif $myHappiness lt 50 and $happyBonus gt 0>>
<<set $happyBonus -= 1>>
<</if>>
<<set $happyBonus += $skillAdj>>
<</nobr>><</widget>>
/////////////////////// TUNNEL MESSAGE ////////////////////////
<<widget tunnelMessage>><<nobr>>
<<set $myMsg = "Your builders have finished a tunnel
section. Your escape tunnel is now "+
($tunnel*100) +" feet long.">>
<<displayMessage>>
<</nobr>><</widget>>
/////////////////////// BATTLE ESCAPE 1 ////////////////////////
<<widget battleEscape1>><<nobr>>
<<if $myDamage*$survivors lt 100>>
<<set _max = 2>>
<<else>>
<<set _max = 1>>
<</if>>
<<for $i = 0; $i < $survivors; $i++>>
<<if random(0,_max) gt 0>>
<<set $escapeKilled += 1>>
<</if>>
<</for>>
<<for $i = 0; $i < $escapeKilled; $i++>>
<<if random(0,$tunnel) gt random(0,(9-$skillAdj))>>
<<set $escapeKilled -= 1>>
<</if>>
<</for>>
<<set $survivors -= $escapeKilled>>
<<if $survivors eq 1>>
<<set $survivors = 2>>
// So I don't have to refer to just one survivor //
<<set $escapeKilled -= 1>>
<</if>>
<<if $survivors gt 0>>
Zombies approach from every direction and attack your group! Your group fights back valiantly. When all is said and done, you lose $escapeKilled survivors from your group.
You and your $survivors survivors must now make a quick decision before other zombies attack.
<<else>>
Zombies approach from every direction and attack your group! Your group fights back valiantly, but one by one, each survivors falls victim to a zombie.<br><br>
[[You realize this is it!|lostEscape]]
<</if>>
<</nobr>><</widget>><<nobr>><<showHUD>>
<<set UIBar.unstow()>>
<font color = green><<="[ Command Post ] ">>
<br>
</font>Your compound can hold a maximum of $maxSurvivors survivors. You are currently standing inside your compound's command post. There is a [[note]] posted by yourself on the wall nearby. There is also a [[guard tower]]<<if $radioTower eq true>> and a [[radio tower]]<</if>> nearby.<<if $researchLab eq true>> There is a [[research lab]] not too far away as well.<</if>>
<<if $pauseGame eq true>>
<br><br>
A massive zombie horde has been spotted from the guard tower in the distance!
<br><br>
Your survivors are awaiting to be assigned tasks.
<</if>>
<br><br>
<<if $pauseGame eq true>>
<<button "Start Easy Game">>
<<set $skillAdj = 1>>
<<set $startDate = new Date(Date.now())>>
<<set $startDate = $curDate.toLocaleString("en-US", { hour: "numeric", minute: "2-digit", second: "2-digit" } )>>
<<set $pauseGame = false>>
<<welcomeMsg0>>
<<if $idleSurv gt 0>>
<<welcomeMsg1>>
<<else>>
<<welcomeMsg2>>
<</if>>
<<goto `passage()`>>
<</button>>
>>>>>>>
<<button "Start Normal Game">>
<<set $skillAdj = 0>>
<<set $startDate = new Date(Date.now())>>
<<set $startDate = $curDate.toLocaleString("en-US", { hour: "numeric", minute: "2-digit", second: "2-digit" } )>>
<<set $pauseGame = false>>
<<welcomeMsg0>>
<<if $idleSurv gt 0>>
<<welcomeMsg1>>
<<else>>
<<welcomeMsg2>>
<</if>>
<<goto `passage()`>>
<</button>>
>>>>>>>
<<button "Start Hard Game">>
<<set $skillAdj = -1>>
<<set $startDate = new Date(Date.now())>>
<<set $startDate = $curDate.toLocaleString("en-US", { hour: "numeric", minute: "2-digit", second: "2-digit" } )>>
<<set $pauseGame = false>>
<<welcomeMsg0>>
<<if $idleSurv gt 0>>
<<welcomeMsg1>>
<<else>>
<<welcomeMsg2>>
<</if>>
<<goto `passage()`>>
<</button>>
<</if>>
<</nobr>>
<<nobr>><<showHUD>>
<font color = green><<="[ Guard Tower ] ">></font>
<br>
You have a 360 degree view of the surrounding area from here. There is<<if $batteriesFound eq false>> an old <<else>> a working <</if>>AM/FM [[radio]] sitting here. Nearby is the compound's [[command post]]<<if $radioTower eq true>> and [[radio tower]]<</if>>.<<if $tunnel gt 0>> There is an [[escape tunnel]] not too far away as well.<</if>><br><br>
Most alarming though, you can see an absolutely massive zombie horde numbering in the thousands.
<<if $pauseGame eq false>>
<<massiveHorde>>
<</if>>
<br><br>
<</nobr>><<showHUD>><font color = green><<="[ Note ]">></font><br>To all of those who follow me,
I know we could all use a little [[help]] during these dark times with all of those lifeless creatures roaming nearby. The key to surviving this situation is to keep our happiness up. However as leader, I have to make difficult decisions. As of now, each of you is limited to <font color = yellow>$dietPlan food/day</font>. This could [[change|Change Diet]] in the future depending on food supplies. I will keep you posted.
-- Your fearless leader
[[Done Reading Note|command post]]
<<nobr>>
<</nobr>><<nobr>><<showHUD>>
<font color = green><<="[ Change ]">></font><br>
<<setDietPlan>><br><br>
<<setFoodDecimalPlaces>><br>
<<setHappinessDecimalPlaces>><br>
<<setCureDecimalPlaces>>
<</nobr>>
[[Done Making Changes|note]]
<<nobr>><<showHUD>>
<font color = green><<="[ Help ]">></font><br>
<<setMessages>><br>
<u>GAME TIPS</u><br>
Scavengers twice as likely to die if attacked by zombies compared to Hunters.<br>
Scavengers complete tasks 20% quicker than compared to Hunters. Farmers are fastest, Researchers slowest.<br>
Your survivors can change tasks prior to meter becoming full and this will be treated as if they were always on that task.<br>
Happiness affects many different aspects of game, such as amt of food and survivors found, horde approach rate, etc.<br>
Happiness is affected by defense %, food on hand, food ration/day, damage #, nearby zombies, and # of guards on duty.
<</nobr>>
[[Return to Note|note]]<<nobr>><<showHUD>>
<font color = green><<="[ Radio - ">>
<<if $batteriesFound eq false>> needs batteries ]
<<else>> batteries installed ]<</if>>
</font><br>
<<if $batteriesFound eq false>>
The radio doesn't seem to have any batteries...it's useless at the moment.
<<elseif $radioTower eq false>>
With batteries for the radio installed, you try searching for any signs of life throughout all the radio frequencies. No matter how hard you try, you only find one station with heavy interference. You can barely make out a message coming from the radio...
<<else>>
Other than your own message you are broadcasting from your radio tower, you have a hard time finding another station. There is one station however that you can barely make out...
<</if>>
<<if $batteriesFound eq true>>
"Th*s is the Civ*l A*thor*ty reqest*ng all c*vili*ns make their w*y to the $rallyPoint f*r y*ur *wn safe*y!"
<br><br>The message repeats over and over.
<</if>><</nobr>>
[[View Surroundings|guard tower]]<<nobr>><<showHUD>>
<font color = green><<="[ Radio Tower ] ">></font>
<br>
An ulgy, yet workable radio tower that stands tall directly in the middle of your compound. The radio tower is setup to repeat a pre-recorded message letting other survivors know they are welcome at your compound. The compound's [[command post]] and [[guard tower]] are nearby.<br><br>
<</nobr>><<showHUD>><<nobr>>
<<set UIBar.stow()>>
With the zombie cure found, you become the most popular person on the planet. <br><br>
You are interviewed by the media...<br><br>
[[Click here to read the most interesting article posted online|win article]]
<</nobr>><<nobr>>
<h1><u><b>//The Daily World Report//</b></u></h1>
<font size = 10>''Zombie Cure Discovered!''</font><</nobr>><font size = 5><br>
Just when all hope seemed to be lost and people were destined to wander the earth lifeless, a ragtag group of brave survivors never gave up hope. The group lead by an insane individual bent on discovering the zombie cure has succeeded where all others have failed. The leader even recorded details from the horrific situation in a [[notebook]].
"When the outbreak originally started, I was scared shirtless. I literally had my shirt torn off of me in a close call by a zombie," said the leader of the group. "Once I was able to organize some survivors together, we thought it was best to aim for the kneecaps and slow these creeps down, but then we realized aiming for the head was a better tactic," continued the leader. "After we were able to defend ourselves adequately, I began to focus our efforts on finding a zombie cure and we finally succeeded," exclaimed the leader.
When asked what was hardest about their ordeal, the leader replied, "No Doordash, Uber Eats...not even GrubHub was operating! Whatever happened to drone delivery? We ate things that would make a billy goat puke, but we never gave up hope."
</font><<showHUD>><<nobr>>
<<set UIBar.stow()>>
Zombies tear a large gapping hole in your compound walls and begin streaming in!
<<if $tunnel gt 0>>
<br><br>
[[Enter your escape tunnel|escape]]
<<else>>
You add one last journal entry in your notebook and place it in your pocket before being bitten by a zombie.<br><br>
Months later after the military comes sweeping through, your notebook is discovered and an [[article|lost article]] appearing in all major newspapers is published worldwide.
<</if>>
<</nobr>><<nobr>>
<<set $lastNote = random(1,5)>>
<<switch $lastNote>>
<<case 1>>
<<set $lastNote = "Tomorrow was Taco Tuesday too...Damnit!">>
<<case 2>>
<<set $lastNote = "Guess my Ex was right.">>
<<case 3>>
<<set $lastNote = "I wonder if I'll taste like chicken to the zombies.">>
<<case 4>>
<<set $lastNote = "I cheated on my taxes in 2012.">>
<<case 5>>
<<set $lastNote = "There's no escape! Oh well, the Wi-Fi sucked here anyways.">>
<</switch>>
/*
<h1><u><b>//The Daily World Report//</b></u></h1>
*/
<font size = 10>''Zombie Notebook Recovered!''</font><</nobr>><font size = 5><br>
When cleaning up the last reminants of the zombie outbreak, a fascinating detailed [[notebook]] was discovered on a unassuming zombie.
"We were just about to throw the zombie into our bark chipper when a young private noticed the notebook," stated an Army spokesperson.
"Apparently the notebook is authored by the leader of a group of ragtag survivors who held out for as long as they could. According to the notebook everything was fine until the author started noticing more gun shots in the neighborhood than usual," said the spokesperson. "From there," continued the spokesperson, "all hell broke loose and this person gathered as many survivors together as possible and they fought to the bitter end."
Sadly, according to the spokesperson, the last entry in the notebook simply states... <br>"<<print $lastNote>>"
"Also, as a quick side note to the readers out there...if you are in need of a bark chip mixture for your flowerbeds, we have plenty," stated the Army spokesperson.
</font>Started playing @ $startDate
<<if $winner eq true>>Won<<else>>Lost<</if>> game @ $curDate
<font color = yellow>NOTEBOOK</font>
<font color = orange>[ Day 0 ]</font> More gunshots than normal in neighborhood. Told spouse to go investigate. I'm busy watching $tvChannel.
<font color = orange>[ Day 1 ]</font> Zombie outbreak is real! Spouse finally returned and attacked me! Luckily I only lost my shirt in the scuffle.
<font color = orange>[ Day 1 ]</font> Organizing neighbors who have't turned yet. We are putting up makeshift walls.
<font color = orange>[ Day 1 ]</font> All communication's are down except for shortwave radio transmissions.
<font color = orange>[ Day 2 ]</font> Offically have a compound now that walls are up. Building a guard tower inside compound walls.
<font color = orange>[ Day 3 ]</font> Guard tower complete. A massive horde of zombies numbering into the thousands is approaching!
<font color = orange>[ Day 3 ]</font> I've been appointed leader. I have $startSurv survivors following my command.
<font color = orange>[ Day 3 ]</font> Assigned all survivors tasks. I posted note about rationing food around compound.
<font color = orange>[ Day 4 ]</font> Saw my Ex driving by the compound in a shiny black BMW. My Ex screamed "LOSER!" at me.
<font color = orange>[ Day 4 ]</font> My Ex wasn't a zombie yet, but I shot an arrow anyways. I believe the arrow ricocheted off the car.
<font color = orange>[ Day 5 ]</font> The good news, it's Taco Tuesday, hell yeah! The bad news, my 401k is down 99%.
<font color = orange>[ Day 5 ]</font> Told Scavenger's to look out for Wi-Fi equipment. I want better Wi-Fi when this is all over.
<font color = orange>[ Day 6 ]</font> Six more days until next Taco Tuesday. Booyah!
<font color = orange>[ Day 7 ]</font> Lots of time to think about stuff. Feeling guilty about something I did back in 2012.
<font color = orange>[ Day 7 ]</font> Playing Phil in a game of chess. He has forced checkmate in two moves...I'm screwed.
<font color = orange>[ Day 8 ]</font> Phil looked like he might be turning...I hit him with a shovel. He screamed for me to stop, but I couldn't chance it.
<font color = orange>[ Day 8 ]</font> Phil's lying on the ground unresponsive and bleeding. I guess I win the chess game. Still undefeated, yes!
<font color = orange>[ Day 9 ]</font> Phil turned. See, I was right. I hit him with the shovel again. He's dead again.
<font color = orange>[ Day 10 ]</font> I'm bored. No one wants to play chess with me. Need to find a new hobby.
<font color = orange>[ Day 10 ]</font> Doing everything we can to recruit survivors and find a cure for this horrible disease.
<font color = orange>[ Day 11 ]</font> <<if $winner eq false and $myDefense lte 0 and $tunnel eq 0>>Defensive walls have failed. All hope is lost!<<elseif $winner eq false and $survivors eq 0>>No more survivors are following me....it's just me. I'm venturing outside compound.<<elseif $tunnel gt 0 and $zombieCure lt 100>> Defensive walls have failed! Me and all survivors are fleeing through the escape tunnel!<<else>>Zombie horde $massiveHorde% the way here from where it was first spotted!<</if>>
<font color = orange>[ Day 11 ]</font><<if $winner eq true and $zombieCure eq 100>> We discovered the cure! Turns out it's one part Jack Daniel's, two parts Fireball, and 3 parts Jose Cuervo!<<elseif $winner eq false>> $lastNote<<else>> Me and $survivors survivors made it to the town rally point and are safe!<</if>>
Hope you enjoyed my game, thanks for playing!<<showHUD>><<nobr>>
<<set UIBar.stow()>>
In a desperate attempt to find other survivors, you venture outside the compound walls. You don't get more than 50 feet away from the compound when you realized you are surrounded by zombies.<br><br>
In an act of defeat, you pull out a notebook from your back pocket and jot down a quick note. Just as you place the notebook back in your pocket, you are attacked and bitten!<br><br>
Months later after the military comes sweeping through, your notebook is discovered and an [[article|lost article]] appearing in all major newspapers is published worldwide.
<</nobr>><<set UIBar.stow()>><<set $pauseGame = true>><<nobr>>
<font color = green><<="[ Escape Tunnel Exit ]">></font><br><br>
You and $survivors survivors hastily enter the escape tunnel as your compound walls begin to fail!<br><br>
As your group exits the escape tunnel <<print ($tunnel*100)>> feet away from your compound, you realize you may have just escaped the massive horde, but now find yourself surrounded by dozens of other zombies.<br><br>
<<battleEscape1>><br><br>
<<if $survivors gt 0>>
To the west is the zombie horde you just fled from. Traveling north will lead to a fire station, but you first spot a large bus alongside the road that will hold up to 30 people. To the east is nothing but burnt cars littering the road, but traveling east will eventually lead to a police station. To the south is what looks like a workable black BMW and also the direction to the nearest mall.<br><br>
Since traveling west is out of the question, which way should you flee, north, east, or south?
<br><br>
[[Move North towards Fire Station|Travel North]]
<br><br>
[[Move East towards Police Station|Travel East]]
<br><br>
[[Move South towards Mall|Travel South]]
<</if>>
<</nobr>><<nobr>>
You realize this is it, no more second chances.<br><br>
In a state of resignation, you pull out a notebook from your back pocket and add one last journal entry before placing it back in your pocket. Only seconds later you are bitten by a zombie.<br><br>
Months later after the military comes sweeping through, your notebook is discovered and an [[article|lost article]] appearing in all major newspapers is published worldwide.
<</nobr>><<nobr>>
After dodging burntout cars for the past few miles and running over the occasional wandering zombie in the middle of the road, you notice what looks like the fire station not too far away.<br><br>
Just as the mood begins to change, an extremely large grinding sound comes from under the bus hood followed by a large plume of smoke and steam. The bus comes to a rolling stop within 100 feet of the fire station.<br><br>
<<if $rallyPoint eq "Fire Station" and (($survivors*$myDamage)+($critical*10)) gt 30 >>
Luckily for you, this seems to be the rallying point for all the survivors in the town. You and your fellow survivors are safe now as other survivors begin to stream out of the fire station to greet you.<br><br>
As you swap survival stories amoungst the other survivors, a reporter takes a great interest in your story throughout this ordeal and asks if he can publish it worldwide. You agree to have your story published.<br><br>
[[Read Article|wonEscape]]
<<else>>
Out of nowhere, zombies from all directions begin to rush the bus.<br><br>
You scream at the other survivors to get off the bus and make a mad dash for the fire station.<br><br>
<<if $rallyPoint neq "Fire Station">>
It's at this point when one of the survivors shouts, "There is no one here, just zombies!!!" You cringingly realize this isn't the town rally point you had hoped it was.<br><br>
<<else>>
It's at this point when one of the survivors shouts, "There's too many of them!!!" You realize the survivor is right, but you think there still may be a chance to get into the fire station alive.<br><br>
<</if>>
In the race to the fire station, one by one the other survivors are caught and torn to pieces by pursuing zombies. It's in this moment that you think to yourself, 'We should have studied zombie weaknesses more or trained our markmanship better!'<br><br>
As you continue running towards the fire station, you are less than a stones throw away from the front door when you realize you're completely surrounded by zombies.<br><br>
[[Your finally moment|lostEscape]]
<</if>>
<</nobr>><<nobr>>
<<if $pDecision eq 1>>
You and your group of survivors quietly avoid the zombies on the road and continue making your way towards the police station.
<<else>>
You and your group of survivors quickly search nearby vehicles for weapons. Your group manages to find an axe, a slingshot, and a .38 cal pistol with 6 rounds of ammo. After making quick work of the zombies blocking your way, you and your group of survivors double time it towards the police station.
<</if>>
<br><br>
After traveling by foot for many hours without incident, you finally approach the police station.<br><br>
<<if $rallyPoint eq "Police Station" and (($survivors*$myDamage)+($critical*10)) gt 30 >>
Luckily for you, this seems to be the rallying point for all the survivors in the town. You and your fellow survivors are safe now as other survivors begin to stream out of the police station to greet you.<br><br>
As you swap survival stories amoungst the other survivors, a reporter takes a great interest in your story throughout this ordeal and asks if he can publish it worldwide. You agree to have your story published.<br><br>
[[Read Article|wonEscape]]
<<else>>
Out of nowhere, zombies from all directions begin to rush your group.<br><br>
You scream at the other survivors to make a mad dash for the police station.<br><br>
<<if $rallyPoint neq "Police Station">>
It's at this point when one of the survivors shouts, "There is no one here, just zombies!!!" You cringingly realize this isn't the town rally point you had hoped it was.<br><br>
<<else>>
It's at this point when one of the survivors shouts, "There's too many of them!!!" You realize the survivor is right, but you think there still may be a chance to get into the police station alive.<br><br>
<</if>>
In the race to the police station, one by one the other survivors are caught and torn to pieces by pursuing zombies. It's in this moment that you think to yourself, 'We should have studied zombie weaknesses more or trained our markmanship better!'<br><br>
As you continue running towards the police station, you are less than a stones throw away from the front door when you realize you're completely surrounded by zombies.<br><br>
[[Your finally moment|lostEscape]]
<</if>>
<</nobr>><<nobr>>
After traveling by foot for many hours without incident, you finally approach the mall.<br><br>
<<if $rallyPoint eq "Mall" and (($survivors*$myDamage)+($critical*10)) gt 30 >>
Luckily for you, this seems to be the rallying point for all the survivors in the town. You and your fellow survivors are safe now as other survivors begin to stream out of the mall to greet you.<br><br>
As you swap survival stories amoungst the other survivors, a reporter takes a great interest in your story throughout this ordeal and asks if he can publish it worldwide. You agree to have your story published.<br><br>
[[Read Article|wonEscape]]
<<else>>
Out of nowhere, zombies from all directions begin to rush your group.<br><br>
You scream at the other survivors to make a mad dash for the mall entrance.<br><br>
<<if $rallyPoint neq "Mall">>
It's at this point when one of the survivors shouts, "There is no one here, just zombies!!!" You cringingly realize this isn't the town rally point you had hoped it was.<br><br>
<<else>>
It's at this point when one of the survivors shouts, "There's too many of them!!!" You realize the survivor is right, but you think there still may be a chance to get into the mall alive.<br><br>
<</if>>
In the race to the mall, one by one the other survivors are caught and torn to pieces by pursuing zombies. It's in this moment that you think to yourself, 'We should have studied zombie weaknesses more or trained our markmanship better!'<br><br>
As you continue running towards the mall, you are less than a stones throw away from the front door when you realize you're completely surrounded by zombies.<br><br>
[[Your finally moment|lostEscape]]
<</if>>
<</nobr>><<nobr>>
You and your $survivors survivors begin moving north and approach the large bus that you saw previously. The bus seems to be in good working order. You jump into the drivers seat.<br><br>
<<if $survivors gt 30>>
You shout at the other survivors to get on the bus. With you in the driver's seat and 30 survivors packed like sardines on bus behind you, there is no room left for anyone else.<br><br>
<<if ($survivors-30) gt 1>>
You tell the survivors outside the bus that you'll return for them as soon as possible.<br><br>
<<else>>
You tell the single survivor outside the bus that you'll return for him as soon as possible.<br><br>
<</if>>
<<set $survivors = 30>>
You slam the bus doors closed before you hear any objections. Just as you are begining to pull away in the bus, you see a large group of zombies approach and you realize there is no hope for anyone outside the bus. You realize you won't be making the return trip afterall.<br><br>
<<else>>
You shout at the other survivors to get on the bus. With you in the driver's seat and the other $survivors survivors sitting behind you, you slam the bus doors closed and fire up the engine. The bus engine makes a large clanking sound, but does manage to start up.<br><br>
<</if>>
[[Drive to Fire Station|Fire Station]]
<</nobr>><<nobr>>
<<set $winner = true>>
<h1><u><b>//The Daily World Report//</b></u></h1>
<font size = 10>''Survivors Overcome Certain Death!''</font><</nobr>><font size = 5><br>
Just when all hope seemed to be lost and people were destined to wander the earth lifeless, a ragtag group of brave survivors never gave up hope. The group lead by an insane individual bent on staying alive until the next Taco Tuesday, has managed to do just that. The leader even recorded fascinating details from the horrific situation in a [[notebook]].
"When the outbreak originally started, I was scared shirtless. I literally had my shirt torn off of me in a close call by a zombie," said the leader of the group. "Once I was able to organize some survivors together, we thought it was best to aim for the kneecaps and slow these creeps down, but then we realized aiming for the head was a better tactic," continued the leader. "After we were able to defend ourselves adequately, I began to focus our efforts on digging an escape tunnel to freedom," exclaimed the leader.
When asked what was hardest about their ordeal, the leader replied, "No Doordash, Uber Eats...not even GrubHub was operating! Whatever happened to drone delivery? We ate things that would make a billy goat puke, but we never gave up hope."
</font><<nobr>><<showHUD>>
<font color = green><<="[ Escape Tunnel ] ">></font>
<br>
Your builders have been busy at work on this underground escape tunnel. Currently it measures <<print ($tunnel*100)>> feet in length.<br><br>
To give us the best chance at survival, the builders recommend a tunnel with a minimum length of 1000 feet, but the longer the better.<br><br>
Also, the more survivors we can get out of here, the better our survival chances will be on the other side.<br><br>
The compound's [[command post]] and [[guard tower]] are nearby.<br><br>
<</nobr>><<nobr>>
You and your $survivors survivors begin moving east along the road. The entire road looks like a large bomb went off in the middle of a used car lot. If you had a nickle for every burnt out vehicle you can see, you'd be flithly rich.<br><br>
Even if one of these vehicles were able to start, there's no way to drive it around in this mess. You abdandon all hope of using a vehicle to make your way to the police station.<br><br>
It's about at this time when you notice a small group of zombies nearby blocking your path to the north.<br><br>
Without thinking, you give a quick order to the others...<br><br>
<<link 'Quietly detour around the zombies and follow me' 'Police Station'>><<set $critical += .2>><<set $pDecision = 1>><</link>>
<br><br>
<<link 'Quickly search the vehicles for any weapons and follow me' 'Police Station'>><<set $myDamage += .1>><<set $pDecision = 2>><</link>>
<</nobr>><<nobr>>
You and your $survivors survivors begin moving south along the road. You don't go far when you come across a familiar looking black BMW. You notice a lifeless body slumped over the sterring wheel with an arrow stuck in it's head. You think to yourself for a second, but then dismiss any crazy ideas that this could be your ex's BMW.<br><br>
Just as your about to inspect the black BMW further, you notice two flat tires. At about the same time you notice the flat tires, the horde of zombies approaching from the west are getting closer and closer.<br><br>
[[Continue traveling south towards the Mall|Mall]]
<</nobr>><<nobr>><<showHUD>>
<font color = green><<="[ Research Lab ] ">></font>
<br>
You are currently standing inside your compounds makeshift laboratory.<br><br>
It is here where you must find a cure! If you had live specimens to study, that would be helpful!<br><br>
<<cureProgress>><br><br>
The compound's [[command post]] and [[guard tower]] are nearby.<br><br>
<</nobr>><b>DAY 0</b>
As you relaxingly try to watch your favorite TV channel from the comfort of your couch, you notice more gunshots than normal ring out in the neighborhood this evening for some reason.
At first the gunshots don't even bother you as it's fairly normal for this neighborhood.
Just when you begin enjoying your TV show, a large explosion in the distance rattles your windows. The distant explosion is almost immediately followed up by more nearby gunshots in the neighborhood. You turn your head towards the direction of the explosion and gunshots, but from your vantage point you're unable to see anything outside.
You shout at your spouse who happens to be in the adjioning room, "Honey! Go outside and see what all the commotion is about!"
Your spouse shouts back, "Why can't you check it out!?"
You quickly reply...
<<link 'I am busy watching HGTV!' 'Day 1 morning'>><</link>>
<<link 'I am busy watching MTV!' 'Day 1 morning'>><<set $tvChannel = "MTV">><</link>>
<<link 'I am busy watching TLC!' 'Day 1 morning'>><<set $tvChannel = "TLC">><</link>>
"I'm busy watching $tvChannel!", you shout at your spouse. Seconds later you hear your spouse exiting the house as the front door slams shut. As your spouse is investigating outside, you slowly drift off to sleep on the couch.
<b>DAY 1</b>
You awaken to the sounds of more nearby gunshots. You realize you fell asleep on the couch and it is now early morning as sunlight begins filling the house once again. The TV is still on, but only static flickers across the screen.
It's at this point that you realize you never heard back from your spouse. You go to check your phone, but the WI-FI is down again and you can't seem to get any sort of signal. You walk into the bedroom only to find the bed hasn't been slept in. You search all other rooms in the house, only to find them just as void of your spouse as the others.
All of a sudden you hear what sounds like a vehicle crashing outside your house. Still in your t-shirt and sweatpants from last night, you quickly make your way to the front door and exit outside.
As soon as you step foot outside, you notice chaos everywhere.
Just about everywhere you look in the distance you see large plumes of dark smoke bellowing into the sky. Gunshots continue to echo from all directions. You notice people screaming and chasing one another down the street. You also notice the car that you heard crash seconds ago, as it lies crashed upside down across the street from you. A lifeless arm dangles from the broken drivers side car window.
It's at this moment you notice your neighbor Phil waving frantically at you near the crashed car.
<<link 'This must be a dream...Give Phil the middle finger and go back into your house' 'Day 1 evening'>><<set $fingerPhil = true>><</link>>
[[Rush over to Phil|Day 1 evening]]<<if $fingerPhil eq true>>You give Phil the middle finger and begin walking back towards your front door when you hear Phil scream, "This isn't the time to be joking around neighbor! I need your help, get over here!" You quickly realize this is no dream and rush over to Phil.<<else>>You rush over to Phil.<</if>>
"Phil, what the hell is going on here?!", you nervously exclaim.
"I think the zombie apocalypse has finally arrived!", states Phil. "See look," continues Phil as he points at the dead car driver turning into a zombie before your very eyes. The zombie is luckily still strapped in a seat belt as his arms flail around wildly inside the crashed car.
Before you can respond to anything that is happening, Phil panickingly says, "All communications are down except shortwave radio I believe. There doesn't appear to be any safe direction to travel from here as it's chaos everywhere. What are we going to do?!"
Without hesitation you respond, "Christ! Ok listen, gather as many as the neighbors together as you can and lets meet back here in five minutes. I have to go and try and find my spouse!"
Phil gives you a nervous head nod and quickly sprints away west like he was running for the gold in the Olympics.
After gathering your thoughts, you take in your surroundings one more time. Out of sheer luck, you see your spouse sprinting towards you from the east.
[[You shout, "Honey! Honey!"|Day 1 walls]]
You shout, "Honey! Honey!", but before you can say anything else, your spouse is on you like white on rice. Your spouse has ran towards you so quickly, that you're knocked to the ground and your spouse is litterally on top of you!
Normally this would be a good thing, but in this case your spouse has already turned and joined the ranks of the undead. You shove and kick at your spouse and then manage to get to your feet, but not before having your shirt torn off of you. Your spouse, in a mad rage, unrelentingly continues coming at you while swinging both arms towards you.
As your spouse nears, you connect with a punch to the head that would make Mike Tyson proud. Your spouse falls lifeless to the ground before you.
Before you can even comprehend what just happened and mourn the loss of your spouse, you hear neighbor Phil shouting at you once again.
You run west to Phil and realize he has gathered another <<print $survivors-1>> neighbors, who are now looking at you for leadership.
"Ok people, I'm not going to sugarcoat this. We're as good as dead if we don't get some sort of defensive compound built immediately," you exclaim!
Since Phil has the largest and nicest home in the neighborhood, you explain to the others that the first line of defense will be boarding up all the windows. Once that is done, we'll put up makeshift walls surrounding Phil's place.
[[The survivors agree and get to work immediately|Day 2]]You and your $survivors neighbors work all night and get the walls up around Phil's place. The walls you've built are nice and tall and should hold off small groups of zombies for the time being.
<b>DAY 2</b>
Though it's morning once again and you have just finished with the walls, this is no time to take a break.
You and the others decide a guard tower must be build to get a better idea on what is happening on the other side of the walls.
Without hesitation, everyone pitches in and begins construction of the guard tower.
<b>DAY 3</b>
Guard tower complete.
Everyone worked all night once again and are totally exhausted.
All the survivors agree you've shown great leadership throughout this ordeal and should be elected leader. The $survivors survivors are willing to follow you're every command at this point.
You accept the role of leader. Unfortunately you've got your work cut out for you as a massive zombie horde numbering into the thousands is spotted in the distance from the newly constructed guard tower.
As leader, your first action is to take note of your food inventory. You immediately post a note about rationing food in what you are calling the [[command post]] area.
<<set UIBar.stow()>>
<b><font size = 12 color = pink>APPROACHING HORDE!</font></b>
An Interactive Fiction by Craig Ruddell
<font size = 12>
[[Begin Intro|Day 0]]
[[Skip Intro|command post]]
</font>