Download

Can't figure out how to call an interface in an anim notify

I currently have a system where the collision of an object is enabled and disabled via an anim notify. This system worked back when it was only being used by my player character. At that time I was casting to the player character. Now, I need to use this system for multiple different actors. I have set up a blueprint interface to do this, but I can’t figure out how to apply the function only to the character that is playing the animation.

This the anim notify blueprint for received notify begin. It is exactly the same for recieved notify end, except that instead it calls Set Collision End.

This is the code called within the character blueprint. I have used strings to test, and can confirm that this does not run. My goal here is to be able to use the animation notify state to call functions in different blueprints, without having to cast to each character using the system. Thank you in advance!

Try calling the “Get Owner” node on the Mesh Comp parameter. This should give you the owning actor that contains that skeletal mesh. If that works, you can then call the interface functions on it without worrying about what type of actor it is.