Answered step by step
Verified Expert Solution
Question
1 Approved Answer
java please Question One: [5 marks] Write a java program that makes use of the following interfaces and classes to comnect commands in games with
java please
Question One: [5 marks] Write a java program that makes use of the following interfaces and classes to comnect commands in games with different controllers. Interfaces: 'XboxController interface has: void RbO; abstract method. void Rt(); abstract method. void Lb(); abstract method. a void Lt(); abstract method. 'PlaystaionController' interface has: . void R10; abstract method. - voud R2(); abstract method. void LIO; abstract method. 4 void L20; abstract method. Classes: An abstract class called 'ConsoleGame' that has: - Private variables gameName, release Year. agcRestriction. - A full-argument constructor to initialize the above variables. a void run (;; abstract method. a void jump( ; abstract method. - void aim(); abstract method. s void shoot0; abstract method. A class called 'PlaystationGiame' that inherits from ConsoleGame and implements "PlaystaionController". The class should have the following: 4. A full-argument constructor. . Override all methods inherited from 'ConsoleGame so it prints the String "methodName in gameName". For example. the run method in a PlaystationGame object With gameXlame- HCaD" should print "Run in A A full-argument constructor to initialize the above variables. void run(;; abstract method. i void jump0; abstract method. void aim0; abstract method void shoot(O; abstract method. - A class called 'PlaystationGame' that inherits from ConsoleGiame and implements 'PlaystaionController'. The class should have the following: - A full-argument constructor. . Override all methods inberited from 'ConsoleGame 'so it prints the String "methodName in gameName". For example, the run method in a PlaystationGiame object with gameName = " CoD " should print "Run in CoD". . Override all methods inherited from 'PlaystaionController' so it calls a method inherited from ConsoleGame class. For example, method RI calls move. 3. A class called 'XboxGame' that inherits from ConsoleGame and implements 'XboxController'. The class should have the following: - A full-argument constructor. , Override all methods inherited from 'ConsoleGame 'so it prints the String "methodName in gameName". For example. the run method in a XboxGame object with gameName = "CoD" should print "Run in CoD". . Override all methods inherited from 'XboxController' so it calls a method inherited from ConsoleGame class. For example, method Rb calls move. + A driver class "GamingStation" that contains main method. You should make: Create a variable of each controller. Create objects of games with real games information. (At least 2 Playstation games and 2 XboxGames) 4. A driver class "GamingStation" that contains main method. You should make: 1. Create a variable of each controller. 2 Create objects of games with real games information. (At least 2 Playstation games and 2 XboxGames) Show the user a list of available games. 4. Let the user choose which game to play. Assign an object of that game to the appropriate controller. : Let the user choose which button to press and call that button. Repeat until the user exits the program. Sample Output: Hat =4 +Hayxtaj Som gaina I- cotel yasgoara tati23 i+iti. Itat of Xabes gatm = s- dears =(2019s+167 Bricat the gune wuntier yoe waish tu julwy: 7 Encer the tutron ms the Pur in ghekarsed Dine 4 in Theet. in Thehtoted 4 linety juftan Eretar the butech zuabit you wian ta padall These you for diayikg timcharted a thesti ititi [Answer] package gamingstation; public abstract class ConsoleGame \{ Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started