Package mastermind.gui.scenes
Class CodeBreaker
java.lang.Object
mastermind.gui.scenes.Scene
mastermind.gui.scenes.CodeBreaker
The Code Breaker gameplay.
-
Field Summary
-
Constructor Summary
ConstructorDescriptionCodeBreaker
(JFrame frame, MastermindAlgorithm algorithm) Represents the CodeBreaker scene in the application, inheriting from the parent `Scene` class. -
Method Summary
Methods inherited from class mastermind.gui.scenes.Scene
createDefaultScene
-
Constructor Details
-
CodeBreaker
Represents the CodeBreaker scene in the application, inheriting from the parent `Scene` class.This scene manages the game logic and user interface for a Mastermind game implementation. It initializes necessary UI components, handles game interactions, and updates the game state.
The class uses a selected algorithm to solve the Mastermind puzzle and provides controls for managing user responses and progression in the game.
- Parameters:
frame
- The parent `JFrame` that contains this scene.algorithm
- The algorithm to be used for solving the Mastermind puzzle. Supported algorithms include `DonaldKnuth`, `Medium`, and `Basic`.- Throws:
IllegalArgumentException
- if the provided algorithm is null or unsupported.
-