Skip to content

oib/nummatch

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

9 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

๐Ÿ”ข NumMatch

A fun and educational math game for children to practice multiplication skills!

๐ŸŽฎ Game Description

NumMatch is an interactive web-based multiplication game where players find two numbers that multiply to match a target number. With its kid-friendly interface, colorful design, and immediate feedback, it makes learning multiplication fun and engaging.

โœจ Features

  • ๐ŸŽฏ Simple Gameplay: Find two numbers that multiply to the target
  • ๐ŸŽจ Kid-Friendly Design: Large buttons, clear visuals, and fun emojis
  • ๐Ÿ“ฑ Responsive: Works on tablets and desktop computers
  • โšก Instant Feedback: Visual and text feedback for every answer
  • ๐ŸŒ™ Dark Theme: Easy on the eyes with kid-friendly dark mode
  • ๐ŸŽฎ Virtual Keypad: Touch-friendly number input

๐Ÿš€ Quick Start

Option 1: Using the provided script (Recommended)

sudo game

Option 2: Manual setup

# Clone the repository
git clone https://github.com/yourusername/nummatch.git
cd nummatch

# Create virtual environment
python3 -m venv venv
source venv/bin/activate

# Install dependencies
pip install fastapi uvicorn

# Run the game
uvicorn main:app --host 0.0.0.0 --port 8000

Open your browser and navigate to http://localhost:8000

๐Ÿ“‹ Requirements

  • Python 3.8+
  • FastAPI
  • Uvicorn

๐ŸŽฏ How to Play

  1. Look at the target number (๐ŸŽฏ)
  2. Enter two numbers that multiply to give the target
  3. Use the virtual keypad or keyboard to input numbers
  4. Click the check button or press Enter
  5. Get instant feedback with emojis and colors
  6. New challenges appear automatically!

๐Ÿ”ง Systemd Service Setup

To run NumMatch as a system service:

  1. Copy the service file:
sudo cp nummatch.service /etc/systemd/system/
  1. Reload systemd:
sudo systemctl daemon-reload
  1. Enable and start the service:
sudo systemctl enable nummatch
sudo systemctl start nummatch
  1. Check status:
sudo systemctl status nummatch

๐Ÿ“ Project Structure

nummatch/
โ”œโ”€โ”€ main.py              # FastAPI backend
โ”œโ”€โ”€ static/              # Frontend assets
โ”‚   โ”œโ”€โ”€ index.html       # Main HTML page
โ”‚   โ”œโ”€โ”€ app.js          # Core game logic
โ”‚   โ”œโ”€โ”€ keypad.js       # Virtual keypad
โ”‚   โ”œโ”€โ”€ button.js       # Button interactions
โ”‚   โ”œโ”€โ”€ message.js      # Message handling
โ”‚   โ””โ”€โ”€ style.css       # Styling (with dark theme)
โ”œโ”€โ”€ docs/
โ”‚   โ””โ”€โ”€ structure.md    # Detailed documentation
โ”œโ”€โ”€ nummatch.service    # Systemd service file
โ”œโ”€โ”€ game               # Startup script
โ”œโ”€โ”€ README.md          # This file
โ””โ”€โ”€ LICENSE            # MIT License

๐ŸŽจ Customization

Changing Difficulty

Edit the generateTarget function in static/app.js to adjust the number ranges.

Adding Themes

Modify static/style.css to add new color schemes or themes.

Language Support

The interface currently uses German. Update the text in static/app.js and static/index.html for other languages.

๐Ÿค Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

  1. Fork the project
  2. Create your feature branch (git checkout -b feature/AmazingFeature)
  3. Commit your changes (git commit -m 'Add some AmazingFeature')
  4. Push to the branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

๐Ÿ“„ License

This project is licensed under the MIT License - see the LICENSE file for details.

๐Ÿ™ Acknowledgments

  • Designed for children learning multiplication
  • Built with FastAPI and vanilla JavaScript
  • Inspired by the need for engaging educational tools

๐Ÿ“ž Support

If you encounter any issues or have suggestions, please:

  • Open an issue on GitHub
  • Check the documentation for technical details

Made with โค๏ธ for young learners everywhere

About

๐Ÿ”ข A fun and educational math game for children to practice multiplication skills! Built with FastAPI and vanilla JavaScript."

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors