Package-level declarations
Overview
Application-specific exceptions for handling GUI-related errors and user-facing error states.
Exception Types
CouldNotLoadAsset— Thrown when audio/visual assets fail to loadErrorMessage— Base exception for user-displayable error messagesExitApp— Exception to signal application exitGameCorrupted— Thrown when loaded game data is corruptedGameIsFull— Thrown when attempting to join a full gameGameNotStartedYet— Thrown when operations require an active gameNoPieceSelected— Thrown when move requires piece selection
Responsibilities
Providing user-friendly error messages
Distinguishing recoverable from fatal errors
Supporting graceful error handling in the UI
Types
Exception thrown when a required text input field is empty.
Exception thrown when a saved game file is corrupted or cannot be deserialized.
Exception thrown when attempting to join a multiplayer game that already has all players.
Exception thrown when an operation requires an active game that hasn't been started yet.
Exception thrown when the user attempts to start a game without selecting a piece color.
Functions
Composable that displays an error message based on the error type.
Composable that shows a toast message for errors. The message is displayed for 2 seconds before being cleared.