From ee4d8f4187059f177c17c8c818352826c6347d38 Mon Sep 17 00:00:00 2001 From: chai Date: Thu, 5 Aug 2021 20:05:44 +0800 Subject: *misc --- Assets/Scripts/Unit/Component/UnitComponent.cs | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'Assets/Scripts/Unit/Component/UnitComponent.cs') diff --git a/Assets/Scripts/Unit/Component/UnitComponent.cs b/Assets/Scripts/Unit/Component/UnitComponent.cs index 6c8dc916..1e4df1fc 100644 --- a/Assets/Scripts/Unit/Component/UnitComponent.cs +++ b/Assets/Scripts/Unit/Component/UnitComponent.cs @@ -4,6 +4,8 @@ using UnityEngine; public class UnitComponent : MonoBehaviour { + public UnitController owner { get { return m_Owner; } } + protected UnitController m_Owner; public bool IsAlive @@ -14,6 +16,14 @@ public class UnitComponent : MonoBehaviour } } + public virtual void Awake() + { + } + + public virtual void OnDestroy() + { + } + public virtual void Initialize() { m_Owner = GetComponent(); -- cgit v1.1-26-g67d0