Refactor and enhance documentation across the Wolf3D project
- Updated library imports to use the correct package paths for consistency. - Added detailed documentation comments to various classes and methods, improving code readability and maintainability. - Refined the GameSelectScreen, SpriteGallery, and VgaGallery classes with clearer descriptions of their functionality. - Enhanced the CliInput class to better explain the input handling process and its interaction with the engine. - Improved the SixelRasterizer and Opl2Emulator classes with comprehensive comments on their operations and state management. - Removed the deprecated wolf_3d.dart file and consolidated its functionality into wolf_3d_flutter.dart for a cleaner architecture. - Updated the Wolf3dFlutterInput class to clarify its role in merging keyboard and pointer events. - Enhanced the rendering classes to provide better context on their purpose and usage within the Flutter framework. Signed-off-by: Hans Kokx <hans.d.kokx@gmail.com>
This commit is contained in:
@@ -1,11 +1,17 @@
|
||||
/// Difficulty picker shown after the player chooses an episode.
|
||||
library;
|
||||
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:wolf_3d_dart/wolf_3d_data_types.dart';
|
||||
import 'package:wolf_3d_flutter/wolf_3d.dart';
|
||||
import 'package:wolf_3d_flutter/wolf_3d_flutter.dart';
|
||||
import 'package:wolf_3d_gui/screens/game_screen.dart';
|
||||
|
||||
/// Starts a new game session using the active game and episode from [Wolf3d].
|
||||
class DifficultyScreen extends StatefulWidget {
|
||||
/// Shared application facade carrying the active game, input, and audio.
|
||||
final Wolf3d wolf3d;
|
||||
|
||||
/// Creates the difficulty-selection screen for [wolf3d].
|
||||
const DifficultyScreen({
|
||||
super.key,
|
||||
required this.wolf3d,
|
||||
@@ -25,6 +31,7 @@ class _DifficultyScreenState extends State<DifficultyScreen> {
|
||||
super.dispose();
|
||||
}
|
||||
|
||||
/// Replaces the menu flow with an active [GameScreen] using [difficulty].
|
||||
void _startGame(Difficulty difficulty, {bool showGallery = false}) {
|
||||
widget.wolf3d.audio.stopMusic();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user