From 33fad45ed326229e54ad23b01466838dfc6b7bb9 Mon Sep 17 00:00:00 2001 From: lbmaian Date: Fri, 30 Jul 2021 06:09:52 -0700 Subject: [PATCH 1/2] Update Harmony nuget, minor misc cleanup --- 1.3/Assemblies/0JecsTools.dll | Bin 112640 -> 112640 bytes 1.3/Assemblies/AbilityUser.dll | Bin 76288 -> 76288 bytes 1.3/Assemblies/CompActivatableEffect.dll | Bin 16896 -> 16896 bytes 1.3/Assemblies/CompBigBox.dll | Bin 6656 -> 6656 bytes 1.3/Assemblies/CompDeflector.dll | Bin 27648 -> 27648 bytes 1.3/Assemblies/CompExtraSounds.dll | Bin 6144 -> 6144 bytes 1.3/Assemblies/CompInstalledPart.dll | Bin 20480 -> 20480 bytes 1.3/Assemblies/CompOversizedWeapon.dll | Bin 8704 -> 8704 bytes 1.3/Assemblies/CompSlotLoadable.dll | Bin 38400 -> 38400 bytes 1.3/Assemblies/CompToggleDef.dll | Bin 13312 -> 13312 bytes 1.3/Assemblies/PawnShields.dll | Bin 35328 -> 35328 bytes About/About.xml | 3 ++- About/Changelog.txt | 1 + .../CompAbilityUser/FlyingObject_Equipable.cs | 4 ++-- .../CompProperties_OversizedWeapon.cs | 3 +-- .../Directory.Build.props | 4 ++-- 16 files changed, 8 insertions(+), 7 deletions(-) diff --git a/1.3/Assemblies/0JecsTools.dll b/1.3/Assemblies/0JecsTools.dll index 2c6d6b44f9065a8d34ffcc4e58483e0384928443..265a30e328bc2517c47b874f2f835ea8cd5de3a9 100644 GIT binary patch delta 47 zcmV+~0MP${@CJbJ29SsZaJ=K;v5d(30RgjB{Ktk6J^64yZbn-{xbMi-c&wC9w=9DJ F)HGAK7)t;E delta 47 zcmV+~0MP${@CJbJ29SsZ<^d#ivb@20ke%Cj}#F2qK2l~7s5@vv4vzvuX@U}EHu;& DqZku- delta 45 zcmZo@VQgq&oY29{ak^w$^b C2N4Va delta 44 zcmZoLX)u}4!6MQ+Y30VAIu1sL&D@-8*#vxJjit6cI_uvpn|3zKA?xVo6Z{rj0B)-g A&;S4c diff --git a/1.3/Assemblies/CompDeflector.dll b/1.3/Assemblies/CompDeflector.dll index 17323f6e2cb70dea0691e55a4567d930630dee2d..da5ba8a7393a31322450660cd96af6ed05d8fc93 100644 GIT binary patch delta 46 zcmV+}0MY+|*a3jp0g#9Ul+dB>v5Y=A0RgkiI9(zT>brTm-wUNhqJ7#Ws?tbdvp8GG E5CGs6$p8QV delta 46 zcmV+}0MY+|*a3jp0g#9U=kGGVv5Y=A0RXehI9(zT~&!@8(59kPb CBN6-n delta 44 zcmV+{0Mq|~Fn}zV5M%oCpB`vndJR1rQ<5A_M5C21&6hw3FJ=2yC+$59kP$ C#}V}a diff --git a/1.3/Assemblies/CompInstalledPart.dll b/1.3/Assemblies/CompInstalledPart.dll index 7669e7eabbeda0da368240e30fa8dfa3207feb37..39fd11010cac562dad321e49f6d41f61bbb76fe0 100644 GIT binary patch delta 46 zcmV+}0MY+|paFoO0g#9U&L}C%v5eRy0RgjRCgT|ptL{U_N3tqGp3`>xgR)PTvsgf= E57iJ9)c^nh delta 46 zcmV+}0MY+|paFoO0g#9U4UIm7v5eRy0RXdQCgT|pD?Hj%@s|fqpHIBhSu4U%vsgf= E52~;d#sB~S diff --git a/1.3/Assemblies/CompOversizedWeapon.dll b/1.3/Assemblies/CompOversizedWeapon.dll index b60001ccdce56a58687cfba1f016b2332c8e9b6e..b7c14cd0ec2acd840cd4f9f34f682bfa55f56362 100644 GIT binary patch delta 44 zcmV+{0Mq|~M1Vw)hy*RR_k^*G=nVk@vvm$j2@q?&{ri+5=S`rX|8pet{Nl6F7cdIN CaTQho delta 44 zcmV+{0Mq|~M1Vw)hy>e5N0G6N=nVk?vvm$j2@s>mI`z;dL`<(gP*Xau)c>>47cdH& CZxXEl diff --git a/1.3/Assemblies/CompSlotLoadable.dll b/1.3/Assemblies/CompSlotLoadable.dll index c79f2a40acd2d5d35e117a6a2449d4ed0267d63f..3be036ac6095e916dba7fad5df9d25929971687b 100644 GIT binary patch delta 46 zcmV+}0MY+|tO9_n0+5IVjTnQ5v5ZVl0RgkwPdhIV4(QvpaBsatp9t3F_55Ievm}4q E7Ry)_HUIzs delta 46 zcmV+}0MY+|tO9_n0+5IVe_3gYv5ZVl0RXevPdhIV(Z?xd7@77+u#+L7Jv`olvm}4q E7QQAEs{jB1 diff --git a/1.3/Assemblies/CompToggleDef.dll b/1.3/Assemblies/CompToggleDef.dll index 9f3ae1ab24d727d981299bab5d962c8653ac9584..2b1701db3f8162bb065a613a5b26adf479212a46 100644 GIT binary patch delta 44 zcmV+{0Mq|~Xn<&thy?6bcB!$9q80%Gvo9Ah4-oSQHuxO02|$rd%{9h95b3jUCXfx3 Cb`g>Q delta 44 zcmV+{0Mq|~Xn<&thyujK%%p7CXfxa CEfT5# diff --git a/1.3/Assemblies/PawnShields.dll b/1.3/Assemblies/PawnShields.dll index 31000d8212f29baab82c6ae109d2f0eda52d95b1..9190eab5ed6060b80f41280e7bc4ae2fb2da9b49 100644 GIT binary patch delta 46 zcmV+}0MY+|lmdX10+5IV5S=lCv5Xu?0RgkANB=DlxewUB3cuq>wC!-P76=92v$%Cg E6tb=pdH?_b delta 46 zcmV+}0MY+|lmdX10+5IVQ7||8v5Xu?0RXe9NB=Dl;false 1.3.0.2 true @@ -40,6 +40,6 @@ - + From 2cc70879d2aa12a53c471eb411b3babc175de53c Mon Sep 17 00:00:00 2001 From: lbmaian Date: Fri, 30 Jul 2021 07:21:28 -0700 Subject: [PATCH 2/2] Workaround for mod lists that contain other mods with an outdated copy of CompOversizedWeapon that's loaded before ours: have CompActivatableEffect not reference new code in our version of CompOversizedWeapon --- 1.3/Assemblies/CompActivatableEffect.dll | Bin 16896 -> 16896 bytes .../HarmonyCompActivatableEffect.cs | 16 +++++++++++++++- 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/1.3/Assemblies/CompActivatableEffect.dll b/1.3/Assemblies/CompActivatableEffect.dll index 62dd4b5fe94dc07d3a17259d4d6e5dc4f65c2d9e..8a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wMK`AT+P-^nlXHh()v0omcK=QrR!^EvQabY`M0TWNi%3X4y8FXQH03@79|;?iCPgJkW<0Fv>Ys?HgFKV0}i8e;I(uC zyiswY@=pP;l_NyOc1mElkLeCjFv*ePc5=Cfd}2venKk;Lw;$0u3Zflxg?)rl^SmF@#1=j z9rhUTw0+a%w)1gTeYA}F;B+ddY;Xk5BTkiAXoF_KV_-vaz@I5k6Xn95OL^dY$_E!< zGfcV*Elpa2mL{!4OOs+~X;Ld%n$(7tCbgqwHWgDnt-?3x>zNjlCngR?=jCkou#;YS zTK@2=5{qztcDFc~Rf3;{@^ud9YqA%r?0#8}2_i}T#w5;yjgT&4JlJRw8l4En_PB`$t5v|` zXBzWok)1_cSd42H3-r|VKo{k7m%4M_w>o@X7!#(w}os3?R0 diff --git a/Source/AllModdingComponents/CompActivatableEffect/HarmonyCompActivatableEffect.cs b/Source/AllModdingComponents/CompActivatableEffect/HarmonyCompActivatableEffect.cs index c8d000b6..e5b6f851 100644 --- a/Source/AllModdingComponents/CompActivatableEffect/HarmonyCompActivatableEffect.cs +++ b/Source/AllModdingComponents/CompActivatableEffect/HarmonyCompActivatableEffect.cs @@ -123,7 +123,7 @@ public static void DrawEquipmentAimingPostFix(Pawn ___pawn, Thing eq, Vector3 dr var weaponComp = compActivatableEffect.GetOversizedWeapon; if (weaponComp != null) { - offset = weaponComp.Props.OffsetFromRotation(___pawn.Rotation); + offset = OffsetFromRotation(weaponComp.Props, ___pawn.Rotation); } if (compActivatableEffect.CompDeflectorIsAnimatingNow) @@ -147,6 +147,20 @@ public static void DrawEquipmentAimingPostFix(Pawn ___pawn, Thing eq, Vector3 dr Graphics.DrawMesh(flip ? MeshPool.plane10Flip : MeshPool.plane10, matrix, matSingle, 0); } + // Workaround for mod lists that contain other mods with an outdated copy of CompOversizedWeapon that's loaded before ours: + // avoid calling new code that's in our version. + private static Vector3 OffsetFromRotation(CompOversizedWeapon.CompProperties_OversizedWeapon weaponComp, Rot4 rotation) + { + if (rotation == Rot4.North) + return weaponComp.northOffset; + else if (rotation == Rot4.East) + return weaponComp.eastOffset; + else if (rotation == Rot4.West) + return weaponComp.westOffset; + else + return weaponComp.southOffset; + } + public static void GetGizmosPostfix(Pawn_EquipmentTracker __instance, ref IEnumerable __result) { if (__instance.Primary?.GetCompActivatableEffect() is CompActivatableEffect compActivatableEffect)