summaryrefslogtreecommitdiff
path: root/scripts/entities/actions/ItemAction.cs
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/entities/actions/ItemAction.cs')
-rw-r--r--scripts/entities/actions/ItemAction.cs15
1 files changed, 15 insertions, 0 deletions
diff --git a/scripts/entities/actions/ItemAction.cs b/scripts/entities/actions/ItemAction.cs
new file mode 100644
index 0000000..54ff207
--- /dev/null
+++ b/scripts/entities/actions/ItemAction.cs
@@ -0,0 +1,15 @@
+using Godot;
+
+public partial class ItemAction : Action
+{
+ private ConsumableItem item;
+ public ItemAction(Actor actor, ConsumableItem item) : base(actor)
+ {
+ this.item = item;
+ }
+
+ public override bool Perform()
+ {
+ return item.Activate(this);
+ }
+} \ No newline at end of file