Build order import

Sc2gears supports importing Build orders, which will be opened in the Replay analyzer, and all the tools and features that you can use to analyzer replays are available to analyze build orders.

To import Build orders, click on the Import Build orders... menu item in the File menu.

This will open a dialog where you can specify up to 8 build orders. You can either copy/paste Build orders into the displayed to text areas, or you can load build orders from files. Sc2gears will simulate a replay creating a player from each provided Build order. You can select a replay version to simulate (unit/building costs and build times may vary in different versions), and you can select a game speed (to be used to convert between times and frames). You can also group the Build orders (later players) into teams, so you can analyze multiple Build orders as a team (if you use the "Group by teams" feature in the Replay analyzer).

The Build order has to be entered/specified in plain text format. The following section describes the format of the Build order text.

Google Ads

Build order text format specification

Foreword

In many cases you don't have to write or edit Build order texts: they are exported from other programs like Build order finders and optimizers.

Sc2gears does not check if the actions of the Build orders are valid. For example you can issue to build a Probe even if you did not select a Nexus before that. Same goes for resources: it does not check if you have enough resources or supply at the specified time. Sc2gears only visualizes the Build order you specified. That means you do not have to implement the whole specification to create valid Build orders. Learn and use only the actions you describe your Build order with. You can create good and informative Build orders just by using 2-3 types of actions (like U.*, B.*, R.*). Also many elements of the format specification are optional: you do not have to specify unit IDs for example nor the target of the actions.

But implementing more of the specification greatly increases the value of the Build orders.

Specification version:

Date:

Author:

1.0

2010-12-22

András Belicza

Multi-line structure

The Build order text is a multi-line text: each line specifies an action. An action can be an order to build a building, train a unit, select some units, use an ability (like Spawn Larva, Calldown MULE etc.). The lines can be separated with either the carriage return ('\r' character code=13), the line feed ('\n' character code=10) or the concatenation of these 2 characters ("\r\n"). To put it simple: just press an ENTER after each action, Sc2gears handles multi-platform line-end variations. If the Build order text is read from a file, the file is interpreted as an UTF-8 encoded file. UTF-8 should not be an issue as the format does not use or require any special characters.

Empty lines are allowed, and they will be ignored.

Examples

First let's see some examples of valid actions that can be used in the Build order text. This example is here to demonstrate what and how can you specify in the Build order text, and will help us easily understand what comes next:

Action examples:

10,SELECT,Nexus

20,SELECT,Nexus[123]

30,U.PROBE

40,SELECT,Nexus[123],6*Probe[1;2;3;4;5;6]

50,"Right click",TU,Mineral Field[222]

60,B.PYLON

70,B.PYLON,TL,36.4,23.123

80,R.PROTOSS_WARP_GATE

90,WU.STALKER,TL,23.0,34.0

100,UA.MASS_RECALL,U.MOTHERSHIP,TL,34.3,23.12

110,UP.TERRAN_SHIP_PLATING_1

120,SELECT,SCV[34]

130,"Stop"

140,UA.RETURN_CARGO,U.SCV

150,SELECT,Hatchery[32]

160,BA.SET_WORKER_RALLY_POINT,B.HATCHERY,TU,Mineral Field[16]

170,SELECT,Command Center

180,BA.LIFT_OFF,B.COMMAND_CENTER

190,SELECT,Command Center (Flying)

200,BA.LAND,B.COMMAND_CENTER

Debugging

If a line contains an invalid or incorrect action, Sc2gears will create a dummy action for that line. The created action will have an "INACTION" action-type, so if you want to see these, you have to select the "Inaction" type. The dummy action will be listed after the previous action in the action list (in chronological order), and its text will show the line number from which it was created.

If the Build order text contains an invalid action, the "Parsing error!" text will be displayed above the action list.

Action format

Actions contain different parts which are separated with commas (','). The parts between commas will be referred to as tokens.

Time token

Each action starts with a time token which specifies the time of the action (when it was/should be issued). The time is expressed by a number known as frames inside StarCraft II. The conversion between seconds and frames is easy. Assuming Normal game speed (every time-related info is specified in Normal game speed inside StarCraft II, like build times, research times etc.):

Seconds - Frames conversion:

frames = seconds * 64

So for example if an action happened at 01:00 (which is 1 minute 0 seconds = 60 seconds), the frame is 60 * 64 = 3840.

