Giter Club home page Giter Club logo

squash_game_implementation's Introduction

squash_game_implementation

Functionality

This the squash game using Python and Pygame libarary created in the OOP approach. This code was based on the Computerphile Pygame tutorial and is my own implementation of the problem. The basic aim of the squash game is to keep bouncing the ball of the controlable paddle for as long as you can.

File structure

The Squash_game consist the following files:

  • squash.py _consist of the main classes (Paddle & Ball) and runs a fully functional Squash game _
  • requirements.txt contains the required packages for the project.

The test files are still under development and will be included in the main project catalog.

Presentation

Zrzut ekranu 2020-08-24 o 21 05 09

Linear Regression

For the purpose of creating a model suitable enough to predict the position of the Paddle the KNN algorithm was used. To colect enough data that could be used in KNN algorithm the model first was trained by user playing a game for some time and writing all the needed posistions to a "game1.csv" file.

Final Pong Game screen view

Zrzut ekranu 2020-08-24 o 23 27 54

Additional challenges

  • write tests for the completed game and placed the test file in the main catalog
  • add second paddle to transform the squash game into a pong game for 2 players
  • add data science to enable playing against AI
  • add more doc strings to make code more user friendly

squash_game_implementation's People

Contributors

markre94 avatar

Watchers

 avatar

squash_game_implementation's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.