A micro-game "flappy bird".

Overview

1-o-flappy

A micro-game "flappy bird".

Gameplays

The game will be installed at /usr/bin . The name of it is "1-o-flappy". You can type "1-o-flappy" to start a game. When the game starts, the "bird" will go down automatically. Press enter to control the vertical moving of the "bird" and it will go up. When the "bird" falls down or touch any rolls, the game will be over and it will show "Game over!". Press Ctrl-C to pause in a game. You will never win this game.
The title bar of the game shows: date and time, the time that the game has run(Unit: second), vertical speed, horizontal speed, the range of the rolls, and the score.

Config

When a game starts, it will load a config file named ".1-o-flappy" that be at your home directory. If that file does not exist, the game will create it. If you want to see the default content of this file, please go to next page.
The file must contain these to run the game normally:

  • roll_skin -> a str
  • width -> an int(> 0)
  • p_skin -> a str
  • height -> an int(> 0)
  • blank_skin -> a str
  • speed_v -> an int or a float(> 0) or a str(eval(str) > 0)
  • v_border -> a str
  • speed_h -> an int or a float(> 0) or a str(eval(str) > 0)
  • h_border -> a str
  • high -> an int(> 0)
  • roll_range -> an int(> 0) or a str(type(eval(str)) == int and eval(str) > 0)
  • cooldown_tile -> an int(>= 0) or a str(type(eval(str)) == int and eval(str) >= 0)

roll_skin means the skin of the rolls(the default is "|").
p_skin means the skin of the "bird"(the default is "O").
blank_skin means the skin of the blank area(the default is " ").
v_border means the skin of the vertical border on the right(the default is "").
h_border means the skin of the horizontal border on the bottom(the default is "-").
You can color the skin(like "\033[42m").
The default content of the config file:

# The config file of Flappy.

# Skin config start
roll_skin = "|"
p_skin = "O"
blank_skin = " "
v_border = ""
h_border = "-"
# Skin config end

# Gameplay config start
width = 79
height = 18
speed_v = 20
speed_h = 4
roll_range = 3
cooldown_tile = 16
high = 15
# Gameplay config end

width means the visible width of the checkerboard(the default is 79).
height means the visible height of the checkerboard(the default is 18).
speed_v means the vertical(right to left) moving speed of the "bird"(the default is 20). It is also the speed of the refreshing.
speed_h means the horizontal moving speed of the "bird"(the default is 4).
roll_range means the passable range of the rolls(the default is 3).
cooldown_tile means the value of the least separation of two rolls(the default is 16).
high means the initial height of the "bird".
speed_v, speed_h, roll_range, cooldown_tile can be a str. If it is a str, the game will read it as eval(str). Be sure the eval value of it is a positive, and also be sure the type of the eval value of roll_range or cooldown_tile is an int. Else an error will occur.
Some usable values:

"(time.time()-start_time)" # the value of the time that game has run(Unit: s)
"(score)" # the score of the game
"(high)" # the height of the "bird"
"(time.time())" # the time that be generated by time.time
"(sum(checkerboard))" # the sum of the height of all the rolls

FAQ

Q: Why the name of this game is "1-o-flappy"?
A: The real name of this game is "1-O-Flappy". "1-o-flappy" is the name of the deb archive. "1" refers to "|", it is the default skin of the rolls. "O" is the default skin of the "bird". The "1-O-" helps the name of the game avoid name conflict.
Q: I pressed enter, but why does not the "bird" go up?
A: That seems your did not press enter frequently or the setting of the repeating of the keyboard inputting is too slow.
Q: Why the game looks like a contorted space after modifying the skins in the config file?
A: That is one of the core features of this game, so enjoy it πŸ˜„
Q: Why this game is installed at /usr/bin but not /usr/games ?
A: Treat it equally with other executable files.

You might also like...
Deep Q-learning for playing chrome dino game
Deep Q-learning for playing chrome dino game

[PYTORCH] Deep Q-learning for playing Chrome Dino

A simple pygame dino game which can also be trained and played by a NEAT KI

Dino Game AI Game The game itself was developed with the Pygame module pip install pygame You can also play it yourself by making the dino jump with t

Implementation of QuickDraw - an online game developed by Google, combined with AirGesture - a simple gesture recognition application
Implementation of QuickDraw - an online game developed by Google, combined with AirGesture - a simple gesture recognition application

QuickDraw - AirGesture Introduction Here is my python source code for QuickDraw - an online game developed by google, combined with AirGesture - a sim

A simple Rock-Paper-Scissors game using CV in python

ML18_Rock-Paper-Scissors-using-CV A simple Rock-Paper-Scissors game using CV in python For IITISOC-21 Rules and procedure to play the interactive game

ICS 4u HD project, start before-wards. A curtain shooting game using python.

Touhou-Star-Salvation HDCH ICS 4u HD project, start before-wards. A curtain shooting game using python and pygame. By Jason Li For arts and gameplay,

A Real-Time-Strategy game for Deep Learning research
A Real-Time-Strategy game for Deep Learning research

Description DeepRTS is a high-performance Real-TIme strategy game for Reinforcement Learning research. It is written in C++ for performance, but provi

A customisable game where you have to quickly click on black tiles in order of appearance while avoiding clicking on white squares.

W.I.P-Aim-Memory-Game A customisable game where you have to quickly click on black tiles in order of appearance while avoiding clicking on white squar

A Game-Theoretic Perspective on Risk-Sensitive Reinforcement Learning

Officile code repository for "A Game-Theoretic Perspective on Risk-Sensitive Reinforcement Learning"

Offline Multi-Agent Reinforcement Learning Implementations: Solving Overcooked Game with Data-Driven Method
Offline Multi-Agent Reinforcement Learning Implementations: Solving Overcooked Game with Data-Driven Method

