initsubstate.cpp

来自「VIGASOCO (VIdeo GAmes SOurce COde) Windo」· C++ 代码 · 共 32 行

CPP
32
字号
// InitSubstate.cpp
//
/////////////////////////////////////////////////////////////////////////////

#include "InitSubstate.h"
#include "Video.h"
#include "Game.h"
#include "Writer.h"

void InitSubstate::run()
{
	// init VRAM and CRAM
	Video::clearVRAM(false);
	Video::clearCRAM();
	Video::initCRAM(0);

	// read DIPSW and save current settings
	theGame->settings.getSettings();

	// init and print scores
	Writer::initAndPrintScores();

	// init pacman and ghosts positions, tile positions, orientation vars and sprite data
	theGame->initCharacterState(false);

	// reset pacman, fruit and ghost positions
	theGame->resetCharacterPositions();

	// changes to demo state
	theGame->state = DEMO;
}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?