Refactored the Gameplay logic, rendering
(Translated using google translate)
Player
- BeatmapRenderer
- BeatmapProcessor
- BeatmapInit
- BeatmapRenderer Only handles the rendering part, emphasizing separation; does not perform judgments or important operations like music.
- BeatmapProcessor Currently only handles song chart parsing.
Current Workflow
PlayerInputHandler → Notifies PlayerJudgment
PlayerJudgement → Notifies Processor (markAsHit / registerMiss)
PlayerJudgement → Can directly call Renderer:addHitEffect() (visual effects)
BeatmapProcessor → Provides render data to Renderer:prepare()
BeatmapRenderer → Almost never actively calls other modules (only reads data, draws)
Because different controllers are interdependent, I plan to solve the controller problem with explicit Dependency Injection.
Log in to leave a comment