import pygame import sys from pygame import * object1 = pygame.Rect((20, 50), (50, 100)) print(object1.collidepoint(50, 75))