How filiph/tictactoe works
This repository is a Flutter tic-tac-toe puzzle game for mobile, with web demos. The intended player journey is app entry, menu, level selection, play against an opponent, then a win/result screen. The tree also shows settings and progress state, plus audio, ads, purchases, game services, and crash reporting. Dart implementation excerpts were not provided, so gameplay and service connections are shown as dashed, unverified relationships; the sampled macOS window-to-plugin registration is supported by source.
Main entry points: main_menu_screen.dart Main menu · play_session_screen.dart Play session · main.dart App entry · ai_opponent.dart AI opponents
Components 26
Player experience
- App entry
lib/main.dart - Main menu
lib/src/main_menu/main_menu_screen.dart - Level selection
lib/src/level_selection/level_selection_screen.dart - Play session
lib/src/play_session/play_session_screen.dart - Game board
lib/src/play_session/game_board.dart - Win screen
lib/src/win_game/win_game_screen.dart
Game logic
- Board state
lib/src/game_internals/board_state.dart - Board tiles
lib/src/game_internals/tile.dart - Board settings
lib/src/game_internals/board_setting.dart - AI opponents
lib/src/ai/ai_opponent.dart - Random opponent
lib/src/ai/random_opponent.dart - Scoring opponent
lib/src/ai/scoring_opponent.dart - Humanlike opponent
lib/src/ai/humanlike_opponent.dart
Player state
- Player progress
lib/src/player_progress/player_progress.dart - Progress persistence
lib/src/player_progress/persistence/local_storage_player_progress_persistence.dart - Settings
lib/src/settings/settings.dart - Settings persistence
lib/src/settings/persistence/local_storage_settings_persistence.dart
Game services
- Audio controller
lib/src/audio/audio_controller.dart - Ads controller
lib/src/ads/ads_controller.dart - In-app purchase
lib/src/in_app_purchase/in_app_purchase.dart - Game services
lib/src/games_services/games_services.dart - Crash reporting
lib/src/crashlytics/crashlytics.dart - App lifecycle
lib/src/app_lifecycle/app_lifecycle.dart
Platform integration
- macOS Flutter window
macos/Runner/MainFlutterWindow.swift - Plugin registration
macos/Flutter/GeneratedPluginRegistrant.swift
Other components
- Player
Connections 23
- Player → App entry: launches
- App entry → Main menu: opens
- Main menu → Level selection: selects level
- Level selection → Play session: starts game
- Play session → Game board: shows board
- Game board → Board state: uses state
- Game board → Board tiles: renders tiles
- Play session → AI opponents: uses opponent
- AI opponents → Random opponent: selects strategy
- AI opponents → Scoring opponent: selects strategy
- AI opponents → Humanlike opponent: selects strategy
- Play session → Win screen: shows result
- Level selection → Player progress: uses progress
- Player progress → Progress persistence: persists progress
- Main menu → Settings: opens settings
- Settings → Settings persistence: persists settings
- Play session → Audio controller: plays audio
- Main menu → Ads controller: displays ads
- Main menu → In-app purchase: offers purchase
- Win screen → Game services: reports score
- App entry → Crash reporting: reports crashes
- App entry → App lifecycle: tracks lifecycle
- macOS Flutter window → Plugin registration: registers plugins
macos/Runner/MainFlutterWindow.swift