Hello Godot Community,
I'm trying to implement a 3D Pinball game and I'm struggling with the physics engine in order to archieve the relatable ball behaviour.
As sandbox, I build a quick and dirty pinball table from build in shapes.
Mostly stretched cubes as static bodies to make to floor and the walls of the table.
The walls are static bodies with appropriate collision shapes.
There are also some wedge meshes used as "reflectors" with collision shapes made with the "create convex collision sibling" function which are static bodies.
My ball is a rigid body sphere with matching collision shape.
The flippers are kinematic bodies, made from a model created in and imported from blender.
I used the "create convex collision sibling" function to create the collision shapes.
The launcher is also a kinematic body with a simple cube mesh and collision shape.
I animated it with an animation player to launch the ball.
I to start the ball I simply start the animation of the launcher, which works well enough for now.
The flippers are controlled via the analog triggers of my X Box Game Controller.
I use the SetRotation function to rotate the flippers according to the ActionStrength of my triggers.
When the ball hits the flippers it sometimes moves as intended, but its kind of glitchy.
The amount of forces the ball receives is not really relatable, small moves may shoot the ball quite fast away, while sometimes a fast flipper movement causes the ball to glitch through the flippers, or does not interact at all.
I tried to increase the physics fps, but it just prevents the ball from shooting out of the top of the table when it "got hit to hard", which fixes this at least.
I also tried using static bodes for the flippers with neglectable results, so I reverted to kinematic bodies.
It's just an prove of concept to get the mechanics straight so no fancy graphics for now.
But is there a fundamental flaw in the design?
What would be a better solution to build a nice and exciting pinball game?