Skip to content

Commit

Permalink
Fix typo
Browse files Browse the repository at this point in the history
  • Loading branch information
N7Huntsman authored and perkinslr committed Feb 1, 2024
1 parent 979553b commit 59b01c1
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -246,7 +246,7 @@ public void AddSuppression(float amount, IntVec3 origin)
}
public bool IgnoreSuppresion(IntVec3 origin)
{
return BlockerRegistry.PawnUnsuppresableFromCallback(parent as Pawn, origin) || SuppressionUtility.InterceptorZonesFor((Pawn)parent).Where(x => x.Contains(parent.Position)).Any(x => !x.Contains(origin));
return BlockerRegistry.PawnUnsuppressableFromCallback(parent as Pawn, origin) || SuppressionUtility.InterceptorZonesFor((Pawn)parent).Where(x => x.Contains(parent.Position)).Any(x => !x.Contains(origin));
}

public override void CompTick()
Expand Down
10 changes: 5 additions & 5 deletions Source/CombatExtended/Compatibility/BlockerRegistry.cs
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ public static class BlockerRegistry
private static List<Func<ProjectileCE, IntVec3, Thing, bool>> checkCellForCollisionCallbacks;
private static List<Func<ProjectileCE, Thing, bool>> impactSomethingCallbacks;
private static List<Func<ProjectileCE, Thing, bool>> beforeCollideWithCallbacks;
private static List<Func<Pawn, IntVec3, bool>> pawnUnsuppresableFromCallback;
private static List<Func<Pawn, IntVec3, bool>> pawnUnsuppressableFromCallback;
private static List<Func<Thing, IEnumerable<IEnumerable<IntVec3>>>> shieldZonesCallback;

private static void EnableCB()
Expand All @@ -47,7 +47,7 @@ private static void EnableSZ()
private static void EnablePUF()
{
enabledPUF = true;
pawnUnsuppresableFromCallback = new List<Func<Pawn, IntVec3, bool>>();
pawnUnsuppressableFromCallback = new List<Func<Pawn, IntVec3, bool>>();
}
private static void EnableBCW()
{
Expand Down Expand Up @@ -118,7 +118,7 @@ public static void RegisterUnsuppresableFromCallback(Func<Pawn, IntVec3, bool> f
{
EnablePUF();
}
pawnUnsuppresableFromCallback.Add(f);
pawnUnsuppressableFromCallback.Add(f);
}

public static bool CheckCellForCollisionCallback(ProjectileCE projectile, IntVec3 cell, Thing launcher)
Expand Down Expand Up @@ -159,13 +159,13 @@ public static IEnumerable<IEnumerable<IntVec3>> ShieldZonesCallback(Thing thing)
}
return shieldZonesCallback.SelectMany(cb => cb(thing));
}
public static bool PawnUnsuppresableFromCallback(Pawn pawn, IntVec3 origin)
public static bool PawnUnsuppressableFromCallback(Pawn pawn, IntVec3 origin)
{
if (!enabledPUF)
{
return false;
}
foreach (var cb in pawnUnsuppresableFromCallback)
foreach (var cb in pawnUnsuppressableFromCallback)
{
if (cb(pawn, origin))
{
Expand Down

0 comments on commit 59b01c1

Please sign in to comment.