Beginner coder, why does my code not work?


Below is a code for the t-rex jumping game. I was following a youtube tutorial on how to make the bot; was using this to learn python. When I click run, it says “Process finished with exit code 0”, but it does nothing. The code was for the bot to automatically restart when it was game over. Please check and see where I am going wrong

from PIL import ImageGrab

import pyautogui

class Cordinates():
replayBtn = (361,364)
def restartGame():

Hi @Newcoder12362!

Welcome to the forum!

I’ve edited your post for readability. When you enter a code block into a forum post, please precede it with a separate line of three backticks and follow it with a separate line of three backticks to make it easier to read.

You can also use the “preformatted text” tool in the editor (</>) to add backticks around text.

See this post to find the backtick on your keyboard.
Note: Backticks (`) are not single quotes (’).