How to continually check bool to switch between two sets of behaviour?

laurien

New member
Hi,

I have a level split into 2 zones. I am checking a bool to see which zone a player is in, as the AI will have different behaviour for each.
I want to be able to continually switch between the 2 sets of behaviour as the player switches zone.

In the setup shown in the sceenshot I'm finding that once the bool has been checked with the Compare SharedBool, it isn't checked again and stays ticked green. Then when the player switches zone this isn't registered.

How do I set it up so I can continually check the bool and flip between two sets of behaviour?

Thanks,
Laurien
 

Attachments

  • CompareBool.png
    CompareBool.png
    58 KB · Views: 11
Your Compare Bool task doesn't have anything to the right of it so the sequence isn't going to do anything. You should have the logic that you want to perform to the right of that Compare Bool task.

Also, you likely don't need the Parallel task over every branch. I recommend using conditional aborts primarily: https://opsive.com/videos/?pid=803&video=3924
 
Top