In this episode of unreal engine C++ tutorial series, I am going to show you how to setup C++ interfaces. The functions implemented through the interfaces will be able to call from both blueprints and C++ classes and also be able to override and implement in both C++ and blueprint. The reason to implement interfaces in this game is, I needed a function to check if the punches and kicks actually hits the opponent in the time of attack. So, I wanted to implement this logic in c++, but the animation notifiers of kick and punch will be fired in animation blueprint. SO, needed a way to call check hit functions from animation blueprint on the character class. With the help of c++ interfaces we can achieve that without having to do a casting to the relevant character class.
password=codelikeme_interface