Skip to content
View theclickerguy's full-sized avatar

Block or report theclickerguy

Block user

Prevent this user from interacting with your repositories and sending you notifications. Learn more about blocking users.

You must be logged in to block users.

Maximum 250 characters. Please don't include any personal information such as legal names or email addresses. Markdown supported. This note will be visible to only you.
Report abuse

Contact GitHub support about this user’s behavior. Learn more about reporting abuse.

Report abuse
theclickerguy/README.md

import pygame import sys

Initialize Pygame

pygame.init()

Constants

WIDTH, HEIGHT = 800, 600 FPS = 60 WHITE = (255, 255, 255)

Initialize screen

screen = pygame.display.set_mode((WIDTH, HEIGHT)) pygame.display.set_caption("Clicker Game")

Fonts

font = pygame.font.Font(None, 36)

Variables

score = 0

Game loop

clock = pygame.time.Clock() running = True while running: # Event handling for event in pygame.event.get(): if event.type == pygame.QUIT: running = False elif event.type == pygame.MOUSEBUTTONDOWN: if event.button == 1: # Left mouse button score += 1

# Update

# Draw
screen.fill(WHITE)
text = font.render(f"Score: {score}", True, (0, 0, 0))
screen.blit(text, (10, 10))

# Refresh screen
pygame.display.flip()

# Cap the frame rate
clock.tick(FPS)

Quit Pygame

pygame.quit() sys.exit()

Popular repositories Loading

  1. theclickerguy theclickerguy Public

    Config files for my GitHub profile.