-
Notifications
You must be signed in to change notification settings - Fork 1
GasDef Properties
All possible properties for you GasDefs.
Source: GasDef.cs
<SCGF.GasDef ParentName="GasBase">
<defName>MyCustomGas</defName>
<label>my custom gas</label>
<!-- RGB colour values. -->
<color>(0, 123, 234)</color>
<!-- Density decreases by 3 (~1%) every gas tick. -->
<dissipationRate>3</dissipationRate>
<!-- Can diffuse into surrounding cells. -->
<diffuses>true</diffuses>
<appliesTo>
<!-- Apply to pawns with 'organic' flesh... -->
<li Class="SCGF.Filters.Organic" />
<!-- That also have the kind or psychopath traits. -->
<li Class="SCGF.Filters.Traits">
<traits>
<li>Kind</li>
<li>Psychopath</li>
</traits>
</li>
</appliesTo>
<immunityWhen>
<!-- Mouth-covering protective apparel (like gas masks) mean immunity for this gas. -->
<li Class="SCGF.Filters.ProtectiveApparel">
<types>
<li>Mouth</li>
</types>
</li>
<!-- Alternatively, pawns with red eyes are also immune. -->
<li Class="SCGF.Filters.Genes">
<genes>
<li>Eyes_Red
</genes>
</li>
</immunityWhen>
<actions>
<!-- Give the Carcinoma hediff. -->
<li Class="SCGF.Actions.ApplyHediff">
<hediffDef>Carcinoma</hediffDef>
</li>
<!-- As well as toxic buildup. -->
<li Class="SCGF.Actions.DoToxicDamage" />
</actions>
<immuneActions>
<!-- Immune pawns get sand in their eyes lol. -->
<li Class="SCGF.Actions.ApplyHediff">
<hediffDef>SandInEyes</hediffDef>
</li>
</immuneActions>
<texPath>Things/Gas/GasCloudThickA</texPath>
<shaderPath>Map/GasRotating</shaderPath>
</SCGF.GasDef>These properties must be defined!
| Type | string |
| Example |
<defName>MyCustomGasWow</defName> |
Unique identifier for this gas.
| Type | string |
| Example |
<label>tox gas 2: electric boogaloo</label> |
Display name for this gas.
| Vanilla Values | |
|---|---|
| Blind Smoke | blind smoke |
| Tox Gas | tox gas |
| Rot Stink | rot stink |
| Deadlife Dust | deadlife dust |
| Type | color |
| Example |
<color>(255, 255, 255)</color> |
RGB colour values, can either be from 0 to 255 or 0 to 1, alpha supported. I like to use this colour mixing tool.
| Vanilla Values | |
|---|---|
| Blind Smoke | (200, 200, 200) |
| Tox Gas | (180, 214, 24) |
| Rot Stink | (214, 90, 24) |
| Deadlife Dust | (3, 13, 51) |
| Type | int |
| Default |
<dissipationRate>0</dissipationRate> |
How many "particles" of the gas are lost every gas tick. Goes from 0 to 255, with 0 meaning the gas will last forever, and 255 meaning the gas will almost instantly disappear.
| Vanilla Values | |
|---|---|
| Blind Smoke | 4 |
| Tox Gas | 3 |
| Rot Stink | 4 |
| Deadlife Dust | 3 |
| Type | bool |
| Default |
<diffuses>false</diffuses> |
Whether this gas can spread into adjacent cells when possible.
| Vanilla Values | |
|---|---|
| Blind Smoke | false |
| Tox Gas | true |
| Rot Stink | true |
| Deadlife Dust | true |
| Type | List<GasFilter|> |
| Default | Empty List |
| Example |
<appliesTo>
<!-- Apply to pawns with 'organic' flesh... -->
<li Class="SCGF.Filters.Organic" />
<!-- That also have the kind or psychopath traits. -->
<li Class="SCGF.Filters.Traits">
<traits>
<li>Kind</li>
<li>Psychopath</li>
</traits>
</li>
</appliesTo> |
List of Gas Filters that determine which pawns this gas can affect. A pawn must pass all of the filters to be affected.
| Type | List<GasFilter> |
| Default | Empty List |
| Example |
<immunityWhen>
<!-- Mouth-covering protective apparel (like gas masks) mean immunity for this gas. -->
<li Class="SCGF.Filters.ProtectiveApparel">
<types>
<li>Mouth</li>
</types>
</li>
<!-- Alternatively, pawns with red eyes are also immune. -->
<li Class="SCGF.Filters.Genes">
<genes>
<li>Eyes_Red
</genes>
</li>
</immunityWhen> |
List of Gas Filters that filter pawns that the gas would otherwise apply to. If a pawn passes any of the filters they are counted as immune to the gas.
| Type | List<GasAction> |
| Default | Empty List |
| Example |
<actions>
<!-- Give the Carcinoma hediff. -->
<li Class="SCGF.Actions.ApplyHediff">
<hediffDef>Carcinoma</hediffDef>
</li>
<!-- As well as toxic buildup. -->
<li Class="SCGF.Actions.DoToxicDamage" />
</actions> |
List of Gas Actions that run for every pawn that is affected by this gas and not considered immune.
| Type | List<GasAction> |
| Default | Empty List |
| Example |
<immuneActions>
<!-- Immune pawns get sand in their eyes lol. -->
<li Class="SCGF.Actions.ApplyHediff">
<hediffDef>SandInEyes</hediffDef>
</li>
</immuneActions> |
List of Gas Actions that run for every pawn that is affected by this gas and considered immune.
| Type | string |
| Default | Things/Gas/GasCloudThickA |
| Example |
<texPath>Things/Item/Skull/Skull_a</texPath> |
Path to the texture to use for the gas cloud, you shouldn't change this unless you know what you're doing.
| Type | string |
| Default | Map/GasRotating |
| Example |
<shaderPath>Map/SolidColor</shaderPath> |
Path to the shader to use for rendering this gas, you shouldn't change this unless you know what you're doing.

Noticed a mistake or have a suggestion to improve this page? Reach out via GitHub issues, Steam discussions, or mention me on Discord!