From fcb16bce6c4a7bb38c9ca24e013d97a3695dbc81 Mon Sep 17 00:00:00 2001 From: tcgj Date: Fri, 17 Apr 2020 11:49:39 +0800 Subject: [PATCH] Temp commit for debugging --- Assets/Scripts/AI/AiAnimation/AiMushroomAnimation.cs | 1 + Assets/Scripts/Network/MonsterNetworkHandler.cs | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/Assets/Scripts/AI/AiAnimation/AiMushroomAnimation.cs b/Assets/Scripts/AI/AiAnimation/AiMushroomAnimation.cs index 1c7c2b41..fe5876f2 100644 --- a/Assets/Scripts/AI/AiAnimation/AiMushroomAnimation.cs +++ b/Assets/Scripts/AI/AiAnimation/AiMushroomAnimation.cs @@ -80,6 +80,7 @@ public override float RandomizeAttack(out string attackName) public override void SetAttackTrigger(string name) { + Debug.Log("Trigger " + name); m_Animator.SetTrigger(name); } } diff --git a/Assets/Scripts/Network/MonsterNetworkHandler.cs b/Assets/Scripts/Network/MonsterNetworkHandler.cs index d12f2807..b059b00f 100644 --- a/Assets/Scripts/Network/MonsterNetworkHandler.cs +++ b/Assets/Scripts/Network/MonsterNetworkHandler.cs @@ -50,7 +50,10 @@ private void Update() string attackName = m_aiMonster.GetAttack(); if (attackName.Length > 0) + { + Debug.Log("Sent attack " + attackName); networkObject.SendRpc(RPC_TRIGGER_ATTACK_ANIM, Receivers.Others, attackName); + } } else { @@ -63,6 +66,7 @@ private void Update() public override void TriggerAttackAnim(RpcArgs args) { + Debug.Log("received attack"); m_aiMonster.GetMonsterAnimation()?.SetAttackTrigger(args.GetNext()); } }