Action token

The frame token is followed by the action token which tells what the action really is. There are 3 forms of action tokens:

The first form looks like this: CLASS.ENITTY

The CLASS can be one of the followings:

The ENTITY depends on the value of CLASS, and its value is derived from the name of the entity it represents by capitalizing its letters and replacing spaces with underscores ('_'). That being said you do not have to memorize the list, it is here only for a reference. Here is a complete list of the possible values of ENTITY depending on the value of CLASS:

    • CLASS=U: SCV, MARINE, REAPER, GHOST, MARAUDER, SIEGE_TANK, THOR, HELLION, MEDIVAC, BANSHEE, RAVEN, BATTLECURISER, VIKING, ZEALOT, STALKER, HIGH_TEMPLAR, DARK_TEMPLAR, SENTRY, PHOENIX, CARRIER, VOID_RAY, WARP_PRISM, OBSERVER, COLOSSUS, IMMORTAL, PROBE, DRONE, ZERGLING, OVERLORD, HYDRALISK, MUTALISK, ULTRALISK, QUEEN

    • CLASS=B: COMMAND_CENTER, SUPPLY_DEPOT, BARRACKS, ENGINEERING_BAY, MISSILE_TURRET, BUNKER, REFINERY, SENSOR_TOWER, GHOST_ACADEMY, FACTORY, STARPORT, ARMORY, FUSION_CORE, TECH_LAB_BARRACKS, REACTOR_BARRACKS, TECH_LAB_FACTORY, REACTOR_FACTORY, TECH_LAB_STARPORT, REACTOR_STARPORT, NEXUS, PYLON, GATEWAY, FORGE, FLEET_BEACON, TWILIGHT_COUNCIL, PHOTON_CANNON, ASSIMILATOR, HATCHERY, SPAWNING_POOL, EVOLUTION_CHAMBER, HYDRALISK_DEN, SPIRE, ULTRALISK_CAVERN, EXTRACTOR, LAIR, HIVE, STARGATE, TEMPLAR_ARCHIVES, DARK_SHRINE, ROBOTICS_BAY, ROBOTICS_FACILITY, CYBERNETICS_CORE, INFESTATION_PIT, NYDUS_NETWORK, BANELING_NEST, ROACH_WARREN, SPINE_CRAWLER, SPORE_CRAWLER, NYDUS_WORM, CREEP_TUMOR

    • CLASS=HU: ARCHON, COLOSSUS, HIGH_TEMPLAR, IMMORTAL, PHOENIX, PROBE, STALKER, VOID_RAY, WARP_PRISM, ZEALOT

    • CLASS=WU: ZEALOT, STALKER, HIGH_TEMPLAR, DARK_TEMPLAR, SENTRY

  • CLASS=R: PROTOSS_FLUX_VANES, PROTOSS_GRAVITON_CATAPULT, PROTOSS_ANION_PULSE_CRYSTALS, ZERG_GLIAL_RECONSTITUTION, ZERG_TUNNELING_CLAWS, ZERG_CHITINOUS_PLATING, TERRAN_NITRO_PACKS, TERRAN_STIMPACK, TERRAN_COMBAT_SHIELD, TERRAN_CONCUSSIVE_SHELLS, TERRAN_SIEGE_TECH, TERRAN_INFERNAL_PRE_IGNITER, TERRAN_250MM_STRIKE_CANNONS, TERRAN_CLOAKING_FIELD, TERRAN_CADUCEUS_REACTOR, TERRAN_CORVID_REACTOR, TERRAN_SEEKER_MISSILE, TERRAN_DURABLE_MATERIALS, TERRAN_PERSONAL_CLOAKING, TERRAN_MOEBIUS_REACTOR, PROTOSS_GRAVITIC_BOOSTER, PROTOSS_GRAVITIC_DRIVE, PROTOSS_EXTENDED_THERMAL_LANCE, PROTOSS_KHAYDARIN_AMULET, PROTOSS_PSIONIC_STORM, ZERG_PNEUMATIZED_CARAPACE, ZERG_VENTRAL_SACKS, ZERG_BURROW, ZERG_ADRENAL_GLANDS, ZERG_METABOLIC_BOOST, ZERG_GROOVED_SNIPES, ZERG_PATHOGEN_GLANDS, ZERG_NEURAL_PARASITE, ZERG_CENTRIFUGAL_HOOKS, TERRAN_WEAPON_REFIT, TERRAN_BEHEMOTH_REACTOR, PROTOSS_WARP_GATE, PROTOSS_CHARGE, PROTOSS_BLINK

    • CLASS=UP: TERRAN_HI_SEC_AUTO_TRACKING, TERRAN_BUILDING_ARMOR, TERRAN_INFANTRY_WEAPONS_1, TERRAN_INFANTRY_WEAPONS_2, TERRAN_INFANTRY_WEAPONS_3, TERRAN_NEOSTEEL_FRAME, TERRAN_INFANTRY_ARMOR_1, TERRAN_INFANTRY_ARMOR_2, TERRAN_INFANTRY_ARMOR_3, TERRAN_VEHICLE_PLATING_1, TERRAN_VEHICLE_PLATING_2, TERRAN_VEHICLE_PLATING_3, TERRAN_VEHICLE_WEAPONS_1, TERRAN_VEHICLE_WEAPONS_2, TERRAN_VEHICLE_WEAPONS_3, PROTOSS_GROUND_WEAPONS_1, PROTOSS_GROUND_WEAPONS_2, PROTOSS_GROUND_WEAPONS_3, PROTOSS_GROUND_ARMOR_1, PROTOSS_GROUND_ARMOR_2, PROTOSS_GROUND_ARMOR_3, PROTOSS_SHIELD_1, PROTOSS_SHIELD_2, PROTOSS_SHIELD_3, ZERG_MELEE_ATTACKS_1, ZERG_MELEE_ATTACKS_2, ZERG_MELEE_ATTACKS_3, ZERG_GROUND_CARAPACE_1, ZERG_GROUND_CARAPACE_2, ZERG_GROUND_CARAPACE_3, ZERG_MISSILE_ATTACKS_1, ZERG_MISSILE_ATTACKS_2, ZERG_MISSILE_ATTACKS_3, ZERG_FLYER_ATTACKS_1, ZERG_FLYER_ATTACKS_2, ZERG_FLYER_ATTACKS_3, ZERG_FLYER_CARAPACE_1, ZERG_FLYER_CARAPACE_2, ZERG_FLYER_CARAPACE_3, TERRAN_SHIP_PLATING_1, TERRAN_SHIP_PLATING_2, TERRAN_SHIP_PLATING_3, TERRAN_SHIP_WEAPONS_1, TERRAN_SHIP_WEAPONS_2, TERRAN_SHIP_WEAPONS_3, PROTOSS_AIR_WEAPONS_1, PROTOSS_AIR_WEAPONS_2, PROTOSS_AIR_WEAPONS_3, PROTOSS_AIR_ARMOR_1, PROTOSS_AIR_ARMOR_2, PROTOSS_AIR_ARMOR_3

    • CLASS=UA: CORRUPTION, REPAIR, WEAPONS_FREE, EXPLODE, FUNGAL_GROWTH, GUARDIAN_SHIELD, MORPH_TO_BANELING, FEEDBACK, MASS_RECALL, BUILD_POINT_DEFENSE_DRONE, RETURN_CARGO, SEEKER_MISSILE, ATTACK_STRUCTURE, INFESTED_TERRAN, NEURAL_PARASITE, SPAWN_LARVA, STIMPACK, CANCEL_BANELING_MORPHING, T250MM_STRIKE_CANNONS, GATHER_RESOURCES_PROTOSS, CLOAK, DECLOAK, SNIPER_ROUND, HEAL, SIEGE_MODE, TANK_MODE, UNLOAD_ALL, LOAD, UNLOAD_UNIT, YAMATO_CANNON, ASSAULT_MODE, FIGHTER_MODE, PSIONIC_STORM, TRAIN_AN_INTERCEPTOR, MORPH_TO_BROOD_LORD, BURROW, UNBURROW, BLINK, MORPH_TO_OVERSEER, CANCEL_OVERSEER_MORPHING, FORCE_FIELD, PHASING_MODE, TRANSPORT_MODE, TAC_NUCLEAR_STRIKE, CANCEL_TAC_NUCLEAR_STRIKE, EMP_ROUND, VORTEX, TRANSFUSION, GENERATE_CREEP, STOP_GENERATING_CREEP, SPAWN_CREEP_TUMOR, BUILD_AUTO_TURRET, CHARGE, CONTAMINATE, GATHER_RESOURCES_TERRAN, SPAWN_CHANGELING, DISGUISE, DISGUISE_AS_ZEALOT, DISGUISE_AS_MARINE_WITH_SHIELD, DISGUISE_AS_MARINE_WITHOUT_SHIELD, DISGUISE_AS_ZERGLING_WITH_WINGS, DISGUISE_AS_ZERGLING_WITHOUT_WINGS, GATHER_RESOURCES_ZERG, CANCEL_BROOD_LORD_MORPHING, ENABLE_BUILDING_ATTACK, DISABLE_BUILDING_ATTACK, TOGGLE_AUTO_CHARGE, TOGGLE_AUTO_REPAIR, TOGGLE_AUTO_HEAL, TOGGLE_AUTO_ATTACK_STRUCTURE

    • CLASS=BA: CALLDOWN_MULE, SET_RALLY_POINT, SET_WORKER_RALLY_POINT, CALLDOWN_EXTRA_SUPPLIES, CHRONO_BOOST, SCANNER_SWEEP, LOAD, UNLOAD_ALL, UNLOAD_UNIT, LIFT_OFF, LAND, LOWER, RAISE, ARM_SILO_WITH_NUKE, MUTATE_INTO_LAIR, MUTATE_INTO_HIVE, MUTATE_INTO_GREATER_SPIRE, UPGRADE_TO_PLANETARY_FORTRESS, UPGRADE_TO_ORBITAL_COMMAND, CANCEL_ORBITAL_COMMAND_UPGRADE, UPGRADE_TO_WARP_GATE, MUTATE_INTO_A_GATEWAY, SALVAGE, UPROOT, ROOT, BUILD_CREEP_TUMOR, CANCEL_AN_ADDON, CANCEL_LAIR_UPGRADE, CANCEL_HIVE_UPGRADE, CANCEL_GREATER_SPIRE_UPGRADE, UNLOAD_ALL_AT, CANCEL_PLANETARY_FORTRESS_UPGRADE, CANCEL_WARP_GATE_UPGRADE, CANCEL_GATEWAY_MUTATION

