How ahmedalkhwalde/cubic_lands works
This is a Java grid puzzle solver: Main defines a level and starts A*; the search asks GameController for legal successor states, movement logic applies rules to copied boards, and the search prints a goal path or failure. The model tracks cube position/color, visited cells, and color-count goals. The excerpts also show DFS, BFS, uniform-cost, hill-climbing, and interactive play capabilities. No README is present, so coverage and relationships reflect the supplied source excerpts and index.
Main entry points: GameController.java Game controller · MoveOnController.java Move execution · Level.java Level loader · Board.java Board state
Components 11
Entry and play
- Level setup
src/Main.java - Game controller
src/controller/GameController.java
Path search
- Search algorithms
src/Logic/Algorithim.java
Move rules
- Move execution
src/controller/MoveOnController.java - Move validation
src/controller/MoveChekcontroller.java
Puzzle state
- Level loader
src/level/Level.java - Game state
src/level/GameState.java - Board state
src/models/Board.java - Grid cells
src/models/Cell.java - Player cube
src/models/Cube.java
Other components
- Console user
Connections 17
- Level setup → Level loader: creates level
src/Main.java - Level setup → Game controller: initializes game
src/Main.java - Level setup → Search algorithms: starts A*
src/Main.java - Game controller → Level loader: loads board
src/controller/GameController.java - Game controller → Move execution: creates moves
src/controller/GameController.java - Search algorithms → Game controller: requests successors
src/Logic/Algorithim.java - Game controller → Move execution: generates successors
src/controller/GameController.java - Move execution → Move validation: checks movement
src/controller/MoveOnController.java - Move execution → Board state: updates board
src/controller/MoveOnController.java - Move execution → Game state: creates successor
src/controller/MoveOnController.java - Move validation → Board state: reads geometry
src/controller/MoveChekcontroller.java - Level loader → Board state: constructs board
src/level/Level.java - Level loader → Grid cells: constructs cells
src/level/Level.java - Level loader → Player cube: constructs cube
src/level/Level.java - Board state → Grid cells: stores grid
src/models/Board.java - Board state → Player cube: stores cube
src/models/Board.java - Console user → Game controller: enters moves