🐛 harvested plants don't come back on scene reload

This commit is contained in:
2025-12-06 20:47:56 +01:00
parent a3651d6268
commit 7bb523f9e7
3 changed files with 12 additions and 0 deletions
@@ -204,6 +204,12 @@ public partial class FieldBehaviour2D : Sprite2D, ISaveable
_currentPlant.Field = this;
}
}
public void HarvestPlant()
{
_currentPlant = null;
UpdateFieldState(FieldState.Empty, true);
}
#region SAVE AND LOAD
@@ -200,4 +200,9 @@ public partial class PlantBehaviour2D : Node2D
_magicWordSaid = true;
Grow();
}
public void Harvest()
{
Field.HarvestPlant();
}
}