PINBALL QUEST: ‘Left And Right’ - Solutions

Quest: Pinball
Challenge: Left And Right

Feel free to share your solutions, ideas and creations below. If you get stuck, you can find some ideas here for completing this challenge.

So I was wondering how to get the left flipper to actually work. I’m out of ideas.

If i remember I copied the right one, then spent ages adjusting the hinge joint and the z rotation

@davidwindsands
see my solution on the “Flippin’ Heck” thread.

public class Flipper : MonoBehaviour
{
    // configs
    [SerializeField] KeyCode keyMapping;

    // cache
    HingeJoint2D joint;

    // Unity messages
    void Awake()
    {
        joint = GetComponent<HingeJoint2D>();
    }

    void Update()
    {
        if (Input.GetKey(keyMapping))
        {
            joint.useMotor = true;
        }
        else
        {
            joint.useMotor = false;
        }
    }
}
2 Likes

Do you put this on both paddles & therefore control the paddle from the controller?

For the left paddle, I set the lower angle to the opposite value of the right flippers lower angle. Then, I needed to set Motor Speed to -10,000 and it worked.


For this challenge I created a serialized field called “isLeft” and set it to true on both my left flippers. Then, I check this bool while checking the input within the update method.

Privacy & Terms