[1.1] Avoid Friendly Fire (stop shooting when friendlies are in the way)

Started by falconne, September 10, 2017, 06:16:37 AM

Previous topic - Next topic

sumghai

falconne, just a heads-up that you may need to change a HugsLib or Harmony method call when updating this mod from B19 to 1.0:


[HugsLib][ERR] AvoidFriendlyFire caused an exception during OnDefsLoaded: System.MissingMethodException: Method not found: 'HugsLib.ModBase.get_HarmonyInst'.
  at HugsLib.HugsLibController.OnDefsLoaded () [0x00000] in <filename unknown>:0
Verse.Log:Error(String, Boolean)
HugsLib.Utils.ModLogger:ReportException(Exception, String, Boolean, String)
HugsLib.HugsLibController:OnDefsLoaded()
HugsLib.HugsLibController:LoadReloadInitialize()
Verse.LongEventHandler:RunEventFromAnotherThread(Action)
Verse.LongEventHandler:<UpdateCurrentAsynchronousEvent>m__1()

falconne

Quote from: sumghai on October 19, 2018, 04:34:25 PM
falconne, just a heads-up that you may need to change a HugsLib or Harmony method call when updating this mod from B19 to 1.0:


That's odd. I did not get this error. Have you updated HugsLib to the latest version?

Also, this mod's been updated to v1.0 now.

sumghai

Quote from: falconne on October 20, 2018, 06:24:48 AMThat's odd. I did not get this error. Have you updated HugsLib to the latest version?

Yes, I was running the latest version of HugsLib (6.0.1) at the time the error occured

Quote from: falconne on October 20, 2018, 06:24:48 AMAlso, this mod's been updated to v1.0 now.

Much appreciated! I can now confirm that the 1.0 release of FF works properly with HugsLib 6.0.1 in RW 1.0.2059.

Jiro

Wait, so will pawns move by themselves if they don't have a shot at the target that won't hit their friends?

falconne

Quote from: 中村ジロ on November 08, 2018, 10:30:37 PM
Wait, so will pawns move by themselves if they don't have a shot at the target that won't hit their friends?

Only while hunting, not while drafted.

Jiro

Quote from: falconne on November 09, 2018, 12:29:30 AM
Quote from: 中村ジロ on November 08, 2018, 10:30:37 PM
Wait, so will pawns move by themselves if they don't have a shot at the target that won't hit their friends?

Only while hunting, not while drafted.
Is that just due to the nature of drafting? Or can some use of trickery achieve the same thing?

falconne

Quote from: 中村ジロ on November 09, 2018, 08:13:03 AM
Is that just due to the nature of drafting? Or can some use of trickery achieve the same thing?

In the game currently, during combat you have to manually place your pawns; they don't automatically move to go find targets. You would generally position ranged pawns behind cover or in tactical places... and you wouldn't want them moving out of position and into danger on their own. So I think if the mod started doing that it would probably not be a feature you'd really want to use.

falconne

Quote from: XeoNovaDan on September 03, 2018, 05:21:08 AM
Hey, so ToWild radius has actually been made dynamic with B19 rather than the old fixed 1.9 cell radius. You can find the values in ShootTuning in Verse.

Latest version now accounts for the larger miss radius

falconne

In the latest update, shooters who are being blocked by friendlies (but would otherwise have a target) will have their name on the map and in the Colonist Bar be written in cyan. Likewise, the first friendly blocking any shooter will show up in green.

togfox

Has a bug been introduced? Yesterday this was working fine and now shooters won't fire "over" shielded melee pawns. They turned blue - which was great - but they had clear shots (as in clear LOS) except for fully shielded pawns that were engaged.

There were 'friendly' animals mixed up in the combat - would that be a reason to hold fire?

I'll experiment some more ...

Great mod btw!

falconne

Quote from: togfox on March 14, 2019, 07:54:52 AM
Has a bug been introduced? Yesterday this was working fine and now shooters won't fire "over" shielded melee pawns. They turned blue - which was great - but they had clear shots (as in clear LOS) except for fully shielded pawns that were engaged.

There were 'friendly' animals mixed up in the combat - would that be a reason to hold fire?

I'll experiment some more ...

Great mod btw!

I just tested with shielded pawns and that doesn't appear broken, they didn't cause shooters to stop. Friendly animals will if you have that option turned on the mod settings. Unfortunately animals don't change colour as their name is not show on the map by default. You can temporarily turn on labels for all tame animals in the game options and then they will change colour. I will see about making animal names show up regardless if they are blocking shooters.

The previous update increased the miss radius used for low skill shooters as mentioned in my previous post, so maybe your seeing that. If you're used to the old one tile radius you might need to readjust your placements. You can check the shooters actual fore cone by clicking their weapon on the pawn toolbar and hovering over the intended target so you can see if the animals are in the red area.

togfox

I used attack animals on this occasion so I'll just put it down to that.

Cheers. Loving it.

falconne

Latest update now forces name labels of friendly animals blocking shooters to be shown in green, even if animal labelling is off in game preferences.


agentbad

Great mod. I am curious if this could be extended to turrets as well?