Ask coding questions

← Back to all posts
Python Question
GeoneveStudios

Python Question

I have a question. In Python how do you make a loading animation.

Answered by 19wintersp [earned 5 cycles]
View Answer
Voters
RAP
ch1ck3n
GeoneveStudios
Comments
hotnewtop
19wintersp

What kind do you want? If you want to overwrite the current line, you can use a carriage return ("\r"). The main thing is having different frames of the animation, and cycling between them:

GeoneveStudios

@19wintersp Thank you; but can it be more simple than that. Because I'm probably going to forget that.

19wintersp

@DashStudios

but can it be more simple than that

I'm really don't understand your point here. This is a bare-bones implementation of doing this.

GeoneveStudios

@19wintersp nevermind I get it now

RYANTADIPARTHI

Solution

Here is how.

like that.
That should work

GeoneveStudios

@RYANTADIPARTHI Thats helpful

RYANTADIPARTHI

@DashStudios no problem.

GeoneveStudios

@RYANTADIPARTHI I'm waiting for 2 more answers to see which is the best

RYANTADIPARTHI
awesomecds7

if you want to make one with graphics, you have to use a moudule called tkinter

awesomecds7

@awesomecds7 Please note that this will loop 3 times.

GeoneveStudios

@19wintersp post was the most helpful

SenatorBinks

@FloCal35 has a good tutorial here

Mozyyoo

I would use Pygame for that, but that's more so game graphics. If you are looking for that though, i recommend this tutorial: https://www.youtube.com/watch?v=UdsNBIzsmlI

GeoneveStudios

Does anyone know how to make a loading animation.