Skip to content

Latest commit

 

History

History
39 lines (28 loc) · 1.49 KB

README.md

File metadata and controls

39 lines (28 loc) · 1.49 KB

Square AI Game

Square AI Game screen

Overview

This is a simple game developed using Pygame, where the red square (controlled by an AI) tries to escape from the black square (controlled by the player). The AI believes the player is an enemy and uses four commands - left, right, up, down - to flee from it.

Video demonstration

https://youtube.com/shorts/unALV4uoLmQ

Features

  • Player control using the arrow keys
  • AI-driven enemy movement using Ollama's Llama model
  • Basic collision detection
  • Simple and clear game loop with Pygame

Requirements

Game Mechanics

Work job gif

The player controls a black square using the arrow keys. The red square (enemy) moves based on the AI model's response to the player's position. If the player catches the enemy, a "Game Over" message is displayed, and the game exits after a short delay.

License

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

Acknowledgements

  • Developed by Serhii Trush
  • Pygame - For the game library
  • Ollama - For the AI model and API
  • ChatGPT - For helping with code and documentation