Skip to content
Sign upLog in
Profile icon

Brendan23

@Brendan23
  • all aboard!

    Cover page
    Made with Python
    Recent comments (2)

    Wow! Nice animation! very impressive. And that guy that got left behind XD

Repls
Community
Brendan23
Brendan23
shared a Post
1 year ago
1
Python Animation Help
Hello, If you run the repl it works but the same line at the top of the console doesn't change! how can I change or remove that? also, if you can, how
Testing
Python
InvisibleOne
InvisibleOne
Just delete line 11 to remove the time it waits.1 year ago
MrVoo
MrVoo
To remove/shorten the delay, edit line 11. Also I would suggest redoing it entirely and have something like this: from sys import stdout from random import randint from time import sleep while True: print('|'+' '*randint(1,30), end='') stdout.flush() sleep(0.005) `1 year ago
Brendan23
Brendan23
shared a Post
1 year ago
1
If you run the repl, make 2 or more food, then do serve food, it will only do one of them. why is that, and how do I solve it?
Work In Progress (WIP)
Python
IMayBeMe
IMayBeMe
It seems to work fine for me?1 year ago
Brendan23
Brendan23
shared a Post
1 year ago
1
First, I know what the list index out of range error is. To see this error, run the repl, do check orders, then go to make food and make one of the f
Work In Progress (WIP)
Python
InvisibleOne
InvisibleOne
Well, done_things is not a list, it's a dictionary.1 year ago
Kai_Justice
Kai_Justice
I suggest just enumerating the list, it'll make your code a bit cleaner and clear up any index related confusion. Lines 130-137: Instead of looking at the size of the "orders_list" list and indexing it this will automatically index and assign the value to the variable "thing" for thing in orders_list: if thing in orders_list: correct_ords+=1 orders_list.remove(thing) done_things.remove(thing) orders[thing]-=1 done_thingss[thing]-=1 1 year ago
Brendan23
Brendan23
shared a Post
1 year ago
1
If You Run The Repl, do make food, wait 20 sec., and serve food, it will give a list index out of range error, why is that?
Work In Progress (WIP)
Python
ruiwenge2
ruiwenge2
that is because the number you used to get an element in the list is out of range, meaning there is no element with that index.1 year ago
Brendan23
Brendan23
shared a Post
1 year ago
1
if you run the repl, input random letters(has to be more than 1), it should be like https://replit.com/@ZarmDev/Intro but instead it prints on multipl
Name thing
Python
Coder100
Coder100
Don't forget to add flush=True as well print("hi", end = "", flush = True) `1 year ago
JBloves27
JBloves27
This could be happening from the second print in the for loops. It prints letters_lower[i], but because it doesn't have end="", I think it may be the reason for this. Hope this helps!1 year ago
Brendan23
Brendan23
shared a Post
1 year ago
1
if you run the repl, there is a space between the ‖ and the green highlight in the beginning and the end. how can I remove that space?
random things
Python
OldWizard209
OldWizard209
You just need to change 60 to 59 on line 11: for i in range(59): emt += ' ' Output: image1 year ago
Coder100
Coder100
use sep='' you see, with each argument, python adds a space in between, so you can remove that: print('‖','\033[0;0;42m'+get,'\033[0;0;0m'+emt,'‖', sep = '') line 151 year ago
LukeWright
LukeWright
instead of print('‖','\033[0;0;42m'+get,'\033[0;0;0m'+emt,'‖') do print('‖'+'\033[0;0;42m'+get,'\033[0;0;0m'+emt+'‖') `1 year ago
Brendan23
Brendan23
shared a Post
1 year ago
1
so, it should work like this: you go through all the choices, enter your text, and then it should print the text delay (about) 2 sec. and then print t
Multi-line ASCII text
Python
candies
candies
hi i have a question not related to this1 year ago
Brendan23
Brendan23
shared a Post
1 year ago
1
So the problem is if you run the repl and input an upper case A, B, C, and D or multiple, (only a, b, c, and d work so far) then input 2/the shady opt
Multi-line ASCII text
Python
JBloves27
JBloves27
You could add the .lower() to the input. So like this: idk = input("input: ").lower() Hope this helps!1 year ago
Brendan23
Brendan23
shared a Post
1 year ago
1
I can't figure out how to save where the person clicked on to a variable. I know how to print it though. take a look at the repl and scroll to the bot
attemptatapythonturtleclicker
Python
Coder100
Coder100
You can use a database. from replit import db my_var = None if 'myvar' in db: myvar = db['my_var'] do magic save the variable! db['myvar'] = myvar `1 year ago
lsikora
lsikora
Try this... with open('doremi.txt', 'w') as f: f.write('Doe, a deer, a female deer\n') f.write('Ray, a drop of golden sun\n') The write() function takes a string and puts that content into the file stream. Although we don't store it, the write() function returns the number of characters it just entered i.e. the length of the input string.1 year ago
Brendan23
Brendan23
shared a Post
2 years ago
1
hello person who's reading this. my question is, first, how do I make a function or something that makes it so that when the "player" clicks and/or h
EuanTH
EuanTH
Here's a link to help with the cursor problem, stackoverflow In summary, it talks about the canvas and binding it to a function, which you can use to bind the mouse position. For the three coloured circles, you can make 3 different turtles that will draw each of the circles. Each would check if the player is over the circle, and if the player has clicked. I would recommend to solve this problem in PyGame, it might take some time to learn but it's a lot easier to write applications like this wi2 years ago
Brendan23
Brendan23
shared a Post
2 years ago
1
best way to clear screen without flicker in python?
icodeletion
icodeletion
print("\033[H",end="") > ###### hope this helped :D2 years ago
Brendan23
Brendan23
shared a Post
2 years ago
4
Credits @Brendan23 How To All you have to do is input your text and choose the color you want it to be. pretty simple. About The Quick version: One d
Colored Text Generator
Python
ProCatGuy
ProCatGuy
Thanks for upvoting my post Brendan23. I value it. This is also a great one.2 years ago
Brendan23
Brendan23
shared a Post
2 years ago
1
anyone need anything to be animated(not to long). come to me. spoiler: it will be in pixel form.
Brendan23
Brendan23
shared a Post
2 years ago
1
so if you type in more than one a when you run the repl, it will print one a and another below it. is there a way to get them side-by-side?
Coder100
Coder100
not to mention it also aligns the text beautifully! (Probably) https://repl.it/@Coder100/WryImaginaryConfiguration-eouae-ou-eoaueao-ue#main.py yay!2 years ago
Coder100
Coder100
Nope, you can't do this simply with yourself. Try dis: def sidebyside(*args): print('\t'.join(args)) And also: sidebyside("hi", "there") you might be thinking bruh isn't this the most obvious thing and you are correct, that is what you have to do in something as limited as a terminal.2 years ago
Brendan23
Brendan23
@LeoXu2 @RYANTADIPARTHI so. what I want to do is print more than one multi-line letters next to each other. make sense? for example, if you run the repl and type in multiple a's then it will print one on top of another. I don't want that. I want it side by side.2 years ago
Brendan23
Brendan23
shared a Post
2 years ago
1
sorry to leave you on a cliffhanger. is there a way to print multiple ASCII letters in a row? I can't figure out how to.
InvisibleOne
InvisibleOne
mabye try import sys and then sys.stdout.write() instead of print?2 years ago
Brendan23
Brendan23
shared a Post
2 years ago
24
About this ASCII animation was made by Andreas Freise. you can check out his site with this link: http://www.ascii-art.de/ How To all you have to do
all aboard!
Python
Wilke000
Wilke000
Don't post things that aren't yours. I've done that, and you don't wanna know what happened2 years ago
Cag82407
Cag82407
how... HOW?!?2 years ago
darkdarcool
darkdarcool
Looks super cool!!2 years ago
Brendan23
Brendan23
shared a Post
2 years ago
2
Question so if you run the "all aboard!" you can see that the cursor moves around and it is choppy. is there a way to change it?(don't say "don't us
all aboard!
Python
icodeletion
icodeletion
Do this: import cursor cursor.hide() At the top of your code.2 years ago
Ganesha1
Ganesha1
Flush the screen constantly or get hacker or learn another lang. Also, file reading does take a second so you may want to keep all the frames in one file and just load them into an array for easier access.2 years ago
Brendan23
Brendan23
shared a Post
2 years ago
3
Credits @Brendan23 @plant3jyyehejy Object of the game Get lots of students and become the best school in the world. Closing Suggestions are recommen
School Empire Tycoon
Python
ToxicHaste
ToxicHaste
This is a good start Brendan, I would now suggest having more friends help out with bigger games, I've seen Snake game, Fortnite even Skyrim in here2 years ago
Brendan23
Brendan23
shared a Post
2 years ago
3
uggg! I have another problem now but its simple. its the IndentationError: unindent does not match any outer indentation level error. I've gotten thi
School Empire Tycoon
Python
SpotSign
SpotSign
Easy. Re-tab all the tabs.2 years ago
xxpertHacker
xxpertHacker
Just use a code formatter, problem solved, Actually no, just stop using Python, problem solved.2 years ago
Brendan23
Brendan23
@RYANTADIPARTHI @SamuelPKuld finally! I figured it out!! I just deleted all of it and rewrote it.2 years ago
Brendan23
Brendan23
shared a Post
2 years ago
2
so I (though) I was done with my (not so good) game when this error popped up: File "", line 1 (user funding['funding']) ^ SyntaxErro
School Empire Tycoon
Python
robowolf
robowolf
On line 128 either choose user['funding'] or funding['funding']. You can't have user funding['funding'].2 years ago