diff --git a/src/uncategorized/arcmgmt.tw b/src/uncategorized/arcmgmt.tw index 05a6883fcc647871e9b54de9ce52fc427f03a404..13642ae02256194ce84aa9f407e5890ec06506c0 100644 --- a/src/uncategorized/arcmgmt.tw +++ b/src/uncategorized/arcmgmt.tw @@ -1498,52 +1498,26 @@ You own <<set _AWeekGrowth -= $arcologies[0].embargo*2>> <</if>> - <<set $desc = []>> - <<set $descNeg = []>> + <<set _desc = []>> + <<set _descNeg = []>> <<for $i = 1; $i < $arcologies.length; $i++>> <<set _opinion = arcologyOpinion($arcologies[0], $arcologies[$i])>> <<if _opinion >= 100>> - <<set $desc.push($arcologies[$i].name)>> + <<set _desc.push($arcologies[$i].name)>> <<elseif _opinion <= -100>> - <<set $descNeg.push($arcologies[$i].name)>> + <<set _descNeg.push($arcologies[$i].name)>> <</if>> <</for>> - <<if $desc.length > 0>> + <<if _desc.length > 0>> Your arcology's economy benefits from close social alignment with - <<if $desc.length > 2>> - ''$desc[0]'', - <<for $k = 1; $k < $desc.length; $k++>> - <<if $k < $desc.length-1>> - ''$desc[$k]'', - <<else>> - and ''$desc[$k]''<<if $descNeg.length > 0>>, but<<else>>.<</if>> - <</if>> - <</for>> - <<elseif $desc.length == 2>> - ''$desc[0]'' and ''$desc[1]''<<if $descNeg.length > 0>>, but<<else>>.<</if>> - <<else>> - ''$desc[0]''<<if $descNeg.length > 0>>, but<<else>>.<</if>> - <</if>> - <<set _AWeekGrowth += $desc.length>> + <<= _desc.reduce((res, ch, i, arr) => res + (i === arr.length - 1 ? ' and ' : ', ') + ch)>><<if _descNeg.length > 0>>, but<<else>>.<</if>> + <<set _AWeekGrowth += _desc.length>> <</if>> - <<if $descNeg.length > 0>> - <<if $desc.length == 0>>Your arcology's economy<</if>> + <<if _descNeg.length > 0>> + <<if _desc.length == 0>>Your arcology's economy<</if>> is hindered by social conflicts with - <<if $descNeg.length > 2>> - ''$descNeg[0]'', - <<for $k = 1; $k < $descNeg.length; $k++>> - <<if $k < $descNeg.length-1>> - ''$descNeg[$k]'', - <<else>> - and ''$descNeg[$k]''. - <</if>> - <</for>> - <<elseif $descNeg.length == 2>> - ''$descNeg[0]'' and ''$descNeg[1]''. - <<else>> - ''$descNeg[0]''. - <</if>> - <<set _AWeekGrowth -= $descNeg.length>> + <<= _descNeg.reduce((res, ch, i, arr) => res + (i === arr.length - 1 ? ' and ' : ', ') + ch)>>. + <<set _AWeekGrowth -= _descNeg.length>> <</if>> <<if $alwaysSubsidizeGrowth == 1>> Growth was subsidized as planned. diff --git a/src/uncategorized/buySlaves.tw b/src/uncategorized/buySlaves.tw index 525e3bd33b516a4033bbc05d21cd72ad74e9728b..bb839ba9cb684251cd4cccb33a789120aa061e84 100644 --- a/src/uncategorized/buySlaves.tw +++ b/src/uncategorized/buySlaves.tw @@ -27,7 +27,7 @@ <h2>Sex Slave Purchase Options</h2> <div> - <<if $corp.Incorporated != 0>> + <<if $corp.Incorporated == 1>> [[Corporate Market][$slavesSeen += 1]] | <<if $cash > _minimumFive>> [[(x5)|Bulk Slave Generate][$slaveMarket = "corporate", $introType = "bulk", $numSlaves = 5]] |