Checking if event is running?

How would i go about checking that my event is running. I have an event which is triggered via a bp interface when i’m looking at an object through checking if the object is running my “looking at” interface through a “does implement” node.

I want to be able to run “if the event is active / in use then do XYZ, else do ABC” but i first need to determine if my event is running.

Event is technically a function just visually different, it does not have “running” or any “active” state, you just call it and it will execute all binded code. You need to make some state varbale indicating that object is in specific state of object as a result of a event.

Look on overlap events, there 2 of them where overlap starts and ends + there a varable (or rether node cheking state of that varable) that shows if actor is overlapping or not, you need to make something similar to this

Please spell check your answers before submitting your reply. Your formulations are also going all over the place and can be unclear. It is “an event”, not “a event”. It’s “variable”. “There are” etc. I am not saying this to hate on you, just to make the answers as easy to understand for those wishing to understand it.

Let me rewrite it for you and I will delete this comment once you update it.
"An event is technically a function, just visually different. It does not have a “running” or an “active” state. You just call it and it will execute all bound code. You need to make some state variable indicating that the object is in a specific state as a result of a event.

Look at overlap events, there are 2 of them;on overlap begin and on overlap end. In addition, there is a variable (or rather a node checking the state of that variable) that shows if the actor is overlapping or not. You need to make something similar to this."

Hi there, was too tired to create you this sample yesterday, but here we go. You got the theory from the others already, nothing more to say about. But it is easier than it sounds.

You need your ILookingAt Interface with 2 Functions: BeginLookingAt and EndLookingAt.
Here the BP for the Actors that can be looked at and therefor need to implement the Interface:

Here the Character that looks at the Actors and therefor calls the interface functions.

This works for a single Character. If more than one Character is looking at one Actor, the first Character that calls EndLookingAt will set the “IsLookAt”-Variable to false even if the other Characters are still looking. If that makes sense to you. So you need to count them (increment counter when BeginLookingAt, decrement counter when EndLookingAt). If counter is 0 then no one is looking at the Actor.

hope that helps :slight_smile: Marooney

Just do not take it too serious boy :slight_smile: I do not think you are in the position to correct someone with 20k karma. No one owes someone a fancy answer. Especially not if it is about basics, that are part of the homework by watching the basic tutorials. Where you lern the terminology to understand what he explains. Just think about why you can “translate” this :slight_smile:

Thanks for this, it helped alot. My only problem with it is that it only realizes i’m not looking at something if i look at something else, if i look at an object and then just look at the sky, it still thinks i’m looking at the object because it hasn’t got any new information.

Any tips on getting around this?

Could you please show me a screenshot of your Character TickEvent? Cannot reproduce this issue on my side.

I seem to have fixed it, i had a few extra nodes that were redundant after i implemented your methods. Thanks anyway, your first answer worked.