package script.developer; import script.library.sui; import script.library.utils; import script.location; import script.obj_id; import java.io.IOException; import java.io.PrintWriter; import java.nio.charset.StandardCharsets; import java.util.Arrays; import java.util.List; /** * SWG Buildout Utility * For World Building in the Release Game Client * To Use: attach developer.buildout_utility to your player and say "info" for commands * * Most usage will be creating an object either with this script or by some other means, * targeting it, and saying "getBuildoutInfo" in spatial which will give you an SUI window * of everything you need to type in to add that object to a buildout. * * ************************************************* * This is a WORK IN PROGRESS * I'm adding it now upon request to help a few people get the gist of buildouts. * ************************************************* * * Authors: Aconite */ public class buildout_utility extends script.base_script { public buildout_utility() { } // Only list planets in the SCENES array that are full size (16000x16000) // Only worlds at full size using -8192 to 8192 coordinates should be used otherwise the positioning will be off because the buildout names won't match to the correct positioning boxes. public static final String[] SCENES = { "tatooine", "yavin4", "mustafar", "endor", "talus", "corellia", "rori", "dathomir", "dantooine", "naboo", "lok" }; public int OnAttach(obj_id self) throws InterruptedException { sendSystemMessageTestingOnly(self, "Buildout Utility Attached... say INFO for help."); return SCRIPT_CONTINUE; } public int OnSpeaking(obj_id self, String text) throws InterruptedException, IOException { if (!isGod(self)) { return SCRIPT_CONTINUE; } java.util.StringTokenizer tok = new java.util.StringTokenizer(text); String command1 = tok.nextToken(); String command2 = ""; if (tok.hasMoreTokens()) { if (tok.hasMoreTokens()) { command2 = tok.nextToken(); } } // =========================================================================== // ===== info // =========================================================================== if (command1.equalsIgnoreCase("info")) { sendSystemMessageTestingOnly(self, "Instructions for buildout utility sent to your console."); sendConsoleMessage(self, "\\#ffff00 ============ buildout_utility spatial chat/speak commands ============ \\#."); sendConsoleMessage(self, "\\#00ffff clearObjects \\#."); sendConsoleMessage(self, "destroys all objects within 500m with buildout_utility.write objvar"); sendConsoleMessage(self, "\\#00ffff createObject \\#bfff00