Question: A scene with 2 balls (javafx.scene.shape.Sphere objects) with Java FX program You are expected to implement (scene) implementation. In this application, the red ball the

A scene with 2 balls (javafx.scene.shape.Sphere objects) with Java FX program You are expected to implement (scene) implementation. In this application, the red ball the master (master), the blue ball is the slave (slave). Holding the red ball with the Mouse dragged and draws a tail leaving a red trail as it drifts (javafx.scene.shape.Path). When we click the mouse again (Mouse pressed), the existing trace is erased and the new trace is started to be drawn. The behavior of the blue ball should be as follows. When the red ball is dragged by the mouse, the blue ball is a synchronized ball with the red ball. it should move symmetrically with respect to the center of the scene. Movement of the blue ball as seen in the picture, according to the movement of the red ball, relative to the center of the scene should be symmetrical. (The red ball should go down, the blue ball should go up while it goes left should go right, etc.). The blue ball cannot be self-dragged, only the user's red moves by the ball drag (symmetrical according to the movement of the red ball)

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!