Hello. Many ready-made logic solutions use the get player character function to apply their effect only to the player character. I’m interested in the question, is it possible to somehow rework this logic so that it works with all actors by tag? Is there some kind of universal solution, or will it be a completely different logic?
You’d typically use Get Player Character as the object in a cast to your character. You’re not going to yield many results with it setup like you have it.
If you were to cast to your character with the Get Player Character node plugged into the cast, you could us the ActorHasTag function to check if your actor has the tag you are looking for.
This is something different, and generally, if you want to change built-in functions, it means modifying the UE source and rebuilding the engine yourself. A more user-friendly approach would be to create your own functions library and implement the necessary functions yourself.
In this case, however, there is a built-in function called Get All Actors with Tag. Just be cautious when using it, as it’s heavy. It iterates through all the actors and checks their tags. You would typically use it after the map loads, store the result and then use the cached array in other places.
You’d typically use Get Player Character as the object in a cast to your character. You’re not going to yield many results with it setup like you have it.
If you were to cast to your character with the Get Player Character node plugged into the cast, you could us the ActorHasTag function to check if your actor has the tag you are looking for.
The problem is that I don’t know how to do this. The actors affected by the blueprint are not game characters. They are used for cinematics, in the sequencer. The Actor has tag function is simply not compatible with the rest of the logic, at least I haven’t found a way to build it in. As I said, a huge amount of logic is built in order to act on the player character/characters. For example, I need logic that allows a character to leave footprints in the snow, as if deforming the landscape, and not just leaving decals. I have a ready-made solution, but again it is designed for a game character. However, I would like to have a way to quickly recycle such blueprints so that I could extend this logic to all the actors I wanted. I am not a programmer and blueprints are not my area of expertise, but very often I have to modify blueprints and sometimes my basic knowledge is not enough. If I find a solution to this problem it will be a big help for me, I can use a huge amount of logic as I don’t care too much about its performance. The main thing is that it works and can be rendered.