As the topic says I'm trying to build a pinball game, however I'm having trouble getting the flipper to work. What I need for this is to be able to have the flipper go up (and stay up) while the trigger is held down then, have it reset back to its original position when released.
I've been trying this for the past few days and while I am able to get the flipper up it tends to bounce around a lot and I am unable to get it to reset back to its original position other than with gravity which isn't quite fast enough, so any help would be appreciated especially visual aids on setting up the events.
You could disable the physics on the flipper and use a "Physics Joint" to make it move as you wish... I guess... little bit more complicated but in case you ran out of ideas...
I tried to make a pinball table, but the ball and the flippers need to be slow enough for the physics engine to react. Otherwise the ball just goes through the flippers and walls. I'm also having difficulties to get the ball to stay on the surface of the table, it tends to bounce high up in the air when smashed around with a great force.
Here's a small video:
Have you tried to add big custom collision on top of your table so it would prevent from jumping too high?Originally Posted by mutetus
High velocity + thin collision also is bad combination. There is also fast object checkbox which can help but the main reason is that with high velocity object can "pass" through thin objects between "tick/frames".
I can limit the ball movement to stay inside the playing field with object position functions, but it's that the ball bounces too much inside the table and easily gets stuck in places it should never go. One solution could be to put custom collision blocks to follow every ramp on the table, but too many large blocks just make it a mess. If I make the ball heavier, the linear motors can't push the ball fast enough or the joints won't take the load.Originally Posted by sipe
Those flippers seem perfect, would you mind making a quick guide on how to make them?
I guess I should take some pictures. It's hard to explain. What I did was:
I Created a physics joint between a dummy object and flipper, type Turning Hinges, Upper limit 60 degrees. Then I enabled angular motor on the physics joint and set the force high enough to be able to hit the ball fast. Then I created a variable data source object for the target velocity of the angular motor.
Then I created two Set value events to set the variable data source value to the decided velocity for the flipper to flip and a negative value for the retaining speed. Then the preferred button trigger to set the high value to the variable data source on press and the negative value on release of the button.
There are many ways to do this, but this was reliable enough for me. This setup is constantly pushing the flipper in either direction, but with the angle limit in the joint and high damping value the flipper seems to stay in place nicely.
Well crap, it seems like I was on the right track, what values did you set the motor at?
2500 and -600. The force is 1000 for 85kg ball. The ball has only little bit of linear damping and friction is 1.
mutetus, 2 things:
1. Did you ever work out how to make the ball not pass through the flipper? I am having the same issue.
2. Your bumpers work flawlessly. How did you make those work? I used a WAY more complicated method and it doesn't work nearly as well.
PM me your GamerTag if you'd rather discuss online. That would be awesome.