Skip to content

Commit

Permalink
Added additional null checks for ejecting.
Browse files Browse the repository at this point in the history
  • Loading branch information
RealityMachina committed Jun 22, 2018
1 parent 6f87bfd commit 3d7103f
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions PunchinOut/BasicPanic.cs
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,11 @@ public static void Prefix(AttackStackSequence __instance, MessageCenterMessage m

}

if(mech == null || mech.GUID == null || attackCompleteMessage == null)
{
return;
}

Holder.SerializeActiveJson();

if (PanicHelpers.IsPanicking(mech, ref IsEarlyPanic) && BasicPanic.RollForEjectionResult(mech, attackCompleteMessage.attackSequence, IsEarlyPanic))
Expand Down
2 changes: 1 addition & 1 deletion mod.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"Name": "BasicPanicSystem",

"Version": "1.0.0",
"Version": "1.0.2",
"Description": "Adds basic panic system, based on mpstark's Punchin' Out.",
"Author": "RealityMachina, forked from mpstark's work",
"Website": "https://github.com/RealityMachina/PunchinOut",
Expand Down

0 comments on commit 3d7103f

Please sign in to comment.