Melee Hit Chance Indoors Dark
This article relates to content added by Ideology (DLC). Please note that it will not be present without the DLC enabled. |
This article is a stub. You can help RimWorld Wiki by expanding it. Reason: 1) Two-way links. |
Melee Hit Chance Indoors Dark is a stat: An offset on melee hit chance if the target is indoors in the dark. Its default value is 0%.
Offsets
- Precepts
- Combat in darkness:
- Preferred: +10%
- Combat in darkness:
Explanation
Darkness Combat Utility is used to calculate when to apply the darkness combat stats.
Indoors and Outdoors
A pawn is considered Outdoors when the roof at their location is not natural or not a thick roof (i.e. Constructed roof).
For reference:
Roof | Thick | Natural |
---|---|---|
Constructed roof | - | false |
Rock roof (thin) | false | true |
Overhead mountain | true | true |
Void metal ceiling | true | true |
If this checks out, the pawn is then tested to see if they are in a room and considered Psychologically outdoors: When the unroofed cell count of the room is ≥ 300, or when the room touches the map edge and the unroofed cell count is ≥ 50% of the room cell count.
As such, a pawn is considered Indoors when they are under a Rock roof (thin), Overhead mountain, or a Void metal ceiling . They are also considered Indoors when they are within a room with an unroofed cell count of < 300, or when the room touches the map edge and the unroofed cell count is < 50% of the room cell count
Darklight Utility
Darklight refers to a default color of
, with a hue range of 49~51%.
For the Red (r), Green (g), and Blue (b) color channels: Light is not considered Darklight when:
- red > green
- red > blue
For the following expression:
If green > blue:
- num = green
- num2 = blue
Otherwise:
- num = blue
- num2 = green
Simply put, the larger value is num, and the smaller is num2.
(num is not zero) and red ≤ (num / 2) and (num2 / num) > 0.85
Light is considered Darklight when the above expression is true.
Lit and Dark
There are 3 different stages of light, defined by PsychGlow (Psychological Glow):
- Dark (Glow ≤ 30%)
- Lit (Glow > 30%)
- Overlit (Glow > 90%)
Glow in this case refers to the cell light level.
When Outdoors, the pawn is considered Lit when the sky light is > 35%, otherwise they will be considered Dark.
When Indoors, the pawn is considered Lit when the light level is Lit and there is no Darklight. The Pawn is considered Dark when the light level is Dark or if there is Darklight.
In short:
Location | Lit | Dark |
---|---|---|
Outdoors | Sky light > 35% | Sky light ≤ 35% |
Indoors | Lit and no Darklight | Dark or Darklight |
Stat Def Data
Def Name Label Label For Full Stat List Offset Label Attributes |
Description | Category | Parameters | Complex Parameters |
Display Priority In Category |
---|---|---|---|---|---|
|
An offset on melee hit chance if the target is indoors in the dark. |
|
|
- | - |
Version history
- Ideology (DLC) Release - Added.