This page describes how to use the in-game editor overlay with its command line interface and documents many internal game variables (cvars).
Index
Editor Overlay
Access the editor overlay either by going straight to Sandbox Mode from the Main Menu, or within gameplay by pressing “\”. The editor overlay is primarily a command driven, but has a number of direct keybindings which are described in this section. Mouse over the console window to enter commands. The overlay is always in either FLY, COMMAND, or EDIT mode.
Read this Introduction to Editor Mode first.
Keybindings
- ‘1’ to switch to FLY mode (takes control of selected ship). Same controls as in-game flying.
- ‘2’ to switch to COMMAND mode, which allows selecting and manipulating ships. Within command mode, left click to select ships and right click to set ship destinations. This is the default mode.
- ‘3’ to switch to EDIT mode, which allows selecting and manipulating individual blocks. Same controls as the in-game ship editor.
- WASD pans the camera in command and edit mode
- Double click to move the deploy location, which appears as a blue circle overlaid with an X. Commands which spawn things will spawn at this location.
- ‘p’ to freeze the game simulation
- ‘o’ to single step the game simulation
- ‘v’ hides the overlay (toggle)
- ‘/’ repeats the last command
- ESC, ‘~’, and ‘\’ exit command mode
- Ctrl-s runs the “level_save” command
- ‘[‘ and ‘]’ adjust the size of the console
- ‘{‘ and ‘}’ adjust the time factor (speed up, slow down the game simulation)
Selected ships have green boxes around them. Certain commands (export, ssave) only work on the primary selection, which additionally has a blue box around it. Standard and primary selection work in all modes – in fly mode the ship under control is considered selected.
Sectors are delimited by green lines. Sandbox mode has a single large sector. In the main game, 9 sectors are loaded at a time. Commands which manipulate sectors (gen, region, leve_save, etc.) work on the sector in the middle of the screen.
Cvars reference
The CVARS are internal variables that control many aspects of Reassembly. Cvars can be modified immediately within the console via the “cvar” command, or by modifying the cvars.txt in the save directory. cvars.txt is loaded at game startup.
This guide omits – for convenience – the ‘k’ which appears in front of all CVARS elements: eg. kBigTimeStep, kDamageReproduceCooldown, etc.
Time Step:
BigTimeStep, TimeStep and SuperTimeStep
The timestep commands determine how often certain aspects of the AI runs. The time unit is in seconds and the smaller you make these amounts, the more taxing it will be on the processor.
DamageDefendTime
This represents the amount of time it takes for a damaged enemy to cease pursuing you.
DamageReproduceCooldown
This represents the amount of time it will take for an enemy to reproduce a child ship after being damaged.
BlockBigTimeStep & BlockSuperTimeStep
Controls how often the AI makes a decision with regards to blocks. This does not include Launcher or Tractor Beam blocks. BlockSuperTimeStep checks on Seed blocks only.
Fleets:
FleetComposeFuzzyP
Scale at which to randomize between ships with similar P slightly when composing fleets.
Sandbox
ConsoleLines
Sets how many lines are in the Console when loaded.
SandboxSize
Sets the radial size of the sandbox.
GarbageCollectEnable
Removes dead ships, and blocks that leave the sandbox bounding area.
Reproduce:
AIParentReproduceCooldown
After a ship is created, this variable tells the AI how long to wait until the reproduce ability is enabled.
AIParentPFleetRatio
This variable determines how large of a fleet AI spawner ships will attempt to maintain. All excess ships spawned will be released as rogue ships, which will not be considered children of the fleet. The ratio works within this formula:
Mothership P * kAIParentPFleetRatio = Fleet size
Pathfinding:
AIPathMaxQueries
The AI Pathfinder will give up if a path is more than X number of turns and straight lines. Making this variable higher equates to more CPU calculations.
AIPathTimeout
This variable represents the time, in seconds, that a path will be considered as valid. It’s an upper bound, meaning that the AI will attempt to repath every X seconds.
AI Targeting:
SensorRangeMultiplier
Allow globally increasing ship sensor range (set it to e.g. 2, 3).
AITargetMin & AITargetThreshold
This combination of variables determines what ships the AI targets. Both of these variables refer to a ship’s deadliness.
The AI will not target anything beneath the AITargetMin unless the AITargetThreshold * Ship’s P is less than AITargetMin
AutoTargetRadius
This variable controls the units of distance around the cursor that a ship will be targeted. Decreasing this requires more accuracy from the player.
AutofireSpreadWeight
The larger this variable is, the more likely your ship’s turrets will target multiple targets over smarter choices.
BadAimErrorAngle
Angle, in radians, that controls the BAD AIM flag.
Agents:
The term “Agents” refers to a ship that is user-created, that will appear within your game as you play.
AgentCount
This represents the number of Agents that spawn when a new game is created.
AgentMaxDeadly & AgentMaxShips & AgentMinDeadly
These three variables control the size and deadliness of an agent fleet. When spawning an Agent fleet, the game will continue to produce ships until either the Max Ships or Max Deadly variable is reached.
AgentMinSpawnDist
During the initial map generation, an Agent fleet will not be placed any closer to the player’s ship than this variable.
Because Agents tend to be more dangerous than the most of the game’s starter ships
AgentSpeed
Controls Agent movement speed in the universe.
AgentDirectory
Sets the directory from which to pull custom agents.
Effects:
BeamGlow & BeamHalo
These two variables affect how lasers look. Both of these control units of distance (width of the beam), and each of these control different parts of the beam. The bigger the number, the bigger the laser visibility.
BloomBlocks
Controls the bloom effect for blocks
BloomBlurRadius
This is the size, in pixels, if the blur effect.
BloomBrightness
This variable controls the bloom brightness.
BloomIntensity
This variable (between 0 and 1) controls how much bloom will be on.
BloomRadius
This is the size, in pixels, of the bloom effect.
BloomResFactor
This controls the bloom associated with weaponry blocks.
BloomScale
This variable controls how many pixels should be used for the bloom effect.
BloomTonemap
Turns on/off tonemapping.
BlurFactor & BlurMenuRadius
These variables control the size of the blur used for background and menu.
BlurMinDepth
If objects in the z dimension meet or exceed this value, the blur effect will turn on.
DisruptIndicatorAlpha & DisruptIndicatorSize
Control the size of the effect that appears on the screen edges when the player ship is hit.
DopplerFactor
Controls the SFX Doppler effect.
DiscoverDistance
Controls the size of the dotted line around objective objects. Allows the player to activate objectives more easily.
kParticleExplosionColor0
Allows you to set the colour of explosions.
kParticleSmokeTime
Allows you to set howlong smoke particles last. ( When blocks are damaged. )
kParticleFireColor0
Allows you to set the colour of fire. ( When blocks are damaged. )
Blocks:
HealMaxDist
Controls the maximum number of blocks through which a healing laser can heal from point of contact with entity.
BlockElasticity & BlockFriction
These two variables control the physics of blocks: namely the elasticity and friction as the names suggest.
BlockExplodeChance
This variable controls the probability that a block will create an explosion (upon its destruction), causing further damage. It operates on a “1 in X” chance-based system, meaning that the higher the number, the lower the chances of an explosion occurring. Setting this to 1 will pretty much cause chaos.
BlockImpulseDamage & BlockSolveDamage
These two variables control the impact damage for blocks. Impulse uses mass and velocity to calculate the damage to a block while Solve represents the minimum amount of impact damage that will be given.
BlockOverlap
This variable grants a certain amount of overlap to blocks during construction. Setting to 0 may break the game.
CommandHaloDeadliness & CommandHaloSize
These two variables control the light that emits from the Command block. Halo Deadliness controls the size as proportional to P value while Halo Size controls the size as proportional to the block size.
Memory:
BlockMemoryPoolSize
This variable controls how much memory is allocated for block storage. The default, 400kb, should be more than sufficient.
MemPoolMaxChain
This controls the total number of memory pools. The default is more than the vast majority of players will need.
Camera:
CameraAutoZoom & CameraEnablePan
Enable and disable the automatic camera movement.
CameraPanTime
This controls the auto pan feature.
CameraWheelZSpeed
Controls the mouse wheel sensitivity of the camera’s zoom movements.
Taking Images:
CleanBackground
Turning this on allows for a black background. Useful for taking screenshots.
ClusterImageSize
This variable controls the size of images for DumpShipImages.
DumpShipImages
When turned on, the game will take and store a picture of every ship upon start.
Resource Collection:
CollectAnimationTime & CollectBlinkTime
These control how long it takes the resource animation to complete.
DeferredCollectInterval & DeferredCollectRadius
Controls how often the resources are collected and how the grouping of collections works.
Construction Editor
ConstructorBlockLimit
This number controls how many blocks can be placed in the editor.
ConstructorViewBounds
The view bounds control the minimum and maximum view sizes for the ship editor.
Fonts
DefaultFontFile, FallbackFontFile, MonoFontFile, SymbolFontFile & TitleFontFile
Each of these allow you to specify a specific and game-recognizable font for the specified purpose.
Utility
kWriteJSON
Writes blocks.json to the Reassembly data directory.
WriteBlocks
Writes blocks.lua to the Reassembly data directory.
ModExportFactionStart
Controls mod export faction ID start
ModExportBlockStart
Controls mod export block ID start
PortRenderNormals
Help for modders to debug port normals.
Command Reference
Commands
help [COMMAND]:
Lists documentation for commands.
Usage Example
> help add
NOTE: This would list the two commands ADD and ADDBLOCKS, along with their variables and their proper syntax.
find [SEARCH STRING]:
List commands that match the search string you type. Also searches the command help string.
sopen <NAME>:
Open a block cluster by name.
ssave [NAME]
Save the selected block cluster using a name of your choosing.
palette <FACTION>:
Palette draws all unique blocks used to build a given faction. The primary difference between PALETTE and MINPALETTE is that PALETTE will also draw variants of the sized blocks.
minpalette <FACTION>:
Minpalette draws the minimum number of blocks for a given faction. The primary difference between PALETTE and MINPALETTE is that PALETTE will also draw variants of the sized blocks.
fleetpalette <FACTION>:
Type the command along with the faction number to see a row of deactivated ships, summing up all ships in your chosen faction. Protip: you can type “fleetp” as a shortcut.
activate:
This command turns on the AI for the selected ship. This requires a ship be present and selected to work and effectively makes it start moving, shooting, and reacting to other objects.
deactivate:
The opposite of the ACTIVATE command, this command turns off the AI for the selected ship. This requires a ship be present and selected to work and effectively makes it stop moving, shooting, and reacting to other objects.
block
Spawn a block at the cursor. Blocks are parsed in the same format as in blocks.lua. You can also specify just a block ID to spawn it directly.
Usage Examble
block 3
block { features=thruster, shape=octagon }
command
Modify command/ai fields. See the definition of “Command” and “ECommandFlags” appendix on the Docs page.
Usage Example
> command {flags=ATTACK, sensorRadius=9999, resources=9999}
Modding Tools
reload [VARIABLES]
Reload various modding data files, including block definitions, cvars, and shaders.lua
refaction <FACTION>:
REFACTION takes a ship from one faction and reinterprets it, using the blocks of another faction. Will try its best to make the change, but will not do it if comparable blocks are not available. The command will attempt to suggest a compatible faction if your selected faction will not work.
Usage Example
> refaction 12
recolor <COLOR0> <COLOR1>:
Recolor whatever object is selected to the two hand-picked colors you provide. Please use the following format for each color: 0xRRBBGG, the same as used in HTML.
Usage Example
> recolor 0x010199 0x990101
Sector/World
fleet <FACTION> [P TOTAL] [COUNT]:
At the cursor position, spawn a faction of ships meeting your set criteria of Power count and Number. The first variable tells which faction (by number of faction), the second variable is the P total (the approximate amount of P you’d like to see used to generate your fleet), and the number of ships you’d like to see appear. Note that your P is spread out among all the ship count, so a large ship count will build smaller ships against your P total.
Usage Example
> fleet 8 200000 30
ship <SHIP NAME>:
Summon a ship by name. Use the TAB button to see what ships are available.
add <SHIP REGEX> [COUNT]:
Spawn and scatter ship objects throughout the sector. Requires a ship name, defaults to a number of 1.
Usage Example
> add 8_supercorvette 5
asteroid <SIZE> <SIDES 1> [SIDES 2] [SIDES 3]
Generate asteroids using up to 3 different shape types. First determine the size (how many blocks the asteroid will be comprised of). The next three variables all determine the shapes of the blocks that make up the asteroid. The variables mean the number of sides.
Usage Example
> asteroid 50 3 5 8
tiling <SIZE> <TYPE>
Generate a tiling asteroid as large as you’d like. Something to drive around, or through, depending on the mining abilities of your spaceship. The SIZE variable is the number of blocks. The TYPE variable represents programmed tile sets assigned numbers 0 through 6.
Usage Example
> tiling 100 3
plant <TYPE> [SUBTYPE] [SIZE]
Nearly identical to the APLANT command with the following differences: you’re only creating a single plant and that plant doesn’t require a surface, it spawns at the cursor position.
Usage Example
> plant 2 3 50
aplant <TYPE> [SUBTYPE] [SIZE] [COUNT]
Spawn a random assortment of plants using the following variables. Note that this command attempts to place plants given available surfaces in the active sector, but is not always successful due to surface area availability and the shape of the plant generated. Use of APLANT may require multiple attempts before a success is noticed.
Note also that types 1, 2 and 3 correspond to green, blue and pink, respectively, in increasing order of resource generation.
TYPE
1 (blue), 2 (pink), or 3 (green). These colors only distinguish how often resources are produced, from least to most frequent. By using higher-valued numbers, the variable defaults to a value of 1.
SUBTYPE
This represents the color of the flowering elements.
SIZE
This represents how many blocks the plant will have. Larger plants have a lower probability of successful generation.
COUNT
Number of plants to place in the play area. A higher count request will merely make more attempts to place a plant, and will not place copies of a specific plant.
Usage Example
> aplant 2 3 65 100
fill <FLAGS> <FILLPERC> <SIZE>:
Fill your sector with a customized asteroid field. The first variable are the flags. Use the TAB button to see what asteroid types are available. The second variable is the sector fill percentage. The third variable is the size of each asteroid in number of blocks.
Usage Example
> fill EXPLOSIVE 20 10
penrose [BLOCK SCALE] [ITERATIONS]:
Generate a nifty penrose asteroid. The penrose is, for all intents and purposes, circular in shape, but is comprised of a set of tiles placed in the very nifty Penrose tiling sequence. Note that both values should be kept to 9 or less.
Usage Example
> penrose 4 5
region <FACTION>:
This command uses the world generation system to fill the current sector with ships and asteroids for the supplied faction based on the region specifications in regions.lua.
target [SIZE] [HEALTH] [SHIELD]:
Generate a test dummy to attack and taunt with all your muster. The HEALTH variable gives health PER BLOCK, so be careful not to generate a target dummy that will overpower your weak little ships. The SHIELD variable merely turns on (1) or off (0).
Usage Example
> target 100 10000 1
Level File Manipulation
level_save [NUMBER]:
Save your current level as a numbered LUA file. Defaults to the currently loaded level file, which in turn defaults to 0.
revert [LEVEL]:
Revert back to previous save or load a desired save state by specifying the level number.
gen [LEVEL]:
Use the GEN command to randomly generate a level (similar to going to a wormhole) or callout a saved file to load it.
clear
Deletes everything in the sector.
Export
export <NAME> [AUTHOR]:
Export your selected ship with this command. Type the ship’s name as well as your name (or penname) to generate a LUA file with the ship’s information. The command line will display where you can go to retrieve your ship.
Usage Example
> export Bootsy Fernando
import [PATH]
Use the IMPORT command in conjunction with a ship file path (LUA file), to pop a ship into your level.
IMPORT can also load fleet files (usually .lua.gz) as downloaded from the wormhole feed: http://www.anisopteragames.com/sync/latest.html.
agent
Spawn a complete agent fleet. The word “agent” refers to a complete fleet of ships designed by one player – parallel to the player’s own fleet. The command requires no further specifications. Use this command several times consecutively for an instant AI battle.
upload
This command will upload your fleet to the Reassembly server. They’ll fly out into the ether and begin destroying other Reassembly players, who themselves are completely unawares of what fate awaits them.
This is similar to the functionality used when entering a wormhole.
constructor [FACTION NAME]
Open the ship constructor with the faction of your choice. Immediately begin editing ships in that faction.
Usage Example
> constructor 7
Utility
options [NAME=VAL]
Control the game’s options from the command line. Not nearly as easy as just going to the Options menu, but some folks like a challenge.
Usage Example
> options musicVolume=90
debug [TYPE]
Use the debug command in conjunction with one or more of the available types to toggle the debug information on that type. Use the TAB button after typing “debug” to see available options.
AI – toggle AI debugging overlay
PROFILE|STUTTER – toggle performance graphs
Usage Example
> debug ai
zonefeatures [TYPE]
Toggle global flags for the current gameplay simulation zone. Available flags:
- RESOURCES – zone has resource packets. Block regeneration rate is also reduced with resources disabled.
- SPACERS – a physics optimization that replaces the collision shape for each block with a convex hull under certain conditions. See also “debug SPACERS”,
- BACKGROUND – enable background stars and halo graphics. Will draw a grid when background graphics are disabled.
- PARTICLES – enable particle effects (thruster trails, explosions, etc.).
- UNDO – enable snapshoting of rectangles of zone state before editing operations to support undo (used in sandbox by default).
- UNDO_ALL – enable snapshoting of entire zone on editing operations (used in ship constructor by default).
- NODEBRIS – destroy all detached blocks when a block cluster splits instead of just disconnecting them.
Usage Example
> zonefeatures SPACERS
screenshot
Take a screenshot. Also you can use F2.
Scripting and Utility
exit
The EXIT function is similar to the \ key in that it quits the command line.
quit
Quit to desktop. Do not pass go. Do not collect $200.
freeze
Very similar to simply pressing the “P” button on the keyboard, FREEZE stops the game in its tracks.
cursor <X> <Y>:
Set an absolute position for the cursor using x/y coordinates.
Usage Example
> cursor 100 250
rcursor <X> <Y>:
Short for, relative cursor, it’s related to the CURSOR command. Move the cursor a precise amount of steps to a new location. Use the mouse and double-click feature if you like to live dangerously!
repeat <TIMES> <COMMAND>:
Repeat a single command multiple times. It could be useful…
Usage Example
> repeat 3 aplant 2 2 50 10
view [ENABLE]
Turning this on (set to 1) will make the console disappear. Pressing any other key will reenable the console. The quickkey command of “v” will also open/close the console.
God Powers
explode [RADIUS] [DAMAGE]
If your sector is looking a little too smug for its own good, the explode command is an excellent solution. If in the Sandbox, set your cursor position, else just define a radius and amount of damage to see some chaos in action.
Usage Example
> explode 1000 1000
god
Use the GOD command to make your ship (or the selected ship) invincible.
noclip
Turn off collision detection for a selected ship. It’s like being a ghost ship!!!! Oooooooooooooooooh
resource [QUANTITY]
Adds a specified number of resources to the cursor position.
wormhole
Use the WORMHOLE command to slap a big ol’ swirling sucky thing on the screen… then fly your butt into it.
reveal
Sick of exploring? This nifty command shows where everything is on the map! Cheating is fun!
conquer
Unlocks all sectors in favor of your faction, but does not destroy all opposing ships. Essentially, this action redraws the map, hiding the possessors of all sectors from you.
Fonts/Text
write <CHARS> [NAME]:
Always wanted to write terrible poetry in a font of purple triangular shapes with blue plants growing out of each letter? Well, now you can. Simply create your fancy font using the SFONT command and then type out your poorly selected words using atrocious spelling and grammar using the WRITE command. You’re welcome.
Usage Example
> write "It was a dark and stormy night" myfont
sfont <CHARS> [NAME]:
Create and save your own font using Reassembly blocks. It’s actually kinda nifty. Select an object to save it as a font.
Usage Example
> sfont a myfont
wfile <filename> [FONT_NAME]:
Always wanted to read The Great Gatsby written in a font of purple triangular shapes with blue plants growing out of each letter? Well, now you can. Simply create your fancy font using the SFONT command and then point the console in the direction of your great American novel using the WFILE command.
Usage Example
> wfile c:/mahbooks/bucketlist/tehgats.txt myfont
Tournament
tournament commands accept either editor selector or file arguments. The files specificed may be (1) a ship.lua file or (2) a save.lua file (aka an agent file or a blueprint file) (3) a directory containing 1 and 2.
pool [ships…]
Runs each ship against all other selected ships.
bracket [ships…]
Start a single-elimination tournament bracket with all selected ships.
arena [team a] [team b]
Start a single-elimination tournament bracket with all selected ships. (NOTE kEnableDevBindings=1 must be set)
There are some Cvars not shown here, primarily the physics controls and button options. Things like KSpeedOfSound, KhasDemoButton, KHeadlessMode and KSpinnerRate for example. Is there another full documentation or wiki i can refer to to sate my curiosity?
The cvars that are not documented are not very interesting if you aren’t developing Reassembly :-D.
It is possible to use a command to unlock all factions, including modded ones? Or do you have to go into configs to do that?
You have to edit configs but it’s pretty simple. Just add the faction numbers to “unlock.lua” in the save directory. It should look something like
{factions={2, 3, 4, 11, 12, 15}}
Please expand on the functionality of each zoneFeature, thanks. Also, how would one go about spawning the gold farmer plants surrounding the asteroids spawned with asteroid/fill/region? For example I’m making a mod that uses plants and I’d like to test their resources in sandbox first.
I added a description of each flag to the description for the zonefeature command. For testing plants, you can use the “add” command to a lot of a plant design quickly, using the same logic as the world generator. For example, “add 5_crop 100” will try to add 100 of the crop plants, placing them randomly. You can also use the “region” command to actually read your regions.lua file and fill the sector based on the description, which is ideal for testing a mod.
how do you generate a level it says gen level 10 failed and so on for a few different numbers why wont it work?
Try the “region” command – e.g. “region 8”.
You can also generate custom levels by combining “fill”, “aplant”, “fleet”, and similar commands.
How do I select another ship in console mode?
Whatever, Got it.
See the (newly added) Editor Overlay section.
When I save my recolored ships the new colors aren’t saved. How do I save my new colors?
How are you saving the ship, and which command are you using to recolor?
I think he’s using ssave instead of export