If CLASS=UA were used, another token has to follow which specifies a unit that used the ability. This has the form: U.ENTITY (where ENTITY is a unit). For example: UA.SPAWN_LARVA,U.QUEEN

If CLASS=BA were used, another token has to follow which specifies a building that used the ability. This has the form: B.ENTITY (where ENTITY is a building). For example: BA.CALLDOWN_MULE,B.ORBITAL_COMMAND

The second form is exact: "SELECT"

This form is used to indicate selecting units and buildings. It is followed by tokens specifying different types of units being selected.

Optionally the following tokens start with a unit count and a multiplier sign: '*'. Then the unit name follows (which includes units, buildings, neutral objects like mineral fields etc.), then optionally the unit IDs between square brackets separated by semicolons (';'). The unit IDs are optional, but if specified, it has to be specified for all units specified by the token. If multiple unit types are selected, unit IDs are optional for each type.

Here are a few SELECT examples:

SELECT examples:

10,SELECT,Nexus

20,SELECT,Nexus[3]

30,SELECT,2*Nexus

40,SELECT,2*Nexus[3;2]

50,SELECT,Probe[2],2*Nexus,3*Zealot[5;6;7]

If you provide a non-listed unit name (below), it will be displayed as "Unknown".

Here is the complete list of unit names that can be used (note that these are not capitalized and spaces are not replaced with underscores):

Colossus, Reactor, Infested Terran, Baneling Cocoon, Baneling, Mothership, Point Defense Drone, Changeling, Command Center, Supply Depot, Refinery, Barracks, Engineering Bay, Missile Turret, Bunker, Sensor Tower, Ghost Academy, Factory, Starport, Armory, Fusion Core, Auto-Turret, Siege Tank, Siege Tank, Viking, Command Center (Flying), Tech Lab (Barracks), Tech Lab (Factory), Tech Lab (Starport), Factory (Flying), Starport (Flying), SCV, Barracks (Flying), Supply Depot (Lowered), Marine, Reaper, Ghost, Marauder, Thor, Hellion, Medivac, Banshee, Raven, Battlecruiser, Nexus, Pylon, Assimilator, Gateway, Forge, Fleet Beacon, Twilight Council, Photon Cannon, Stargate, Templar Archives, Dark Shrine, Robotics Bay, Robotics Facility, Cybernetics Core, Zealot, Stalker, High Templar, Dark Templar, Sentry, Phoenix, Carrier, Void Ray, Warp Prism, Observer, Immortal, Probe, Hatchery, Creep Tumor, Extractor, Spawning Pool, Evolution Chamber, Hydralisk Den, Spire, Ultralisk Cavern, Infestation Pit, Nydus Network, Baneling Nest, Roach Warren, Spine Crawler, Spore Crawler, Lair, Hive, Greater Spire, Egg, Drone, Zergling, Overlord, Hydralisk, Mutalisk, Ultralisk, Roach, Infestor, Corruptor, Brood Lord Cocoon, Brood Lord, Baneling (Burrowed), Drone (Burrowed), Hydralisk (Burrowed), Roach (Burrowed), Zergling (Burrowed), Infested Terran (Burrowed), Queen (Burrowed), Queen, Infestor (Burrowed), Overseer Cocoon, Overseer, Planetary Fortress, Ultralisk (Burrowed), Orbital Command, Warp Gate, Orbital Command (Flying), Warp Prism (Phasing Mode), Creep Tumor (Burrowed), Spine Crawler (Uprooted), Spore Crawler (Uprooted), Archon, Nydus Worm (Canal), Rich Mineral Field, Xel'Naga Tower, Infested Swarm Egg, Larva, MULE, Broodling, Beacon (Protoss Large), Beacon (Protoss Small), Beacon (Terran Large), Beacon (Terran Small), Beacon (Zerg Large), Beacon (Zerg Small), Lyote, Urubu, Male Karak, Female Karak, Male Ursadak, Female Ursadak, Ursadak Calf, Male Ursadak (Exotic), Female Ursadak (Exotic), Automaton 2000, Scantipede, Mineral Field, Vespene Geyser, Space Platform Geyser, Rich Vespene Geyser, Garbage, Garbage (Large), Braxis Alpha - Destrurctible Debris, Destructible Debris, Destructible Rock, The Gift of Freedom (Mengsk Statue Alone), Glory of the Dominion (Mengsk Statue), The Wolves of Korhal (Wolf Statue), Capitol Statue (Globe Statue)

