bugfix 07/10/26 + evil laugh
This commit is contained in:
parent
eaa87f892a
commit
0159f1e8c4
11 changed files with 417 additions and 8 deletions
|
|
@ -601,4 +601,30 @@ namespace RacesOfValheim
|
|||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// The rest of the human's attack loop, shut while a dragon form is up: crossbow reload and draw
|
||||
/// live in PlayerAttackInput, and the form's Animator fires the held attack through
|
||||
/// OnAttackTrigger. Without these a crossbow in hand shot on every form attack. See Fenrir's
|
||||
/// BlockPlayerAttackInputPatch.
|
||||
/// </summary>
|
||||
[HarmonyPatch(typeof(Player), "PlayerAttackInput")]
|
||||
public static class SkadiBlockAttackInputPatch
|
||||
{
|
||||
public static bool Prefix(Player __instance)
|
||||
{
|
||||
if (__instance != Player.m_localPlayer) return true;
|
||||
return __instance.GetComponentInChildren<DrakeFormBehavior>() == null;
|
||||
}
|
||||
}
|
||||
|
||||
[HarmonyPatch(typeof(Humanoid), nameof(Humanoid.OnAttackTrigger))]
|
||||
public static class SkadiBlockAttackTriggerPatch
|
||||
{
|
||||
public static bool Prefix(Humanoid __instance)
|
||||
{
|
||||
if (__instance != Player.m_localPlayer) return true;
|
||||
return __instance.GetComponentInChildren<DrakeFormBehavior>() == null;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue