Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- '''
- СКАЧАТЬ ЛОЛЮ: https://imgur.com/a/epTldMS
- '''
- from tkinter import *
- from time import *
- root = Tk()
- print("[CORE] Enabling: imported tkinter") # LOGGER
- root.resizable(False, False) # made root aka canvas not able to resize
- root.title("АНИМЕ ПОМОЙКА")
- print('[CORE] Added some parameters to root: resizability and title')
- girl = PhotoImage(file='girl_2.png') # anime girl import lmao
- def draw_bus(x, y): # x = 50, y = 100
- canvas.create_rectangle(x, y-50, x+100, y, fill='#7289DA') # a fucking BUS dude
- canvas.create_oval(x, y, x+25, y+25, fill='black') # yyeeahhaw thats a wheel
- canvas.create_oval(x+75, y, x+100, y+25, fill='black') # one more wheel
- canvas.create_rectangle(x+90, y-20, x+100, y-10, fill="yellow") # ahahah that's a light dude
- canvas.create_image(x+25, y-50, image=girl, anchor=NW)
- print('[CANVAS] Created a bus LOL')
- def draw_environment():
- canvas.create_rectangle(0, 125, 800, 210, fill="green", outline='green') # let's plant some fucking grass mate
- print('[CANVAS] Planted fucking grass')
- canvas.create_oval(750, -50, 850, 50, fill='yellow') # Hier kommt die Sonne
- print('[CANVAS] Hier kommt die Sonne')
- canvas.create_text(400, 150, text="лоля катается лол", font="Times 30 bold")
- print('[CORE] Associated new variable for tkinter') # LOGGER
- canvas = Canvas(root, width=800, height=200, bg='light blue') # some parameters for a window
- canvas.pack()
- print('[CORE] Added canvas and packed it oh hell yeah!') # LOGGER
- # draw_environment() # calls some plants and stuff
- # draw_bus(50, 100) # calls amazing drawing function from the top of a code
- x = 0 # base variables for the fucking bus
- y = 120
- while True:
- if x == 0: side = 1
- else: side = -1
- for i in range(700):
- canvas.update()
- sleep(0.008)
- canvas.delete('all')
- x += side
- draw_environment()
- draw_bus(x, y)
- root.mainloop()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement