Overview
Currently, pawns with 0% Moving capacity (e.g., legs lost, spine shattered) are unable to respond to normal conversations initiated by others. Their generated dialogue requests remain stuck in the Pending state.
While combat monologues (Urgent type) work fine, normal chat responses (Chitchat type) are silently discarded by the system.
Current Logic & Issues
-
The Root Cause (Filtering):
In TalkService.DisplayTalk(), there is logic to suppress casual talk when a pawn is in danger:
if (pawn.IsInDanger())
{
// Ignores all responses EXCEPT Urgent and User types
pawnState.IgnoreAllTalkResponses([TalkType.Urgent, TalkType.User]);
}
Problem: Immobile pawns are always considered "In Danger", so they immediately discard any normal response.
-
The "Danger" Definition Dilemma:
PawnUtil.IsInDanger() defines danger as:
if (pawn.Downed) return true; // [A]
if (!pawn.health.capacities.CapableOf(PawnCapacityDefOf.Moving)) return true; // [B]
Initially, I thought removing line [B] would fix it. However, in RimWorld, 0% Moving capacity automatically results in IsDowned = true. So even if we remove [B], they will still be caught by [A].
Actual Cases (Observed)
-
Case 1: Combat Monologue (Working)
- A hostile pawn with 0% movement can speak a monologue during combat.
- Reason: Combat monologues are
TalkType.Urgent, which bypasses the danger filter.
-
Case 2: Specific Interaction (Broken)
- Pawn B (Healthy) talks to Pawn A (Legless/Immobile).
- AI generates a
Chitchat response for Pawn A.
- Pawn A is
Downed (due to no legs) -> IsInDanger() == true.
- The
Chitchat response is filtered out and never shown.
-
Case 3: Group Cell Deadlock (Broken)
- Simultaneous conversations occur among prisoners in a shared cell.
- The conversation queue reaches a pawn with movement paralysis (0% Moving).
- Result: Because the immobile pawn discards the response but holds the turn, the queue stalls. All subsequent dialogues from other prisoners remain stuck in the Pending state indefinitely.
Expected Behavior
A pawn should be considered "safe enough to talk" if they are conscious, even if they are downed due to physical disability.
- Scenario A: Pawn downed by pain shock/unconsciousness -> Silence (Correct)
- Scenario B: Pawn immobilized by missing legs but fully conscious -> Can Chat (Currently Broken)
Proposed Solution Direction
We need to refine IsInDanger() to allow conscious downed pawns to speak.
Instead of just checking pawn.Downed, we should check if they are capable of Consciousness(or Communication?).
Overview
Currently, pawns with 0% Moving capacity (e.g., legs lost, spine shattered) are unable to respond to normal conversations initiated by others. Their generated dialogue requests remain stuck in the
Pendingstate.While combat monologues (
Urgenttype) work fine, normal chat responses (Chitchattype) are silently discarded by the system.Current Logic & Issues
The Root Cause (Filtering):
In
TalkService.DisplayTalk(), there is logic to suppress casual talk when a pawn is in danger:Problem: Immobile pawns are always considered "In Danger", so they immediately discard any normal response.
The "Danger" Definition Dilemma:
PawnUtil.IsInDanger()defines danger as:Initially, I thought removing line
[B]would fix it. However, in RimWorld, 0% Moving capacity automatically results inIsDowned = true. So even if we remove[B], they will still be caught by[A].Actual Cases (Observed)
Case 1: Combat Monologue (Working)
TalkType.Urgent, which bypasses the danger filter.Case 2: Specific Interaction (Broken)
Chitchatresponse for Pawn A.Downed(due to no legs) ->IsInDanger() == true.Chitchatresponse is filtered out and never shown.Case 3: Group Cell Deadlock (Broken)
Expected Behavior
A pawn should be considered "safe enough to talk" if they are conscious, even if they are downed due to physical disability.
Proposed Solution Direction
We need to refine
IsInDanger()to allow conscious downed pawns to speak.Instead of just checking
pawn.Downed, we should check if they are capable ofConsciousness(or Communication?).