change: adding stats to combat movement
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
using System.Collections.Generic;
|
||||
using NodeCanvas.Tasks.Actions;
|
||||
using Reset.Items;
|
||||
using UnityEngine;
|
||||
|
||||
@@ -23,6 +24,21 @@ namespace Reset.Units{
|
||||
storedItems.Add(newItem);
|
||||
}
|
||||
|
||||
public void Equip(Item item){
|
||||
if (item is not IEquipable) {
|
||||
Debug.LogError("This item is not equippable.", item);
|
||||
return;
|
||||
}
|
||||
|
||||
if (item is Weapon thisWeapon) {
|
||||
if (meleeWeapon != null) {
|
||||
storedItems.Add(meleeWeapon);
|
||||
}
|
||||
|
||||
meleeWeapon = thisWeapon;
|
||||
}
|
||||
}
|
||||
|
||||
// Update is called once per frame
|
||||
void Update(){
|
||||
|
||||
|
||||
Reference in New Issue
Block a user