added: item pickups with online persistency
This commit is contained in:
@@ -9,6 +9,8 @@ namespace NodeCanvas.Tasks.Conditions {
|
||||
public BBParameter<string> observerLabel;
|
||||
public BBParameter<RaycastHit> outputHitTo;
|
||||
|
||||
public bool deactivateOnFinish = true;
|
||||
|
||||
protected override string info{
|
||||
get {
|
||||
return $"Check Environment Observer, [\"{observerLabel.value}\"]";
|
||||
@@ -33,7 +35,9 @@ namespace NodeCanvas.Tasks.Conditions {
|
||||
|
||||
//Called whenever the condition gets disabled.
|
||||
protected override void OnDisable() {
|
||||
agent.FindObserverFromString(observerLabel.value).active = false;
|
||||
if (deactivateOnFinish){
|
||||
agent.FindObserverFromString(observerLabel.value).active = false;
|
||||
}
|
||||
}
|
||||
|
||||
//Called once per frame while the condition is active.
|
||||
|
||||
Reference in New Issue
Block a user