Files
wolf_dart/packages/wolf_3d_flutter/lib/widgets/wolf3d_app.dart
T

26 lines
674 B
Dart

library;
import 'package:flutter/material.dart';
import 'package:wolf_3d_flutter/wolf_3d_flutter.dart';
/// Minimal app shell that binds a prepared [Wolf3dFlutterEngine] instance to
/// host screens.
class Wolf3dApp extends StatelessWidget {
/// Shared initialized facade that owns game data, input, and audio services.
final Wolf3dFlutterEngine engine;
const Wolf3dApp({
super.key,
required this.engine,
});
@override
Widget build(BuildContext context) {
return engine.availableGames.isEmpty
? NoGameDataScreen(
configuredDataDirectory: engine.configuredDataDirectory,
)
: GameScreen(wolf3d: engine);
}
}