public void TakeFromTarget() { if (Target.Take()) { _gathered++; OnGatheredChanged?.Invoke(_gathered); } }
public void DropAllResources() { if (_gathered > 0) { FindObjectOfType <WoodDropper>().Drop(_gathered, transform.position); _gathered = 0; OnGatheredChanged?.Invoke(_gathered); } }
public bool Take() { if (_gathered <= 0) { return(false); } _gathered--; OnGatheredChanged?.Invoke(_gathered); return(true); }