The third form is informal. It has to be written between quotes, for example: "Right click"

Here is a complete list of informal actions:

"Stop", "Hold position", "Move", "Patrol", "Move", "Scan Move", "Attack", "Hold fire", "Cancel", "Set rally point", "Unload All (Command Center/Planetary Fortress)", "Load All(Command Center/Planetary Fortress)", "Unload Unit (Command Center/Planetary Fortress)", "Halt (on building)", "Halt (on unit)", "Cheer", "Dance", "Hold position", "Stimpack (Mixed Units)", "Archon Warp (High Templar or Dark Templar)", "Cancel Egg", "Cancel Research/Upgrade", "Cancel Research/Upgrade in queue", "Cancel in queue", "Cancel a building in progress", "Attack (Mixed Units)", "Stop (Mixed units)", "Mutate into an Infested Terran (Infested Terrans Egg)", "Stop (Burrowed units)", "Cancel Rooting (Spine Crawler)", "Cancel Rooting (Spore Crawler)", "Cancel Creep Tumor (Creep Tumor)"

Many actions have targets. There are 2 types of targets: unit target (the action is targeted at a unit) and location target (the action is targeted at a specified location, specified by x,y coordinates). Most of the actions has targets. Most of the actions can have both types of targets (but only 1 at a time). For example a Calldown MULE action can target either a specific location (x,y) or it can target a Mineral field in which case the MULE will start mining immediately after its birth.

After the action definition there might be optional tokens defining the target.

    • In case of Unit target a "TU" token must follow. After this token a unit name token must follow, optionally specifying the unit ID (as described above).

    • In case of Location target a "TL" token must follow. After this token 2 more tokens must follow specifying the 2 coordinates (x, y) in decimal fraction format.

Examples for specifying different types of targets:

Examples of specifying targets:

10,BA.CALLDOWN_MULE,B.ORBITAL_COMMAND

20,BA.CALLDOWN_MULE,B.ORBITAL_COMMAND,TU,Mineral field

30,BA.CALLDOWN_MULE,B.ORBITAL_COMMAND,TU,Mineral field[123]

40,BA.CALLDOWN_MULE,B.ORBITAL_COMMAND,TL,12.12,23.4