//This runs the game void MainGame::run() { initSystems(); //This only returns when the game ends gameLoop(); }
void MainGame::run() { initSystems(); //_sprite.init(-1.0f, -1.0f, 2.0f, 2.0f, "Texture/PNG/CharacterRight_Standing.png"); _sprites.push_back(new nEngine::Sprite()); _sprites.back()->init(0, 0, 500.0f,500.0f, "Texture/PNG/CharacterRight_Standing.png"); //_sprites.push_back(new nEngine::Sprite()); //_sprites.back()->init(0.0f, -1.0f, 1.0f, 1.0f, "Texture/PNG/CharacterRight_Standing.png"); //_sprites.push_back(new nEngine::Sprite()); //_sprites.back()->init(0.0f, 0.0f, 1.0f, 1.0f, "Texture/PNG/CharacterRight_Standing.png"); //_sprites.push_back(new nEngine::Sprite()); //_sprites.back()->init(-1.0f, 0.0f, 1.0f, 1.0f, "Texture/PNG/CharacterRight_Standing.png"); //_playerTexture= ImageLoader::loadPNG("Texture/PNG/CharacterRight_Standing.png"); gameLoop(); };
Game::Game(){ music = Mix_LoadMUS("data/sounds/music.mp3"); sound = Mix_LoadWAV("data/sounds/sfx.wav"); // SDL_WM_SetCaption("ARKANOID", NULL); if(initSystems() == -1) cerr << "Problem occured while initializing SDL systems" << endl; font = TTF_OpenFont("data/mainfont.ttf", 35); if(!font) { cerr << "Could not load font " << TTF_GetError << endl; exit(1); } running = true ; //just for now gameFPS = 60; musicOn = false; sfxOn = false; control_type = KEYBOARD; current_state = MENU ; fps_counter = new FpsCounter(gameFPS); game_state = new MenuState(); game_state->InitState(); }
void MainGame::run() { initSystems(); initLevel(); gameLoop(); }
void Game::Run() { initSystems(); _sprite.Init(-1.0f, -1.0f, 2.0f, 2.0f); _playerTexture = ImageLoader::LoadPNG("textures/jimmyjump_pack/png/characterright_standing.png"); gameLoop(); }
void RubikGame::run() { initSystems(); const std::vector<std::string> texPaths = { texture_path1, texture_path2, texture_path3, texture_path4, texture_path5, texture_path6 }; const std::string texPathsSame[6] = { texture_pathAyse, texture_pathAyse, texture_pathAyse, texture_pathAyse, texture_pathAyse, texture_pathAyse }; initVoxels(glm::vec3{ 0.0f, 0.0f, 0.0f }, glm::vec3{ 1.0f, 1.0f, 1.0f }, texPaths); gameLoop(); }
void GameScreen::run(Window *window) { m_window = window; initSystems(); initShaders(); runLoop(); }
void MainGame::run(){ initSystems(); //_playerTexture = LoadGLTexture::LoadTexture("../Textures/jimmyJump_pack/PNG/CharacterRight_Standing.png"); gameLoop(); }
//This runs the game void MainVidGame::run() { initSystems(); _sprite.init(-1.0f, -1.0f, 1.0f, 1.0f); gameLoop(); }
//入口 void MainGame::run(){ initSystems(); initLevel(); NeroEngine::Music bgMusic = _audioEngine.loadMusic("Sound/background.mp3"); bgMusic.play(-1); gameLoop(); }
void MainGame::run() { initSystems(); initLevel(); Adina::Music music = m_audioEngine.loadMusic("Sound/XYZ.ogg"); music.play(-1); gameLoop(); }
int main(int argc, char** argv) { initSystems(); draw(); while(!exiting){ processInput(); //reloadShaders(); draw(); } return 0; }
//This runs the game void MainGame::run() { initSystems(); //Initialize our sprites. (temporary) _sprites.push_back(new iron::graphics::Sprite()); _sprites.back()->init(0.0f, 0.0f, _screenWidth / 2, _screenWidth / 2, "Textures/jimmyJump_pack/PNG/CharacterRight_Standing.png"); _sprites.push_back(new iron::graphics::Sprite()); _sprites.back()->init(_screenWidth / 2, 0.0f, _screenWidth / 2, _screenWidth / 2, "Textures/jimmyJump_pack/PNG/CharacterRight_Standing.png"); //This only returns when the game ends gameLoop(); }
bool IMainGame::init() { Bengine::init(); if (!initSystems()) return false; onInit(); addScreens(); m_currentScreen = m_screenList->getCurrent(); m_currentScreen->onEntry(); m_currentScreen->setRunning(); return true; }
bool IMainGame::init() { CoreEngine::init(); SDL_GL_SetAttribute(SDL_GL_ACCELERATED_VISUAL, 1); initSystems(); onInit(); addScreens(); m_currentScreen = m_screenList->getCurrent(); m_currentScreen->onEntry(); m_currentScreen->setRunning(); return true; }
bool IMainGame::init() { SDL_Init(SDL_INIT_EVERYTHING); SDL_GL_SetAttribute(SDL_GL_ACCELERATED_VISUAL, 1); if (!initSystems()) return false; onInit(); addScreens(); _currentScreen = _screenList->getCurrent(); _currentScreen->onEntry(); _currentScreen->setRunning(); return true; }
bool ApplicationManager::init() { if (mInitialised) return true; LOG("Initializing ApplicationManager"); if (!mCanBeInit) return false; if (!mPluginsLoaded) loadPlugins(); setupSystems(); mInitialised = initSystems(); if (!mInitialised) return mInitialised; mInitialised = loadAssets(); return mInitialised; }
bool IMainGame::init(){ MasaEngine::init(); SDL_GL_SetAttribute(SDL_GL_ACCELERATED_VISUAL, 1); if (!initSystems()) return false; //Custom initialization. onInit(); addScreens(); _currentScreen = _screenList->getCurrentScreen(); _currentScreen->onEntry(); _currentScreen->setRunning(); return true; }
bool IGame::init() { SDL_Init(SDL_INIT_EVERYTHING); SDL_GL_SetAttribute(SDL_GL_ACCELERATED_VISUAL, 1); SDL_GL_SetAttribute(SDL_GL_CONTEXT_MAJOR_VERSION, 3); SDL_GL_SetAttribute(SDL_GL_CONTEXT_MINOR_VERSION, 1); SDL_GL_SetAttribute(SDL_GL_CONTEXT_PROFILE_MASK, SDL_GL_CONTEXT_PROFILE_CORE); SDL_GL_SetAttribute(SDL_GL_DOUBLEBUFFER, 1); SDL_ShowCursor(false); SDL_StartTextInput(); initSystems(); onInit(); addScreens(); _currentScreen = _screenManager->getCurrent(); _currentScreen->onEntry(); _currentScreen->setRunning(); return true; }
/* * Game execution */ void Game::run() { //System initializations initSystems(); //Start the game if all the elements are ready gameLoop(); }
Engine::Engine() { initGame(); initSystems(); // initEntities(); }
void MainGame::Run() { initSystems(); gameLoop(); }
void Game::run() { initSystems(); gameLoop(); }