CombatExtended-Continued / CombatExtended

Combat Extended mod for RimWorld
377 stars 254 forks source link

[Bug]: Pawn Stuck and throwing error every tick #2922

Open chri20q5 opened 10 months ago

chri20q5 commented 10 months ago

Rimworld version: 1.4.3901 rev238 Combat Extended version: 1.4.5.5 Combat Extended source (Steam, GitHub, etc.): Github Your operating system: Windows 10 Your mod list: https://rentry.co/iuo4v

Description I was raided and one of my pawns tried to melee an invader whom I guess died. After this issue the pawn tried to change their work to repairing a wall, but was instead frozen and the game started throwing an error every second into the log.

I have tried reloading, killing and resurrecting the pawn, capturing the pawn and everything else I can think of. Whille killing and capturing the pawn removes the error every tick, as soon as the pawn is alive again, or has been put down onto a prisoner bed, the error comes back.

Expected behavior For it to not throw that kind of error xD I mean all over the log it screams combat extended so I just wanted to provide the log for you guys to maybe help me out with this out problem.

To reproduce I would think to have a pawn try and melee an invader that was shot dead right before the melee was executed.

Screenshots & log dumps https://gist.github.com/HugsLibRecordKeeper/369dc1b5f76bdb9a25c22c18c1a357e8 https://imgur.com/a/stqXX1W

Complete the following checklist I hereby verify that I have done the following:

SamaelGray commented 10 months ago

What race was your pawn that tried to melee the enemy pawn? Also what was the melee weapon, if any, that the your attacking pawn was wielding?

chri20q5 commented 10 months ago

What race was your pawn that tried to melee the enemy pawn? Also what was the melee weapon, if any, that the your attacking pawn was wielding?

Standard baseliner, no melee weapon equipped

SamaelGray commented 10 months ago

Absolutely nothing equipped when attempted to melee attack? Can you try and see if your other colonists can melee attack other pawns? It might be something wrong with your pawns in general or that specific pawn had something unique about it. Your issue usually happens when a melee attacker tries to attack another pawn with a weapon/anything that does not have proper melee weapon tools (tools are what defines the attack types of weapons in melee combat). The attacker pawn was capable of violence, right?

chri20q5 commented 10 months ago

Absolutely nothing equipped when attempted to melee attack? Can you try and see if your other colonists can melee attack other pawns? It might be something wrong with your pawns in general or that specific pawn had something unique about it. Your issue usually happens when a melee attacker tries to attack another pawn with a weapon/anything that does not have proper melee weapon tools (tools are what defines the attack types of weapons in melee combat). The attacker pawn was capable of violence, right?

A revolver was equipped by my melee attacking pawn, but no melee weapon. And yes capable of violence.

I can try tomorrow morning to try with a another pawn and see if the same problem occurs, but so far thia problem hasn't occured when my pawns melee attack.

I can imagine it was a isolated case, which is why I am even more curious if there is a way to fix the issue without restarting the colony completely or killing the pawn and continuing without it.

Its one of my starting pawns which I would love to continue with, but so far any solution tgat I have mentioned trying, only removes the ticking error until my lawn is again living (laying down as a prisoner still spams the error and killing the pawn removes the error until I ressurect the pawn again)

I guess Im mostly trying to find a solution to removing the ticking error that makes the game unplayable without completely removing the pawn?

SamaelGray commented 10 months ago

Was it the base game revolver or a modded one?

To stop the pawn from throwing those errors you need to interrupt it from its current job being the melee attack that its stuck on doing, try sending it to the world pawns via the game's dev commands and respawn it into the colony again and see if it helps.

chri20q5 commented 10 months ago

Was it the base game revolver or a modded one?

To stop the pawn from throwing those errors you need to interrupt it from its current job being the melee attack that its stuck on doing, try sending it to the world pawns via the game's dev commands and respawn it into the colony again and see if it helps.

So, apologies for the long awaited reply, real life took a hold for a few days. So the revolver that the pawn has been using is the standard revolver (magnum pistol) which to me seems like its the base game revolver (albeit possibly modded due to changes from CE and VE?).

I have also tried sending the pawn in question to world pawns and then respawn it back in, however that still continues the ticking error of the pawn: "Vicky meleed from out of melee position." Vicky meleed from out of melee position. UnityEngine.StackTraceUtility:ExtractStackTrace () (wrapper dynamic-method) Verse.Log:Verse.Log.Warning_Patch1 (string) CombatExtended.Verb_MeleeAttackCE:TryCastShot () (wrapper dynamic-method) Verse.Verb:Verse.Verb.TryCastNextBurstShot_Patch2 (Verse.Verb) Verse.Verb:VerbTick () (wrapper dynamic-method) Verse.VerbTracker:Verse.VerbTracker.VerbsTick_Patch0 (Verse.VerbTracker) (wrapper dynamic-method) Verse.Pawn:Verse.Pawn.Tick_Patch1 (Verse.Pawn) Verse.TickList:Tick () (wrapper dynamic-method) Verse.TickManager:Verse.TickManager.DoSingleTick_Patch6 (Verse.TickManager) Verse.TickManager:TickManagerUpdate () (wrapper dynamic-method) Verse.Game:Verse.Game.UpdatePlay_Patch5 (Verse.Game) (wrapper dynamic-method) Verse.Root_Play:Verse.Root_Play.Update_Patch1 (Verse.Root_Play)

chri20q5 commented 10 months ago

So just a short update. I feel like I tried anything creative solution I could think of.

In the end, the only solution I found that was the closest to keeping my pawn was to clone the bugged pawn and remove the bugged from existence. Will update here if I run into further similar issues that seem to scream CE in the log.

SamaelGray commented 10 months ago

Was it the base game revolver or a modded one? To stop the pawn from throwing those errors you need to interrupt it from its current job being the melee attack that its stuck on doing, try sending it to the world pawns via the game's dev commands and respawn it into the colony again and see if it helps.

So, apologies for the long awaited reply, real life took a hold for a few days. So the revolver that the pawn has been using is the standard revolver (magnum pistol) which to me seems like its the base game revolver (albeit possibly modded due to changes from CE and VE?).

I have also tried sending the pawn in question to world pawns and then respawn it back in, however that still continues the ticking error of the pawn: "Vicky meleed from out of melee position." Vicky meleed from out of melee position. UnityEngine.StackTraceUtility:ExtractStackTrace () (wrapper dynamic-method) Verse.Log:Verse.Log.Warning_Patch1 (string) CombatExtended.Verb_MeleeAttackCE:TryCastShot () (wrapper dynamic-method) Verse.Verb:Verse.Verb.TryCastNextBurstShot_Patch2 (Verse.Verb) Verse.Verb:VerbTick () (wrapper dynamic-method) Verse.VerbTracker:Verse.VerbTracker.VerbsTick_Patch0 (Verse.VerbTracker) (wrapper dynamic-method) Verse.Pawn:Verse.Pawn.Tick_Patch1 (Verse.Pawn) Verse.TickList:Tick () (wrapper dynamic-method) Verse.TickManager:Verse.TickManager.DoSingleTick_Patch6 (Verse.TickManager) Verse.TickManager:TickManagerUpdate () (wrapper dynamic-method) Verse.Game:Verse.Game.UpdatePlay_Patch5 (Verse.Game) (wrapper dynamic-method) Verse.Root_Play:Verse.Root_Play.Update_Patch1 (Verse.Root_Play)

No worries, life happens. I was just going to recommend you clone the pawn with Character Editor given the description of the problem you gave me being a seemingly ordinary situation resulting in that bug that only happens when something is wrong with the pawn or the weapon it wields.