Code Monkey home page Code Monkey logo

ascii_racer's Introduction

                    _ _                           
     /\            (_(_)                          
    /  \   ___  ___ _ _   _ __ __ _  ___ ___ _ __ 
   / /\ \ / __|/ __| | | | '__/ _` |/ __/ _ | '__|
  / ____ \\__ | (__| | | | | | (_| | (_|  __| |   
 /_/    \_|___/\___|_|_| |_|  \__,_|\___\___|_|   

PyPI Build Status GitHub last commit Downloads License: MIT

An endless racing game that runs in the terminal. 100% Python.

ascii-racer

Instructions

Collect as many alcoholic drinks as possible, while avoiding the Beer drinks. The game is only key-based.

Keys Role
a Move Left
d Move Right
w Accelerate
s Decelerate
q Quit game

Installation

+ Please report issues if you try to install and run into problems!

Make sure you are running at least Python 3.6.0

Install using pip:

pip3 install asciiracer

or clone the repository and install manually:

$ git clone https://github.com/UpGado/ascii_racer.git
$ cd ascii_racer && python3 setup.py install

Start Game

To start the game, run either:

$ asciiracer
$ python -m asciiracer

Scoring

There are four different types of drinks that you can collect on the racetrack.

  • Vodka - 10 Points
  • Gin - 5 Points
  • $ - 1 Point
  • Beer - Negative 20 points

Contributions

+ If you think this is cool, fork it and make it cooler!

This might be great practice if you want to learn Python, and you can personally reach out to me if you have any questions about the simple but elegant code base.

Possible Improvements

  • Color support.
  • Curvy roads and more interesting tracks.
  • Multiplayer/Competitive racing.
  • Your creative idea.

If you encounter any problem or have any suggestions, please open an issue or send a PR.

ascii_racer's People

Contributors

creik74 avatar jbarna avatar nithilan4 avatar rbagrov avatar upgado avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

ascii_racer's Issues

The game crashes after a few seconds

Here is the stack trace

Traceback (most recent call last):
File "/home/naveen/anaconda3/bin/asciiracer", line 11, in
load_entry_point('asciiracer==0.1.1', 'console_scripts', 'asciiracer')()
File "/home/naveen/anaconda3/lib/python3.6/site-packages/pkg_resources/init.py", line 570, in load_entry_point
return get_distribution(dist).load_entry_point(group, name)
File "/home/naveen/anaconda3/lib/python3.6/site-packages/pkg_resources/init.py", line 2751, in load_entry_point
return ep.load()
File "/home/naveen/anaconda3/lib/python3.6/site-packages/pkg_resources/init.py", line 2405, in load
return self.resolve()
File "/home/naveen/anaconda3/lib/python3.6/site-packages/pkg_resources/init.py", line 2411, in resolve
module = import(self.module_name, fromlist=['name'], level=0)
File "/home/naveen/anaconda3/lib/python3.6/site-packages/asciiracer/main.py", line 1, in
from . import game
File "/home/naveen/anaconda3/lib/python3.6/site-packages/asciiracer/game.py", line 54, in
curses.wrapper(main)
File "/home/naveen/anaconda3/lib/python3.6/curses/init.py", line 94, in wrapper
return func(stdscr, *args, **kwds)
File "/home/naveen/anaconda3/lib/python3.6/site-packages/asciiracer/game.py", line 40, in main
draw_scene(screen)
File "/home/naveen/anaconda3/lib/python3.6/site-packages/asciiracer/misc.py", line 17, in run
raise RuntimeError('cannot keep up with target FPS')
RuntimeError: cannot keep up with target FPS

Help

Where to get ncurses modules

Hi and thank you

I was new to github and a search for several project to see how it could be done properly as i was making a python project too.
I took a lot from your readme ahah but also the GetResolution that worik for windows, and i tried to fork the travis.yml but i'm not ready yet..
So here it is a big thank you for your project ^^

Submit button on your website doesn't work

@UpGado
Sorry, if i write here but the submit button on your website doesn't work and i didn't find a mail address do go in contact with you.

Can you check the submit button on your website please?

Thx!

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.