0

Sans text

Is there a way to have a string print itself out over the console? Example would be like like in undertale, when sans has a message to say it prints itself out instead of all of the text appearing in one instance.

3rd Oct 2019, 4:12 PM
Advanced Incognizant
6 odpowiedzi
+ 2
I will give you the code, but this will work just on your computer, in the python ide or in windows cmd: import time from os import system sentence = "Hello here is a sentence I am long to see my effect" for i in sentence: print(i, end="", sep="", flush=True) time.sleep(0.05) ### copy the code just till here if you are working in python IDE### print("\n") a = system('cls') for l in range(10): print(sentence) time.sleep(0.5) system('cls') time.sleep(0.5) print(sentence) time.sleep(10) ### copy the whole code if you are working in the command line to see the flickering effect of the text ### notice that this code will not work on solo learn I hope I could help you out
3rd Oct 2019, 10:18 PM
William M
William M - avatar
+ 1
William M This is exactly what i needed, thank you! I used repl.it to run the code and it works just fine
3rd Oct 2019, 11:05 PM
Advanced Incognizant
+ 1
You are welcome any time
3rd Oct 2019, 11:05 PM
William M
William M - avatar
0
I don't get you. Can you clarify it without the undertale example cuz I do not know the game undertale
3rd Oct 2019, 9:23 PM
William M
William M - avatar
0
William M Sorry, what Im having an issue with is when ill do something like “print(‘random sentence’)” And then run the program, the text appears all at once. What i want to happen is each letter appear after another, making it look like the text is being typed out across the screen
3rd Oct 2019, 9:39 PM
Advanced Incognizant
0
And tell me about the results
3rd Oct 2019, 10:19 PM
William M
William M - avatar