I'm trying to get it to say all numbers in upper case. But FOUR and FIVE are coming out as OUR and IVE also EIGHT is coming out as EIHT. Code below any solutions?
import tkinter as tk
import num2word as n2w
import keyboard as kb
import random
import time
# Define the main function
def main():
global jjAmount
time.sleep(3)
for number in range(1, jjAmount + 1):
currentword = n2w.word(number).upper()
# Press and release space to make a jump
kb.press("space")
time.sleep(random.uniform(0.01, 0.03))
kb.release("space")
kb.press("/")
time.sleep(random.uniform(0.01, 0.02))
kb.release("/")
# Say the number
for letter in currentword.upper():
letter = letter.upper()
kb.press(f"shift+{letter}")
time.sleep(random.uniform(0.01, 0.03))
kb.release(letter)
kb.press("enter")
time.sleep(random.uniform(0.01, 0.03))
kb.release("enter")
# Wait before starting the next "JJ"
time.sleep(random.uniform(0.5, 1.0)) # Adjust the time as needed
# Define the function to start the script
def start_script():
global jjAmount
jjAmount = int(entry_jj_amount.get())
main()
# Create the main tkinter window
root = tk.Tk()
root.title("Roblox Auto-JJ")
# Create and pack the widgets
label_jj_type = tk.Label(root, text="JJ type:")
label_jj_type.pack()
entry_jj_type = tk.Entry(root)
entry_jj_type.pack()
label_jj_amount = tk.Label(root, text="Amount of JJ's:")
label_jj_amount.pack()
entry_jj_amount = tk.Entry(root)
entry_jj_amount.pack()
button_start = tk.Button(root, text="Start Script", command=start_script)
button_start.pack()
# Start the tkinter event loop
root.mainloop()