A simple Tic Tac Toe game built with Flutter and Dart for two players, featuring background sound. This project demonstrates the use of the Flutter framework along with flame_audio
for sound effects and flutter_launcher_icons
for custom app icons.
The project is organized as follows:
tic_tac_toe/
│ ├── lib/
│ ├── main.dart
│ └── home_page.dart
│ ├── pubspec.yaml
└── README.md
lib/main.dart
: The entry point of the application.lib/home_page.dart
: The main page where the game is played.
This project uses the following external dependencies:
flame_audio: ^2.10.1
: For playing background sound and sound effects.flutter_launcher_icons: ^0.13.1
: For custom app icons.
To get started with the Tic Tac Toe Flutter app, follow these steps:
-
Clone the repository:
git clone https://github.com/yourusername/tictactoe_flutter.git cd tictactoe_flutter
-
Install dependencies:
Ensure you have Flutter installed. Then, run:
flutter pub get
-
Run the app:
You can run the app on an emulator or physical device using:
flutter run
-
Setting up
flutter_launcher_icons
:Configure your app icon in the
pubspec.yaml
file under theflutter_launcher_icons
section. For example:flutter_launcher_icons: android: true ios: true image_path: "assets/icon/app_icon.png"
Replace
assets/icon/app_icon.png
with the path to your app icon image. -
Playing Background Sound:
Make sure to place your audio files in the appropriate assets directory and configure them in
pubspec.yaml
:flutter: assets: - assets/sounds/background_music.mp3
Feel free to open issues, submit pull requests, or contribute in any way to improve the app.
Contributions are welcome! To contribute:
- Fork the repository.
- Create a new branch (git checkout -b feature/YourFeature).
- Make your changes.
- Commit your changes (git commit -am 'Add some feature').
- Push to the branch (git push origin feature/YourFeature).
- Create a Pull Request.