Author Topic: [Resolved] Jammed in overwatch freezes the battle  (Read 61 times)

ushas

  • Hero Member
  • *****
  • Posts: 502
    • View Profile
[Resolved] Jammed in overwatch freezes the battle
« on: September 08, 2017, 09:10:55 PM »
(v19, linux)

I know you said that all the various conditions were tested. So it's possibly resolved. But as jamming wasn't much mentioned before in this relation, I will rather report this.

Problem: Elena got her assault rifle jammed (I saw that red floating text) right when she was about to make burst overwatch attack. It freezes the battle during an enemy's turn at the point of jamming.

In the log there are no errors. The last part around jamming happening:
Code: [Select]
CharMoveScript.StartMovement. Path position is: 1
CharMoveScript.StartMovement. next tile in movement is: (2.0, 11.0)
CharacterMovementScript.StartMovement. current tile position is: (3.0, 0.0, -12.8) / player position: (1.8, 0.0, -14.0)
CharacterMovementScript.SetIsMovingState. Name: Brother Soileau Requested state: True
CharacterMovementScript.InvokeSetAimingAnimationParameterFalse. Method called
CharacterMovementScript.SetAimingAnimationParameterFalse. Method called
CharacterMovementScript.PlayFootSteps. Method called. SFX volume is: 0.4761905
BCS.CheckIfClearLOSBetweenTiles. Clear LOS between phy (9.0, 1.5, -8.0) and (3.0, 1.5, -12.8)Tile: (7.0, 7.0) and(2.0, 11.0)
BattleControlScript.GetRangedChanceToHit. Is overwatch attack, so making calculation vs next tile: (2.0, 11.0)
BattleControlScript.CalculateShotDifficulty. Method called. Distance is: 5
BCS.CalculateShotDifficulty. Shot difficulty is: 131 base shot difficulty: 60 shot difficulty from distance: 55 shot difficulty from crouching target: 0 shot difficulty from smoke: 0 shot difficulty from directional cover: 0 defense from evasion: 12 defense from armour: 4
BattleControlScript.CalculateShotScore. Character gets accuracy bonus from cover
CharacterMainScript.CheckIfCrowded. Is using rifle
CharacterMainScript.CheckIfCrowded. No adjacent enemy
BCS.GetRangedChanceToHit. Shot difficulty is: 131 / shot score is: 129 chance to hit is: 95 use mode: 2
OverwatchManager.AttemptOverwatchAttackForThisMovement. Overwatch character has current tile LOS to moving character. CTH is: 95
OverwatchManager.SetOverwatchBeingResolved. Current state: True / new state: True
CharacterMainScript.SetupRangedAttack. Method called. Selected weapon name is: Raskol 148 use mode pos: 2 body part damage modifier1 status effect: -1 is overwatch: True
CharacterMainScript.CheckIfWeaponJams. This weapon can jam. Condition is: 0.4533339 Jam %: 0
CharacterMainScript.CheckIfWeaponJams. This weapon can jam. Condition is: 0.4533339 Jam %: 31.99992
CharacterMainScript.CheckIfAttackCritical. Success! Roll chance: 31.99992 Random number (must be lower): 11
CharacterMainScript.CheckIfWeaponJams. Weapon jams: True condition: 0.4533339
CharacterVoiceScript.PlayVoiceClip. Method called. Clip type: 0 Char has voice clips: True
BattleControlScript.EnablePlayerInput. Time is: 281.2196 time until user input enabled: 258.7582
BattleControlScript.EnablePlayerInput. Time is: 281.2196 time until user input enabled: 258.7582 ENABLING
BattleControlScript.RemoveCharacterFromOverwatchList. Player character removed


Edit: I'm trying to recreate the issue and now the weapon got jammed right away when wanted to enter overwatch with Snap mode. So it doesn't let me and no battle freezing happens.

Do I understand it right that the game checks this before it lets me end the turn? Because in that case the reported situation shouldn't happen at all. It was clear to me that weapon jamming happened during an enemy's turn when Elena was already in overwatching mode. So in that case maybe there is another  if jammed  check that shouldn't be called.

I will try to re-test, maybe the issue is burst mode related... I don't know what is jamming behavior during normal turn, does it check once at the start of attack or for each shot within burst?

Edit2: Recreated. This time Normal weapon mode, so not burst specific (log says "use mode: 1"). At the point of entering overwatch no jamming, but at the point of OW the attack it got jammed and freezes the battle.
« Last Edit: September 09, 2017, 11:50:11 AM by Daithi »

Daithi

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 958
    • View Profile
Re: Jammed in overwatch freezes the battle
« Reply #1 on: September 09, 2017, 11:03:35 AM »
I prevented entering overwatch if weapon is jammed, and did a check if weapon will jam in next attack, but must have missed something... will look at this one now.
« Last Edit: September 09, 2017, 11:38:02 AM by Daithi »

Daithi

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 958
    • View Profile
Re: Jammed in overwatch freezes the battle
« Reply #2 on: September 09, 2017, 11:49:47 AM »
For overwatch, it does a pre check, and prevents OW if the weapon will jam. Problem was it was rechecking if the weapon jams when overwatch starts and there was no code to handle the outcome. Fixed now. Good catch!