Hello again. Definitely a noob question, but when trying to work out some logic chains for how I can get my events to print string under certain scenarios, this is the issue I’m having at the minute:
In my level blueprint, on event tick, I’m using a ‘cast to’ node to get a reference to my enemy that exists in the level. Said enemy actor is in my level, yet the current print string I’m getting on an event tick is always failing, I would think in this case as long as my enemy actor is active and present in the level then it would always pass success, what am I missing here?
I know that using an event tick in a level blueprint isnt the most optimized approach, but this was just for the sake of testing some logic.
The problem with doing it like this is now there is no logic to tell it which print string to use, the cast success or fail which was the point of trying to use a cast to node.
For 3rd time… no need to cast - read the blue note This will never fail, the fail condition will never trigger (unless the actor is removed from the game). Perhaps there’s some confusion here regarding what casting is for…
as long as my enemy actor is active and present in the level
I think the original reason my inclination was to go for a cast to is because Id like this to apply to any actor of that class, maybe there is still a way to do that without trying to have a reference to just the very specific one that exists in the world outliner.
Not sure I understand. Cast To does the opposite - it’s a test, a filter, a type conversion mechanism. When you cast, you test if the object reference is of Enemy type. That’s it.
If you want to interact with multiple classes, look into interface communication.