Documentation: Reaction
List of known properties, their default values, types, ranges and other information for <Reaction/> XML tables
These are used in the materials file for the game alongside the <CellData/> tables
Property | Default Value | Value type / range | Info |
---|---|---|---|
fast_reaction | 0 | bool | Prioritises the reaction over others? |
probability | 0 | int* | Decides the probability to take place. Effects seem to flatten out setting it at around 0 and 100?
*Value is taken as a float, multiplied by 100 and then converted to int. Basically its an int with 2 decimal placed, like 100.00 |
req_lifetime | 0 | int | untested. Presumably checks against the lowest lifetime of the input materials and if it is too low, it doesn't react until the lifetime gets high enough (materials do not need to have a lifetime field in the CellData?) |
blob_radius1 | 0 | byte | Radius of Output1 Blob. Allows 1 pixel of a material to create more than 1 pixel of a product. |
blob_radius2 | 0 | byte | Radius of Output2 Blob. Allows 1 pixel of a material to create more than 1 pixel of a product. |
blob_restrict_to_input1 | 1 | bool | Restricts the Output1 block to Input1 |
blob_restrict_to_input2 | 1 | bool | Restricts the Output2 block to Input2 |
destroy_horizontally_lonely_pixels | 0 | bool | ? |
convert_all | 0 | bool | When enabled, converts all of input1 that is in contact with the reaction and all of input2 that is in contact with the reaction as if they both had very large blob radiuses |
entity | "" | string
(filepath to entity) |
Summons an entity at the location of the reaction
String should be the filepath to the entity.xml |
direction | "none" | "none", "top", "bottom", "left", "right" | Direction of reaction (from Input1 to Input2?)
ENUMS for -1, 0, 1, 2, 3, 4 respectively |
ExplosionConfig | ConfigExplosion | Use <ExplosionConfig field1="val1" field2="val2"></ExplosionConfig> in the materials XML
| |
audio_fx_volume_1 | 0 | float | Volume of reaction sound? |
cosmetic_particle | "" | <ParticleEffect> | Particle Component created when the reaction occurs. See ParticleEffect for more info. |
input_cell1 | REQUIRED | string | First input material name or [material tag]
Game will crash if not a correct material name (so unknown will crash) |
input_cell2 | REQUIRED | string | Second input material name or [material tag]
Game will crash if not a correct material name (so unknown will crash) |
intput_cell3 | "" | string | Third input material name or [material tag] |
output_cell1 | REQUIRED | string | First output material name or [material tag]
Game will crash if not a correct material name (so unknown will crash) |
output_cell2 | REQUIRED | string | Second output material name or [material tag]
Game will crash if not a correct material name (so unknown will crash) |
output_cell3 | "" | string | Third output material name or [material tag] |
Technically Input and Output Cells 1 & 2 all default to "unknown", but "unknown" is exempt from any and all reactions (even if you create a CellData for it). The game will just show an error in the logs and move on without compiling the reaction
Engine Tags
Much of the game's reactions are handled through material tags, such as the [water] tag mixing with Odd Brickwork to create Smoke and Teleportatium, or the [corrodible] tag which allows Acid to burn through materials. Almost all material tags are defined in the game's materials.xml file
, but there are exceptions to this. There are a few known engine-side tags that are almost entirely unreferenced in the base game, the sole known example of one of these tags being used is Mimicium mimicking [any_liquid]. There are 3 known engine tags:
Tag | Uses | Definition |
---|---|---|
[*] | Unused | Simply refers to any material |
[any_liquid] | used by Mimicium | Refers to any material with cell_type="liquid" and liquid_sand="0"
|
[any_powder] | Unused | Refers to any material with cell_type="liquid" and liquid_sand="1"
|
While very unlikely, it is entirely possible there may be more engine tags than these three. However if there are any others, these are the only ones that have been discovered thus far.
Keep gambling.
unknown
unknown
is not an actual material in the base game, but it is used as a placeholder for a non-existent material within the engine for adding reactions. If either the first or second material for the input or output of a material is left blank or if the first input of a reaction is "air", it will default to "unknown", and the engine will reject any reaction that has a material with this name. Due to this very unique functionality, any material with the id "unknown" cannot have any reactions applied to it, this includes direct engine tags such as [*]
or [any_liquid]
. Suffix/Prefix based reactions also have no effect, and the material cannot externally be set on fire (it can however burn away if it starts on fire with the material's on_fire="1"
property). This unique behaviour means it is almost entirely disconnected from the rest of the game as a material
This has yet to be taken advantage of by any mods, but it should be noted that only one mod can pull this trick off at a time, so it should ideally be used sparingly, possibly have a priority system which checks if other mods are using the material namespace at the given moment, idk