playMaker

Author Topic: How to send an event when a ray does NOT hit ?  (Read 917 times)

secondsight

  • Playmaker Newbie
  • *
  • Posts: 24
How to send an event when a ray does NOT hit ?
« on: February 13, 2020, 11:42:59 AM »
Hey there,
I´m trying to make some obstacle avoidance. And I´m wondering how I cant sent an event when a raycast is not hitting a target / point in range anymore.
Currently I let an object rotate 180 degress over time when the ray hits the surface of an obstacle, but I want it to stop as soon as the range is clear so it can go straight again.

How would I do that ?

Thanks !

djaydino

  • Administrator
  • Hero Member
  • *****
  • Posts: 7615
    • jinxtergames
Re: How to send an event when a ray does NOT hit ?
« Reply #1 on: February 13, 2020, 02:47:04 PM »
Hi.
if you need to raycast once (so not every frame) you can use a finished event.
if cast did not hit it should then finish.

but there are also some raycast actions on the Ecossystem that has a no hit event on them.