Trouble with toggling actor

Currently having issues with toggling a torch actor class with a separate actor to help with a slightly large level,

1st and 2nd image is the toggle actor and the 3rd is the torch actor, any help would be much appreciated as i’m currently stumped :sweat_smile:

Can you give a short explanation on what you are trying to achieve?

Since its a larger level i’m starting to run into some issues with performance and i’m trying to cut down on it, and since the largest amount of actors are torches/ light sources i’m trying to set them to invisible at certain point where they have no bearing on the level. so i want to cast to all actors of the class and set them to invisible and i’m essentially just using the same torch over and over again just with different names.

IMO first thing is to delete that tick event and create 2 custom events / functions for the on and off.

You are only affecting 1 instance of the torch here, don’t know if this is what you intended.

Every torch has this overlap or just one that manages all?

I thought it would replicate to all instances of the torchs since its the same actor just duplicated, its seems like i was mistaken any idea how i should properly get all the torch actors? and i’m using a box actor as a trigger so when the character overlaps it it’ll cast to the corresponding group of torches so its just on the one actor currently and i’ll make each one tied to a seperate group.

After messing around with it i found a solution but im not sure if there will be any problems currently, i made the out actors of get all actors a variable and on overlap i set up a for each loop to trigger toggle active on the group of torches, thanks a bunch for steering me in the right direction :grinning:

Here is an idea if you want to try different solutions:

  • Assuming you have less triggers than torches try having the torch search for the triggers and bind the overlaps to on / off of the torch.
  • You can compare tags of both torches and trigger actors to bind. Like so:


…Or if you want to go an extra step, create an actor component that you can add to your trigger box actors that dispatches events:

Now only the component checks once who overlapped and not each torch on every overlap:

Maybe this is not what you are looking for, but it will most certainly help

17 minute mark, light culling, its a great feature.