Overcooked-AI We suppose to apply traditional offline reinforcement learning technique to multi-agent algorithm. In this repository, we implemented be

Releases(v0.1.3.59123)
Owner
Just make it.
UNAVOIDS: Unsupervised and Nonparametric Approach for Visualizing Outliers and Invariant Detection Scoring

UNAVOIDS: Unsupervised and Nonparametric Approach for Visualizing Outliers and Invariant Detection Scoring Code Summary aggregate.py: this script aggr

1 Dec 28, 2021
Contrastively Disentangled Sequential Variational Audoencoder

Contrastively Disentangled Sequential Variational Audoencoder (C-DSVAE) Overview This is the implementation for our C-DSVAE, a novel self-supervised d

Junwen Bai 35 Dec 24, 2022
Codes for the AAAI'22 paper "TransZero: Attribute-guided Transformer for Zero-Shot Learning"

TransZero [arXiv] This repository contains the testing code for the paper "TransZero: Attribute-guided Transformer for Zero-Shot Learning" accepted to

Shiming Chen 52 Jan 01, 2023
An open-source outlier detection package by Getcontact Data Team

pyfbad The pyfbad library supports anomaly detection projects. An end-to-end anomaly detection application can be written using the source codes of th

Teknasyon Tech 41 Dec 27, 2022
Tutel MoE: An Optimized Mixture-of-Experts Implementation

Project Tutel Tutel MoE: An Optimized Mixture-of-Experts Implementation. Supported Framework: Pytorch Supported GPUs: CUDA(fp32 + fp16), ROCm(fp32) Ho

Microsoft 344 Dec 29, 2022
This repository contains the code for EMNLP-2021 paper "Word-Level Coreference Resolution"

Word-Level Coreference Resolution This is a repository with the code to reproduce the experiments described in the paper of the same name, which was a

79 Dec 27, 2022
BMW TechOffice MUNICH 148 Dec 21, 2022
Decompose to Adapt: Cross-domain Object Detection via Feature Disentanglement

Decompose to Adapt: Cross-domain Object Detection via Feature Disentanglement In this project, we proposed a Domain Disentanglement Faster-RCNN (DDF)

19 Nov 24, 2022
Mini Software that give reminder to drink water as per your weight.

Water Notification Desktop Python The Mini Software built in Python (tkinter) that will remind you to drink water on specific time span based on your

Om Jogani 5 Dec 16, 2022
This repository for project that can Automate Number Plate Recognition (ANPR) in Morocco Licensed Vehicles. πŸ’» + πŸš™ + πŸ‡²πŸ‡¦ = πŸ€– πŸ•΅πŸ»β€β™‚οΈ

MoroccoAI Data Challenge (Edition #001) This Reposotory is result of our work in the comepetiton organized by MoroccoAI in the context of the first Mo

SAFOINE EL KHABICH 14 Oct 31, 2022
Python package for covariance matrices manipulation and Biosignal classification with application in Brain Computer interface

pyRiemann pyRiemann is a python package for covariance matrices manipulation and classification through Riemannian geometry. The primary target is cla

447 Jan 05, 2023
Advanced Deep Learning with TensorFlow 2 and Keras (Updated for 2nd Edition)

Advanced Deep Learning with TensorFlow 2 and Keras (Updated for 2nd Edition)

Packt 1.5k Jan 03, 2023
Systematic generalisation with group invariant predictions

Requirements are Python 3, TensorFlow v1.14, Numpy, Scipy, Scikit-Learn, Matplotlib, Pillow, Scikit-Image, h5py, tqdm. Experiments were run on V100 GPUs (16 and 32GB).

Faruk Ahmed 30 Dec 01, 2022
Pytorch implementation for "Large-Scale Long-Tailed Recognition in an Open World" (CVPR 2019 ORAL)

Large-Scale Long-Tailed Recognition in an Open World [Project] [Paper] [Blog] Overview Open Long-Tailed Recognition (OLTR) is the author's re-implemen

Zhongqi Miao 761 Dec 26, 2022
SalFBNet: Learning Pseudo-Saliency Distribution via Feedback Convolutional Networks

SalFBNet This repository includes Pytorch implementation for the following paper: SalFBNet: Learning Pseudo-Saliency Distribution via Feedback Convolu

12 Aug 12, 2022
A pytorch reproduction of { Co-occurrence Feature Learning from Skeleton Data for Action Recognition and Detection with Hierarchical Aggregation }.

A PyTorch Reproduction of HCN Co-occurrence Feature Learning from Skeleton Data for Action Recognition and Detection with Hierarchical Aggregation. Ch

Guyue Hu 210 Dec 31, 2022
PyTorch implementation for the ICLR 2020 paper "Understanding the Limitations of Variational Mutual Information Estimators"

Smoothed Mutual Information ``Lower Bound'' Estimator PyTorch implementation for the ICLR 2020 paper Understanding the Limitations of Variational Mutu

50 Nov 09, 2022
3D Human Pose Machines with Self-supervised Learning

3D Human Pose Machines with Self-supervised Learning Keze Wang, Liang Lin, Chenhan Jiang, Chen Qian, and Pengxu Wei, β€œ3D Human Pose Machines with Self

Chenhan Jiang 398 Dec 20, 2022
PyTorch code for our paper "Attention in Attention Network for Image Super-Resolution"

Under construction... Attention in Attention Network for Image Super-Resolution (A2N) This repository is an PyTorch implementation of the paper "Atten

Haoyu Chen 71 Dec 30, 2022
Medical-Image-Triage-and-Classification-System-Based-on-COVID-19-CT-and-X-ray-Scan-Dataset

Medical-Image-Triage-and-Classification-System-Based-on-COVID-19-CT-and-X-ray-Sc

2 Dec 26, 2021