'''
load game window
'''
import pygame
# define constants
SCREEN_WIDTH=700
SCREEN_HEIGHT=500
BG_COLOR=pygame.Color(255,255,255)
#from curses import window
class MainGame():
window=None
# initialization method
def __init__(self) -> None:
pass
# start game
def startGame(self):
#initialize the window
pygame.display.init()
#set the size of window
MainGame.window=pygame.display.set_mode((SCREEN_WIDTH, SCREEN_HEIGHT))
# set the title of window
pygame.display.set_caption("tank war1.03")
while True:
# set the fill color for the window
MainGame.window.fill(BG_COLOR)
pygame.display.update
# end game
def endGame(self):
pass
class Tank():
def __init__(self) -> None:
pass
#defition of show tank
def displayTank(self):
pass
#movement of tank
def move(self):
pass
#shoot
def shot(self):
pass
#our tank
class MyTank(Tank):
#initialization method
def __init__(self) -> None:
pass
#enemy tank
class EnemyTank(Tank):
def __init__(self) -> None:
pass
# class bullet
class Bullet():
def __init__(self) -> None:
pass
#show bullet
def displayBullet(self):
pass
#move
def move(self):
pass
# class wall
class Wall():
def __init__(self) -> None:
pass
# the defition of show wall
def displayWall(self):
pass
# class explosion effect
class Explode():
def __init__(self) -> None:
pass
#display the effect of explosion
def displayExplode(self):
pass
#class of sound effect
class Music():
def __init__(self) -> None:
pass
#play music
def playMusic(self):
pass
# main method
if __name__ =='__main__':
# call startGame() in the main class
MainGame().startGame()
为什么我这窗口还是黑色的
