Perception not triggering, line of height

Wraithin 5 months ago in Behavior updated by markusrgb 4 months ago 18 4 duplicates


-- Create new project with URP Template (Unity 2019.3.11f1)

-- Import Game Creator 1.1.7, import behaviour Module 0.2.4

-- Create Player, Create Character

-- Add Perception to Character

-- Add Trigger/Behaviour for Line of Sight / Can See (Invoker see's player)


Trigger/Behaviour fires only if the player is jumping. Horizontal range seems to work, vertical not.

Debug Output



Should fire as soon as it gets into the perception range.

Unity version:
Game Creator version:



I'm closing this thread as the error has been fixed. Sorry I said the update would come today, but I had to attend other things first. I'll be pushing an update after I write this message and hopefully Unity will approve it tomorrow morning. Cheers!

Satisfaction mark by Wraithin 5 months ago

Duplicates 4

Under review

Looks like something is blocking the view of the car. When you select the object that the Player's sight tracks (the Can See), is the outer-most object of the Car?

Rephrasing the previous question: Does the root of the car have a collider? Or its children? The Can See condition needs a collider in order to properly raycast. This collider needs also to have the "is Trigger" checkbox disabled.

There is nothing hissing between the car and the player.

There is also no invisible collider that could disturb.

All objects of the car have a mesh collider (the main object and all child objects)

"is Trigger" is disabled

Here are some pictures:

Strange is: If I stand very close to the car, then it happens occasionally at 1 time out of 20 try, that I get "can see" as a message.

I tried to disable the mash collider from the main object and use a box collider instead.

That did not work either.

Only when I pull the new box collider further apart, so that it doesn't touch the car anymore, it works.

But unfortunately this is not the solution that helps me.

I have the impression that there are problems with the "Can See" function when several colliders of an object overlap.

I also tried to create a cube with a cube child object. There everything works as usual.

I've tried reproducing this issue but seems to work fine on my end. I'm attaching the scene in this thread so you can see it.

The only thing that occurs to me that could be causing an issue is the Pivot of the object being too close to the ground. When the Perception tracks an object, it throws a raycast to the origin of the object to decide whether it is in the line of sight or not.

The problem comes when that pivot not at the center of the collider, but touching the ground or to some other collider. The line of sight might get blocked by the floor, incorrectly reporting that the floor is blocking the view.

A quick way to test this is done by moving the car up in the air and see if the player can see it. Also, remember to have a generous Vision Distance.

Let me know if that solves the problem.

Scene - Can See Test

Hi, Marti,

I have now tested your "Can See Test" scene... But there is only one cube. But as I have already described, the "Can See" function also works for me with a cube without problems. I have problems with more complex game objects.

I tested your scene with Unity 2018 and 2019.3 and added the auto there.

Unfortunately I have the same problem again - it does not work.

When I place the car up (away from the ground) it does not work.

I have added the car here as a file:

Maybe you can find the reason for the error


At the moment I have little time to test the object you sent on an example. If the scene that I sent you works out, but not with the car, maybe the problem is because you set that object on a different layer, or you may have changed the collision layers. Is that possible?

There's no reason why a collider would work differently changing from a cube to a mesh collider. Check out that there are no other inner colliders inside the car that overlap the car's main collider.

Under review

Hi Jay. As far as I know, these work fine. Would you mind sharing some screenshots of the Behavior Graph and/or a video showing what's happening? Otherwise it's a bit difficult to imagine.

Hi, Marti,

the levels are all default.

I haven't changed anything on the layers.

I bought the package in the Unity Store and didn't change anything.

It doesn't matter if I deactivate all colliders or activate them all - it doesn't work !

Even if I just select the car door, apply the script with Game Creator to it, and deactivate all other colliders - it doesn't work !

The package consists of several objects .... Cabinets, chairs, and many more simple things .... for all of them the Can See function has worked so far. It is only the vehicles in this package that are causing problems, it doesn't work with any of them!

I do not understand why!

I've tried 100 different things - But : It doesn't work !

Sometimes, it happens that one of 100 clicks at once works.

Perhaps the can see function is not always returning true when it should.

Or my issue may be the result of the can see condition returning true then running the actions in the task.  But by the time the actions finish the can see condition returns fails and so the entire task returns false and therefore the next task in the sequence does not run.

I think I can prevent this by splitting the can see condition and actions into two separate tasks in the sequence.

Under review

Thanks for the report! I'll take a look as soon as I can and circle back with a solution

Hi Jay, there's been reports on the Can See returning a false positive under some circumstances. This looks like was introduced during the last update. I'm working on finding the problem and I'll push an update as soon as possible.

I'm cautiously merging this ticket with the Can See bug report. If it happens to be something else, I'll un-merge the threads


There's a bug introduced in the latest Behavior update that prevents the use of the Can See action under some circumstances. I'm working on it at the moment and I'll circle back when this is resolved.


Hi Mark; It looks like there is a problem with the sight perception. I'm merging this ticket with the other reports. Just in case you read this first, I've already identified the problem and I'm working on an emergency patch update that should be available on Monday. Sorry for the trouble.


no problem

Problems are there to be solved ;)

I'll start by saying thank you


I'm closing this thread as the error has been fixed. Sorry I said the update would come today, but I had to attend other things first. I'll be pushing an update after I write this message and hopefully Unity will approve it tomorrow morning. Cheers!

ok, i'm a bit confused. i thought the problem with the "can see" function was fixed now. i downloaded version 1.1.8 GC from the Unity store and now i have to realize that the "can see" function has no function at all. i also started an empty project and tested it with a cube. no matter if i use "can see" or "can not see" no condition is fulfilled and therefore no action is executed.

if i use the old "can see" function from the Unity Hub it works at least in 80% of the cases. it doesn't matter if the cube touches the ground or not, the result is the same. see the attached photos: