Skip to content

This is a Python 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.

License

Notifications You must be signed in to change notification settings

techn0man1ac/simpleAIGame

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 

Repository files navigation

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

About

This is a Python 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.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages