Share your repls and programming experiences

← Back to all posts
🐦 Flappy Block 🐦
LorenzoCampos (574)

Unicode character based so it runs 'well' on repl. If this even reaches half the popularity of snake I'll make a bunch of other small games using similar methods.

For people with problems seeing the Unicode characters here's a solution from @sojs

Very big thank you to @firefish for the suggestion on how to clear more efficiently
Thank you to @Muffinlavania for reminding me and for the cursor advice

Coder100 if you're reading this I'm still figuring curses out I didn't ignore your suggestion lmao
Comments
hotnewtop
sojs (295)


It is just a bunch of squares for me.

==Edit==
Wow lot o' upvotes.

tussiez (1435)

@sojs Rip, have you tried switching the emojis

sojs (295)

ya, I forked the repl, and changed air to " ", and walls to "|". everything else worked fine. (view other comment - scroll down a bit) @tussiez

TheC0derGirl (210)

@sojs lul it would have been squares bc your computer/phone hasn't updated their emoji's

LorenzoCampos (574)

@sojs I made sure to link your solution in the description so more people get to use your solution! -thank you

Do you mind updating it a bit? there were small improvements added just so everyone can enjoy them

AndrewMarkarian (15)

Hey it doesn't say that to me it just doesn't let me go up.

Muffinlavania (1512)

A VERY good suggestion I got a while back (I forget from who) is instead of
os.system('clear') #(Or whatever fancy version you have)
You can do
print("\033[H",end="")
One downside is it only update characters, so if some was to spam keys then maybe it would semi glitch out, one major upside is it barely flickers ever
so pog

Muffinlavania (1512)

@Muffinlavania btw this is a much easier thing instead of weird modules like curses and stuff i gave up trying to find out how to do that a while ago Also i think this would be perfect for this since spamming does like nothing

Muffinlavania (1512)

@JBloves27 wait did you give me that

also hi lol haven't been on in a while but im working on a big thing

LorenzoCampos (574)

Thanks for the suggestion, about 2 days ago firefish said the same, I forgot it until now thanks for reminding me!

Muffinlavania (1512)

@LorenzoCampos cool beanz (btw if you gonna give credit for the idea do firefish lol)

Muffinlavania (1512)

@Muffinlavania oh also if you want to not see the cursor having a heart attack you can just put

import cursor 
cursor.hide()

at the start of the code

Muffinlavania (1512)

@JBloves27 i was talking about the print("\033[H",end="") thing, i think it was firefish idk

SeamusDonahue (437)

<consolevar>.erase does the same but without that glitchyness
@Muffinlavania

Nettakrim (678)

@Muffinlavania you can also use "\033[?25l" and "\033[?25h" to hide/show the cursor (this has the advantage of not needing to import anything, speeding up initial load time significantly, but like all ansi codes its only really found on linux)

there is also a chance that the person who told you that was me, or someone who i told
edit: in this post, look at the second comment down

Muffinlavania (1512)

@Nettakrim the man behind the magic print("\033[H",end="")

sojs (295)

Hello everyone! For I see that a lot of people are just seeing squares. Why? I have no idea. Do not worry. You can still play this game. I forked @LorenzoCampos's repl, and changed the characters to standard keyboard ones. Find the repl here. Remember to upvote the post if you like it, as all the code was actually made by @LorenzoCampos, I just changed some parameters.
(Nice game by the way)

TheC0derGirl (210)

@sojs your computer\laptop doesn't have the emoji's (the emojis @LorenzoCampos are too new) so it will come up as squares

sojs (295)

Yes, that is why I forked it. So I could change the emojis. @TheC0derGirl

RhinoRunner (692)

My life

The story of

YeetThatMeat (1)

absolutely phenomenal. The only improvements that I see would be to have just pressing enter on the "want to play again" screen restart it, and perhaps checking the height of the bird relative to the world in scroll() before giving y a value, as spamming space or up arrow can cause the game to continue scrolling without taking damage nor receiving points until it manages to load them. Making this is incredibly impressive. Not only that, but it's a good and fluid game. Keep it up!

LorenzoCampos (574)

@YeetThatMeat great suggestion, ill make sure to include it in future projects!
for the spamming the key thing I'll work on it a bit later when I have more free time

Brendan23 (137)

@LorenzoCampos I don't think you die when you touch the ground in flappy bird.

LorenzoCampos (574)

@Brendan23 I had to do that because it works with a 2d array, if it goes down more it'll just pop up at the top lmao, this was the easiest way to fix that

peternielsen112 (37)

GOTTEM AT 6 bruh

Also, bro. How d'you get so many upvotes? .....

LorenzoCampos (574)

@peternielsen112 I guess you make something fun and people seem to like it!

peternielsen112 (37)

@LorenzoCampos I have a bunch of old projects but they're garbage... and some python text based games. I tried posting but it never gets seen. Any ideas?

LorenzoCampos (574)

@peternielsen112 I guess if you do something uncommon people tend to notice them more, try a unique idea and work on it for a bit and see how it goes!

elijahbernard (6)

Cool game, I got to 45!

generationXcode (329)

my high score is 3 points

IcynDevz (725)

lol I died on the spot

JULIODIAZ1 (46)

brubh if theres a really har obstacle i dont wanna do i found out you can just spam and you skip it

XanthusPettitt (6)

me: plays with 60 frames
this game: I'm bout to end this mans whole career

ThePotatoNinja (0)

Let's gooooooooooo, got 15

chibifox (1)

i died with 32:(

Niamh1234 (0)

5
🟦 🟦 🟩 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟩 🟦 🟦 🟦 🟦 🟦 🟩 🟦 🟦 🟦
🟦 🟦 🟩 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟩 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦
🟦 🟦 🟩 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟩 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦
🟦 🟦 🟩 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟩 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦
🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦
🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦
🟦 🟦 🟩 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟩 🟦 🟦 🟦
🟦 🟦 🟩 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟩 🟦 🟦 🟦 🟦 🟦 🟩 🟦 🟦 🟦
🟦 🟦 🟩 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟩 🟦 🟦 🟦 🟦 🟦 🟩 🟦 🟦 🟦
🟦 ☠ 🟩 🟦 🟦 🟦 🟦 🟦 🟦 🟦 🟩 🟦 🟦 🟦 🟦 🟦 🟩 🟦 🟦 🟦
🟩 🟩 🟩 🟩 🟩 🟩 🟩 🟩 🟩 🟩 🟩 🟩 🟩 🟩 🟩 🟩 🟩 🟩 🟩 🟩
You died with 5 points :)
Want to play again?

ThisUserTaken (237)

Me: ez
Lag: are you sure about that
Me: wait wat
Lag: Its time to add an extra challenge
Program: You died with 0 points

LingWu1 (87)

This is impressive but how on earth did it get so popular

AmefiaDev (2)

Very good. I enjoy.

CoolCoderSJ (499)

this is really cool

PolinaSafonova (0)


died with 14 points, first time playing loool

BananaJellyfish (199)

unfortunately, my computer doesn't process these icons

Coder100 (16802)

bruh i'm living under a rock these days @Coder100

AndrewMarkarian (15)

Beat my highscore of 7!

lolguineapig (20)

wow this is amazing

M1L35 (0)

This is awsome!