diff --git a/compile.sh b/compile.sh index f05d1157aba596f9e170a8c77b8f9eb57fc87e28..2c4a6fc90afdbbe2851a7f63a401f8a4fd5f718c 100755 --- a/compile.sh +++ b/compile.sh @@ -11,7 +11,7 @@ Options: -d, --dry Do not compile -g, --git Add hash of HEAD to filename -h, --help Show this help text - -j, --java Run sanityCheck based on java + -j, --java Run sanityCheck based on java (recommended) -p, --python Run sanityCheck based on python -q, --quiet Suppress terminal output HelpText diff --git a/sanityCheck.sh b/sanityCheck.sh index 824ddf13024205c33c76b001e4573480ebc2361e..3f8de9e97321f4e2ffe010f5ec786ffbbbf6e4ec 100755 --- a/sanityCheck.sh +++ b/sanityCheck.sh @@ -19,7 +19,7 @@ if [[ "$1" == "java" ]]; then java="true" fi -#for all that want to add new checks, just add them outside the java checks. +#for everyone that wants to add new checks; just add them outside the java checks. GREP="git grep -n --color" @@ -136,22 +136,24 @@ $GREP -i "non.lethal" -- 'src/*' | myprint "ShouldBeNonlethal" # Check for missing quotation marks around selectors #$GREP "span class=[^\"]" -- src/*.js --exclude 'src/001-lib/Jquery/Jquery.js' | myprint "MissingQuotes" disabled until I can figure out how to exclude files +( +cd src/ + if [[ ! "$java" ]]; then # Check that we do not have any variables that we use only once. e.g. $onlyUsedOnce # Ignore *Nationalities - ( - cd src/ cat $(find . -name "*.tw" ) | tr -c '$a-zA-Z' '\n' | sed -n '/^[$]/p' | grep -v "Nationalities" | sort | uniq -u | sed 's/^[$]/-e[$]/' | sed 's/$/\\\\W/' | xargs -r git grep -n --color | myprint "OnlyUsedOnce" cat $(find . -name "*.tw" ) | tr -c '.$a-zA-Z[]_' '\n' | sed 's/SugarCube\.State\.variables\./$/g' | sed -n -e 's/^[$]\(PC\|activeSlave\|\(slaves\|tanks\)\[[^]]*\]*\)[.]\([a-zA-Z]\+\).*$/[.]\3/p' | sort | uniq -u |sed 's/^\(.*\)$/-e\1\\\\\b/' | xargs -r git grep -n --color | myprint "SlaveAttributeUsedOnce" - $GREP "\$\(PC\|activeSlave\|slaves\|tanks\)[.][^a-zA-Z]" | myprint "UnexpectedCharAfterDot" - - ) fi +$GREP "\$\(PC\|activeSlave\|slaves\|tanks\)[.][^a-zA-Z]" | myprint "UnexpectedCharAfterDot" + +) + # Check that all the tags are properly opened and closed if [[ "$java" ]]; then - java -jar devTools/javaSanityCheck/SanityCheck.jar + java -jar devTools/javaSanityCheck/SanityCheck.jar # and all the excluded stuff else git ls-files "src/*.tw" | xargs -d '\n' ./devTools/check.py fi diff --git a/src/init/dummy.tw b/src/init/dummy.tw index fa833daabbf31bf7e718424223b1e7d43935d841..b30c762d2e5c6ce81e981463ee50566e22fb9ba4 100644 --- a/src/init/dummy.tw +++ b/src/init/dummy.tw @@ -43,7 +43,8 @@ $JobIDArray /% SugarCube-style comment because it is not ignored by the Java based sanityCheck -$scarheal, $clamp, $wGain, $wLoss, $androgyny +$scarheal /* WIP */ +$clamp $MAX $MIN $SCHOOL @@ -126,10 +127,11 @@ $Categorizer $ready $rest $new -$interfaceTail $currentTarget $upgrade $W.O.L $FSCummunismDecoration, $FSIncestFetishistDecoration, $FSGenderFundamentalistResearch, $FSPaternalistResearch, $FSDegradationistResearch, $FSBodyPuristResearch, $FSMaturityPreferentialistResearch, $FSPastoralistResearch, $FSPhysicalIdealistResearch, $FSRepopulationFocusResearch, $FSRestartResearchPassed +$0, $2 +$defaultColorMap /* delete when light/normal colormodes are finished */ %/ diff --git a/src/interaction/prothesticLab.tw b/src/interaction/prothesticLab.tw index 8f3cc31836f3ef8695ca00f07a7d5c19e507dd6d..19f0395ff3ed83b9d7f566b8ecf36ef88bd8c98d 100644 --- a/src/interaction/prothesticLab.tw +++ b/src/interaction/prothesticLab.tw @@ -204,7 +204,7 @@ Prosthetic Lab Available building projects:<br> <<for _p range setup.prostheticIDs>> <<if $prosthetics[_p].research == 1>> - <<if _p != setup.prostheticIDs.erectile>> /*excludes erectile*/ + <<if _p != "erectile">> /*excludes erectile*/ <<capture _p>> <<link "Build <<= addA(setup.prosthetics[_p].name)>>" "Prosthetic Lab">> diff --git a/src/js/economyJS.js b/src/js/economyJS.js index 61e8197b7277a727ccd1de3d5c3791ad04e5540e..1627b0c52e7d41a8d62d9a0e45fa202f03d6c27e 100644 --- a/src/js/economyJS.js +++ b/src/js/economyJS.js @@ -901,7 +901,7 @@ window.NPCSexSupply = function(LC) { // The function for calculating and storing a slave's sexual interaction with citizens/'the outside' window.slaveJobValues = function() { const V = State.variables; - const slaveJobValues = {arcade: 0, club: 0, clubSP: 0}; let clubSpots = 0; const toTheClubTotal = 0; let DJRepBonus = 0; + const slaveJobValues = {arcade: 0, club: 0, clubSP: 0}; let clubSpots = 0; const toTheClubTotal = 0; V.slavesGettingHelp = 0; // This section is for specific slaves or non-unique slaves adding their values to the whole @@ -938,26 +938,27 @@ window.slaveJobValues = function() { } } if (V.DJ !== 0) { + V.DJRepBonus = 0; if (V.DJ.relationship === -3 && V.DJ.devotion > 50) { - DJRepBonus += 0.1; + V.DJRepBonus += 0.1; // $He tries $his best to be your energetic, cheerful wife. } if (V.DJ.eyes === -2) { - DJRepBonus += 0.15; + V.DJRepBonus += 0.15; } if (V.DJ.skill.entertainment <= 10) { // Though $DJ.slaveName does $his best to lead on the club, with $his lack of skill $he can do little. } else if (V.DJ.skill.entertainment <= 30) { - DJRepBonus += 0.05; + V.DJRepBonus += 0.05; // $DJ.slaveName's basic skills marginally <span class="green">improve</span> the atmosphere in $clubName. } else if (V.DJ.skill.entertainment <= 60) { - DJRepBonus += 0.1; + V.DJRepBonus += 0.1; // $DJ.slaveName's skills <span class="green">improve</span> the atmosphere in $clubName. } else if (V.DJ.skill.entertainment < 100) { - DJRepBonus += 0.15; + V.DJRepBonus += 0.15; // $DJ.slaveName's skills greatly <span class="green">improve</span> the atmosphere in $clubName. } else if (V.DJ.skill.entertainment >= 100) { - DJRepBonus += 0.20; + V.DJRepBonus += 0.20; // $DJ.slaveName's mastery immensely <span class="green">;improves</span> the atmosphere in $clubName. } if (V.DJ.muscles > 5 && V.DJ.muscles <= 95) { @@ -965,18 +966,18 @@ window.slaveJobValues = function() { // $His toned body helps $him lead $his fellow club girls by letting $him dance all night. } if (V.DJ.intelligence + V.DJ.intelligenceImplant > 15) { - DJRepBonus += 0.05 * Math.floor((V.DJ.intelligence + V.DJ.intelligenceImplant) / 32); + V.DJRepBonus += 0.05 * Math.floor((V.DJ.intelligence + V.DJ.intelligenceImplant) / 32); // $He's smart enough to make an actual contribution to the music, greatly enhancing the entire experience. } if (V.DJ.face > 95) { - DJRepBonus += 0.05; + V.DJRepBonus += 0.05; // $His great beauty is a further draw, even when $he's in $his DJ booth, but especially when $he comes out to dance. } if (setup.DJCareers.includes(V.DJ.career)) { - DJRepBonus += 0.05; + V.DJRepBonus += 0.05; // $He has musical experience from $his life before $he was a slave, a grounding that gives $his tracks actual depth. } else if (V.DJ.skill.DJ >= V.masteredXP) { - DJRepBonus += 0.05; + V.DJRepBonus += 0.05; // $He has musical experience from working for you, giving $his tracks actual depth. } @@ -1114,7 +1115,7 @@ window.slaveJobValues = function() { } } if (s.assignment === "serve in the club" || toTheClub === 1) { - beautyMultiplier += DJRepBonus; + beautyMultiplier += V.DJRepBonus; } if (canHear(s) === false) { beautyMultiplier -= 0.15; diff --git a/src/uncategorized/endWeek.tw b/src/uncategorized/endWeek.tw index 2890586bb40fc1bfac4490a630ec9395ef9a788e..f907ebb374607e06de18338dc74f4eba1a034bee 100644 --- a/src/uncategorized/endWeek.tw +++ b/src/uncategorized/endWeek.tw @@ -240,7 +240,7 @@ <<set $PC.pregWeek++>> <</if>> -<<set $HGEnergy = 0, $HGCum = 0, $HGSlaveSuccess = 0, $HeadGirl = 0, $Recruiter = 0, $Madam = 0, $madamCashBonus = 0, $DJ = 0, $unDJ = 0, $Milkmaid = 0, $Farmer = 0, $Collectrix = 0, $Stewardess = 0, $Schoolteacher = 0, $Wardeness = 0, $Concubine = 0, $Attendant = 0, $Matron = 0, $Nurse = 0, $Bodyguard = 0, $fuckSlaves = 0, $freeSexualEnergy = 0, $publicServants = 0, $cumSlaves = 0, $averageDick = 0, $slavesWithWorkingDicks = 0, $slaveJobValues = {}>> +<<set $HGEnergy = 0, $HGCum = 0, $HGSlaveSuccess = 0, $HeadGirl = 0, $Recruiter = 0, $Madam = 0, $madamCashBonus = 0, $DJ = 0, $unDJ = 0, $DJRepBonus = 0, $Milkmaid = 0, $Farmer = 0, $Collectrix = 0, $Stewardess = 0, $Schoolteacher = 0, $Wardeness = 0, $Concubine = 0, $Attendant = 0, $Matron = 0, $Nurse = 0, $Bodyguard = 0, $fuckSlaves = 0, $freeSexualEnergy = 0, $publicServants = 0, $cumSlaves = 0, $averageDick = 0, $slavesWithWorkingDicks = 0, $slaveJobValues = {}>> /* GAMEOVERS */ <<if $slaves.length < 1>>