# This module is where the code is originally ran. Sets up everything # for the game. # Imports modules that we use here import pygame,sys,Board,Constants,InputManager,Menu,GameState from pygame.locals import * pygame.init() size = Constants.SIZE window = pygame.display.set_mode(size) pygame.display.set_caption("Checkers 2ME3/2AA4 #CompSci4Life") done = False clock = pygame.time.Clock() Menu.init_buttons() #drawPickedUpPiece function: This function draws the piece that is placed # on our custom board. def drawPickedUpPiece(): posx,posy = pygame.mouse.get_pos() posx = posx - 18 posy = posy - 18 if GameState.s.getPickedUpPiece()=="white": piece = pygame.image.load("white.png").convert_alpha() window.blit(piece,(posx,posy)) elif GameState.s.getPickedUpPiece()=="black": piece = pygame.image.load("black.png").convert_alpha() window.blit(piece,(posx,posy))