made it go boom
This commit is contained in:
@@ -1,17 +1,34 @@
|
||||
import tkinter as tk
|
||||
import random
|
||||
|
||||
class App:
|
||||
def __init__(self, root):
|
||||
self.root = root
|
||||
root.title("oh hey your computer go boom now")
|
||||
root.geometry("900x700")
|
||||
root.minsize(650, 500)
|
||||
self.idk(self.root)
|
||||
root.geometry("400x400")
|
||||
|
||||
self.label = tk.Label(root, text="Say bye to your computer", fg="red", font=("Courier", 20, "bold"))
|
||||
self.label.pack(expand=True)
|
||||
|
||||
# Start spawning windows
|
||||
self.spawn_popup()
|
||||
|
||||
def spawn_popup(self):
|
||||
# Create a new Toplevel window (separate from root)
|
||||
popup = tk.Toplevel(self.root)
|
||||
popup.title("Fatal Error: fu")
|
||||
popup.geometry(f"300x200+{random.randint(0,800)}+{random.randint(0,600)}")
|
||||
|
||||
tk.Label(
|
||||
popup,
|
||||
text="Say bye to your computer",
|
||||
fg="red",
|
||||
font=("Courier", 14, "bold")
|
||||
).pack(expand=True)
|
||||
|
||||
# Schedule next popup
|
||||
self.root.after(10, self.spawn_popup) # 1000 ms = 1 second
|
||||
|
||||
def idk(self):
|
||||
while True:
|
||||
win = self.root
|
||||
win.title("Fatal Error: fu"); win.geometry("400x400")
|
||||
tk.Label(win, text="Say bye to your computer",fg="red", font=("Courier", 24, "bold")).pack()
|
||||
def main():
|
||||
root = tk.Tk()
|
||||
app = App(root)
|
||||
|
||||
Reference in New Issue
Block a user