Genesis Game Client Project Setup
This commit is contained in:
28
Assets/02_Scripts/_Shared/Combat/CombatSystem.cs
Normal file
28
Assets/02_Scripts/_Shared/Combat/CombatSystem.cs
Normal file
@@ -0,0 +1,28 @@
|
||||
using UnityEngine;
|
||||
using UnityEngine.InputSystem;
|
||||
|
||||
public class CombatSystem : MonoBehaviour
|
||||
{
|
||||
private PlayerStateMachine _playerStateMachine;
|
||||
private Animator _animator;
|
||||
private float _chargeTimer;
|
||||
|
||||
[SerializeField] private Weapon _currentWeapon; // 현재 장착된 무기
|
||||
|
||||
void Awake()
|
||||
{
|
||||
_playerStateMachine = GetComponent<PlayerStateMachine>();
|
||||
_animator = GetComponent<Animator>();
|
||||
}
|
||||
|
||||
public void OnAttackInput(InputAction.CallbackContext context)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
void Update()
|
||||
{
|
||||
if (_playerStateMachine.CurrentState == PlayerState.Charge)
|
||||
_chargeTimer += Time.deltaTime;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user