Skip to content
Snippets Groups Projects
Commit 9858ff04 authored by Pregmodder's avatar Pregmodder
Browse files

Merge branch 'aztec-slave-sacrifice' into 'pregmod-master'

Slave sacrifice for the Aztec FS

See merge request !469
parents f35bf893 8a07a3ec
No related branches found
No related tags found
No related merge requests found
...@@ -1327,6 +1327,23 @@ window.totalPlayerRelatives = function(pc) { ...@@ -1327,6 +1327,23 @@ window.totalPlayerRelatives = function(pc) {
return relatives return relatives
}; };
window.isVegetable = function(slave) {
slave = slave || State.variables.activeSlave;
if(!slave) { return false; }
return (slave.fetish === 'mindbroken');
};
window.repGainSacrifice = function(slave, arcology) {
slave = slave || State.variables.activeSlave;
arcology = arcology || State.variables.arcologies[0];
if(!slave || !arcology || arcology.FSAztecRevivalist === "unset" || arcology.FSAztecRevivalist <= 0) {
return 0;
}
return Math.ceil(
(Math.min(100, Math.pow(1.0926, State.variables.week - slave.weekAcquired)) + slave.prestige * 30)
* arcology.FSAztecRevivalist / 100 / ((State.variables.slavesSacrificedThisWeek || 0) + 1));
};
window.ngUpdateGenePool = function(genePool) { window.ngUpdateGenePool = function(genePool) {
var transferredSlaveIds = (SugarCube.State.variables.slaves || []) var transferredSlaveIds = (SugarCube.State.variables.slaves || [])
.filter(function(s) { return s.ID >= 1200000; }) .filter(function(s) { return s.ID >= 1200000; })
......
:: Aztec Slave Sacrifice
<<set $nextButton = "Back to Main", $nextLink = "Main", $returnTo = "Main", $showEncyclopedia = 1, $encyclopedia = "Aztec Revivalism">>
<<SlavePronouns $activeSlave>>
<<set _activeSlaveRepSacrifice = repGainSacrifice()>>
$pronounCap dies screaming as $possessive still beating heart is ripped out of $possessive body. <<if _activeSlaveRepSacrifice <= 0>>Nobody cares.<<elseif _activeSlaveRepSacrifice < 10>>The few spectators are suitably impressed.<<elseif _activeSlaveRepSacrifice < 100>>The small crowd appreciates your devotion to the Aztec culture.<<else>>The crowd cheers to the bloody spectacle.<</if>><<if $slaves.length > 0>> On the other hand, your remaining <<if $slaves.length == 1>>slave is<<else>>slaves are<</if>> suitably @@.gold;horrified@@.<</if>>
<<set $rep = Math.min(20000, $rep + _activeSlaveRepSacrifice)>>
<<run $slaves.filter(function(s) { return !isVegetable(s); }).forEach(function(s) { s.trust -= 5 + random(5); })>>
<<if $arcologies[0].FSAztecRevivalist !== "unset" && $arcologies[0].FSAztecRevivalist < 100>>
<<set $arcologies[0].FSAztecRevivalist += 1>>
<</if>>
<<set $slavesSacrificedThisWeek = ($slavesSacrificedThisWeek || 0) + 1>>
<<include "Remove activeSlave">>
...@@ -209,7 +209,7 @@ ...@@ -209,7 +209,7 @@
<</if>> <</if>>
<</if>> <</if>>
<<set $coursed = 0, $eventDescription = 0, $manuallyRetired = 0, $pitFought = 0, $preOwnedViewed = 0, $prestigeAuctioned = 0, $repGain = 0, $shelterSlave = 0, $shelterSlaveBought = 0, $slaveMarketLimit = 10 + ($rep / 1000), $slavesSeen = 0>> <<set $coursed = 0, $eventDescription = 0, $manuallyRetired = 0, $pitFought = 0, $preOwnedViewed = 0, $prestigeAuctioned = 0, $repGain = 0, $shelterSlave = 0, $shelterSlaveBought = 0, $slaveMarketLimit = 10 + ($rep / 1000), $slavesSeen = 0, $slavesSacrificedThisWeek = 0>>
/% These are variables that either should be made into _temp vars or should be Zeroed out once done with them instead of here. This can also interfere with debugging or hide NaN's as zeroing things out would clear a NaN. Also could stop from NaN's getting worse? %/ /% These are variables that either should be made into _temp vars or should be Zeroed out once done with them instead of here. This can also interfere with debugging or hide NaN's as zeroing things out would clear a NaN. Also could stop from NaN's getting worse? %/
/% Integer and float variables. No real need to zero them out but doesn't hurt to have them in a known state, though this might mask variables NaN'ing out. Takes up the least amount of Memory besides a "" string. %/ /% Integer and float variables. No real need to zero them out but doesn't hurt to have them in a known state, though this might mask variables NaN'ing out. Takes up the least amount of Memory besides a "" string. %/
......
...@@ -311,6 +311,10 @@ ...@@ -311,6 +311,10 @@
| <<link "Fuck its rear hole">><<replace "#miniscene">><<FFuckdollAnal>><br><</replace>><</link>> | <<link "Fuck its rear hole">><<replace "#miniscene">><<FFuckdollAnal>><br><</replace>><</link>>
<</if>> <</if>>
<</if>> <</if>>
<<set _activeSlaveRepSacrifice = repGainSacrifice()>>
<<if _activeSlaveRepSacrifice > 0>>
| [[Sacrifice her on the altar|Aztec Slave Sacrifice]] //This will kill her and gain you _activeSlaveRepSacrifice reputation//
<</if>>
/* pregmod start */ /* pregmod start */
<<if $familyTesting == 1>> <<if $familyTesting == 1>>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment