You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

32 lines
953 B
C#

3 weeks ago
using System;
using Unity.BossRoom.Gameplay.GameplayObjects.Character;
using UnityEngine;
namespace Unity.BossRoom.Gameplay.Actions
{
public abstract class BaseActionInput : MonoBehaviour
{
protected ServerCharacter m_PlayerOwner;
protected Vector3 m_Origin;
protected ActionID m_ActionPrototypeID;
protected Action<ActionRequestData> m_SendInput;
System.Action m_OnFinished;
public void Initiate(ServerCharacter playerOwner, Vector3 origin, ActionID actionPrototypeID, Action<ActionRequestData> onSendInput, System.Action onFinished)
{
m_PlayerOwner = playerOwner;
m_Origin = origin;
m_ActionPrototypeID = actionPrototypeID;
m_SendInput = onSendInput;
m_OnFinished = onFinished;
}
public void OnDestroy()
{
m_OnFinished();
}
public virtual void OnReleaseKey() { }
}
}