diff --git a/compile b/compile index d44d129ab69d49563aebeec6f894f4e42b013f7a..c9bb6c0cd576c3111a246d3985f774f3c7670586 100755 --- a/compile +++ b/compile @@ -66,3 +66,6 @@ fi #Make the output prettier, replacing \t with a tab and \n with a newline sed -i -e '/^.*<div id="store-area".*$/s/\\t/\t/g' -e '/^.*<div id="store-area".*$/s/\\n/\n/g' bin/FC_pregmod_tmp.html \ && mv bin/FC_pregmod_tmp.html bin/FC_pregmod.html + +echo "bin/FC_pregmod.html compilation finished." + diff --git a/compile-git b/compile-git index 92331b4916db9a0906e43e383916518ab689f2e5..43304f9a1090397b866dd284c853f9b6a80502ad 100755 --- a/compile-git +++ b/compile-git @@ -41,4 +41,4 @@ $TWEEGO_EXE -o "bin/FC_pregmod_${HASH}_tmp.html" src/ sed -i -e '/^<div id="store-area".*$/s/\\t/\t/g' -e '/^<div id="store-area".*$/s/\\n/\n/g' "bin/FC_pregmod_${HASH}_tmp.html" \ && mv "bin/FC_pregmod_${HASH}_tmp.html" "bin/FC_pregmod_${HASH}.html" -echo "FC_pregmod_$HASH.html compilation finished." +echo "bin/FC_pregmod_$HASH.html compilation finished." diff --git a/devNotes/Useful JS Function Documentation.txt b/devNotes/Useful JS Function Documentation.txt index f0e1e92a9e73e1da7cba0f26865d7308bb427605..8f1186b094e7df8479a806c141d379f88b14df9d 100644 --- a/devNotes/Useful JS Function Documentation.txt +++ b/devNotes/Useful JS Function Documentation.txt @@ -346,4 +346,6 @@ UtilJS [script] removeDuplicates() - Takes an array and returns a new array without duplicate entries - HackingSkillMultiplier() - outputs a value based off of the PC's hacking skill. \ No newline at end of file + HackingSkillMultiplier() - outputs a value based off of the PC's hacking skill. + + upgradeMultiplierArcology() - outputs a value based off of the PC's engineering skill. diff --git a/devNotes/VersionChangeLog-Premod+LoliMod.txt b/devNotes/VersionChangeLog-Premod+LoliMod.txt index ab5ff93babc9ee0ca6b8f7bf156a3212890fe177..579ba6ae6c235153c6a1bfdc7ed4eb98b9da19bd 100644 --- a/devNotes/VersionChangeLog-Premod+LoliMod.txt +++ b/devNotes/VersionChangeLog-Premod+LoliMod.txt @@ -2,6 +2,13 @@ Pregmod 0.10.7.1-2.2.x +03/13/2019 + + 4 + -fixes + -code cleaning + -player engineering skill now functional + 03/11/2019 3 diff --git a/devTools/javaSanityCheck/src/DisallowedTagException.java b/devTools/javaSanityCheck/src/DisallowedTagException.java index f4cc75e736b162192a5f18bbc55a10edb21eaa38..cd479fbdf5f9c8b42a9271b8c0049cba10bcb72a 100644 --- a/devTools/javaSanityCheck/src/DisallowedTagException.java +++ b/devTools/javaSanityCheck/src/DisallowedTagException.java @@ -2,7 +2,7 @@ package org.arkerthan.sanityCheck; public class DisallowedTagException extends RuntimeException { - public DisallowedTagException(String tag) { - super(tag); - } + public DisallowedTagException(String tag) { + super(tag); + } } diff --git a/devTools/javaSanityCheck/src/Main.java b/devTools/javaSanityCheck/src/Main.java index eea3a4ff611203b0025cd29ce1fe431447f80e1c..d8af45777314f08b03eb5f471be4cdb9ba72f703 100644 --- a/devTools/javaSanityCheck/src/Main.java +++ b/devTools/javaSanityCheck/src/Main.java @@ -14,306 +14,306 @@ import java.util.*; public class Main { - public static TagSearchTree<Tag> htmlTags, twineTags; - private static String currentFile; - private static int currentLine, currentPosition; - private static Stack<Element> stack; - private static List<SyntaxError> errors = new LinkedList<>(); - private static String[] excluded; - - public static void main(String[] args) { - //setup - setupExclude(); - setupHtmlTags(); - setupTwineTags(); - Path workingDir = Paths.get("").toAbsolutePath(); - - //actual sanityCheck - runSanityCheckInDirectory(workingDir, new File("src/")); - - //handle errors - for (SyntaxError e : - errors) { - System.out.println(e.getError()); - } - } - - - /** - * Goes through the whole directory including subdirectories and runs - * sanityCheck() on all .tw files - * - * @param dir to be checked - */ - private static void runSanityCheckInDirectory(Path workingDir, File dir) { - //subdirectories are checked recursively - - try { - for (File file : dir.listFiles()) { - if (file.isFile()) { //run sanityCheck if file is a .tw file - String path = file.getAbsolutePath(); - if (path.endsWith(".tw")) { - sanityCheck(workingDir.relativize(file.toPath())); - } - } else if (file.isDirectory()) { - runSanityCheckInDirectory(workingDir, file.getAbsoluteFile()); - } - } - } catch (NullPointerException e) { - e.printStackTrace(); - System.err.println("Couldn't find directory " + currentFile); - System.exit(-1); - } - } - - /** - * Runs the sanity check for one file. Does not run if file is excluded. - * - * @param path file to be checked - */ - private static void sanityCheck(Path path) { - File file = path.toFile(); - - // replace this with a known encoding if possible - Charset encoding = Charset.defaultCharset(); - - if (!excluded(file.getPath())) { - try { - currentFile = file.getPath(); - currentLine = 1; - stack = new Stack<>(); - - //actually opening and reading the file - try (InputStream in = new FileInputStream(file); - Reader reader = new InputStreamReader(in, encoding); - // buffer for efficiency - Reader buffer = new BufferedReader(reader)) { - handleCharacters(buffer); - } - } catch (IOException e) { - System.err.println("Couldn't read " + file); - } - } - } - - /** - * sets up the alphabetical search tree for fast access of HTML tags later - */ - private static void setupHtmlTags() { - //load HTML tags into a list - List<Tag> TagsList = new LinkedList<>(); - try { - - Files.lines(new File("devTools/javaSanityCheck/htmlTags").toPath()).map(String::trim) - .filter(s -> !s.startsWith("#")) - .forEach(s -> TagsList.add(parseTag(s))); - } catch (IOException e) { - System.err.println("Couldn't read devTools/javaSanityCheck/htmlTags"); - } - - //turn List into alphabetical search tree - try { - htmlTags = new TagSearchTree(TagsList); - } catch (ArrayIndexOutOfBoundsException e) { - System.err.println("Illegal Character in devTools/javaSanityCheck/htmlTags"); - System.exit(-1); - } - } - - /** - * sets up the alphabetical search tree for fast access of twine tags later - */ - private static void setupTwineTags() { - //load twine tags into a list - List<Tag> TagsList = new LinkedList<>(); - try { - - Files.lines(new File("devTools/javaSanityCheck/twineTags").toPath()).map(String::trim) - .filter(s -> !s.startsWith("#")) - .forEach(s -> TagsList.add(parseTag(s))); - } catch (IOException e) { - System.err.println("Couldn't read devTools/javaSanityCheck/twineTags"); - } - - //turn List into alphabetical search tree - try { - twineTags = new TagSearchTree(TagsList); - } catch (ArrayIndexOutOfBoundsException e) { - System.err.println("Illegal Character in devTools/javaSanityCheck/twineTags"); - System.exit(-1); - } - } - - /** - * Turns a string into a Tag - * ";1" at the end of the String indicates that the tag needs to be closed later - * - * @param s tag as String - * @return tag as Tag - */ - private static Tag parseTag(String s) { - String[] st = s.split(";"); - if (st.length > 1 && st[1].equals("1")) { - return new Tag(st[0], false); - } - return new Tag(st[0], true); - } - - /** - * sets up the excluded array. - */ - private static void setupExclude() { - //load excluded files - List<String> excludedList = new ArrayList<>(); - try { - Files.lines(new File("devTools/javaSanityCheck/excluded").toPath()).map(String::trim) - .filter(s -> !s.startsWith("#")) - .forEach(excludedList::add); - } catch (IOException e) { - System.err.println("Couldn't read devTools/javaSanityCheck/excluded"); - } - - //turn excluded files into an array and change them to windows style if needed - if (isWindows()) { - excluded = new String[excludedList.size()]; - int i = 0; - for (String s : - excludedList) { - excluded[i++] = s.replaceAll("/", "\\\\"); - } - } else { - excluded = excludedList.toArray(new String[0]); - } - } - - /** - * @return whether OS is Windows or not - */ - private static boolean isWindows() { - return (System.getProperty("os.name").toLowerCase(Locale.ENGLISH).contains("windows")); - } - - /** - * checks if a file or directory is excluded from the sanity check - * - * @param s file/directory to be checked - * @return whether it is excluded or not - */ - private static boolean excluded(String s) { - for (String ex : - excluded) { - if (s.startsWith(ex)) return true; - } - return false; - } - - /** - * Reads the file character by character. - * - * @param reader reader that is read - * @throws IOException thrown if the file can't be read - */ - private static void handleCharacters(Reader reader) throws IOException { - int r; - while ((r = reader.read()) != -1) { - char c = (char) r; - handleCharacter(c); - } - } - - /** - * Handles a single character - * - * @param c next character - */ - private static void handleCharacter(char c) { - //updating position - currentPosition++; - if (c == '\n') { - currentLine++; - currentPosition = 1; - } - - //try applying to the innermost element - if (!stack.empty()) { - int change; - try { - change = stack.peek().handleChar(c); - } catch (SyntaxError e) { - change = e.getChange(); - addError(e); - } - - //change greater 0 means the innermost element did some work - if (change > 0) { - //2 means the Element is complete - if (change == 2) { - //remove the topmost element from stack since it is complete - stack.pop(); - return; - } - //3 means the Element is complete and part of a two tag system - if (change == 3) { - //remove the topmost element from stack since it is complete - KnownElement k = stack.pop().getKnownElement(); - /*if (k.isOpening()) { - stack.push(k); - } else */ - if (k.isClosing()) { - if (stack.empty()) { - addError(new SyntaxError("Closed tag " + k.getShortDescription() + " without having any open tags.", -2)); - } else if (stack.peek() instanceof KnownElement) { - KnownElement kFirst = (KnownElement) stack.pop(); - if (!kFirst.isMatchingElement(k)) { - addError(new SyntaxError("Opening tag " + kFirst.getShortDescription() + - " does not match closing tag " + k.getShortDescription() + ".", -2)); - } - //stack.pop(); - } else { - addError(new SyntaxError("Closing tag " + k.getShortDescription() + " inside " + - "another tag: " + stack.peek().getShortDescription(), -2, true)); - } - } - if (k.isOpening()) { - stack.push(k); - } - return; - } - if (change == 4) { - stack.pop(); - } else { - return; - } - } - } - - - //innermost element was uninterested, trying to find matching element - switch (c) { - //case '@': - // stack.push(new AtElement(currentLine, currentPosition)); - //break; - case '<': - stack.push(new AngleBracketElement(currentLine, currentPosition)); - break; - //case '>': - //addError(new SyntaxError("Dangling \">\", current innermost: " + (stack.empty() ? "null" : stack.peek().getShortDescription()), -2)); - //break; - case '/': - stack.push(new CommentElement(currentLine, currentPosition)); - break; - } - } - - /** - * add an error to the error list - * - * @param e new error - */ - private static void addError(SyntaxError e) { - e.setFile(currentFile); - e.setLine(currentLine); - e.setPosition(currentPosition); - errors.add(e); - } + public static TagSearchTree<Tag> htmlTags, twineTags; + private static String currentFile; + private static int currentLine, currentPosition; + private static Stack<Element> stack; + private static List<SyntaxError> errors = new LinkedList<>(); + private static String[] excluded; + + public static void main(String[] args) { + //setup + setupExclude(); + setupHtmlTags(); + setupTwineTags(); + Path workingDir = Paths.get("").toAbsolutePath(); + + //actual sanityCheck + runSanityCheckInDirectory(workingDir, new File("src/")); + + //handle errors + for (SyntaxError e : + errors) { + System.out.println(e.getError()); + } + } + + + /** + * Goes through the whole directory including subdirectories and runs + * sanityCheck() on all .tw files + * + * @param dir to be checked + */ + private static void runSanityCheckInDirectory(Path workingDir, File dir) { + //subdirectories are checked recursively + + try { + for (File file : dir.listFiles()) { + if (file.isFile()) { //run sanityCheck if file is a .tw file + String path = file.getAbsolutePath(); + if (path.endsWith(".tw")) { + sanityCheck(workingDir.relativize(file.toPath())); + } + } else if (file.isDirectory()) { + runSanityCheckInDirectory(workingDir, file.getAbsoluteFile()); + } + } + } catch (NullPointerException e) { + e.printStackTrace(); + System.err.println("Couldn't find directory " + currentFile); + System.exit(-1); + } + } + + /** + * Runs the sanity check for one file. Does not run if file is excluded. + * + * @param path file to be checked + */ + private static void sanityCheck(Path path) { + File file = path.toFile(); + + // replace this with a known encoding if possible + Charset encoding = Charset.defaultCharset(); + + if (!excluded(file.getPath())) { + try { + currentFile = file.getPath(); + currentLine = 1; + stack = new Stack<>(); + + //actually opening and reading the file + try (InputStream in = new FileInputStream(file); + Reader reader = new InputStreamReader(in, encoding); + // buffer for efficiency + Reader buffer = new BufferedReader(reader)) { + handleCharacters(buffer); + } + } catch (IOException e) { + System.err.println("Couldn't read " + file); + } + } + } + + /** + * sets up the alphabetical search tree for fast access of HTML tags later + */ + private static void setupHtmlTags() { + //load HTML tags into a list + List<Tag> TagsList = new LinkedList<>(); + try { + + Files.lines(new File("devTools/javaSanityCheck/htmlTags").toPath()).map(String::trim) + .filter(s -> !s.startsWith("#")) + .forEach(s -> TagsList.add(parseTag(s))); + } catch (IOException e) { + System.err.println("Couldn't read devTools/javaSanityCheck/htmlTags"); + } + + //turn List into alphabetical search tree + try { + htmlTags = new TagSearchTree(TagsList); + } catch (ArrayIndexOutOfBoundsException e) { + System.err.println("Illegal Character in devTools/javaSanityCheck/htmlTags"); + System.exit(-1); + } + } + + /** + * sets up the alphabetical search tree for fast access of twine tags later + */ + private static void setupTwineTags() { + //load twine tags into a list + List<Tag> TagsList = new LinkedList<>(); + try { + + Files.lines(new File("devTools/javaSanityCheck/twineTags").toPath()).map(String::trim) + .filter(s -> !s.startsWith("#")) + .forEach(s -> TagsList.add(parseTag(s))); + } catch (IOException e) { + System.err.println("Couldn't read devTools/javaSanityCheck/twineTags"); + } + + //turn List into alphabetical search tree + try { + twineTags = new TagSearchTree(TagsList); + } catch (ArrayIndexOutOfBoundsException e) { + System.err.println("Illegal Character in devTools/javaSanityCheck/twineTags"); + System.exit(-1); + } + } + + /** + * Turns a string into a Tag + * ";1" at the end of the String indicates that the tag needs to be closed later + * + * @param s tag as String + * @return tag as Tag + */ + private static Tag parseTag(String s) { + String[] st = s.split(";"); + if (st.length > 1 && st[1].equals("1")) { + return new Tag(st[0], false); + } + return new Tag(st[0], true); + } + + /** + * sets up the excluded array. + */ + private static void setupExclude() { + //load excluded files + List<String> excludedList = new ArrayList<>(); + try { + Files.lines(new File("devTools/javaSanityCheck/excluded").toPath()).map(String::trim) + .filter(s -> !s.startsWith("#")) + .forEach(excludedList::add); + } catch (IOException e) { + System.err.println("Couldn't read devTools/javaSanityCheck/excluded"); + } + + //turn excluded files into an array and change them to windows style if needed + if (isWindows()) { + excluded = new String[excludedList.size()]; + int i = 0; + for (String s : + excludedList) { + excluded[i++] = s.replaceAll("/", "\\\\"); + } + } else { + excluded = excludedList.toArray(new String[0]); + } + } + + /** + * @return whether OS is Windows or not + */ + private static boolean isWindows() { + return (System.getProperty("os.name").toLowerCase(Locale.ENGLISH).contains("windows")); + } + + /** + * checks if a file or directory is excluded from the sanity check + * + * @param s file/directory to be checked + * @return whether it is excluded or not + */ + private static boolean excluded(String s) { + for (String ex : + excluded) { + if (s.startsWith(ex)) return true; + } + return false; + } + + /** + * Reads the file character by character. + * + * @param reader reader that is read + * @throws IOException thrown if the file can't be read + */ + private static void handleCharacters(Reader reader) throws IOException { + int r; + while ((r = reader.read()) != -1) { + char c = (char) r; + handleCharacter(c); + } + } + + /** + * Handles a single character + * + * @param c next character + */ + private static void handleCharacter(char c) { + //updating position + currentPosition++; + if (c == '\n') { + currentLine++; + currentPosition = 1; + } + + //try applying to the innermost element + if (!stack.empty()) { + int change; + try { + change = stack.peek().handleChar(c); + } catch (SyntaxError e) { + change = e.getChange(); + addError(e); + } + + //change greater 0 means the innermost element did some work + if (change > 0) { + //2 means the Element is complete + if (change == 2) { + //remove the topmost element from stack since it is complete + stack.pop(); + return; + } + //3 means the Element is complete and part of a two tag system + if (change == 3) { + //remove the topmost element from stack since it is complete + KnownElement k = stack.pop().getKnownElement(); + /*if (k.isOpening()) { + stack.push(k); + } else */ + if (k.isClosing()) { + if (stack.empty()) { + addError(new SyntaxError("Closed tag " + k.getShortDescription() + " without having any open tags.", -2)); + } else if (stack.peek() instanceof KnownElement) { + KnownElement kFirst = (KnownElement) stack.pop(); + if (!kFirst.isMatchingElement(k)) { + addError(new SyntaxError("Opening tag " + kFirst.getShortDescription() + + " does not match closing tag " + k.getShortDescription() + ".", -2)); + } + //stack.pop(); + } else { + addError(new SyntaxError("Closing tag " + k.getShortDescription() + " inside " + + "another tag: " + stack.peek().getShortDescription(), -2, true)); + } + } + if (k.isOpening()) { + stack.push(k); + } + return; + } + if (change == 4) { + stack.pop(); + } else { + return; + } + } + } + + + //innermost element was uninterested, trying to find matching element + switch (c) { + //case '@': + // stack.push(new AtElement(currentLine, currentPosition)); + //break; + case '<': + stack.push(new AngleBracketElement(currentLine, currentPosition)); + break; + //case '>': + //addError(new SyntaxError("Dangling \">\", current innermost: " + (stack.empty() ? "null" : stack.peek().getShortDescription()), -2)); + //break; + case '/': + stack.push(new CommentElement(currentLine, currentPosition)); + break; + } + } + + /** + * add an error to the error list + * + * @param e new error + */ + private static void addError(SyntaxError e) { + e.setFile(currentFile); + e.setLine(currentLine); + e.setPosition(currentPosition); + errors.add(e); + } } diff --git a/devTools/javaSanityCheck/src/SyntaxError.java b/devTools/javaSanityCheck/src/SyntaxError.java index 150f2bd449b8c318b5a05884868a71538554ec67..2eaf24c6ec434192048c93891d72897c29dea9a6 100644 --- a/devTools/javaSanityCheck/src/SyntaxError.java +++ b/devTools/javaSanityCheck/src/SyntaxError.java @@ -1,40 +1,40 @@ package org.arkerthan.sanityCheck; public class SyntaxError extends Exception { - private String file; - private int line, position; - private String description; - private int change; //see Element for values; -2 means not thrown - private boolean warning = false; - - public SyntaxError(String description, int change) { - this.description = description; - this.change = change; - } - - public SyntaxError(String description, int change, boolean warning) { - this(description, change); - this.warning = warning; - } - - public void setFile(String file) { - this.file = file; - } - - public void setLine(int line) { - this.line = line; - } - - public void setPosition(int position) { - this.position = position; - } - - public String getError() { - String s = warning ? "Warning: " : "Error: "; - return s + file + ": " + line + ":" + position + " : "+ description; - } - - public int getChange() { - return change; - } + private String file; + private int line, position; + private String description; + private int change; //see Element for values; -2 means not thrown + private boolean warning = false; + + public SyntaxError(String description, int change) { + this.description = description; + this.change = change; + } + + public SyntaxError(String description, int change, boolean warning) { + this(description, change); + this.warning = warning; + } + + public void setFile(String file) { + this.file = file; + } + + public void setLine(int line) { + this.line = line; + } + + public void setPosition(int position) { + this.position = position; + } + + public String getError() { + String s = warning ? "Warning: " : "Error: "; + return s + file + ": " + line + ":" + position + " : "+ description; + } + + public int getChange() { + return change; + } } diff --git a/devTools/javaSanityCheck/src/Tag.java b/devTools/javaSanityCheck/src/Tag.java index 8a13ee4f7a178399db3eaf626b693e8a12ae71df..5c3c92651a71beb8a4e3cba73d1eb64238fc9908 100644 --- a/devTools/javaSanityCheck/src/Tag.java +++ b/devTools/javaSanityCheck/src/Tag.java @@ -1,11 +1,11 @@ package org.arkerthan.sanityCheck; public class Tag { - public final String tag; - public final boolean single; + public final String tag; + public final boolean single; - public Tag(String tag, boolean single) { - this.tag = tag; - this.single = single; - } + public Tag(String tag, boolean single) { + this.tag = tag; + this.single = single; + } } diff --git a/devTools/javaSanityCheck/src/TagSearchTree.java b/devTools/javaSanityCheck/src/TagSearchTree.java index dde49df879a346f124d15647cfeb821d0e0735fb..71e89ec769ff658b246886a179976055f2633709 100644 --- a/devTools/javaSanityCheck/src/TagSearchTree.java +++ b/devTools/javaSanityCheck/src/TagSearchTree.java @@ -9,72 +9,72 @@ import java.util.List; * @param <E> Tag class to be stored */ public class TagSearchTree<E extends Tag> { - private static final int SIZE = 128; - private final TagSearchTree<E>[] branches; - private E element = null; - private String path; + private static final int SIZE = 128; + private final TagSearchTree<E>[] branches; + private E element = null; + private String path; - /** - * creates a new empty TagSearchTree - */ - private TagSearchTree() { - branches = new TagSearchTree[SIZE]; - } + /** + * creates a new empty TagSearchTree + */ + private TagSearchTree() { + branches = new TagSearchTree[SIZE]; + } - /** - * Creates a new filled TagSearchTree - * - * @param list Tags to be inserted - */ - public TagSearchTree(List<E> list) { - this(); - for (E e : list) { - this.add(e, 0); - } - } + /** + * Creates a new filled TagSearchTree + * + * @param list Tags to be inserted + */ + public TagSearchTree(List<E> list) { + this(); + for (E e : list) { + this.add(e, 0); + } + } - /** - * adds a new Tag to the TagSearchTree - * - * @param e Tag to be stored - * @param index index of relevant char for adding in tag - */ - private void add(E e, int index) { - //set the path to here - path = e.tag.substring(0, index); - //checks if tag has to be stored here or further down - if (e.tag.length() == index) { - element = e; - } else { - //store tag in correct branch - char c = e.tag.charAt(index); - if (branches[c] == null) { - branches[c] = new TagSearchTree<>(); - } - branches[c].add(e, index + 1); - } - } + /** + * adds a new Tag to the TagSearchTree + * + * @param e Tag to be stored + * @param index index of relevant char for adding in tag + */ + private void add(E e, int index) { + //set the path to here + path = e.tag.substring(0, index); + //checks if tag has to be stored here or further down + if (e.tag.length() == index) { + element = e; + } else { + //store tag in correct branch + char c = e.tag.charAt(index); + if (branches[c] == null) { + branches[c] = new TagSearchTree<>(); + } + branches[c].add(e, index + 1); + } + } - /** - * @param c character of branch needed - * @return branch or null if branch doesn't exist - */ - public TagSearchTree<E> getBranch(char c) { - if (c >= SIZE) return null; - return branches[c]; - } + /** + * @param c character of branch needed + * @return branch or null if branch doesn't exist + */ + public TagSearchTree<E> getBranch(char c) { + if (c >= SIZE) return null; + return branches[c]; + } - /** - * @return stored Tag, null if empty - */ - public E getElement() { - return element; - } + /** + * @return stored Tag, null if empty + */ + public E getElement() { + return element; + } - /** - * @return path inside full tree to get to this Branch - */ - public String getPath() { - return path; - } + /** + * @return path inside full tree to get to this Branch + */ + public String getPath() { + return path; + } } diff --git a/devTools/javaSanityCheck/src/UnknownStateException.java b/devTools/javaSanityCheck/src/UnknownStateException.java index dceb35bc3d5b57fa3d710e9e61d3ce427a3499c3..80dbe598682d23875efe5517170f4f1c91a96246 100644 --- a/devTools/javaSanityCheck/src/UnknownStateException.java +++ b/devTools/javaSanityCheck/src/UnknownStateException.java @@ -2,7 +2,7 @@ package org.arkerthan.sanityCheck; public class UnknownStateException extends RuntimeException { - public UnknownStateException(int state) { - super(String.valueOf(state)); - } + public UnknownStateException(int state) { + super(String.valueOf(state)); + } } diff --git a/devTools/javaSanityCheck/src/element/AngleBracketElement.java b/devTools/javaSanityCheck/src/element/AngleBracketElement.java index e4819ba37ea48e4924dc944827d651fa14e02ad1..99549cda24411a29d1dfe32a0693cff99edbb46c 100644 --- a/devTools/javaSanityCheck/src/element/AngleBracketElement.java +++ b/devTools/javaSanityCheck/src/element/AngleBracketElement.java @@ -6,355 +6,355 @@ import java.util.Arrays; import java.util.List; public class AngleBracketElement extends Element { - private static final List<String> logicTags = Arrays.asList("if", "elseif", "else", "switch", "case", "default"); - private int state = 0; - /* - 0 - initial: < - TWINE - 1 - << - -1 - <</ - 2 - trying to complete twine tag: <<tag ???>> - -2 - trying to complete twine tag: <</tag>> - 3 - waiting for >> - -3 - expecting > from 3 - 4 - waiting for >> with KnownElement - -4 - expecting > from 4 - 5 - expecting >> - -5 - expecting > - 6 - expecting > with KnownElement opening; comparison? - -6 - expecting > with KnownElement closing + private static final List<String> logicTags = Arrays.asList("if", "elseif", "else", "switch", "case", "default"); + private int state = 0; + /* + 0 - initial: < + TWINE + 1 - << + -1 - <</ + 2 - trying to complete twine tag: <<tag ???>> + -2 - trying to complete twine tag: <</tag>> + 3 - waiting for >> + -3 - expecting > from 3 + 4 - waiting for >> with KnownElement + -4 - expecting > from 4 + 5 - expecting >> + -5 - expecting > + 6 - expecting > with KnownElement opening; comparison? + -6 - expecting > with KnownElement closing - HTML - -9 - </ - 10 - trying to complete HTML tag: <tag ???> + HTML + -9 - </ + 10 - trying to complete HTML tag: <tag ???> -10 - trying to complete HTML tag: </tag> - 11 - waiting for > + 11 - waiting for > -11 - expecting > - 12 - waiting for > with KnownElement - */ + 12 - waiting for > with KnownElement + */ - private TagSearchTree<Tag> tree; + private TagSearchTree<Tag> tree; - public AngleBracketElement(int line, int pos) { - super(line, pos); - } + public AngleBracketElement(int line, int pos) { + super(line, pos); + } - @Override - public int handleChar(char c) throws SyntaxError { - switch (state) { - case 0: - switch (c) { - case '<': - state = 1; - return 1; - case '>': - throw new SyntaxError("Empty Statement?", 2); - case '/': - state = -9; - return 1; - case ' ':// assume comparison - case '=':// " - return 2; - case '3'://a heart: <3 - return 2; - default: - try { - state = 10; - tree = Main.htmlTags; - return handleOpeningHTML(c); - } catch (SyntaxError e) { - state = 1; - throw new SyntaxError("Opening \"<\" missing, found " + c + " [debug:initialCase]", 1); - } - } - case 1: - if (c == '<') { - throw new SyntaxError("Too many \"<\".", 1); - } else if (c == '>') { - state = 3; - throw new SyntaxError("Empty Statement?", 1); - } else if (c == '/') { - state = -1; - return 1; - } - state = 2; - tree = Main.twineTags; - return handleOpeningTwine(c); - case -1: - if (c == '>') { - throw new SyntaxError("Empty Statement?", 2, true); - } - state = -2; - tree = Main.twineTags; - return handleClosingTwine(c); + @Override + public int handleChar(char c) throws SyntaxError { + switch (state) { + case 0: + switch (c) { + case '<': + state = 1; + return 1; + case '>': + throw new SyntaxError("Empty Statement?", 2); + case '/': + state = -9; + return 1; + case ' ':// assume comparison + case '=':// " + return 2; + case '3'://a heart: <3 + return 2; + default: + try { + state = 10; + tree = Main.htmlTags; + return handleOpeningHTML(c); + } catch (SyntaxError e) { + state = 1; + throw new SyntaxError("Opening \"<\" missing, found " + c + " [debug:initialCase]", 1); + } + } + case 1: + if (c == '<') { + throw new SyntaxError("Too many \"<\".", 1); + } else if (c == '>') { + state = 3; + throw new SyntaxError("Empty Statement?", 1); + } else if (c == '/') { + state = -1; + return 1; + } + state = 2; + tree = Main.twineTags; + return handleOpeningTwine(c); + case -1: + if (c == '>') { + throw new SyntaxError("Empty Statement?", 2, true); + } + state = -2; + tree = Main.twineTags; + return handleClosingTwine(c); - case 2: - return handleOpeningTwine(c); - case -2: - return handleClosingTwine(c); - case 3: - if (c == '>') { - state = -3; - return 1; - } - break; - case -3: - if (c == '>') { - return 2; - } else if (c == ' ' || c == '=') { // assuming comparison - state = 3; - return 1; - } else { - throw new SyntaxError("Closing \">\" missing, opened [" + line + ":" + pos + "]", 2); - } - case 4: - if (c == '>') { - state = -4; - return 1; - } - break; - case -4: - if (c == '>') { - return 3; - } else if (c == ' ' || c == '=') { // assuming comparison - state = 4; - return 1; - } else { - throw new SyntaxError("Closing \">\" missing, opened [" + line + ":" + pos + "]", 2); - } - case 5: - if (c == '>') { - state = -5; - return 1; - } else { - throw new SyntaxError("Closing \">\" missing, opened [" + line + ":" + pos + "]", 2); - } - case -5: - if (c == '>') { - return 2; - } - throw new SyntaxError("Closing \">\" missing, opened [" + line + ":" + pos + "]", 2); - case 6: - if (c == '>') { - return 3; - } else if (c == ' ' || c == '=') { - state = 3; - return 1; - } else { - throw new SyntaxError("Closing \">\" missing, opened [" + line + ":" + pos + "]", 3); - } - case -6: - if (c == '>') { - return 3; - } - throw new SyntaxError("Closing \">\" missing, opened [" + line + ":" + pos + "]", 3); + case 2: + return handleOpeningTwine(c); + case -2: + return handleClosingTwine(c); + case 3: + if (c == '>') { + state = -3; + return 1; + } + break; + case -3: + if (c == '>') { + return 2; + } else if (c == ' ' || c == '=') { // assuming comparison + state = 3; + return 1; + } else { + throw new SyntaxError("Closing \">\" missing, opened [" + line + ":" + pos + "]", 2); + } + case 4: + if (c == '>') { + state = -4; + return 1; + } + break; + case -4: + if (c == '>') { + return 3; + } else if (c == ' ' || c == '=') { // assuming comparison + state = 4; + return 1; + } else { + throw new SyntaxError("Closing \">\" missing, opened [" + line + ":" + pos + "]", 2); + } + case 5: + if (c == '>') { + state = -5; + return 1; + } else { + throw new SyntaxError("Closing \">\" missing, opened [" + line + ":" + pos + "]", 2); + } + case -5: + if (c == '>') { + return 2; + } + throw new SyntaxError("Closing \">\" missing, opened [" + line + ":" + pos + "]", 2); + case 6: + if (c == '>') { + return 3; + } else if (c == ' ' || c == '=') { + state = 3; + return 1; + } else { + throw new SyntaxError("Closing \">\" missing, opened [" + line + ":" + pos + "]", 3); + } + case -6: + if (c == '>') { + return 3; + } + throw new SyntaxError("Closing \">\" missing, opened [" + line + ":" + pos + "]", 3); - case -9: - if (c == '>') { - throw new SyntaxError("Empty Statement?", 2, true); - } - state = -10; - tree = Main.htmlTags; - return handleClosingHTML(c); - case 10: - return handleOpeningHTML(c); - case -10: - return handleClosingHTML(c); - case 11: - if (c == '>') - return 2; - if (c == '@') //@ inside HTML tags is allowed - return 1; - break; - case -11: - if (c == '>') - return 2; - throw new SyntaxError("Closing \">\" missing [2]", 2); - case 12: - if (c == '>') - return 3; - if (c == '@') //@ inside HTML tags is allowed - return 1; - break; - default: - throw new UnknownStateException(state); - } - return 0; - } + case -9: + if (c == '>') { + throw new SyntaxError("Empty Statement?", 2, true); + } + state = -10; + tree = Main.htmlTags; + return handleClosingHTML(c); + case 10: + return handleOpeningHTML(c); + case -10: + return handleClosingHTML(c); + case 11: + if (c == '>') + return 2; + if (c == '@') //@ inside HTML tags is allowed + return 1; + break; + case -11: + if (c == '>') + return 2; + throw new SyntaxError("Closing \">\" missing [2]", 2); + case 12: + if (c == '>') + return 3; + if (c == '@') //@ inside HTML tags is allowed + return 1; + break; + default: + throw new UnknownStateException(state); + } + return 0; + } - private int handleOpeningHTML(char c) throws SyntaxError { - if (c == ' ') { - state = 11; - if (tree.getElement() == null) { - throw new SyntaxError("Unknown HTML tag", 1); - } - if (!tree.getElement().single) { - k = new KnownHtmlElement(line, pos, true, tree.getElement().tag); - state = 12; - return 1; - } - return 1; - } - if (c == '>') { - if (tree.getElement() == null) { - throw new SyntaxError("Unknown HTML tag", 2); - } - if (!tree.getElement().single) { - k = new KnownHtmlElement(line, pos, true, tree.getElement().tag); - return 3; - } - return 2; - } + private int handleOpeningHTML(char c) throws SyntaxError { + if (c == ' ') { + state = 11; + if (tree.getElement() == null) { + throw new SyntaxError("Unknown HTML tag", 1); + } + if (!tree.getElement().single) { + k = new KnownHtmlElement(line, pos, true, tree.getElement().tag); + state = 12; + return 1; + } + return 1; + } + if (c == '>') { + if (tree.getElement() == null) { + throw new SyntaxError("Unknown HTML tag", 2); + } + if (!tree.getElement().single) { + k = new KnownHtmlElement(line, pos, true, tree.getElement().tag); + return 3; + } + return 2; + } - tree = tree.getBranch(c); - if (tree == null) { - state = 11; - throw new SyntaxError("Unknown HTML tag or closing \">\" missing, found " + c, 1); - } + tree = tree.getBranch(c); + if (tree == null) { + state = 11; + throw new SyntaxError("Unknown HTML tag or closing \">\" missing, found " + c, 1); + } - return 1; - } + return 1; + } - private int handleClosingHTML(char c) throws SyntaxError { - if (c == '>') { - if (tree.getElement() == null) { - throw new SyntaxError("Unknown HTML tag", 2); - } - if (tree.getElement().single) { - throw new SyntaxError("Single HTML tag used as closing Tag: " + tree.getElement().tag, 2); - } - k = new KnownHtmlElement(line, pos, false, tree.getElement().tag); - return 3; - } + private int handleClosingHTML(char c) throws SyntaxError { + if (c == '>') { + if (tree.getElement() == null) { + throw new SyntaxError("Unknown HTML tag", 2); + } + if (tree.getElement().single) { + throw new SyntaxError("Single HTML tag used as closing Tag: " + tree.getElement().tag, 2); + } + k = new KnownHtmlElement(line, pos, false, tree.getElement().tag); + return 3; + } - tree = tree.getBranch(c); - if (tree == null) { - state = -11; - throw new SyntaxError("Unknown HTML tag or closing \">\" missing, found " + c, 1); - } + tree = tree.getBranch(c); + if (tree == null) { + state = -11; + throw new SyntaxError("Unknown HTML tag or closing \">\" missing, found " + c, 1); + } - return 1; - } + return 1; + } - private int handleOpeningTwine(char c) throws SyntaxError { - if (c == ' ') { - state = 3; - if (tree.getElement() == null) { - //assuming not listed means widget until better solution - return 1; - //throw new SyntaxError("Unknown Twine tag or closing \">>\" missing, found " + tree.getPath(), 1); - } - if (!tree.getElement().single) { - if (logicTags.contains(tree.getElement().tag)) { - k = new KnownLogicElement(line, pos, tree.getElement().tag, false); - } else { - k = new KnownTwineElement(line, pos, true, tree.getElement().tag); - } - state = 4; - return 1; - } - return 1; - } - if (c == '>') { - state = -5; - if (tree.getElement() == null) { - //assuming not listed means widget until better solution - //throw new SyntaxError("Unknown Twine tag or closing \">>\" missing, found " + tree.getPath(), 1); - return 1; - } - if (!tree.getElement().single) { - if (logicTags.contains(tree.getElement().tag)) { - k = new KnownLogicElement(line, pos, tree.getElement().tag, false); - } else { - k = new KnownTwineElement(line, pos, true, tree.getElement().tag); - } - state = 6; - return 1; - } - return 2; - } + private int handleOpeningTwine(char c) throws SyntaxError { + if (c == ' ') { + state = 3; + if (tree.getElement() == null) { + //assuming not listed means widget until better solution + return 1; + //throw new SyntaxError("Unknown Twine tag or closing \">>\" missing, found " + tree.getPath(), 1); + } + if (!tree.getElement().single) { + if (logicTags.contains(tree.getElement().tag)) { + k = new KnownLogicElement(line, pos, tree.getElement().tag, false); + } else { + k = new KnownTwineElement(line, pos, true, tree.getElement().tag); + } + state = 4; + return 1; + } + return 1; + } + if (c == '>') { + state = -5; + if (tree.getElement() == null) { + //assuming not listed means widget until better solution + //throw new SyntaxError("Unknown Twine tag or closing \">>\" missing, found " + tree.getPath(), 1); + return 1; + } + if (!tree.getElement().single) { + if (logicTags.contains(tree.getElement().tag)) { + k = new KnownLogicElement(line, pos, tree.getElement().tag, false); + } else { + k = new KnownTwineElement(line, pos, true, tree.getElement().tag); + } + state = 6; + return 1; + } + return 2; + } - tree = tree.getBranch(c); - if (tree == null) { - //assuming not listed means widget until better solution - state = 3; - //throw new SyntaxError("Unknown Twine tag or closing \">>\" missing, found " + c, 1); - } + tree = tree.getBranch(c); + if (tree == null) { + //assuming not listed means widget until better solution + state = 3; + //throw new SyntaxError("Unknown Twine tag or closing \">>\" missing, found " + c, 1); + } - return 1; - } + return 1; + } - private int handleClosingTwine(char c) throws SyntaxError { - if (c == '>') { - if (tree.getElement() == null) { - throw new SyntaxError("Unknown Twine tag", 2); - } - if (tree.getElement().single) { - throw new SyntaxError("Single Twine tag used as closing Tag: " + tree.getElement().tag, 2); - } - if (logicTags.contains(tree.getElement().tag)) { - k = new KnownLogicElement(line, pos, tree.getElement().tag, true); - } else { - k = new KnownTwineElement(line, pos, false, tree.getElement().tag); - } - state = -6; - return 1; - } + private int handleClosingTwine(char c) throws SyntaxError { + if (c == '>') { + if (tree.getElement() == null) { + throw new SyntaxError("Unknown Twine tag", 2); + } + if (tree.getElement().single) { + throw new SyntaxError("Single Twine tag used as closing Tag: " + tree.getElement().tag, 2); + } + if (logicTags.contains(tree.getElement().tag)) { + k = new KnownLogicElement(line, pos, tree.getElement().tag, true); + } else { + k = new KnownTwineElement(line, pos, false, tree.getElement().tag); + } + state = -6; + return 1; + } - tree = tree.getBranch(c); - if (tree == null) { - state = 3; - throw new SyntaxError("Unknown Twine closing tag or closing \">>\" missing, found " + c, 1); - } + tree = tree.getBranch(c); + if (tree == null) { + state = 3; + throw new SyntaxError("Unknown Twine closing tag or closing \">>\" missing, found " + c, 1); + } - return 1; - } + return 1; + } - @Override - public String getShortDescription() { - StringBuilder builder = new StringBuilder(); - builder.append('[').append(line).append(":").append(pos).append("] "); - switch (state) { - case 0: - builder.append("<"); - break; - case 1: - builder.append("<<"); - break; - case -1: - builder.append("<</"); - break; - case 2: - builder.append("<<").append(tree.getPath()); - break; - case -2: - builder.append("<</").append(tree.getPath()); - break; - case 3: - builder.append("<<??? ???"); - break; - case 4: - builder.append("<<?").append(tree.getPath()).append(" ???"); - break; - case -3: - builder.append("<<??? ???>"); - break; - case -4: - builder.append("<<?").append(tree.getPath()).append(" ???>"); - break; - case 5: - builder.append("<").append(tree.getPath()).append(" ???"); - break; - case -5: - builder.append("</").append(tree.getPath()); - break; - case 6: - builder.append("<").append(tree.getPath()).append(" ???"); - break; - default: - //throw new UnknownStateException(state); - } - return builder.toString(); - } + @Override + public String getShortDescription() { + StringBuilder builder = new StringBuilder(); + builder.append('[').append(line).append(":").append(pos).append("] "); + switch (state) { + case 0: + builder.append("<"); + break; + case 1: + builder.append("<<"); + break; + case -1: + builder.append("<</"); + break; + case 2: + builder.append("<<").append(tree.getPath()); + break; + case -2: + builder.append("<</").append(tree.getPath()); + break; + case 3: + builder.append("<<??? ???"); + break; + case 4: + builder.append("<<?").append(tree.getPath()).append(" ???"); + break; + case -3: + builder.append("<<??? ???>"); + break; + case -4: + builder.append("<<?").append(tree.getPath()).append(" ???>"); + break; + case 5: + builder.append("<").append(tree.getPath()).append(" ???"); + break; + case -5: + builder.append("</").append(tree.getPath()); + break; + case 6: + builder.append("<").append(tree.getPath()).append(" ???"); + break; + default: + //throw new UnknownStateException(state); + } + return builder.toString(); + } } diff --git a/devTools/javaSanityCheck/src/element/AtElement.java b/devTools/javaSanityCheck/src/element/AtElement.java index 0dad04247c50f2a9a77bb9ce584ded8de0377ed2..168e340a4326b24c0dff912c64d25ec5042d6fe5 100644 --- a/devTools/javaSanityCheck/src/element/AtElement.java +++ b/devTools/javaSanityCheck/src/element/AtElement.java @@ -4,102 +4,102 @@ import org.arkerthan.sanityCheck.SyntaxError; import org.arkerthan.sanityCheck.UnknownStateException; public class AtElement extends Element { - private int state = 0; - // 0 = @ - // 1 = @@ - // 2 = @@. - // 3 = @@.a -- @@.ab -- @@.abc - // 4 = @@.abc;abc - // 5 = @@.abc;abc@ + private int state = 0; + // 0 = @ + // 1 = @@ + // 2 = @@. + // 3 = @@.a -- @@.ab -- @@.abc + // 4 = @@.abc;abc + // 5 = @@.abc;abc@ - // example: @@.red;some text@@ + // example: @@.red;some text@@ - public AtElement(int line, int pos) { - super(line, pos); - } + public AtElement(int line, int pos) { + super(line, pos); + } - @Override - public int handleChar(char c) throws SyntaxError { - switch (state) { - case 0: - state = 1; - if (c == '@') { - return 1; - } else { - if (c == '.') { - state = 2; - } - throw new SyntaxError("Opening \"@\" missing.", 1); - } - case 1: - if (c == '.') { - state = 2; - return 1; - } else { - state = 4; - throw new SyntaxError("\".\" missing, found \"" + c + "\". This might also indicate a " + - "missing closure in the previous color code.", 0, true); - } - case 2: - state = 3; - if (Character.isAlphabetic(c)) { - return 1; - } else { - throw new SyntaxError("Identifier might be wrong.", 1, true); - } - case 3: - if (c == ';') { - state = 4; - return 1; - } else if (c == ' ') { - state = 4; - throw new SyntaxError("\";\" missing or wrong space.", 1); - } - break; - case 4: - if (c == '@') { - state = 5; - return 1; - } - break; - case 5: - if (c == '@') { - return 2; - } else { - throw new SyntaxError("Closing \"@\" missing.", 2); - } - default: - throw new UnknownStateException(state); - } - return 0; - } + @Override + public int handleChar(char c) throws SyntaxError { + switch (state) { + case 0: + state = 1; + if (c == '@') { + return 1; + } else { + if (c == '.') { + state = 2; + } + throw new SyntaxError("Opening \"@\" missing.", 1); + } + case 1: + if (c == '.') { + state = 2; + return 1; + } else { + state = 4; + throw new SyntaxError("\".\" missing, found \"" + c + "\". This might also indicate a " + + "missing closure in the previous color code.", 0, true); + } + case 2: + state = 3; + if (Character.isAlphabetic(c)) { + return 1; + } else { + throw new SyntaxError("Identifier might be wrong.", 1, true); + } + case 3: + if (c == ';') { + state = 4; + return 1; + } else if (c == ' ') { + state = 4; + throw new SyntaxError("\";\" missing or wrong space.", 1); + } + break; + case 4: + if (c == '@') { + state = 5; + return 1; + } + break; + case 5: + if (c == '@') { + return 2; + } else { + throw new SyntaxError("Closing \"@\" missing.", 2); + } + default: + throw new UnknownStateException(state); + } + return 0; + } - @Override - public String getShortDescription() { - StringBuilder builder = new StringBuilder(); - builder.append(line).append(":").append(pos).append(" "); - switch (state) { - case 0: - builder.append("@"); - break; - case 1: - builder.append("@@"); - break; - case 2: - builder.append("@@."); - break; - case 3: - builder.append("@@.???"); - break; - case 4: - builder.append("@@???"); - break; - case 5: - builder.append("@@???@"); - break; - default: - throw new UnknownStateException(state); - } - return builder.toString(); - } + @Override + public String getShortDescription() { + StringBuilder builder = new StringBuilder(); + builder.append(line).append(":").append(pos).append(" "); + switch (state) { + case 0: + builder.append("@"); + break; + case 1: + builder.append("@@"); + break; + case 2: + builder.append("@@."); + break; + case 3: + builder.append("@@.???"); + break; + case 4: + builder.append("@@???"); + break; + case 5: + builder.append("@@???@"); + break; + default: + throw new UnknownStateException(state); + } + return builder.toString(); + } } diff --git a/devTools/javaSanityCheck/src/element/CommentElement.java b/devTools/javaSanityCheck/src/element/CommentElement.java index 3a3cc12aff9f3c2e4b06cc7240d14824575cc96e..7906986e3dae2c3829d3ff5bd2bf76eddcbbd5c7 100644 --- a/devTools/javaSanityCheck/src/element/CommentElement.java +++ b/devTools/javaSanityCheck/src/element/CommentElement.java @@ -4,63 +4,63 @@ import org.arkerthan.sanityCheck.SyntaxError; import org.arkerthan.sanityCheck.UnknownStateException; public class CommentElement extends Element { - int state = 0; - /* - 0 - / - 1 - /*??? - 2 - /*???* - 3 - /%??? - 4 - /%???% - */ + int state = 0; + /* + 0 - / + 1 - /*??? + 2 - /*???* + 3 - /%??? + 4 - /%???% + */ - public CommentElement(int line, int pos) { - super(line, pos); - } + public CommentElement(int line, int pos) { + super(line, pos); + } - @Override - public int handleChar(char c) throws SyntaxError { - switch (state) { - case 0: - if (c == '*') { - state = 1; - } else if (c == '%') { - state = 3; - } else if (c == '>') { - throw new SyntaxError("XHTML style closure", 4, true); - } else { - return 4; - } - break; - case 1: - if (c == '*') { - state = 2; - } - break; - case 2: - if (c == '/') { - return 2; - } - state = 1; - break; - case 3: - if (c == '%') { - state = 4; - } - break; - case 4: - if (c == '/') { - return 2; - } - state = 3; - break; - default: - throw new UnknownStateException(state); - } - return 1; - } + @Override + public int handleChar(char c) throws SyntaxError { + switch (state) { + case 0: + if (c == '*') { + state = 1; + } else if (c == '%') { + state = 3; + } else if (c == '>') { + throw new SyntaxError("XHTML style closure", 4, true); + } else { + return 4; + } + break; + case 1: + if (c == '*') { + state = 2; + } + break; + case 2: + if (c == '/') { + return 2; + } + state = 1; + break; + case 3: + if (c == '%') { + state = 4; + } + break; + case 4: + if (c == '/') { + return 2; + } + state = 3; + break; + default: + throw new UnknownStateException(state); + } + return 1; + } - @Override - public String getShortDescription() { - return null; - } + @Override + public String getShortDescription() { + return null; + } } diff --git a/devTools/javaSanityCheck/src/element/Element.java b/devTools/javaSanityCheck/src/element/Element.java index b0f99fa904f66a6a9ebcecb5ffdfb7040493b08b..f80a85f8c1800ca4cb3422f9a29c91938900b39f 100644 --- a/devTools/javaSanityCheck/src/element/Element.java +++ b/devTools/javaSanityCheck/src/element/Element.java @@ -3,38 +3,38 @@ package org.arkerthan.sanityCheck.element; import org.arkerthan.sanityCheck.SyntaxError; public abstract class Element { - protected KnownElement k; - protected int line, pos; + protected KnownElement k; + protected int line, pos; - /** - * @param line Line the instance was created - * @param pos Position in line the instance was created - */ - protected Element(int line, int pos) { - this.line = line; - this.pos = pos; - } + /** + * @param line Line the instance was created + * @param pos Position in line the instance was created + */ + protected Element(int line, int pos) { + this.line = line; + this.pos = pos; + } - /** - * Parses a Char and returns an int depending on the state of the element - * 0 - the Element did nothing - * 1 - the Element changed state - * 2 - the Element is finished - * 3 - the Element is finished and a KnownHtmlElement was generated - * 4 - the Element is finished and the char is still open for use - * - * @param c - * @return - * @throws Error - */ - public abstract int handleChar(char c) throws SyntaxError; + /** + * Parses a Char and returns an int depending on the state of the element + * 0 - the Element did nothing + * 1 - the Element changed state + * 2 - the Element is finished + * 3 - the Element is finished and a KnownHtmlElement was generated + * 4 - the Element is finished and the char is still open for use + * + * @param c + * @return + * @throws Error + */ + public abstract int handleChar(char c) throws SyntaxError; - public KnownElement getKnownElement() { - return k; - } + public KnownElement getKnownElement() { + return k; + } - /** - * @return a short description usually based on state and position of the Element - */ - public abstract String getShortDescription(); + /** + * @return a short description usually based on state and position of the Element + */ + public abstract String getShortDescription(); } diff --git a/devTools/javaSanityCheck/src/element/KnownElement.java b/devTools/javaSanityCheck/src/element/KnownElement.java index 305be2fe65210b191d96ead352487b35e448ce39..b3164c2a5890f646bbf75207827049d7ae5d5658 100644 --- a/devTools/javaSanityCheck/src/element/KnownElement.java +++ b/devTools/javaSanityCheck/src/element/KnownElement.java @@ -4,28 +4,28 @@ import org.arkerthan.sanityCheck.SyntaxError; public abstract class KnownElement extends Element { - public KnownElement(int line, int pos) { - super(line, pos); - } + public KnownElement(int line, int pos) { + super(line, pos); + } - /** - * @return true, if it needs another Known Element to close it. - */ - public abstract boolean isOpening(); + /** + * @return true, if it needs another Known Element to close it. + */ + public abstract boolean isOpening(); - /** - * @return true if it closes another Element. - */ - public abstract boolean isClosing(); + /** + * @return true if it closes another Element. + */ + public abstract boolean isClosing(); - /** - * @param k Element to be checked - * @return true if given Element closes Element - */ - public abstract boolean isMatchingElement(KnownElement k); + /** + * @param k Element to be checked + * @return true if given Element closes Element + */ + public abstract boolean isMatchingElement(KnownElement k); - @Override - public int handleChar(char c) throws SyntaxError { - return 0; - } + @Override + public int handleChar(char c) throws SyntaxError { + return 0; + } } diff --git a/devTools/javaSanityCheck/src/element/KnownHtmlElement.java b/devTools/javaSanityCheck/src/element/KnownHtmlElement.java index d086a74bc547a0aa90520e50c4398f5cf6dc365e..51abacd60ac47a000fa47b2fe88f61ca8daf2bc6 100644 --- a/devTools/javaSanityCheck/src/element/KnownHtmlElement.java +++ b/devTools/javaSanityCheck/src/element/KnownHtmlElement.java @@ -2,40 +2,40 @@ package org.arkerthan.sanityCheck.element; public class KnownHtmlElement extends KnownElement { - private boolean opening; - private String statement; + private boolean opening; + private String statement; - public KnownHtmlElement(int line, int pos, boolean opening, String statement) { - super(line, pos); - this.opening = opening; - this.statement = statement; - } + public KnownHtmlElement(int line, int pos, boolean opening, String statement) { + super(line, pos); + this.opening = opening; + this.statement = statement; + } - @Override - public String getShortDescription() { - StringBuilder builder = new StringBuilder(); - builder.append('[').append(line).append(":").append(pos).append("] <"); - if (!opening) { - builder.append("/"); - } - return builder.append(statement).append(">").toString(); - } + @Override + public String getShortDescription() { + StringBuilder builder = new StringBuilder(); + builder.append('[').append(line).append(":").append(pos).append("] <"); + if (!opening) { + builder.append("/"); + } + return builder.append(statement).append(">").toString(); + } - @Override - public boolean isOpening() { - return opening; - } + @Override + public boolean isOpening() { + return opening; + } - @Override - public boolean isClosing() { - return !opening; - } + @Override + public boolean isClosing() { + return !opening; + } - @Override - public boolean isMatchingElement(KnownElement k) { - if (k instanceof KnownHtmlElement) { - return ((KnownHtmlElement) k).statement.equals(this.statement); - } - return false; - } + @Override + public boolean isMatchingElement(KnownElement k) { + if (k instanceof KnownHtmlElement) { + return ((KnownHtmlElement) k).statement.equals(this.statement); + } + return false; + } } diff --git a/devTools/javaSanityCheck/src/element/KnownLogicElement.java b/devTools/javaSanityCheck/src/element/KnownLogicElement.java index 502abde93a296c3dffb2391b75b08893aeecd2c5..994201c5a9ba40a4aea01252bb0ba6765a5841b7 100644 --- a/devTools/javaSanityCheck/src/element/KnownLogicElement.java +++ b/devTools/javaSanityCheck/src/element/KnownLogicElement.java @@ -7,111 +7,111 @@ import java.util.Arrays; import java.util.List; public class KnownLogicElement extends KnownElement { - private static final List<String> allowedTags = Arrays.asList("if", "elseif", "else"); - private final int state; - private boolean last; - /* - 0 - if - 1 - elseif - 2 - else - 3 - switch - 4 - case - 5 - default - */ + private static final List<String> allowedTags = Arrays.asList("if", "elseif", "else"); + private final int state; + private boolean last; + /* + 0 - if + 1 - elseif + 2 - else + 3 - switch + 4 - case + 5 - default + */ - public KnownLogicElement(int line, int pos, String tag, boolean last) { - this(line, pos, tag); - this.last = last; - } + public KnownLogicElement(int line, int pos, String tag, boolean last) { + this(line, pos, tag); + this.last = last; + } - public KnownLogicElement(int line, int pos, String tag) { - super(line, pos); - switch (tag) { - case "if": - state = 0; - break; - case "elseif": - state = 1; - break; - case "else": - state = 2; - break; - case "switch": - state = 3; - break; - case "case": - state = 4; - break; - case "default": - state = 5; - break; - default: - throw new DisallowedTagException(tag); - } - last = false; - } + public KnownLogicElement(int line, int pos, String tag) { + super(line, pos); + switch (tag) { + case "if": + state = 0; + break; + case "elseif": + state = 1; + break; + case "else": + state = 2; + break; + case "switch": + state = 3; + break; + case "case": + state = 4; + break; + case "default": + state = 5; + break; + default: + throw new DisallowedTagException(tag); + } + last = false; + } - @Override - public boolean isOpening() { - return !last; - } + @Override + public boolean isOpening() { + return !last; + } - @Override - public boolean isClosing() { - return (state != 0 && state != 3) || last; - } + @Override + public boolean isClosing() { + return (state != 0 && state != 3) || last; + } - @Override - public boolean isMatchingElement(KnownElement k) { - if (!(k instanceof KnownLogicElement)) { - return false; - } - KnownLogicElement l = (KnownLogicElement) k; - switch (state) { - case 0: - case 1: - return l.state == 1 || l.state == 2 || (l.state == 0 && l.last); - case 2: - return l.state == 0 && l.last; - case 3: - case 4: - return l.state == 3 || l.state == 4; - case 5: - return l.state == 3 && l.last; - default: - throw new UnknownStateException(state); - } - } + @Override + public boolean isMatchingElement(KnownElement k) { + if (!(k instanceof KnownLogicElement)) { + return false; + } + KnownLogicElement l = (KnownLogicElement) k; + switch (state) { + case 0: + case 1: + return l.state == 1 || l.state == 2 || (l.state == 0 && l.last); + case 2: + return l.state == 0 && l.last; + case 3: + case 4: + return l.state == 3 || l.state == 4; + case 5: + return l.state == 3 && l.last; + default: + throw new UnknownStateException(state); + } + } - @Override - public String getShortDescription() { - StringBuilder builder = new StringBuilder(); - builder.append("[").append(line).append(":").append(pos).append("] <<"); - if (last) { - builder.append('/'); - } - switch (state) { - case 0: - builder.append("if"); - break; - case 1: - builder.append("elseif"); - break; - case 2: - builder.append("else"); - break; - case 3: - builder.append("switch"); - break; - case 4: - builder.append("case"); - break; - case 5: - builder.append("default"); - break; - default: - throw new UnknownStateException(state); - } - return builder.append(">>").toString(); - } + @Override + public String getShortDescription() { + StringBuilder builder = new StringBuilder(); + builder.append("[").append(line).append(":").append(pos).append("] <<"); + if (last) { + builder.append('/'); + } + switch (state) { + case 0: + builder.append("if"); + break; + case 1: + builder.append("elseif"); + break; + case 2: + builder.append("else"); + break; + case 3: + builder.append("switch"); + break; + case 4: + builder.append("case"); + break; + case 5: + builder.append("default"); + break; + default: + throw new UnknownStateException(state); + } + return builder.append(">>").toString(); + } } diff --git a/devTools/javaSanityCheck/src/element/KnownTwineElement.java b/devTools/javaSanityCheck/src/element/KnownTwineElement.java index 24003fd00be0bb79aa6a01b2fbd2d9a91439ac6a..399fa5192181044e589ffd5d4222941b001f3066 100644 --- a/devTools/javaSanityCheck/src/element/KnownTwineElement.java +++ b/devTools/javaSanityCheck/src/element/KnownTwineElement.java @@ -2,40 +2,40 @@ package org.arkerthan.sanityCheck.element; public class KnownTwineElement extends KnownElement { - private boolean opening; - private String statement; + private boolean opening; + private String statement; - public KnownTwineElement(int line, int pos, boolean opening, String statement) { - super(line, pos); - this.opening = opening; - this.statement = statement; - } + public KnownTwineElement(int line, int pos, boolean opening, String statement) { + super(line, pos); + this.opening = opening; + this.statement = statement; + } - @Override - public String getShortDescription() { - StringBuilder builder = new StringBuilder(); - builder.append("[").append(line).append(":").append(pos).append("] <<"); - if (!opening) { - builder.append("/"); - } - return builder.append(statement).append(">>").toString(); - } + @Override + public String getShortDescription() { + StringBuilder builder = new StringBuilder(); + builder.append("[").append(line).append(":").append(pos).append("] <<"); + if (!opening) { + builder.append("/"); + } + return builder.append(statement).append(">>").toString(); + } - @Override - public boolean isOpening() { - return opening; - } + @Override + public boolean isOpening() { + return opening; + } - @Override - public boolean isClosing() { - return !opening; - } + @Override + public boolean isClosing() { + return !opening; + } - @Override - public boolean isMatchingElement(KnownElement k) { - if (k instanceof KnownTwineElement) { - return ((KnownTwineElement) k).statement.equals(this.statement); - } - return false; - } + @Override + public boolean isMatchingElement(KnownElement k) { + if (k instanceof KnownTwineElement) { + return ((KnownTwineElement) k).statement.equals(this.statement); + } + return false; + } } diff --git a/src/SpecialForce/SpecialForce.js b/src/SpecialForce/SpecialForce.js index 144bbe80a68815ab91d62097edf1adb1ef496bf1..9c48ecb64983d85fcabd96cfaffbca5ce77f6b3f 100644 --- a/src/SpecialForce/SpecialForce.js +++ b/src/SpecialForce/SpecialForce.js @@ -683,7 +683,7 @@ window.FlavourText = function(View) { if (S.AA >= 8) stealth=`The old skin has been replaced with a radar-absorbent material, making the aircraft difficult to pick up on radar.`; if (S.AA >= 9) scramble=`The VTOLs can scramble to react to any threat in under three minutes.`; if (S.AA >= 10) PAI=`A piloting AI has been installed, allowing the VTOLs to perform impossible maneuvers that cannot be done by a human pilot. This removes the need for a human in the aircraft altogether.`; - return `${group}. Several of the landing pads around $arcologies[0].name host groups of four fighters, ready to defend the arcology. ${scramble} The attack VTOL are currently ${W1} with a Gatling cannon${W2} ${W3}${support}. ${TAI} ${PAI} ${engines} ${lock} ${stealth}`; + return `${group}. Several of the landing pads around ${V.arcologies[0].name} host groups of four fighters, ready to defend the arcology. ${scramble} The attack VTOL are currently ${W1} with a Gatling cannon${W2} ${W3}${support}. ${TAI} ${PAI} ${engines} ${lock} ${stealth}`; } function TA() { @@ -730,7 +730,7 @@ window.FlavourText = function(View) { function AC() { let recom=`has been recommissioned from the Old World for ${V.SF.Lower}. It`, jets=`Formerly mothballed strike jets`, loc=``, radar=``, AAG=``, prop=``, torp=``, armor=``, power=``, scramble=``; - if (V.week % 6 === 0) { loc=`moored to the pier in the Naval Yard`; } else { loc=`patrolling the waters near $arcologies[0].name`; } + if (V.week % 6 === 0) { loc=`moored to the pier in the Naval Yard`; } else { loc=`patrolling the waters near ${V.arcologies[0].name}`; } if (S.AircraftCarrier >= 2) { radar=`The island's radar and comms have been improved.`; recom=``; } if (S.AircraftCarrier >= 3) AAG=`The antiair guns have been updated to automatically track and predict enemy aircraft movement.`; if (S.AircraftCarrier >= 4) jets=`Modern strike jets with state-of-the-art armaments`; diff --git a/src/SpecialForce/Upgrades.tw b/src/SpecialForce/Upgrades.tw index e1aaa7b15af009ee9869d00b0b82262811cd2770..b687b53da20f5270e3a0a6b563c6f9a7c5aa9338 100644 --- a/src/SpecialForce/Upgrades.tw +++ b/src/SpecialForce/Upgrades.tw @@ -1,5 +1,5 @@ :: Upgrades [nobr] - <br><br> <<if $SF.Size !== _max>> Total upgrade progress: <<print progress($SF.Size,_max)>> $SF.Size/_max(<<print ($SF.Size/_max).toFixed(2)>>%) <<if $SF.Size < 30>><br>//<<print (30-$SF.Size )>> more upgrades is needed untill the next tier unlocks.//<</if>> + <br><br> <<if $SF.Size !== _max>> Total upgrade progress: <<print progress($SF.Size,_max)>> $SF.Size/_max(<<print ($SF.Size/_max).toFixed(2)>>%) <<if $SF.Size < 30>><br>//<<print (30-$SF.Size )>> more upgrades is needed until the next tier unlocks.//<</if>> <<else>>There are no more upgrades available.<</if>> <<if $SF.Upgrade > 0 && ($SF.Size !== _max)>> <<set _cost = Math.ceil(Math.abs($cash*.05*(1.25+($SF.Size/1000))))>> diff --git a/src/cheats/PCCheatMenuCheatDatatypeCleanup.tw b/src/cheats/PCCheatMenuCheatDatatypeCleanup.tw index 928a415334cca34355d5cdfcf1bdc70eed2472a3..377239aaf99d4455ce6044a94e7c5a569479aeee 100644 --- a/src/cheats/PCCheatMenuCheatDatatypeCleanup.tw +++ b/src/cheats/PCCheatMenuCheatDatatypeCleanup.tw @@ -31,6 +31,8 @@ <<set $tempSlave.pregWeek = 0>> <</if>> <<run PCDatatypeCleanup()>> +<<set $upgradeMultiplierArcology = upgradeMultiplierArcology()>> +<<set $HackingSkillMultiplier = HackingSkillMultiplier()>> <<if $tempSlave.boobs == 0>> <<set $tempSlave.boobsBonus = 0>> diff --git a/src/cheats/mod_EditFSCheat.tw b/src/cheats/mod_EditFSCheat.tw index 434a64cf002347a1cacf655a8d7c414c462e2fee..83b314e537f52114d245c4e1ccd6ee43957519db 100644 --- a/src/cheats/mod_EditFSCheat.tw +++ b/src/cheats/mod_EditFSCheat.tw @@ -35,7 +35,7 @@ <<radiobutton "$arcologies[0].FSSupremacistRace" "semitic">> Semitic | <<radiobutton "$arcologies[0].FSSupremacistRace" "mixed race">> Mixed Race - <br>[[Apply and reset Racial Subjugationism|MOD_Edit FS Cheat][removeFS("FSSubjugationist")]] + <br>[[Apply and reset Racial Subjugationism|MOD_Edit FS Cheat][FutureSocieties.remove("FSSubjugationist")]] <br><br> @@ -71,7 +71,7 @@ <<radiobutton "$arcologies[0].FSSubjugationistRace" "semitic">> Semitic | <<radiobutton "$arcologies[0].FSSubjugationistRace" "mixed race">> Mixed Race - <br>[[Apply and reset Racial Supremacy|MOD_Edit FS Cheat][removeFS("FSSupremacist")]] + <br>[[Apply and reset Racial Supremacy|MOD_Edit FS Cheat][FutureSocieties.remove("FSSupremacist")]] <br><br> @@ -101,7 +101,7 @@ | <<radiobutton "$arcologies[0].FSGenderRadicalistLawFuta" 3>> 3 (Big butts and skilled buttholes pref.) | <<radiobutton "$arcologies[0].FSGenderRadicalistLawFuta" 4>> 4 (Trap pref.) - <br>[[Apply and reset Gender Traditionalism|MOD_Edit FS Cheat][removeFS("FSGenderFundamentalist")]] + <br>[[Apply and reset Gender Traditionalism|MOD_Edit FS Cheat][FutureSocieties.remove("FSGenderFundamentalist")]] <br><br> @@ -124,7 +124,7 @@ <<radiobutton "$arcologies[0].FSGenderFundamentalistSMR" 0>> 0 (Not passed.) | <<radiobutton "$arcologies[0].FSGenderFundamentalistSMR" 1>> 1 (Passed.) - <br>[[Apply and reset Gender Radicalism|MOD_Edit FS Cheat][removeFS("FSGenderRadicalist")]] + <br>[[Apply and reset Gender Radicalism|MOD_Edit FS Cheat][FutureSocieties.remove("FSGenderRadicalist")]] <<if $seePreg != 0>> <br><br> @@ -152,7 +152,7 @@ <<radiobutton "$arcologies[0].FSRepopulationFocusLaw" 0>> 0 (Not passed.) | <<radiobutton "$arcologies[0].FSRepopulationFocusLaw" 1>> 1 (Passed.) - <br>[[Apply and reset Eugenics|MOD_Edit FS Cheat][removeFS("FSRestart")]] + <br>[[Apply and reset Eugenics|MOD_Edit FS Cheat][FutureSocieties.remove("FSRestart")]] <br><br> @@ -175,7 +175,7 @@ <<radiobutton "$arcologies[0].FSRestartSMR" 0>> 0 (Not passed.) | <<radiobutton "$arcologies[0].FSRestartSMR" 1>> 1 (Passed.) - <br>[[Apply and reset Repopulation Efforts|MOD_Edit FS Cheat][removeFS("FSRepopulationFocus")]] + <br>[[Apply and reset Repopulation Efforts|MOD_Edit FS Cheat][FutureSocieties.remove("FSRepopulationFocus")]] <</if>> <br><br> @@ -199,7 +199,7 @@ <<radiobutton "$arcologies[0].FSPaternalistLaw" 0>> 0 (Not passed.) | <<radiobutton "$arcologies[0].FSPaternalistLaw" 1>> 1 (Passed.) - <br>[[Apply and reset Degradationism|MOD_Edit FS Cheat][removeFS("FSDegradationist")]] + <br>[[Apply and reset Degradationism|MOD_Edit FS Cheat][FutureSocieties.remove("FSDegradationist")]] <br><br> @@ -222,7 +222,7 @@ <<radiobutton "$arcologies[0].FSDegradationistLaw" 0>> 0 (Not passed.) | <<radiobutton "$arcologies[0].FSDegradationistLaw" 1>> 1 (Passed.) - <br>[[Apply and reset Paternalism|MOD_Edit FS Cheat][removeFS("FSPaternalist")]] + <br>[[Apply and reset Paternalism|MOD_Edit FS Cheat][FutureSocieties.remove("FSPaternalist")]] <br><br> @@ -245,7 +245,7 @@ <<radiobutton "$arcologies[0].FSBodyPuristLaw" 0>> 0 (Not passed.) | <<radiobutton "$arcologies[0].FSBodyPuristLaw" 1>> 1 (Passed.) - <br>[[Apply and reset Body Transformationism|MOD_Edit FS Cheat][removeFS("FSTransformationFetishist")]] + <br>[[Apply and reset Body Transformationism|MOD_Edit FS Cheat][FutureSocieties.remove("FSTransformationFetishist")]] <br><br> @@ -268,7 +268,7 @@ <<radiobutton "$arcologies[0].FSTransformationFetishistSMR" 0>> 0 (Not passed.) | <<radiobutton "$arcologies[0].FSTransformationFetishistSMR" 1>> 1 (Passed.) - <br>[[Apply and reset Body Purism|MOD_Edit FS Cheat][removeFS("FSBodyPurist")]] + <br>[[Apply and reset Body Purism|MOD_Edit FS Cheat][FutureSocieties.remove("FSBodyPurist")]] <br><br> @@ -292,7 +292,7 @@ <<radiobutton "$arcologies[0].FSYouthPreferentialistLaw" 0>> 0 (Not passed.) | <<radiobutton "$arcologies[0].FSYouthPreferentialistLaw" 1>> 1 (Passed.) - <br>[[Apply and reset Maturity Preferentialism|MOD_Edit FS Cheat][removeFS("FSMaturityPreferentialist")]] + <br>[[Apply and reset Maturity Preferentialism|MOD_Edit FS Cheat][FutureSocieties.remove("FSMaturityPreferentialist")]] <br><br> @@ -316,7 +316,7 @@ <<radiobutton "$arcologies[0].FSMaturityPreferentialistLaw" 0>> 0 (Not passed.) | <<radiobutton "$arcologies[0].FSMaturityPreferentialistLaw" 1>> 1 (Passed.) - <br>[[Apply and reset Youth Preferentialism|MOD_Edit FS Cheat][removeFS("FSYouthPreferentialist")]] + <br>[[Apply and reset Youth Preferentialism|MOD_Edit FS Cheat][FutureSocieties.remove("FSYouthPreferentialist")]] <br><br> @@ -339,7 +339,7 @@ <<radiobutton "$arcologies[0].FSSlimnessEnthusiastSMR" 0>> 0 (Not passed.) | <<radiobutton "$arcologies[0].FSSlimnessEnthusiastSMR" 1>> 1 (Passed.) - <br>[[Apply and reset Asset Expansionism|MOD_Edit FS Cheat][removeFS("FSAssetExpansionist")]] + <br>[[Apply and reset Asset Expansionism|MOD_Edit FS Cheat][FutureSocieties.remove("FSAssetExpansionist")]] <br><br> @@ -363,7 +363,7 @@ <<radiobutton "$arcologies[0].FSAssetExpansionistSMR" 0>> 0 (Not passed.) | <<radiobutton "$arcologies[0].FSAssetExpansionistSMR" 1>> 1 (Passed.) - <br>[[Apply and reset Slimness Enthusiasm|MOD_Edit FS Cheat][removeFS("FSSlimnessEnthusiast")]] + <br>[[Apply and reset Slimness Enthusiasm|MOD_Edit FS Cheat][FutureSocieties.remove("FSSlimnessEnthusiast")]] <br><br> @@ -409,7 +409,7 @@ <<radiobutton "$arcologies[0].FSPhysicalIdealistSMR" 0>> 0 (Not passed.) | <<radiobutton "$arcologies[0].FSPhysicalIdealistSMR" 1>> 1 (Passed.) - <br>[[Apply and reset Hedonistic Decadence|MOD_Edit FS Cheat][removeFS("FSHedonisticDecadence")]] + <br>[[Apply and reset Hedonistic Decadence|MOD_Edit FS Cheat][FutureSocieties.remove("FSHedonisticDecadence")]] <br><br> @@ -440,7 +440,7 @@ <<radiobutton "$arcologies[0].FSHedonisticDecadenceLaw2" 0>> 0 (Not passed.) | <<radiobutton "$arcologies[0].FSHedonisticDecadenceLaw2" 1>> 1 (Passed.) - <br>[[Apply and reset Physical Idealist|MOD_Edit FS Cheat][removeFS("FSPhysicalIdealist")]] + <br>[[Apply and reset Physical Idealist|MOD_Edit FS Cheat][FutureSocieties.remove("FSPhysicalIdealist")]] <br><br> @@ -486,7 +486,7 @@ <<radiobutton "$arcologies[0].FSRomanRevivalistLaw" 0>> 0 (Not passed.) | <<radiobutton "$arcologies[0].FSRomanRevivalistLaw" 1>> 1 (Passed.) - <br>[[Apply and reset other Revivalisms|MOD_Edit FS Cheat][removeFS("FSAztecRevivalist"), removeFS("FSEgyptianRevivalist"), removeFS("FSEdoRevivalist"), removeFS("FSArabianRevivalist"), removeFS("FSChineseRevivalist")]] + <br>[[Apply and reset other Revivalisms|MOD_Edit FS Cheat][FutureSocieties.remove("FSAztecRevivalist"), FutureSocieties.remove("FSEgyptianRevivalist"), FutureSocieties.remove("FSEdoRevivalist"), FutureSocieties.remove("FSArabianRevivalist"), FutureSocieties.remove("FSChineseRevivalist")]] <br><br> @@ -509,7 +509,7 @@ <<radiobutton "$arcologies[0].FSAztecRevivalistLaw" 0>> 0 (Not passed.) | <<radiobutton "$arcologies[0].FSAztecRevivalistLaw" 1>> 1 (Passed.) - <br>[[Apply and reset other Revivalisms|MOD_Edit FS Cheat][removeFS("FSRomanRevivalist"), removeFS("FSEgyptianRevivalist"), removeFS("FSEdoRevivalist"), removeFS("FSArabianRevivalist"), removeFS("FSChineseRevivalist")]] + <br>[[Apply and reset other Revivalisms|MOD_Edit FS Cheat][FutureSocieties.remove("FSRomanRevivalist"), FutureSocieties.remove("FSEgyptianRevivalist"), FutureSocieties.remove("FSEdoRevivalist"), FutureSocieties.remove("FSArabianRevivalist"), FutureSocieties.remove("FSChineseRevivalist")]] <br><br> @@ -532,7 +532,7 @@ <<radiobutton "$arcologies[0].FSEgyptianRevivalistLaw" 0>> 0 (Not passed.) | <<radiobutton "$arcologies[0].FSEgyptianRevivalistLaw" 1>> 1 (Passed.) - <br>[[Apply and reset other Revivalisms|MOD_Edit FS Cheat][removeFS("FSRomanRevivalist"), removeFS("FSAztecRevivalist"), removeFS("FSEdoRevivalist"), removeFS("FSArabianRevivalist"), removeFS("FSChineseRevivalist")]] + <br>[[Apply and reset other Revivalisms|MOD_Edit FS Cheat][FutureSocieties.remove("FSRomanRevivalist"), FutureSocieties.remove("FSAztecRevivalist"), FutureSocieties.remove("FSEdoRevivalist"), FutureSocieties.remove("FSArabianRevivalist"), FutureSocieties.remove("FSChineseRevivalist")]] <br><br> @@ -555,7 +555,7 @@ <<radiobutton "$arcologies[0].FSEdoRevivalistLaw" 0>> 0 (Not passed.) | <<radiobutton "$arcologies[0].FSEdoRevivalistLaw" 1>> 1 (Passed.) - <br>[[Apply and reset other Revivalisms|MOD_Edit FS Cheat][removeFS("FSRomanRevivalist"), removeFS("FSAztecRevivalist"), removeFS("FSEgyptianRevivalist"), removeFS("FSArabianRevivalist"), removeFS("FSChineseRevivalist")]] + <br>[[Apply and reset other Revivalisms|MOD_Edit FS Cheat][FutureSocieties.remove("FSRomanRevivalist"), FutureSocieties.remove("FSAztecRevivalist"), FutureSocieties.remove("FSEgyptianRevivalist"), FutureSocieties.remove("FSArabianRevivalist"), FutureSocieties.remove("FSChineseRevivalist")]] <br><br> @@ -578,7 +578,7 @@ <<radiobutton "$arcologies[0].FSArabianRevivalistLaw" 0>> 0 (Not passed.) | <<radiobutton "$arcologies[0].FSArabianRevivalistLaw" 1>> 1 (Passed.) - <br>[[Apply and reset other Revivalisms|MOD_Edit FS Cheat][removeFS("FSRomanRevivalist"), removeFS("FSAztecRevivalist"), removeFS("FSEgyptianRevivalist"), removeFS("FSEdoRevivalist"), removeFS("FSChineseRevivalist")]] + <br>[[Apply and reset other Revivalisms|MOD_Edit FS Cheat][FutureSocieties.remove("FSRomanRevivalist"), FutureSocieties.remove("FSAztecRevivalist"), FutureSocieties.remove("FSEgyptianRevivalist"), FutureSocieties.remove("FSEdoRevivalist"), FutureSocieties.remove("FSChineseRevivalist")]] <br><br> @@ -601,4 +601,4 @@ <<radiobutton "$arcologies[0].FSChineseRevivalistLaw" 0>> 0 (Not passed.) | <<radiobutton "$arcologies[0].FSChineseRevivalistLaw" 1>> 1 (Passed.) - <br>[[Apply and reset other Revivalisms|MOD_Edit FS Cheat][removeFS("FSRomanRevivalist"), removeFS("FSAztecRevivalist"), removeFS("FSEgyptianRevivalist"), removeFS("FSEdoRevivalist"), removeFS("FSArabianRevivalist")]] + <br>[[Apply and reset other Revivalisms|MOD_Edit FS Cheat][FutureSocieties.remove("FSRomanRevivalist"), FutureSocieties.remove("FSAztecRevivalist"), FutureSocieties.remove("FSEgyptianRevivalist"), FutureSocieties.remove("FSEdoRevivalist"), FutureSocieties.remove("FSArabianRevivalist")]] diff --git a/src/cheats/mod_EditFSCheatDatatypeCleanup.tw b/src/cheats/mod_EditFSCheatDatatypeCleanup.tw index 460a79ba8d52f964b4d619b9359b8b8c59e4b866..f0dc1eabfd1d3b10eb3c864d0c1c40eb882af4fb 100644 --- a/src/cheats/mod_EditFSCheatDatatypeCleanup.tw +++ b/src/cheats/mod_EditFSCheatDatatypeCleanup.tw @@ -141,7 +141,7 @@ <</if>> <<for _fscdc = 0; _fscdc < setup.FutureSocieties.length; _fscdc++>> <<if !($arcologies[0][setup.FutureSocieties[_fscdc]] > 0)>> - <<run removeFS(setup.FutureSocieties[_fscdc])>> + <<run FutureSocieties.remove(setup.FutureSocieties[_fscdc])>> <</if>> <</for>> diff --git a/src/events/intro/initNationalities.tw b/src/events/intro/initNationalities.tw index e4c1f257698a4d5a2336fbaac72fbb311d6b78c5..ed54a9c4fe997cd7e13325d014bff9c5682ba29e 100644 --- a/src/events/intro/initNationalities.tw +++ b/src/events/intro/initNationalities.tw @@ -26,7 +26,6 @@ <<set $trinkets.push("an artist's impression of an early arcology design")>> <<set $arcologyUpgrade.drones = 1, $arcologyUpgrade.hydro = 1>> <<set $secBots.active = 1, $secBots.troops = 30, $secBots.maxTroops = 30>> - <<set $upgradeMultiplierArcology = 0.6>> <<elseif $PC.career == "medicine">> <<set $trinkets.push("a framed postsurgical x-ray")>> <<set $surgeryCost = Math.trunc($surgeryCost/2)>> @@ -36,7 +35,6 @@ <<run repX(4000, "event")>> <<elseif $PC.career == "arcology owner">> <<set $trinkets.push("a miniature model of your first arcology")>> - <<set $upgradeMultiplierArcology = 0.8>> <<run repX(2000, "event")>> <<elseif $PC.career == "escort">> <<set $trinkets.push("a copy of the first porno you starred in")>> diff --git a/src/facilities/farmyard/futureAnimals.tw b/src/facilities/farmyard/futureAnimals.tw index dac46ad0138ac862ffc280ee6fd008d5174e2373..aa19e9d14c7a7552bc445e36ba69a88273361601 100644 --- a/src/facilities/farmyard/futureAnimals.tw +++ b/src/facilities/farmyard/futureAnimals.tw @@ -1,6 +1,6 @@ /* Putting them here because commenting them out was breaking for some reason */ -<<if $animalsBought.germanShepherds == 0>> + <<if $animalsBought.germanShepherds == 0>> <<link "Purchase German Shepherds" "FarmyardAnimals">><<set cashX(forceNeg(Math.trunc(20000*$upgradeMultiplierArcology)), "farmyard"), $animalsBought.germanShepherds = 1, $animalsBought.canines += 1, $canines.push("German Shepherds")>><</link>> <br> <<elseif $animalsBought.germanShepherds == 1>> @@ -108,7 +108,6 @@ <</if>> <br> <</if>> -<</if>> @@ -237,7 +236,6 @@ <br> <</if>> <</if>> -<</if>> @@ -367,4 +365,4 @@ //Set as active feline// <</if>> <br> - <</if>> \ No newline at end of file + <</if>> diff --git a/src/facilities/nursery/childSummary.tw b/src/facilities/nursery/childSummary.tw index 78449006c71ef6d6c5753beb58d866e9c3b713cb..c69071588e1d848fc05799662b5dc08b7dacc03c 100644 --- a/src/facilities/nursery/childSummary.tw +++ b/src/facilities/nursery/childSummary.tw @@ -95,10 +95,6 @@ <<switch _Pass>> <<case "Main">> - <<if $useSlaveSummaryTabs == 1>> - <<if $childAssignmentTab == "overview">> - <</if>> - <<if (_Child.choosesOwnClothes == 1) && (_Child.clothes == "choosing her own clothes")>> <<set _oldDevotion = _Child.devotion>> <<set _chosenClothes = saChoosesOwnClothes(_Child)>> diff --git a/src/interaction/cyberConfig.tw b/src/interaction/cyberConfig.tw index 3c327fc67cc1dcab062c4f93feb7db5b38940b80..eacceaf73b8e5ed7146bd85b92e3be3fa92335d1 100644 --- a/src/interaction/cyberConfig.tw +++ b/src/interaction/cyberConfig.tw @@ -157,7 +157,7 @@ <<if $stockpile.sexPTail > 0>>| [[Attach Pleasure Tail|cyberConfig][$temp = 8, $activeSlave.tail = "sex", $activeSlave.tailColor = "pink", $stockpile.sexPTail -= 1]]<</if>> <</if>> <<else>> - $He does not have a neural tail interface installed so you can not attach a tail. + $He does not have a neural tail interface installed so you cannot attach a tail. <</if>> <<if $activeSlave.tail == "mod">><br> $He currently has a modular tail, styled to look like diff --git a/src/js/futureSocietyJS.js b/src/js/futureSocietyJS.js new file mode 100644 index 0000000000000000000000000000000000000000..57b68a487060e7c04c5a8ba112554d9591871ec8 --- /dev/null +++ b/src/js/futureSocietyJS.js @@ -0,0 +1,112 @@ +window.FutureSocieties = (function() { + return { + remove: removeFS, + resetCredits: resetFSCredits + }; + + // call as FutureSocieties.remove(FS) + // FS must be a string (e.g. "FSPaternalist" or "FSDegradationist"). + function removeFS(FS) { + const V = State.variables; + const arcology = V.arcologies[0]; + const FSDecoration = FS + "Decoration"; + const FSSMR = FS + "SMR"; + let FSLaw = FS + "Law"; + if (arcology[FS] === undefined) { + console.log(`ERROR: bad FS reference, $arcologies[0].${FS} not defined`); + return; + } + + if (FS === "FSSupremacist" || FS === "FSSubjugationist") + FSLaw += "ME"; + if (FS !== "FSNull") + arcology[FSDecoration] = 20; + arcology[FS] = "unset"; + switch (FS) { + case "FSPaternalist": + arcology[FSLaw] = 0; + arcology[FSSMR] = 0; + V.slaveWatch = 0; + break; + case "FSDegradationist": + arcology[FSLaw] = 0; + arcology[FSSMR] = 0; + V.liveTargets = 0; + break; + case "FSGenderRadicalist": + arcology.FSGenderRadicalistLawBeauty = 0; + arcology.FSGenderRadicalistLawFuta = 0; + break; + case "FSGenderFundamentalist": + arcology.FSGenderFundamentalistLawBeauty = 0; + arcology.FSGenderFundamentalistLawBimbo = 0; + arcology.FSGenderFundamentalistSMR = 0; + break; + case "FSTransformationFetishist": + case "FSAssetExpansionist": + arcology[FSSMR] = 0; + break; + case "FSPhysicalIdealist": + arcology.FSPhysicalIdealistLaw = 0; + arcology.FSPhysicalIdealistSMR = 0; + arcology.FSPhysicalIdealistStrongFat = 0; + V.martialSchool = 0; + break; + case "FSHedonisticDecadence": + arcology.FSHedonisticDecadenceLaw = 0; + arcology.FSHedonisticDecadenceLaw2 = 0; + arcology.FSHedonisticDecadenceSMR = 0; + arcology.FSHedonisticDecadenceStrongFat = 0; + break; + case "FSChattelReligionist": + arcology.FSChattelReligionistLaw = 0; + arcology.FSChattelReligionistSMR = 0; + arcology.FSChattelReligionistCreed = 0; + V.subsidyChurch = 0; + break; + case "FSRepopulationFocus": + arcology[FSLaw] = 0; + arcology[FSSMR] = 0; + V.universalRulesChildrenBecomeBreeders = 0; + break; + case "FSRestart": + arcology[FSLaw] = 0; + arcology[FSSMR] = 0; + V.eliteOfficers = 0; + V.propOutcome = 0; + V.failedElite = 0; + break; + case "FSNull": + break; + default: // all others have one law and one SMR + arcology[FSLaw] = 0; + arcology[FSSMR] = 0; + break; + } + + FacilityDecorationCleanup(); + resetFSCredits(); + } + + function resetFSCredits() { + const V = State.variables; + let activeFS = 0; + for (let i = 0; i < setup.FutureSocieties.length; i++) { + if (V.arcologies[0][setup.FutureSocieties[i]] > 0) { + activeFS++; + } + } + if (V.arcologies[0].FSNull > 0) { // possibly recalculate for multiculturalism + activeFS--; + if (V.FSCreditCount === 4) + activeFS += V.arcologies[0].FSNull/25; + else if (V.FSCreditCount === 6) + activeFS += V.arcologies[0].FSNull/17; + else if (V.FSCreditCount === 7) + activeFS += V.arcologies[0].FSNull/15; + else + activeFS += V.arcologies[0].FSNull/20; + } + V.FSCredits = Math.max(Math.trunc(V.FSGotRepCredits - activeFS), 0); + } +})(); diff --git a/src/js/slaveStatsChecker.js b/src/js/slaveStatsChecker.js index c9fd17b4d5e24f359da2b6fabe0a11b82dee1d04..87ba3f18033a475d023a16a3a2c1a762dba89bf6 100644 --- a/src/js/slaveStatsChecker.js +++ b/src/js/slaveStatsChecker.js @@ -5,7 +5,7 @@ window.SlaveStatsChecker = (function() { piercingScore: piercingScore, tatScore: tatScore }; - + function hasLisp(slave) { if (State.variables.disableLisping === 1) { return false; diff --git a/src/js/storyJS.js b/src/js/storyJS.js index 1d9a97fd8aa7fc8669e6a5ad71795452e355a843..67101c00926a46acb0769f864892593c465c45ff 100644 --- a/src/js/storyJS.js +++ b/src/js/storyJS.js @@ -808,109 +808,6 @@ window.SoftenSexualFlaw = /** @param {App.Entity.SlaveState} slave */ function S slave.sexualFlaw = "none"; }; -window.removeFS = function(FS) { - const V = State.variables; - const arcology = V.arcologies[0]; - let FSDecoration = FS + "Decoration"; - let FSSMR = FS + "SMR"; - let FSLaw = FS + "Law"; - if (FS === "FSSupremacist" || FS === "FSSubjugationist") { - FSLaw += "ME"; - } - switch (FS) { - case "FSPaternalist": - arcology[FSLaw] = 0; - arcology[FSSMR] = 0; - V.slaveWatch = 0; - break; - case "FSDegradationist": - arcology[FSLaw] = 0; - arcology[FSSMR] = 0; - V.liveTargets = 0; - break; - case "FSGenderRadicalist": - arcology.FSGenderRadicalistLawBeauty = 0; - arcology.FSGenderRadicalistLawFuta = 0; - break; - case "FSGenderFundamentalist": - arcology.FSGenderFundamentalistLawBeauty = 0; - arcology.FSGenderFundamentalistLawBimbo = 0; - arcology.FSGenderFundamentalistSMR = 0; - break; - case "FSTransformationFetishist": - case "FSAssetExpansionist": - arcology[FSSMR] = 0; - break; - case "FSPhysicalIdealist": - arcology.FSPhysicalIdealistLaw = 0; - arcology.FSPhysicalIdealistSMR = 0; - arcology.FSPhysicalIdealistStrongFat = 0; - V.martialSchool = 0; - break; - case "FSHedonisticDecadence": - arcology.FSHedonisticDecadenceLaw = 0; - arcology.FSHedonisticDecadenceLaw2 = 0; - arcology.FSHedonisticDecadenceSMR = 0; - arcology.FSHedonisticDecadenceStrongFat = 0; - break; - case "FSChattelReligionist": - arcology.FSChattelReligionistLaw = 0; - arcology.FSChattelReligionistSMR = 0; - arcology.FSChattelReligionistCreed = 0; - V.subsidyChurch = 0; - break; - case "FSRepopulationFocus": - arcology[FSLaw] = 0; - arcology[FSSMR] = 0; - V.universalRulesChildrenBecomeBreeders = 0; - break; - case "FSRestart": - arcology[FSLaw] = 0; - arcology[FSSMR] = 0; - V.eliteOfficers = 0; - break; - case "FSNull": - break; - default: /* all others have one law and one SMR */ - arcology[FSLaw] = 0; - arcology[FSSMR] = 0; - break; - } - if (FS !== "FSNull") { - arcology[FSDecoration] = 20; - if (FS === "FSRestart") { - V.propOutcome = 0; - V.failedElite = 0; - } - } - arcology[FS] = "unset"; - FacilityDecorationCleanup(); - resetFSCredits(); -}; - -window.resetFSCredits = function() { - const V = State.variables; - let activeFS = 0; - for (let i = 0; i < setup.FutureSocieties.length; i++) { - if (V.arcologies[0][setup.FutureSocieties[i]] > 0) { - activeFS++; - } - } - if (V.arcologies[0].FSNull > 0) { /* possibly recalculate for multiculturalism */ - activeFS--; - if (V.FSCreditCount === 4) { - activeFS += V.arcologies[0].FSNull/25; - } else if (V.FSCreditCount === 6) { - activeFS += V.arcologies[0].FSNull/17; - } else if (V.FSCreditCount === 7) { - activeFS += V.arcologies[0].FSNull/15; - } else { - activeFS += V.arcologies[0].FSNull/20; - } - } - V.FSCredits = Math.max(Math.trunc(V.FSGotRepCredits - activeFS), 0); -}; - window.generatePlayerPronouns = function(PC) { if (PC.title === 0) { PC.pronoun = "she"; @@ -977,3 +874,84 @@ window.generateAssistantPronouns = function() { V.marketAssistantPronouns.noun = "girl"; } }; + +window.printTrinkets = function printTrinkets() { + function trinketPluralReplacer(desc) { + switch (desc) { + /* not supported + best in show ribbons + napkins + saPorn trinkets + wedding photos + */ + // should never have plurals + case "a collection of diplomas from expensive schools": + case "a framed low denomination piece of paper money from your native country": + case "a battered old assault rifle": + case "a framed picture of a slave with her sale price scrawled across the bottom": + case "an artist's impression of an early arcology design": + case "a framed copy of the first news story featuring yourself": + case "a miniature model of your first arcology": + case "a copy of the first porno you starred in": + case "a framed picture of your late Master": + case "your favorite handgun, whose sight has instilled fear in many": + case "a news clipping of your first successful live hack": + case "a damaged plate carrier bearing Daughters of Liberty insignia": + case "a Daughters of Liberty flag that once hung in their forward command post within your arcology": + case "a Daughters of Liberty brassard": + case "a shot-torn flag of the failed nation whose militants attacked the Free City": + return desc; + // manual replacement + case "a thank-you note from a MILF tourist whom you made feel welcome in the arcology": + return "several thank-you notes from MILF tourists whom you made feel welcome in the arcology"; + // replacement by groups + default: + let r = desc; + if (desc.endsWith("citizen")) { // will not reduce spam from different future societies + r = r.replace("message", "messages"); + r = r.replace("from a", "from"); + r = r.replace("a ", "several "); + r = r.replace("citizen", "citizens"); + r = r.replace("number", "numbers"); + r = r.replace("test", "tests"); + } else if (desc.endsWith("acquaintance")) { + r = r.replace("note", "notes"); + r = r.replace("from a", "from"); + r = r.replace("a ", "several "); + r = r.replace("owner", "owners"); + } + return r; + } + } + + if (State.variables.trinkets.length === 0) + return ''; + + const trinkets = weightedArray2HashMap(State.variables.trinkets); + let trinketString = []; + let plurals = false; + + for (let trinketDesc in trinkets) { + if (trinkets[trinketDesc] === 1) { + trinketString.push(trinketDesc); + } else if (trinkets[trinketDesc] > 1) { + trinketString.push(trinketPluralReplacer(trinketDesc)); + plurals = true; + } + } + + // depending on length of trinketString, add necessary conjunctions + if (trinketString.length === 1) { + if (plurals === false) { + trinketString = `a single item: ${trinketString[0]}`; + } else { + trinketString = trinketString[0]; + } + } else if (trinketString.length === 2 && plurals === false) { + trinketString = `a couple of items: ${trinketString[0]}, and ${trinketString[1]}`; + } else { + trinketString[trinketString.length - 1] = "and " + trinketString[trinketString.length - 1]; + trinketString = trinketString.join(", "); + } + return `There's a display case behind your desk, with ${trinketString}.`; +}; diff --git a/src/js/utilJS.js b/src/js/utilJS.js index 752971d503bb5094c9839831dcd348fd34cbda57..17431b10bdaa9c0f91cba21be764550f6a9695a8 100644 --- a/src/js/utilJS.js +++ b/src/js/utilJS.js @@ -1732,3 +1732,34 @@ window.SkillIncrease = (function() { Entertain: EntertainSkillIncrease }; })(); + +window.upgradeMultiplierArcology = function() { + const V = State.variables; + if (V.PC.career === "engineer" || (V.arcologies[0].FSRestartDecoration >= 100 && V.eugenicsFullControl === 0) ) { + return 0.6; + } else if (V.PC.engineering <= -100) { + return 1.5; + } else if (V.PC.engineering <= -75) { + return 1.35; + } else if (V.PC.engineering <= -50) { + return 1.25; + } else if (V.PC.engineering <= -25) { + return 1.15; + } else if (V.PC.engineering < 0) { + return 1.10; + } else if (V.PC.engineering === 0) { + return 1; + } else if (V.PC.engineering <= 10) { + return 0.97; + } else if (V.PC.engineering <= 25) { + return 0.95; + } else if (V.PC.engineering <= 50) { + return 0.90; + } else if (V.PC.engineering <= 75) { + return 0.85; + } else if (V.PC.engineering < 100) { + return 0.83; + } else if (V.PC.engineering >= 100 || V.PC.career === "arcology owner") { + return 0.80; + } +}; \ No newline at end of file diff --git a/src/js/walkPastJS.js b/src/js/walkPastJS.js index 39f6a270a8365e934fe81ae83ab847d4714516e9..745fd0c905ff883e8e5d29d742ac3c8646751e5a 100644 --- a/src/js/walkPastJS.js +++ b/src/js/walkPastJS.js @@ -1965,7 +1965,7 @@ window.boobWatch = function(slave) { case "a scalemail bikini": t += `${His} scalemail bikini covers `; if (slave.boobs < 300) { - t += `all of $his flat chest.`; + t += `all of ${his} flat chest.`; } else if (slave.boobs < 700) { t += `${his} breasts entirely.`; } else if (slave.boobs < 1500) { diff --git a/src/pregmod/eliteTakeOverResult.tw b/src/pregmod/eliteTakeOverResult.tw index dccc19a952106e372614f6ffa3b125d4573c667a..217375157a756110bad97acd413bc07e60455148 100644 --- a/src/pregmod/eliteTakeOverResult.tw +++ b/src/pregmod/eliteTakeOverResult.tw @@ -210,4 +210,4 @@ <</if>> /* clean up */ -<<set $failedElite = 0, $eugenicsFullControl = 1, $upgradeMultiplierArcology = 1>> +<<set $failedElite = 0, $eugenicsFullControl = 1>> diff --git a/src/pregmod/manageCorporation.tw b/src/pregmod/manageCorporation.tw index 958fdb839754b959cfd7ac22cfb60aa870ece4ee..c85814df18974ba4c7e6ea9e102749c95ab8335f 100644 --- a/src/pregmod/manageCorporation.tw +++ b/src/pregmod/manageCorporation.tw @@ -819,7 +819,7 @@ __Division Management__ <<elseif $corpDivTrainSurgerySwitch == 1 && $corpDivTrainSurgeryTimer < 5>> <br>You can sell these slaves on the market. [[Sell 1|Manage Corporation][$corpCash += Math.trunc((26 + $corpDivTrainSurgeryTimer * 1.6) * menialSlaveCost()), $corpDivTrainSlaves2 -= 1, $menialDemandFactor -= 1, $corpRev += Math.trunc((26 + $corpDivTrainSurgeryTimer * 1.6) * menialSlaveCost())]] <<if $corpDivTrainSlaves2 >= 10>> - | [[Sell 10|Manage Corporation][$corpCash += Math.trunc((26 +\ $corpDivTrainSurgeryTimer * 1.6) * 10 * menialSlaveCost(-10)), $corpDivTrainSlaves2 -= 10, $menialDemandFactor -= 10, $corpRev += Math.trunc((26 + $corpDivTrainSurgeryTimer * 1.6) * 10 * menialSlaveCost())]] + | [[Sell 10|Manage Corporation][$corpCash += Math.trunc((26 + $corpDivTrainSurgeryTimer * 1.6) * 10 * menialSlaveCost(-10)), $corpDivTrainSlaves2 -= 10, $menialDemandFactor -= 10, $corpRev += Math.trunc((26 + $corpDivTrainSurgeryTimer * 1.6) * 10 * menialSlaveCost())]] <</if>> <<if $corpDivTrainSlaves2 >= 100>> | [[Sell 100|Manage Corporation][$corpCash += Math.trunc((26 + $corpDivTrainSurgeryTimer * 1.6) * 100 * menialSlaveCost(-100)), $corpDivTrainSlaves2 -= 100, $menialDemandFactor -= 100, $corpRev += Math.trunc((26 + $corpDivTrainSurgeryTimer * 1.6) * 100 * menialSlaveCost())]] diff --git a/src/uncategorized/BackwardsCompatibility.tw b/src/uncategorized/BackwardsCompatibility.tw index 3729710f4963f663a9b5e49c18e7c1d8eb9be77b..c5484f2bba9b4df0b83bd2eff46a5a529b3b6320 100644 --- a/src/uncategorized/BackwardsCompatibility.tw +++ b/src/uncategorized/BackwardsCompatibility.tw @@ -2092,7 +2092,6 @@ Setting missing global variables: <<if ndef $trinkets>> <<set $trinkets = []>> - <<set $upgradeMultiplierArcology = 1>> <<set $upgradeMultiplierMedicine = 1>> <<if $PC.career == "wealth">> <<set $trinkets.push("a collection of diplomas from expensive schools")>> @@ -2104,7 +2103,6 @@ Setting missing global variables: <<set $trinkets.push("a framed picture of a slave with her sale price scrawled across the bottom")>> <<elseif $PC.career == "engineer">> <<set $trinkets.push("an artist's impression of an early arcology design")>> - <<set $upgradeMultiplierArcology = 0.6>> <<elseif $PC.career == "medicine">> <<set $trinkets.push("a framed postsurgical x-ray")>> <<set $upgradeMultiplierMedicine = 0.8>> @@ -3566,6 +3564,7 @@ Done! <</if>> <<set $HackingSkillMultiplier = HackingSkillMultiplier()>> +<<set $upgradeMultiplierArcology = upgradeMultiplierArcology()>> /* reset NaNArray after BC is run */ -<<set $NaNArray = findNaN()>> +<<set $NaNArray = findNaN()>> \ No newline at end of file diff --git a/src/uncategorized/costsWidgets.tw b/src/uncategorized/costsWidgets.tw index b952e9b8177fddd9132b3e0ed8fe885a045eb3f5..2fbf44cfbdda9715a8bfd4320a02313d3ab6cbe1 100644 --- a/src/uncategorized/costsWidgets.tw +++ b/src/uncategorized/costsWidgets.tw @@ -414,7 +414,7 @@ You bought $him for: @@.red;<<print cashFormat($args[0].slaveCost)>>@@. <<set _Cost = $args[0].slaveCost>> <<elseif $args[0].slaveCost == 0>> - You spent nothing to aquire $him. + You spent nothing to acquire $him. <<set _Cost = $args[0].slaveCost>> <<else>> You have no record of how much <<if $args[0].origin != 0>>this<<else>>$he originally<</if>> cost. diff --git a/src/uncategorized/customSlave.tw b/src/uncategorized/customSlave.tw index ed2ac67c84c2c131058b4536485cfc1a95865d1b..08c6f865eca42d3e25ae23ce32715538ca827a56 100644 --- a/src/uncategorized/customSlave.tw +++ b/src/uncategorized/customSlave.tw @@ -458,8 +458,8 @@ <<if $customSlave.weight == -50>>Very thin. <<elseif $customSlave.weight == -15>>Thin. <<elseif $customSlave.weight == 0>>Average weight. -<<elseif $customSlave.weight == 15>>Chubby. -<<elseif $customSlave.weight == 50>>Plump. +<<elseif $customSlave.weight == 15>>Plush. +<<elseif $customSlave.weight == 50>>Chubby. <<elseif $customSlave.weight == 100>>Fat. <<elseif $customSlave.weight == 150>>Very Fat. <<else>>Immobile. @@ -480,12 +480,12 @@ <<CustomSlaveWeight>> <</link>> | -<<link "Chubby">> +<<link "Plush">> <<set $customSlave.weight = 15>> <<CustomSlaveWeight>> <</link>> | -<<link "Plump">> +<<link "Chubby">> <<set $customSlave.weight = 50>> <<CustomSlaveWeight>> <</link>> diff --git a/src/uncategorized/fsDevelopments.tw b/src/uncategorized/fsDevelopments.tw index 60e018b48d914a42b862f4814831669101c99a3d..a36258e4325634e3327dc3365155b4aa62d8a03a 100644 --- a/src/uncategorized/fsDevelopments.tw +++ b/src/uncategorized/fsDevelopments.tw @@ -695,7 +695,7 @@ $arcologies[0].name is unconvinced of $arcologies[0].FSSupremacistRace superiority. <</if>> <<if $arcologies[0].FSSupremacist < 0>> - <<run removeFS("FSSupremacist")>> + <<run FutureSocieties.remove("FSSupremacist")>> <<if $assistantFSAppearance == "supremacist">><<set $assistantFSAppearance = "default">><</if>> <<ClearFacilityDecorations>> @@.red;Your future society project has failed:@@ your citizens were repelled from your idea more than they were attracted to it. @@.yellow;You may select another option, or elect to try again.@@ @@ -725,7 +725,7 @@ $arcologies[0].name is unconvinced of the inferiority of $arcologies[0].FSSubjugationistRace people. <</if>> <<if $arcologies[0].FSSubjugationist < 0>> - <<run removeFS("FSSubjugationist")>> + <<run FutureSocieties.remove("FSSubjugationist")>> <<if $assistantFSAppearance == "subjugationist">><<set $assistantFSAppearance = "default">><</if>> <<ClearFacilityDecorations>> @@.red;Your future society project has failed:@@ your citizens were repelled from your idea more than they were attracted to it. @@.yellow;You may select another option, or elect to try again.@@ @@ -755,7 +755,7 @@ $arcologies[0].name is unconvinced that all women should be pregnant. <</if>> <<if $arcologies[0].FSRepopulationFocus < 0>> - <<run removeFS("FSRepopulationFocus")>> + <<run FutureSocieties.remove("FSRepopulationFocus")>> <<if $assistantFSAppearance == "repopulation focus">><<set $assistantFSAppearance = "default">><</if>> <<ClearFacilityDecorations>> @@.red;Your future society project has failed:@@ your citizens were repelled from your idea more than they were attracted to it. @@.yellow;You may select another option, or elect to try again.@@ @@ -785,7 +785,7 @@ $arcologies[0].name is unconvinced that only the elite should reproduce. <</if>> <<if $arcologies[0].FSRestart < 0 && $arcologies[0].FSRestartDecoration != 100>> - <<run removeFS("FSRestart")>> + <<run FutureSocieties.remove("FSRestart")>> <<if $assistantFSAppearance == "eugenics">><<set $assistantFSAppearance = "default">><</if>> <<ClearFacilityDecorations>> @@.red;Your future society project has failed:@@ your citizens were repelled from your idea more than they were attracted to it. @@.yellow;You may select another option, or elect to try again.@@ @@ -815,7 +815,7 @@ $arcologies[0].name is unconvinced of the need to redefine gender around power. <</if>> <<if $arcologies[0].FSGenderRadicalist < 0>> - <<run removeFS("FSGenderRadicalist")>> + <<run FutureSocieties.remove("FSGenderRadicalist")>> <<if $assistantFSAppearance == "gender radicalist">><<set $assistantFSAppearance = "default">><</if>> <<ClearFacilityDecorations>> @@.red;Your future society project has failed:@@ your citizens were repelled from your idea more than they were attracted to it. @@.yellow;You may select another option, or elect to try again.@@ @@ -845,7 +845,7 @@ $arcologies[0].name is unconvinced of the need to preserve traditional gender roles. <</if>> <<if $arcologies[0].FSGenderFundamentalist < 0>> - <<run removeFS("FSGenderFundamentalist")>> + <<run FutureSocieties.remove("FSGenderFundamentalist")>> <<if $assistantFSAppearance == "gender fundamentalist">><<set $assistantFSAppearance = "default">><</if>> <<ClearFacilityDecorations>> @@.red;Your future society project has failed:@@ your citizens were repelled from your idea more than they were attracted to it. @@.yellow;You may select another option, or elect to try again.@@ @@ -875,7 +875,7 @@ $arcologies[0].name is unconvinced of the vision of a well-bred race of slaves. <</if>> <<if $arcologies[0].FSPaternalist < 0>> - <<run removeFS("FSPaternalist")>> + <<run FutureSocieties.remove("FSPaternalist")>> <<if $assistantFSAppearance == "paternalist">><<set $assistantFSAppearance = "default">><</if>> <<ClearFacilityDecorations>> @@.red;Your future society project has failed:@@ your citizens were repelled from your idea more than they were attracted to it. @@.yellow;You may select another option, or elect to try again.@@ @@ -905,7 +905,7 @@ $arcologies[0].name is unconvinced that slaves are not human and should be thoroughly degraded. <</if>> <<if $arcologies[0].FSDegradationist < 0>> - <<run removeFS("FSDegradationist")>> + <<run FutureSocieties.remove("FSDegradationist")>> <<if $assistantFSAppearance == "degradationist">><<set $assistantFSAppearance = "default">><</if>> <<ClearFacilityDecorations>> @@.red;Your future society project has failed:@@ your citizens were repelled from your idea more than they were attracted to it. @@.yellow;You may select another option, or elect to try again.@@ @@ -935,7 +935,7 @@ $arcologies[0].name is unconvinced of the unattractive nature of implants. <</if>> <<if $arcologies[0].FSBodyPurist < 0>> - <<run removeFS("FSBodyPurist")>> + <<run FutureSocieties.remove("FSBodyPurist")>> <<if $assistantFSAppearance == "body purist">><<set $assistantFSAppearance = "default">><</if>> <<ClearFacilityDecorations>> @@.red;Your future society project has failed:@@ your citizens were repelled from your idea more than they were attracted to it. @@.yellow;You may select another option, or elect to try again.@@ @@ -963,7 +963,7 @@ $arcologies[0].name is unconvinced about the attractiveness of implants. <</if>> <<if $arcologies[0].FSTransformationFetishist < 0>> - <<run removeFS("FSTransformationFetishist")>> + <<run FutureSocieties.remove("FSTransformationFetishist")>> <<if $assistantFSAppearance == "transformation fetishist">><<set $assistantFSAppearance = "default">><</if>> <<ClearFacilityDecorations>> @@.red;Your future society project has failed:@@ your citizens were repelled from your idea more than they were attracted to it. @@.yellow;You may select another option, or elect to try again.@@ @@ -991,7 +991,7 @@ $arcologies[0].name is unconvinced about your preference for older ladies. <</if>> <<if $arcologies[0].FSMaturityPreferentialist < 0>> - <<run removeFS("FSMaturityPreferentialist")>> + <<run FutureSocieties.remove("FSMaturityPreferentialist")>> <<if $assistantFSAppearance == "maturity preferentialist">><<set $assistantFSAppearance = "default">><</if>> <<ClearFacilityDecorations>> @@.red;Your future society project has failed:@@ your citizens were repelled from your idea more than they were attracted to it. @@.yellow;You may select another option, or elect to try again.@@ @@ -1019,7 +1019,7 @@ $arcologies[0].name is unconvinced about your preference for young women. <</if>> <<if $arcologies[0].FSYouthPreferentialist < 0>> - <<run removeFS("FSYouthPreferentialist")>> + <<run FutureSocieties.remove("FSYouthPreferentialist")>> <<if $assistantFSAppearance == "youth preferentialist">><<set $assistantFSAppearance = "default">><</if>> <<ClearFacilityDecorations>> @@.red;Your future society project has failed:@@ your citizens were repelled from your idea more than they were attracted to it. @@.yellow;You may select another option, or elect to try again.@@ @@ -1047,7 +1047,7 @@ $arcologies[0].name is unconvinced about your preference for slim slaves with girlish figures. <</if>> <<if $arcologies[0].FSSlimnessEnthusiast < 0>> - <<run removeFS("FSSlimnessEnthusiast")>> + <<run FutureSocieties.remove("FSSlimnessEnthusiast")>> <<if $assistantFSAppearance == "slimness enthusiast">><<set $assistantFSAppearance = "default">><</if>> <<ClearFacilityDecorations>> @@.red;Your future society project has failed:@@ your citizens were repelled from your idea more than they were attracted to it. @@.yellow;You may select another option, or elect to try again.@@ @@ -1077,7 +1077,7 @@ $arcologies[0].name is unconvinced that all tits and asses should be bigger. <</if>> <<if $arcologies[0].FSAssetExpansionist < 0>> - <<run removeFS("FSAssetExpansionist")>> + <<run FutureSocieties.remove("FSAssetExpansionist")>> <<if $assistantFSAppearance == "asset expansionist">><<set $assistantFSAppearance = "default">><</if>> <<ClearFacilityDecorations>> @@.red;Your future society project has failed:@@ your citizens were repelled from your idea more than they were attracted to it. @@.yellow;You may select another option, or elect to try again.@@ @@ -1107,7 +1107,7 @@ $arcologies[0].name is unconvinced that slaves should be milked. <</if>> <<if $arcologies[0].FSPastoralist < 0>> - <<run removeFS("FSPastoralist")>> + <<run FutureSocieties.remove("FSPastoralist")>> <<if $assistantFSAppearance == "pastoralist">><<set $assistantFSAppearance = "default">><</if>> <<ClearFacilityDecorations>> @@.red;Your future society project has failed:@@ your citizens were repelled from your idea more than they were attracted to it. @@.yellow;You may select another option, or elect to try again.@@ @@ -1137,7 +1137,7 @@ $arcologies[0].name is unconvinced that all slaves should be tall and strong. <</if>> <<if $arcologies[0].FSPhysicalIdealist < 0>> - <<run removeFS("FSPhysicalIdealist")>> + <<run FutureSocieties.remove("FSPhysicalIdealist")>> <<if $assistantFSAppearance == "physical idealist">><<set $assistantFSAppearance = "default">><</if>> <<ClearFacilityDecorations>> @@.red;Your future society project has failed:@@ your citizens were repelled from your idea more than they were attracted to it. @@.yellow;You may select another option, or elect to try again.@@ @@ -1167,7 +1167,7 @@ $arcologies[0].name is unconvinced that all slaves should be soft and laid-back. <</if>> <<if $arcologies[0].FSHedonisticDecadence < 0>> - <<run removeFS("FSHedonisticDecadence")>> + <<run FutureSocieties.remove("FSHedonisticDecadence")>> <<if $assistantFSAppearance == "hedonistic decadence">><<set $assistantFSAppearance = "default">><</if>> <<ClearFacilityDecorations>> @@.red;Your future society project has failed:@@ your citizens were repelled from your idea more than they were attracted to it. @@.yellow;You may select another option, or elect to try again.@@ @@ -1197,7 +1197,7 @@ $arcologies[0].name is unconvinced of a version of religion that emphasizes slaveholding traditions. <</if>> <<if $arcologies[0].FSChattelReligionist < 0>> - <<run removeFS("FSChattelReligionist")>> + <<run FutureSocieties.remove("FSChattelReligionist")>> <<if $assistantFSAppearance == "chattel religionist">><<set $assistantFSAppearance = "default">><</if>> <<ClearFacilityDecorations>> @@.red;Your future society project has failed:@@ your citizens were repelled from your idea more than they were attracted to it. @@.yellow;You may select another option, or elect to try again.@@ @@ -1227,7 +1227,7 @@ $arcologies[0].name is unconvinced of the wisdom of your project to build a new Rome. <</if>> <<if $arcologies[0].FSRomanRevivalist < 0>> - <<run removeFS("FSRomanRevivalist")>> + <<run FutureSocieties.remove("FSRomanRevivalist")>> <<if $assistantFSAppearance == "roman revivalist">><<set $assistantFSAppearance = "default">><</if>> <<ClearFacilityDecorations>> @@.red;Your future society project has failed:@@ your citizens were repelled from your idea more than they were attracted to it. @@.yellow;You may select another option, or elect to try again.@@ @@ -1257,7 +1257,7 @@ $arcologies[0].name is unconvinced of the wisdom of your project to build a new Aztec Empire. <</if>> <<if $arcologies[0].FSAztecRevivalist < 0>> - <<run removeFS("FSAztecRevivalist")>> + <<run FutureSocieties.remove("FSAztecRevivalist")>> <<if $assistantFSAppearance == "aztec revivalist">><<set $assistantFSAppearance = "default">><</if>> <<ClearFacilityDecorations>> @@.red;Your future society project has failed:@@ your citizens were repelled from your idea more than they were attracted to it. @@.yellow;You may select another option, or elect to try again.@@ @@ -1287,7 +1287,7 @@ $arcologies[0].name is unconvinced of the wisdom of your project to build a new land of the Pharaohs. <</if>> <<if $arcologies[0].FSEgyptianRevivalist < 0>> - <<run removeFS("FSEgyptianRevivalist")>> + <<run FutureSocieties.remove("FSEgyptianRevivalist")>> <<if $assistantFSAppearance == "egyptian revivalist">><<set $assistantFSAppearance = "default">><</if>> <<ClearFacilityDecorations>> @@.red;Your future society project has failed:@@ your citizens were repelled from your idea more than they were attracted to it. @@.yellow;You may select another option, or elect to try again.@@ @@ -1317,7 +1317,7 @@ $arcologies[0].name is unconvinced of the wisdom of your project to build a new Edo Japan. <</if>> <<if $arcologies[0].FSEdoRevivalist < 0>> - <<run removeFS("FSEdoRevivalist")>> + <<run FutureSocieties.remove("FSEdoRevivalist")>> <<if $assistantFSAppearance == "edo revivalist">><<set $assistantFSAppearance = "default">><</if>> <<ClearFacilityDecorations>> @@.red;Your future society project has failed:@@ your citizens were repelled from your idea more than they were attracted to it. @@.yellow;You may select another option, or elect to try again.@@ @@ -1347,7 +1347,7 @@ $arcologies[0].name is unconvinced of the wisdom of your project to build a new Sultanate. <</if>> <<if $arcologies[0].FSArabianRevivalist < 0>> - <<run removeFS("FSArabianRevivalist")>> + <<run FutureSocieties.remove("FSArabianRevivalist")>> <<if $assistantFSAppearance == "arabian revivalist">><<set $assistantFSAppearance = "default">><</if>> <<ClearFacilityDecorations>> @@.red;Your future society project has failed:@@ your citizens were repelled from your idea more than they were attracted to it. @@.yellow;You may select another option, or elect to try again.@@ @@ -1377,7 +1377,7 @@ $arcologies[0].name is unconvinced of the wisdom of your pursuit of the Mandate of Heaven. <</if>> <<if $arcologies[0].FSChineseRevivalist < 0>> - <<run removeFS("FSChineseRevivalist")>> + <<run FutureSocieties.remove("FSChineseRevivalist")>> <<if $assistantFSAppearance == "chinese revivalist">><<set $assistantFSAppearance = "default">><</if>> <<ClearFacilityDecorations>> @@.red;Your future society project has failed:@@ your citizens were repelled from your idea more than they were attracted to it. @@.yellow;You may select another option, or elect to try again.@@ diff --git a/src/uncategorized/futureSociety.tw b/src/uncategorized/futureSociety.tw index d253264c5153ab60250308b5bcc9bab3d0f2921b..5df1ca07eb6cb70511e37f45024cc4346dbbfc67 100644 --- a/src/uncategorized/futureSociety.tw +++ b/src/uncategorized/futureSociety.tw @@ -593,7 +593,7 @@ You are spending <<print cashFormat($FSSpending)>> each week to support your soc </span> <<if $arcologies[0].FSSupremacist != "unset">> - <br>''You are pursuing'' $arcologies[0].FSSupremacistRace superiority. //<<link "Abandon" "Future Society">><<run removeFS("FSSupremacist")>><<if $assistantFSAppearance == "supremacist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> + <br>''You are pursuing'' $arcologies[0].FSSupremacistRace superiority. //<<link "Abandon" "Future Society">><<run FutureSocieties.remove("FSSupremacist")>><<if $assistantFSAppearance == "supremacist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> <<FSChangeDecoration "FSSupremacist">> <<if $PAPublic == 1>> <<if ($assistantAppearance == "amazon") || ($assistantAppearance == "monstergirl") || ($assistantAppearance == "succubus")>> @@ -622,7 +622,7 @@ You are spending <<print cashFormat($FSSpending)>> each week to support your soc <</if>> <<if $arcologies[0].FSSubjugationist != "unset">> - <br>''You are pursuing'' $arcologies[0].FSSubjugationistRace inferiority. //<<link "Abandon" "Future Society">><<run removeFS("FSSubjugationist")>><<if $assistantFSAppearance == "subjugationist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> + <br>''You are pursuing'' $arcologies[0].FSSubjugationistRace inferiority. //<<link "Abandon" "Future Society">><<run FutureSocieties.remove("FSSubjugationist")>><<if $assistantFSAppearance == "subjugationist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> <<FSChangeDecoration "FSSubjugationist">> <<if $PAPublic == 1>> <<if ($assistantAppearance == "businesswoman") || ($assistantAppearance == "amazon") || ($assistantAppearance == "imp")>> @@ -654,7 +654,7 @@ You are spending <<print cashFormat($FSSpending)>> each week to support your soc <<if $arcologies[0].FSRestart == "unset">> <<if $arcologies[0].FSRepopulationFocus != "unset">> <br>''You are pursuing'' the belief that mass breeding will save humanity. - //<<link "Abandon" "Future Society">><<run removeFS("FSRepopulationFocus")>><<if $assistantFSAppearance == "repopulation focus">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> + //<<link "Abandon" "Future Society">><<run FutureSocieties.remove("FSRepopulationFocus")>><<if $assistantFSAppearance == "repopulation focus">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> <<FSChangeDecoration "FSRepopulationFocus" "clothesBoughtMaternityLingerie" "clothesBoughtMaternityDress" "clothesBoughtBelly">> <<if $PAPublic == 1>> <<if ($assistantAppearance == "goddess") || ($assistantAppearance == "hypergoddess") || ($assistantAppearance == "preggololi") || ($assistantAppearance == "pregnant fairy") || ($assistantAppearance == "succubus") || ($assistantAppearance == "witch")>> @@ -674,14 +674,14 @@ You are spending <<print cashFormat($FSSpending)>> each week to support your soc <<if $arcologies[0].FSRestart != "unset">> <<if $arcologies[0].FSRestartDecoration != 100>> <br>''You are pursuing'' Eugenics. - //<<link "Abandon" "Future Society">><<run removeFS("FSRestart")>><<if $assistantFSAppearance == "eugenics">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> + //<<link "Abandon" "Future Society">><<run FutureSocieties.remove("FSRestart")>><<if $assistantFSAppearance == "eugenics">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> <<FSChangeDecoration "FSRestart">> <<else>> <br>''You have established'' Eugenics. <<if $eugenicsFullControl != 1>> The Societal Elite will not permit you to abandon Eugenics. <<else>> - //<<link "Abandon" "Future Society">><<run removeFS("FSRestart")>><<if $assistantFSAppearance == "eugenics">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>// + //<<link "Abandon" "Future Society">><<run FutureSocieties.remove("FSRestart")>><<if $assistantFSAppearance == "eugenics">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>// <</if>> <br> <<FSChangeDecoration "FSRestart">> @@ -706,7 +706,7 @@ You are spending <<print cashFormat($FSSpending)>> each week to support your soc <<if $arcologies[0].FSGenderFundamentalist == "unset">> <<if $arcologies[0].FSGenderRadicalist != "unset">> <br>''You are pursuing'' a radical redefinition of gender that identifies powerful people as male, and everyone else as female. - //<<link "Abandon" "Future Society">><<run removeFS("FSGenderRadicalist")>><<if $assistantFSAppearance == "gender radicalist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> + //<<link "Abandon" "Future Society">><<run FutureSocieties.remove("FSGenderRadicalist")>><<if $assistantFSAppearance == "gender radicalist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> <<FSChangeDecoration "FSGenderRadicalist">> <<if $PAPublic == 1>> <<if ($assistantAppearance == "shemale") || ($assistantAppearance == "monstergirl") || ($assistantAppearance == "incubus") || ($assistantAppearance == "succubus") || ($assistantAppearance == "witch")>> @@ -726,7 +726,7 @@ You are spending <<print cashFormat($FSSpending)>> each week to support your soc <<if $arcologies[0].FSGenderRadicalist == "unset">> <<if $arcologies[0].FSGenderFundamentalist != "unset">> <br>''You are pursuing'' gender traditionalism, including a societal preference for feminine slaves and support for slave pregnancy. - //<<link "Abandon" "Future Society">><<run removeFS("FSGenderFundamentalist")>><<if $assistantFSAppearance == "gender fundamentalist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> + //<<link "Abandon" "Future Society">><<run FutureSocieties.remove("FSGenderFundamentalist")>><<if $assistantFSAppearance == "gender fundamentalist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> <<FSChangeDecoration "FSGenderFundamentalist" "clothesBoughtBunny">> <<if $PAPublic == 1>> <<if ($assistantAppearance == "schoolgirl") || ($assistantAppearance == "goddess") || ($assistantAppearance == "hypergoddess") || ($assistantAppearance == "preggololi") || ($assistantAppearance == "loli") || ($assistantAppearance == "fairy") || ($assistantAppearance == "pregnant fairy") || ($assistantAppearance == "angel") || ($assistantAppearance == "cherub") || ($assistantAppearance == "succubus") || ($assistantAppearance == "witch")>> @@ -745,7 +745,7 @@ You are spending <<print cashFormat($FSSpending)>> each week to support your soc <<if $arcologies[0].FSDegradationist == "unset">> <<if $arcologies[0].FSPaternalist != "unset">> <br>''You are pursuing'' a vision of slave improvement, including slaves' health, mental well-being, and education. - //<<link "Abandon" "Future Society">><<run removeFS("FSPaternalist")>><<if $assistantFSAppearance == "paternalist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> + //<<link "Abandon" "Future Society">><<run FutureSocieties.remove("FSPaternalist")>><<if $assistantFSAppearance == "paternalist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> <<FSChangeDecoration "FSPaternalist" "clothesBoughtConservative">> <<if $PAPublic == 1>> <<if ($assistantAppearance == "schoolgirl") || ($assistantAppearance == "goddess") || ($assistantAppearance == "hypergoddess") || ($assistantAppearance == "preggololi") || ($assistantAppearance == "loli") || ($assistantAppearance == "fairy") || ($assistantAppearance == "pregnant fairy") || ($assistantAppearance == "angel") || ($assistantAppearance == "cherub")>> @@ -764,7 +764,7 @@ You are spending <<print cashFormat($FSSpending)>> each week to support your soc <<if $arcologies[0].FSPaternalist == "unset">> <<if $arcologies[0].FSDegradationist != "unset">> <br>''You are pursuing'' slave degradation, a belief that slaves are not human and should not be treated decently. - //<<link "Abandon" "Future Society">><<run removeFS("FSDegradationist")>><<if $assistantFSAppearance == "degradationist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> + //<<link "Abandon" "Future Society">><<run FutureSocieties.remove("FSDegradationist")>><<if $assistantFSAppearance == "degradationist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> <<FSChangeDecoration "FSDegradationist" "clothesBoughtChains">> <<if $PAPublic == 1>> <<if ($assistantAppearance == "monstergirl") || ($assistantAppearance == "businesswoman") || ($assistantAppearance == "preggololi") || ($assistantAppearance == "succubus") || ($assistantAppearance == "incubus") || ($assistantAppearance == "imp")>> @@ -783,7 +783,7 @@ You are spending <<print cashFormat($FSSpending)>> each week to support your soc <<if $arcologies[0].FSTransformationFetishist == "unset">> <<if $arcologies[0].FSBodyPurist != "unset">> <br>''You are pursuing'' societal disapproval of implant surgery. - //<<link "Abandon" "Future Society">><<run removeFS("FSBodyPurist")>><<if $assistantFSAppearance == "body purist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> + //<<link "Abandon" "Future Society">><<run FutureSocieties.remove("FSBodyPurist")>><<if $assistantFSAppearance == "body purist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> <<FSChangeDecoration "FSBodyPurist">> <<if $PAPublic == 1>> <<if ($assistantAppearance == "amazon") || ($assistantAppearance == "goddess") || ($assistantAppearance == "loli") || ($assistantAppearance == "fairy") || ($assistantAppearance == "pregnant fairy") || ($assistantAppearance == "angel") || ($assistantAppearance == "succubus") || ($assistantAppearance == "incubus") || ($assistantAppearance == "witch")>> @@ -802,7 +802,7 @@ You are spending <<print cashFormat($FSSpending)>> each week to support your soc <<if $arcologies[0].FSBodyPurist == "unset">> <<if $arcologies[0].FSTransformationFetishist != "unset">> <br>''You are pursuing'' societal fetishization of implant surgery. - //<<link "Abandon" "Future Society">><<run removeFS("FSTransformationFetishist")>><<if $assistantFSAppearance == "transformation fetishist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> + //<<link "Abandon" "Future Society">><<run FutureSocieties.remove("FSTransformationFetishist")>><<if $assistantFSAppearance == "transformation fetishist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> <<FSChangeDecoration "FSTransformationFetishist">> <<if $PAPublic == 1>> <<if ($assistantAppearance == "businesswoman") || ($assistantAppearance == "shemale") || ($assistantAppearance == "succubus") || ($assistantAppearance == "incubus") || ($assistantAppearance == "witch") || ($assistantAppearance == "ERROR_1606_APPEARANCE_FILE_CORRUPT")>> @@ -821,7 +821,7 @@ You are spending <<print cashFormat($FSSpending)>> each week to support your soc <<if $arcologies[0].FSMaturityPreferentialist == "unset">> <<if $arcologies[0].FSYouthPreferentialist != "unset">> <br>''You are pursuing'' an accentuated societal preference for younger slaves. - //<<link "Abandon" "Future Society">><<run removeFS("FSYouthPreferentialist")>><<if $assistantFSAppearance == "youth preferentialist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> + //<<link "Abandon" "Future Society">><<run FutureSocieties.remove("FSYouthPreferentialist")>><<if $assistantFSAppearance == "youth preferentialist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> <<FSChangeDecoration "FSYouthPreferentialist">> <<if $PAPublic == 1>> <<if ($assistantAppearance == "schoolgirl") || ($assistantAppearance == "shemale") || ($assistantAppearance == "preggololi") || ($assistantAppearance == "loli") || ($assistantAppearance == "succubus") || ($assistantAppearance == "angel") || ($assistantAppearance == "cherub") || ($assistantAppearance == "imp") || ($assistantAppearance == "witch")>> @@ -840,7 +840,7 @@ You are spending <<print cashFormat($FSSpending)>> each week to support your soc <<if $arcologies[0].FSYouthPreferentialist == "unset">> <<if $arcologies[0].FSMaturityPreferentialist != "unset">> <br>''You are pursuing'' a societal preference for older women. - //<<link "Abandon" "Future Society">><<run removeFS("FSMaturityPreferentialist")>><<if $assistantFSAppearance == "maturity preferentialist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> + //<<link "Abandon" "Future Society">><<run FutureSocieties.remove("FSMaturityPreferentialist")>><<if $assistantFSAppearance == "maturity preferentialist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> <<FSChangeDecoration "FSMaturityPreferentialist">> <<if $PAPublic == 1>> <<if ($assistantAppearance == "businesswoman") || ($assistantAppearance == "goddess") || ($assistantAppearance == "succubus") || ($assistantAppearance == "incubus") || ($assistantAppearance == "witch") || ($assistantAppearance == "angel")>> @@ -859,7 +859,7 @@ You are spending <<print cashFormat($FSSpending)>> each week to support your soc <<if $arcologies[0].FSAssetExpansionist == "unset">> <<if $arcologies[0].FSSlimnessEnthusiast != "unset">> <br>''You are supporting'' enthusiasm for slaves with girlish figures. - //<<link "Abandon" "Future Society">><<run removeFS("FSSlimnessEnthusiast")>><<if $assistantFSAppearance == "slimness enthusiast">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> + //<<link "Abandon" "Future Society">><<run FutureSocieties.remove("FSSlimnessEnthusiast")>><<if $assistantFSAppearance == "slimness enthusiast">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> <<FSChangeDecoration "FSSlimnessEnthusiast">> <<if $PAPublic == 1>> <<if ($assistantAppearance == "schoolgirl") || ($assistantAppearance == "shemale") || ($assistantAppearance == "loli") || ($assistantAppearance == "cherub") || ($assistantAppearance == "imp") || ($assistantAppearance == "succubus") || ($assistantAppearance == "witch")>> @@ -878,7 +878,7 @@ You are spending <<print cashFormat($FSSpending)>> each week to support your soc <<if $arcologies[0].FSSlimnessEnthusiast == "unset">> <<if $arcologies[0].FSAssetExpansionist != "unset">> <br>''You are pursuing'' societal hunger for huge assets. - //<<link "Abandon" "Future Society">><<run removeFS("FSAssetExpansionist")>><<if $assistantFSAppearance == "asset expansionist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> + //<<link "Abandon" "Future Society">><<run FutureSocieties.remove("FSAssetExpansionist")>><<if $assistantFSAppearance == "asset expansionist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> <<FSChangeDecoration "FSAssetExpansionist">> <<if $PAPublic == 1>> <<if ($assistantAppearance == "businesswoman") || ($assistantAppearance == "shemale") || ($assistantAppearance == "hypergoddess") || ($assistantAppearance == "succubus") || ($assistantAppearance == "incubus") || ($assistantAppearance == "witch")>> @@ -896,7 +896,7 @@ You are spending <<print cashFormat($FSSpending)>> each week to support your soc <<if $arcologies[0].FSPastoralist != "unset">> <br>''You are pursuing'' societal normalization of slave milking. - //<<link "Abandon" "Future Society">><<run removeFS("FSPastoralist")>><<if $assistantFSAppearance == "pastoralist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> + //<<link "Abandon" "Future Society">><<run FutureSocieties.remove("FSPastoralist")>><<if $assistantFSAppearance == "pastoralist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> <<FSChangeDecoration "FSPastoralist" "clothesBoughtWestern">> <<if $PAPublic == 1>> <<if ($assistantAppearance == "goddess") || ($assistantAppearance == "shemale") || ($assistantAppearance == "hypergoddess") || ($assistantAppearance == "incubus") || ($assistantAppearance == "succubus") || ($assistantAppearance == "witch")>> @@ -914,7 +914,7 @@ You are spending <<print cashFormat($FSSpending)>> each week to support your soc <<if $arcologies[0].FSHedonisticDecadence == "unset">> <<if $arcologies[0].FSPhysicalIdealist != "unset">> <br>''You are pursuing'' societal reverence for the idealized human form, including height, health and muscle. - //<<link "Abandon" "Future Society">><<run removeFS("FSPhysicalIdealist")>><<if $assistantFSAppearance == "physical idealist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> + //<<link "Abandon" "Future Society">><<run FutureSocieties.remove("FSPhysicalIdealist")>><<if $assistantFSAppearance == "physical idealist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> <<FSChangeDecoration "FSPhysicalIdealist" "clothesBoughtOil">> <<if $PAPublic == 1>> <<if ($assistantAppearance == "amazon") || ($assistantAppearance == "shemale") || ($assistantAppearance == "incubus") || ($assistantAppearance == "succubus") || ($assistantAppearance == "witch")>> @@ -933,7 +933,7 @@ You are spending <<print cashFormat($FSSpending)>> each week to support your soc <<if $arcologies[0].FSPhysicalIdealist == "unset">> <<if $arcologies[0].FSHedonisticDecadence != "unset">> <br>''You are pursuing'' societal normalization of overindulgence and immediate gratification. Be it food, drink, sex, drugs or whatever one's desire may be. - //<<link "Abandon" "Future Society">><<run removeFS("FSHedonisticDecadence")>><<if $assistantFSAppearance == "hedonistic decadence">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> + //<<link "Abandon" "Future Society">><<run FutureSocieties.remove("FSHedonisticDecadence")>><<if $assistantFSAppearance == "hedonistic decadence">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> <<FSChangeDecoration "FSHedonisticDecadence">> <<if $PAPublic == 1>> <<if ($assistantAppearance == "goddess") || ($assistantAppearance == "hypergoddess") || ($assistantAppearance == "preggololi") || ($assistantAppearance == "imp") || ($assistantAppearance == "incubus") || ($assistantAppearance == "succubus") || ($assistantAppearance == "witch")>> @@ -952,7 +952,7 @@ You are spending <<print cashFormat($FSSpending)>> each week to support your soc <<if $arcologies[0].FSNull == "unset">> <<if $arcologies[0].FSChattelReligionist != "unset">> <br>''You are pursuing'' a new strain of religion that emphasizes the slaveholding portions of religious history. - //<<link "Abandon" "Future Society">><<run removeFS("FSChattelReligionist")>><<if $assistantFSAppearance == "chattel religionist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> + //<<link "Abandon" "Future Society">><<run FutureSocieties.remove("FSChattelReligionist")>><<if $assistantFSAppearance == "chattel religionist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> <<FSChangeDecoration "FSChattelReligionist" "clothesBoughtHabit">> <<if $PAPublic == 1>> <<if ($assistantAppearance == "goddess") || ($assistantAppearance == "monstergirl") || ($assistantAppearance == "incubus") || ($assistantAppearance == "succubus") || ($assistantAppearance == "witch") || ($assistantAppearance == "angel") || ($assistantAppearance == "cherub") || ($assistantAppearance == "imp")>> @@ -971,7 +971,7 @@ You are spending <<print cashFormat($FSSpending)>> each week to support your soc <<if ($arcologies[0].FSAztecRevivalist == "unset") && ($arcologies[0].FSEgyptianRevivalist == "unset") && ($arcologies[0].FSEdoRevivalist == "unset") && ($arcologies[0].FSArabianRevivalist == "unset") && ($arcologies[0].FSChineseRevivalist == "unset")>> <<if $arcologies[0].FSRomanRevivalist != "unset">> <br>''You are pursuing'' a vision of a new Rome. - //<<link "Abandon" "Future Society">><<run removeFS("FSRomanRevivalist")>><<if $assistantFSAppearance == "roman revivalist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> + //<<link "Abandon" "Future Society">><<run FutureSocieties.remove("FSRomanRevivalist")>><<if $assistantFSAppearance == "roman revivalist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> <<FSChangeDecoration "FSRomanRevivalist" "clothesBoughtToga">> <<if $PAPublic == 1>> <<if ($assistantAppearance == "businesswoman") || ($assistantAppearance == "amazon") || ($assistantAppearance == "incubus") || ($assistantAppearance == "succubus")>> @@ -990,7 +990,7 @@ You are spending <<print cashFormat($FSSpending)>> each week to support your soc <<if ($arcologies[0].FSRomanRevivalist == "unset") && ($arcologies[0].FSEgyptianRevivalist == "unset") && ($arcologies[0].FSEdoRevivalist == "unset") && ($arcologies[0].FSArabianRevivalist == "unset") && ($arcologies[0].FSChineseRevivalist == "unset")>> <<if $arcologies[0].FSAztecRevivalist != "unset">> <br>''You are pursuing'' a vision of a new Aztec Empire. - //<<link "Abandon" "Future Society">><<run removeFS("FSAztecRevivalist")>><<if $assistantFSAppearance == "aztec revivalist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> + //<<link "Abandon" "Future Society">><<run FutureSocieties.remove("FSAztecRevivalist")>><<if $assistantFSAppearance == "aztec revivalist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> <<FSChangeDecoration "FSAztecRevivalist" "clothesBoughtHuipil">> <<if $PAPublic == 1>> <<if ($assistantAppearance == "goddess") || ($assistantAppearance == "amazon") || ($assistantAppearance == "incubus") || ($assistantAppearance == "succubus")>> @@ -1009,7 +1009,7 @@ You are spending <<print cashFormat($FSSpending)>> each week to support your soc <<if ($arcologies[0].FSRomanRevivalist == "unset") && ($arcologies[0].FSAztecRevivalist == "unset") && ($arcologies[0].FSEdoRevivalist == "unset") && ($arcologies[0].FSArabianRevivalist == "unset") && ($arcologies[0].FSChineseRevivalist == "unset")>> <<if $arcologies[0].FSEgyptianRevivalist != "unset">> <br>''You are pursuing'' a vision of Pharaoh's Egypt. - //<<link "Abandon" "Future Society">><<run removeFS("FSEgyptianRevivalist")>><<if $assistantFSAppearance == "egyptian revivalist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> + //<<link "Abandon" "Future Society">><<run FutureSocieties.remove("FSEgyptianRevivalist")>><<if $assistantFSAppearance == "egyptian revivalist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> <<FSChangeDecoration "FSEgyptianRevivalist" "clothesBoughtEgypt">> <<if $PAPublic == 1>> <<if ($assistantAppearance == "goddess") || ($assistantAppearance == "monstergirl") || ($assistantAppearance == "incubus") || ($assistantAppearance == "succubus")>> @@ -1028,7 +1028,7 @@ You are spending <<print cashFormat($FSSpending)>> each week to support your soc <<if ($arcologies[0].FSRomanRevivalist == "unset") && ($arcologies[0].FSAztecRevivalist == "unset") && ($arcologies[0].FSEgyptianRevivalist == "unset") && ($arcologies[0].FSArabianRevivalist == "unset") && ($arcologies[0].FSChineseRevivalist == "unset")>> <<if $arcologies[0].FSEdoRevivalist != "unset">> <br>''You are pursuing'' a vision of Edo Japan. - //<<link "Abandon" "Future Society">><<run removeFS("FSEdoRevivalist")>><<if $assistantFSAppearance == "edo revivalist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> + //<<link "Abandon" "Future Society">><<run FutureSocieties.remove("FSEdoRevivalist")>><<if $assistantFSAppearance == "edo revivalist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> <<FSChangeDecoration "FSEdoRevivalist" "clothesBoughtKimono">> <<if $PAPublic == 1>> <<if ($assistantAppearance == "amazon") || ($assistantAppearance == "monstergirl") || ($assistantAppearance == "loli") || ($assistantAppearance == "kitsune") || ($assistantAppearance == "incubus") || ($assistantAppearance == "succubus")>> @@ -1047,7 +1047,7 @@ You are spending <<print cashFormat($FSSpending)>> each week to support your soc <<if ($arcologies[0].FSRomanRevivalist == "unset") && ($arcologies[0].FSAztecRevivalist == "unset") && ($arcologies[0].FSEgyptianRevivalist == "unset") && ($arcologies[0].FSEdoRevivalist == "unset") && ($arcologies[0].FSChineseRevivalist == "unset")>> <<if $arcologies[0].FSArabianRevivalist != "unset">> <br>''You are pursuing'' a vision of the Sultanate of old. - //<<link "Abandon" "Future Society">><<run removeFS("FSArabianRevivalist")>><<if $assistantFSAppearance == "arabian revivalist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> + //<<link "Abandon" "Future Society">><<run FutureSocieties.remove("FSArabianRevivalist")>><<if $assistantFSAppearance == "arabian revivalist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> <<FSChangeDecoration "FSArabianRevivalist" "clothesBoughtHarem">> <<if $PAPublic == 1>> <<if ($assistantAppearance == "businesswoman") || ($assistantAppearance == "schoolgirl") || ($assistantAppearance == "incubus") || ($assistantAppearance == "succubus")>> @@ -1066,7 +1066,7 @@ You are spending <<print cashFormat($FSSpending)>> each week to support your soc <<if ($arcologies[0].FSRomanRevivalist == "unset") && ($arcologies[0].FSAztecRevivalist == "unset") && ($arcologies[0].FSEgyptianRevivalist == "unset") && ($arcologies[0].FSEdoRevivalist == "unset") && ($arcologies[0].FSArabianRevivalist == "unset")>> <<if $arcologies[0].FSChineseRevivalist != "unset">> <br>''You are pursuing'' a vision of ancient China. - //<<link "Abandon" "Future Society">><<run removeFS("FSChineseRevivalist")>><<if $assistantFSAppearance == "chinese revivalist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> + //<<link "Abandon" "Future Society">><<run FutureSocieties.remove("FSChineseRevivalist")>><<if $assistantFSAppearance == "chinese revivalist">><<set $assistantFSAppearance = "default">><</if>><<ClearFacilityDecorations>><</link>>//<br> <<FSChangeDecoration "FSChineseRevivalist" "clothesBoughtQipao">> <<if $PAPublic == 1>> <<if ($assistantAppearance == "schoolgirl") || ($assistantAppearance == "monstergirl") || ($assistantAppearance == "incubus") || ($assistantAppearance == "succubus")>> @@ -1087,7 +1087,7 @@ You are spending <<print cashFormat($FSSpending)>> each week to support your soc <<if $arcologies[0].FSNull != "unset">> <br>''You are permitting <<if $arcologies[0].FSNull <= 25>>basic<<elseif $arcologies[0].FSNull <= 50>>considerable<<elseif $arcologies[0].FSNull <= 75>>advanced<<else>>absolute<</if>>'' cultural freedom in your arcology. <<if $arcologies[0].FSNull <= 25>> - //[[Abandon|Future Society][removeFS("FSNull")]]// + //[[Abandon|Future Society][FutureSocieties.remove("FSNull")]]// <<else>> //[[Withdraw|Future Society][$arcologies[0].FSNull -= 25, $FSCredits += 1]]// <</if>> @@ -1106,7 +1106,7 @@ You are spending <<print cashFormat($FSSpending)>> each week to support your soc <<if $arcologies[0].FSNull != "unset">> <br>''You are permitting <<if $arcologies[0].FSNull <= 17>>basic<<elseif $arcologies[0].FSNull <= 34>>some<<elseif $arcologies[0].FSNull <= 51>>considerable<<elseif $arcologies[0].FSNull <= 68>>great<<elseif $arcologies[0].FSNull <= 85>>advanced<<else>>absolute<</if>>'' cultural freedom in your arcology. <<if $arcologies[0].FSNull <= 20>> - //[[Abandon|Future Society][removeFS("FSNull")]]// + //[[Abandon|Future Society][FutureSocieties.remove("FSNull")]]// <<else>> //[[Withdraw|Future Society][$arcologies[0].FSNull -= 17, $FSCredits += 1]]// <</if>> @@ -1125,7 +1125,7 @@ You are spending <<print cashFormat($FSSpending)>> each week to support your soc <<if $arcologies[0].FSNull != "unset">> <br>''You are permitting <<if $arcologies[0].FSNull <= 15>>basic<<elseif $arcologies[0].FSNull <= 30>>some<<elseif $arcologies[0].FSNull <= 45>>notable<<elseif $arcologies[0].FSNull <= 60>>considerable<<elseif $arcologies[0].FSNull <= 75>>great<<elseif $arcologies[0].FSNull <= 90>>advanced<<else>>absolute<</if>>'' cultural freedom in your arcology. <<if $arcologies[0].FSNull <= 20>> - //[[Abandon|Future Society][removeFS("FSNull")]]// + //[[Abandon|Future Society][FutureSocieties.remove("FSNull")]]// <<else>> //[[Withdraw|Future Society][$arcologies[0].FSNull -= 15, $FSCredits += 1]]// <</if>> @@ -1144,7 +1144,7 @@ You are spending <<print cashFormat($FSSpending)>> each week to support your soc <<if $arcologies[0].FSNull != "unset">> <br>''You are permitting <<if $arcologies[0].FSNull <= 20>>basic<<elseif $arcologies[0].FSNull <= 40>>considerable<<elseif $arcologies[0].FSNull <= 60>>great<<elseif $arcologies[0].FSNull <= 80>>advanced<<else>>absolute<</if>>'' cultural freedom in your arcology. <<if $arcologies[0].FSNull <= 20>> - //[[Abandon|Future Society][removeFS("FSNull")]]// + //[[Abandon|Future Society][FutureSocieties.remove("FSNull")]]// <<else>> //[[Withdraw|Future Society][$arcologies[0].FSNull -= 20, $FSCredits += 1]]// <</if>> diff --git a/src/uncategorized/nextWeek.tw b/src/uncategorized/nextWeek.tw index 755f3ae730b60212efec12788c39065972d0665b..64b03fe8c148bf095b275a50d8cd198ef5184e78 100644 --- a/src/uncategorized/nextWeek.tw +++ b/src/uncategorized/nextWeek.tw @@ -1,6 +1,7 @@ :: Next Week [nobr] <<set $HackingSkillMultiplier = HackingSkillMultiplier()>> +<<set $upgradeMultiplierArcology = upgradeMultiplierArcology()>> <<if $rivalOwner != 0>> <<set _rival = $arcologies.find(function(s) { return s.rival == 1; })>> diff --git a/src/uncategorized/officeDescription.tw b/src/uncategorized/officeDescription.tw index 1ccfe6471e364b873b1339505976bf1430b3ad85..160f9ae27cdc35e6a923fc11f28c99c0592c0804 100644 --- a/src/uncategorized/officeDescription.tw +++ b/src/uncategorized/officeDescription.tw @@ -179,22 +179,7 @@ <</switch>> <</if>> <</if>> -<<if $trinkets.length > 0>> -There's a display case behind your desk, -<<if $trinkets.length > 2>> - with - <<for $i = 0; $i < $trinkets.length; $i++>> - <<if $i < $trinkets.length-1>> - $trinkets[$i], - <<else>> - and $trinkets[$i]. - <</if>> - <</for>> -<<elseif $trinkets.length > 1>> - with a couple of items: $trinkets[0], and $trinkets[1]. -<<else>> - with a single item: $trinkets[0]. -<</if>> +<<= printTrinkets()>> A small mirror resides on your desk, facing you. A $PC.visualAge year old<<if $PC.markings == "freckles">>, freckled<<elseif $PC.markings == "heavily freckled">>, densely freckled<</if>> $PC.faceShape face stares back at you. @@ -204,4 +189,3 @@ A $PC.visualAge year old<<if $PC.markings == "freckles">>, freckled<<elseif $PC. <<PlayerCrotch>> <<PlayerButt>> -<</if>> diff --git a/src/uncategorized/reputation.tw b/src/uncategorized/reputation.tw index 6aabb016be8fec2a20487c172c056891f3ead47f..cc6aad833f56b3774849a3092e0b98d505d63d56 100644 --- a/src/uncategorized/reputation.tw +++ b/src/uncategorized/reputation.tw @@ -782,7 +782,7 @@ On formal occasions, you are announced as $PCTitle. <<if $eugenicsFullControl != 1>> <<if $failedElite > 300>> The Societal Elite @@.red;have departed from your arcology in disgust@@. - <<run removeFS("FSRestart")>> + <<run FutureSocieties.remove("FSRestart")>> <<run repX(-10000, "event")>> <<set $eliteFail = random(30,100), $eliteFailTimer = 15>> diff --git a/src/uncategorized/saRelationships.tw b/src/uncategorized/saRelationships.tw index b896b95ba25d7648cc75382dcd67903a6f23d313..cbbd3947f175172a9e3d329d7cbe010f67e236f1 100644 --- a/src/uncategorized/saRelationships.tw +++ b/src/uncategorized/saRelationships.tw @@ -1456,19 +1456,19 @@ <<if (_SlaveJ.oralSkill > _SlaveI.oralSkill) || ((_SlaveJ.analSkill > _SlaveI.analSkill) && (_SlaveI.anus > 0)) || ((_SlaveJ.vaginalSkill > _SlaveI.vaginalSkill) && (_SlaveI.vagina > 0) && (_SlaveJ.vagina > 0)) || (_SlaveJ.trust > _SlaveI.trust)>> _SlaveI.slaveName's <<if _SlaveI.relationship >= 5>>wife<<else>>lover<</if>> is older, more experienced, and <<if (_SlaveJ.oralSkill > _SlaveI.oralSkill)>> - better at blowjobs than $he is. They are such good slaves that the senior _girlA serves as a mentor to the junior, improving $his oral skills. + better at blowjobs than $he is. They are such good slaves that the senior _girl2 serves as a mentor to the junior, improving $his oral skills. <<set $skillIncrease = 5>><<OralSkillIncrease _SlaveI>> <<elseif (_SlaveJ.analSkill > _SlaveI.analSkill) && (_SlaveI.anus > 0)>> - better at taking a buttfuck than $he is, and they are such good slaves that the senior _girlA serves as a mentor to the junior, improving $his anal skills. + better at taking a buttfuck than $he is, and they are such good slaves that the senior _girl2 serves as a mentor to the junior, improving $his anal skills. <<set $skillIncrease = 5>><<AnalSkillIncrease _SlaveI>> <<elseif (_SlaveJ.vaginalSkill > _SlaveI.vaginalSkill) && (_SlaveI.vagina > 0) && (_SlaveJ.vagina > 0)>> - a better lover than $he is, and they are such good slaves that the senior _girlA serves as a mentor to the junior, improving $his vaginal skills. + a better lover than $he is, and they are such good slaves that the senior _girl2 serves as a mentor to the junior, improving $his vaginal skills. <<set $skillIncrease = 5>><<VaginalSkillIncrease _SlaveI>> <<elseif (_SlaveJ.trust > _SlaveI.trust)>> - a better slave than $he is, and they are such obedient slaves that the senior _girlA serves as a mentor to the junior, @@.mediumaquamarine;improving $his trust.@@ + a better slave than $he is, and they are such obedient slaves that the senior _girl2 serves as a mentor to the junior, @@.mediumaquamarine;improving $his trust.@@ <<set _SlaveI.trust += 11>> <<else>> - a more devoted slave than $he is; since they are such obedient slaves, the senior _girlA serves as a mentor to the junior, @@.mediumaquamarine;teaching $him to better serve you.@@ + a more devoted slave than $he is; since they are such obedient slaves, the senior _girl2 serves as a mentor to the junior, @@.mediumaquamarine;teaching $him to better serve you.@@ <<set _SlaveI.devotion += 2>> <</if>> <</if>> diff --git a/src/utility/miscWidgets.tw b/src/utility/miscWidgets.tw index ad4a6170a1dd8f759702f208d3e9e91ab988ce74..d5ec0b01f6d1f16a00e375d94c365a76783cce00 100644 --- a/src/utility/miscWidgets.tw +++ b/src/utility/miscWidgets.tw @@ -685,6 +685,8 @@ This experience [[Customize the exterior of the arcology to support this goal|Future Society][$arcologies[0][_FSDecoration] = 100, State.variables[$args[1]] = 1, State.variables[$args[2]] = 1, State.variables[$args[3]] = 1, cashX(-20000, "capEx")]] //Costs <<print cashFormat(20000)>>// <<elseif def $args[1]>> [[Customize the exterior of the arcology to support this goal|Future Society][$arcologies[0][_FSDecoration] = 100, State.variables[$args[1]] = 1, cashX(-20000, "capEx")]] //Costs <<print cashFormat(20000)>>// + <<elseif $args[0] == "FSRestart">> + [[Customize the exterior of the arcology to support this goal and fully establish the Societal Elite|Future Society][$arcologies[0].FSRestartDecoration = 100, $upgradeMultiplierArcology = upgradeMultiplierArcology(), $upgradeMultiplierMedicine = 0.5, $cash -= 75000]] //Costs <<print cashFormat(75000)>> and may dilute your control over the arcology// <<else>> [[Customize the exterior of the arcology to support this goal|Future Society][$arcologies[0][_FSDecoration] = 100, cashX(-20000, "capEx")]] //Costs <<print cashFormat(20000)>>// <</if>>