Can't get actors Z location for a branch check

I’m trying to make it so a branch checks to see if an actor is above a certain high, that being 200 z units up, at which point i want to stop it from going any higher. (the 2nd check on the event tick)

However I can’t get the branch to result in true, I’ve tried every “Get Transform” and location based node I can think of but nothing so far will get it to make the branch switch to true.

I can’t think of any other way to check it’s position.

the asteroid starts at -300 Z and get’s pushed up. it also flies right past my camera so it clearly passes the 200 z point.

Ah yup, that did it. Thanks I was using those checks before with the “get actor transform” node which would never work, but using those checks again with the “get world location” which I’m using now has it working perfectly. I’m Using the “Nearly Equal” node with a tolerance of 8 and yeah all good.

When comparing floats, don’t use Equal, use Nearly Equal with a certain threshold. But in your case you’d better compare it with >= than ==, because the chance that your meteor will be at exactly 200Z is next to zero.

I still insist on >= though.

You should always consider the possibility of someone having a lower frame rate; even when your project grows larger, your own frame rate will certainly drop. And when it does, the 8-unit tolerance won’t be good enough.

I still insist on >=, because at lower frame rates 8-unit tolerance may be insufficient.