def __init__(self): gcommon.app = self pygame.mixer.init() pyxel.init(256, 200, caption="GRASLAY", fps=60, quit_key=pyxel.KEY_Q) Settings.loadSettings() # コマンドライン解析 parseCommandLine() pyxel.load("assets/graslay.pyxres") pyxel.image(0).load(0, 0, "assets/graslay0.png") gcommon.init_atan_table() gcommon.initStar() gcommon.setGetMapDataByMapPosHandler( gcommon.getMapDataByMapPosimplement) rm = ranking.RankingManager() rm.load() if gcommon.START_STAGE != None: GameSession.init(Settings.difficulty, Settings.playerStock, gcommon.GAMEMODE_CUSTOM, gcommon.START_STAGE, 1) self.startNextStage(gcommon.START_STAGE) else: self.nextScene = None self.scene = None self.stage = None self.startTitle() pyxel.run(self.update, self.draw)
def startBossRushGame(self): # debug #stageManager = stage.StageLinkManager() #stageList = stageManager.findStage("3B") #print("Difficulty : " + str(difficulty)) if gcommon.CustomNormal: # カスタムでも通常にしたい場合(デバッグ) GameSession.init(gcommon.DIFFICULTY_NORMAL, Settings.playerStock, gcommon.GAMEMODE_NORMAL, "B1", 1) else: # 通常 GameSession.init(gcommon.DIFFICULTY_NORMAL, Settings.playerStock, gcommon.GAMEMODE_BOSSRUSH, "B1", 1) GameSession.playerStock -= 1 GameSession.weaponType = Settings.weaponType GameSession.multipleCount = Settings.multipleCount #self.stage = Settings.startStage #self.setScene(MainGame(self.stage)) self.setScene(MainGame("B1"))
def startCustomGame(self): # debug #stageManager = stage.StageLinkManager() #stageList = stageManager.findStage("3B") #print("Difficulty : " + str(difficulty)) if gcommon.CustomNormal: # カスタムでも通常にしたい場合(デバッグ) GameSession.init(Settings.difficulty, Settings.playerStock, gcommon.GAMEMODE_NORMAL, Settings.startStage, 1) else: # 通常 GameSession.init(Settings.difficulty, Settings.playerStock, gcommon.GAMEMODE_CUSTOM, Settings.startStage, 1) GameSession.playerStock -= 1 GameSession.weaponType = Settings.weaponType GameSession.multipleCount = Settings.multipleCount #self.stage = Settings.startStage #self.setScene(MainGame(self.stage)) self.setScene(stageSelect.CustomStageSelectScene(self))