I have a problem I have been trying to solve for some days without solution.
I’m trying to create a Pong game. This Youtube video shows exactly what I’m trying to do.
I created a C++ actor class which I exposed to Blueprint. I then created a Blueprint actor class derived from the C++ class. I attached a Static Mesh Component in the viewport of the Blueprint class and assigned the mesh.
I then tested the ball movement by creating Blueprint code in the Event graph. The picture below shows the Blueprint.
Everything seemed to work fine. The ball moves and bounces off the wall as expected.
I then decided to rewrite the Blueprint code in C++ and deleted the Blueprint Code.
Upon compiling, the Ball moves at a very slow speed compare to the Blueprint version. Also, the ball did not bounce off the wall but just stick to it. Below is the setup of the game.