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.
PyTorch implementation of D2C: Diffuison-Decoding Models for Few-shot Conditional Generation.

D2C: Diffuison-Decoding Models for Few-shot Conditional Generation Project | Paper PyTorch implementation of D2C: Diffuison-Decoding Models for Few-sh

Jiaming Song 90 Dec 27, 2022
automated systems to assist guarding corona Virus precautions for Closed Rooms (e.g. Halls, offices, etc..)

Automatic-precautionary-guard automated systems to assist guarding corona Virus precautions for Closed Rooms (e.g. Halls, offices, etc..) what is this

badra 0 Jan 06, 2022
GarmentNets: Category-Level Pose Estimation for Garments via Canonical Space Shape Completion

GarmentNets This repository contains the source code for the paper GarmentNets: Category-Level Pose Estimation for Garments via Canonical Space Shape

Columbia Artificial Intelligence and Robotics Lab 43 Nov 21, 2022
Implement of "Training deep neural networks via direct loss minimization" in PyTorch for 0-1 loss

This is the implementation of "Training deep neural networks via direct loss minimization" published at ICML 2016 in PyTorch. The implementation targe

Cuong Nguyen 1 Jan 18, 2022
A module for solving and visualizing Schrödinger equation.

qmsolve This is an attempt at making a solid, easy to use solver, capable of solving and visualize the Schrödinger equation for multiple particles, an

506 Dec 28, 2022
Discretized Integrated Gradients for Explaining Language Models (EMNLP 2021)

Discretized Integrated Gradients for Explaining Language Models (EMNLP 2021) Overview of paths used in DIG and IG. w is the word being attributed. The

INK Lab @ USC 17 Oct 27, 2022
Unofficial Implementation of MLP-Mixer, gMLP, resMLP, Vision Permutator, S2MLPv2, RaftMLP, ConvMLP, ConvMixer in Jittor and PyTorch.

Unofficial Implementation of MLP-Mixer, gMLP, resMLP, Vision Permutator, S2MLPv2, RaftMLP, ConvMLP, ConvMixer in Jittor and PyTorch! Now, Rearrange and Reduce in einops.layers.jittor are support!!

130 Jan 08, 2023
Self-Supervised Methods for Noise-Removal

SSMNR | Self-Supervised Methods for Noise Removal Image denoising is the task of removing noise from an image, which can be formulated as the task of

1 Jan 16, 2022
Various operations like path tracking, counting, etc by using yolov5

Object-tracing-with-YOLOv5 Various operations like path tracking, counting, etc by using yolov5

Pawan Valluri 5 Nov 28, 2022
This repository contains the code used for Predicting Patient Outcomes with Graph Representation Learning (https://arxiv.org/abs/2101.03940).

Predicting Patient Outcomes with Graph Representation Learning This repository contains the code used for Predicting Patient Outcomes with Graph Repre

Emma Rocheteau 76 Dec 22, 2022
PyTorch implementation of Advantage async actor-critic Algorithms (A3C) in PyTorch

Advantage async actor-critic Algorithms (A3C) in PyTorch @inproceedings{mnih2016asynchronous, title={Asynchronous methods for deep reinforcement lea

LEI TAI 111 Dec 08, 2022
An Open Source Machine Learning Framework for Everyone

Documentation TensorFlow is an end-to-end open source platform for machine learning. It has a comprehensive, flexible ecosystem of tools, libraries, a

170.1k Jan 04, 2023
Replication Package for AequeVox:Automated Fariness Testing for Speech Recognition Systems

AequeVox Replication Package for AequeVox:Automated Fariness Testing for Speech Recognition Systems README under development. Python Packages Required

Sai Sathiesh 2 Aug 28, 2022
This is project is the implementation of the DeepShift: Towards Multiplication-Less Neural Networks paper

DeepShift This is project is the implementation of the DeepShift: Towards Multiplication-Less Neural Networks paper, that aims to replace multiplicati

Mostafa Elhoushi 88 Dec 23, 2022
HyperPose is a library for building high-performance custom pose estimation applications.

HyperPose is a library for building high-performance custom pose estimation applications.

TensorLayer Community 1.2k Jan 04, 2023
A Pytorch implementation of "Manifold Matching via Deep Metric Learning for Generative Modeling" (ICCV 2021)

Manifold Matching via Deep Metric Learning for Generative Modeling A Pytorch implementation of "Manifold Matching via Deep Metric Learning for Generat

69 Dec 10, 2022
"NAS-Bench-301 and the Case for Surrogate Benchmarks for Neural Architecture Search".

NAS-Bench-301 This repository containts code for the paper: "NAS-Bench-301 and the Case for Surrogate Benchmarks for Neural Architecture Search". The

AutoML-Freiburg-Hannover 57 Nov 30, 2022
This project is the PyTorch implementation of our CVPR 2022 paper:

Requirements and Dependency Install PyTorch with CUDA (for GPU). (Experiments are validated on python 3.8.11 and pytorch 1.7.0) (For visualization if

Lei Huang 23 Nov 29, 2022
FreeSOLO for unsupervised instance segmentation, CVPR 2022

FreeSOLO: Learning to Segment Objects without Annotations This project hosts the code for implementing the FreeSOLO algorithm for unsupervised instanc

NVIDIA Research Projects 253 Jan 02, 2023
SCI-AIDE : High-fidelity Few-shot Histopathology Image Synthesis for Rare Cancer Diagnosis

SCI-AIDE : High-fidelity Few-shot Histopathology Image Synthesis for Rare Cancer Diagnosis Pretrained Models In this work, we created synthetic tissue

Emirhan Kurtuluş 1 Feb 07, 2022