Create a class that represents points on a 2d plane. Each point will need to access a
Question:
Create a class that represents points on a 2d plane. Each point will need to access a file and obtain an x and y axis (float). The program must accept a name to the file (points.txt for example) and once the X button is pressed on the program. THE MOVED POINTS MUST BE SAVED IN THE FILE.
Below is a list of what should be completed with the program:
- When the user closes your program by clicking the X in the right-hand corner of the window, your program should save the new point coordinates to the points.txt file
- When the user has finished dragging, the coordinates of that point will be updated and reported in the text field
- When the user hovers their mouse over one of the points, display the coordinates in a text field at the bottom of the screen. For this, use Arial 12 point font
- Create Point objects from the data in the text file and store them in a suitable data structure
- Map and display these points against the screen coordinate system used by the JavaFX package (i.e., with 0,0 located at the top left hand corner)
- Each point should be displayed as a circle with a radius of 5 pixels
READ THE ABOVE INSTRUCTIONS CAREFULLY AND COMPLETE THE PROGRAM
Program TWO must meet these requirements:
Create the following graphical application. The main features of the application are as follows:
The blades of the fan are arcs. When the application first loads, the fan should be in the stop state. The user can press either Start or Reverse to move the fan. Pressing Start moves the fan clockwise, while Reverse moves the fan counter-clockwise. When the fan is moving, it should emit a fan sound (you will need a sound file for this). Handle any errors if the user presses an unusual sequence of buttons (e.g., “start”, then “start” again while the fan is still in motion). You may use any colours you choose for the fan blades. Below is a description of what the program should look like.