I know what logic I want to have happen, just having some trouble getting it implemented in BD.
Goal:
During step 1 above, a conditional abort can be triggered if there is no "next resource" to be found, then worker returns to job location.
During step 3 above, worker's inventory may become full which triggers the same return to job location to unload inventory.
One problem I have is when the conditional abort happens, it fails the current repeater "do work" branch which I can't figure out how to resume.
The Utility Selector almost seems like a better fit, where I can then control which branch should be executing (do work, or unload inventory, or idle), but I have no use for the changing priority curve or limited wait time.
Right now I'm just restarting the entire BT with reset variables to force the "do work" back into an active state.
Maybe I should be looking at events? Or write a custom Utility selector implementation?
Thanks
Goal:
- Colony Sim-like worker behaviour (eg. harvest mushrooms)
- Start goes to workplace (transform)
- Then repeat "do work" branch
- Find next resource target (transform)
- Goto next target
- Gather resource
During step 1 above, a conditional abort can be triggered if there is no "next resource" to be found, then worker returns to job location.
During step 3 above, worker's inventory may become full which triggers the same return to job location to unload inventory.
One problem I have is when the conditional abort happens, it fails the current repeater "do work" branch which I can't figure out how to resume.
The Utility Selector almost seems like a better fit, where I can then control which branch should be executing (do work, or unload inventory, or idle), but I have no use for the changing priority curve or limited wait time.
Right now I'm just restarting the entire BT with reset variables to force the "do work" back into an active state.
Maybe I should be looking at events? Or write a custom Utility selector implementation?
Thanks