Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include "LogManager.h"
- #include "Clock.h"
- #include "GameManager.h"
- #include "GraphicsManager.h"
- #include "Position.h"
- #include "Utility.h"
- #include <iostream>
- #include <string>
- #include <ctime>
- #include <sstream>
- #ifdef CYGWIN
- # include <ncurses/curses.h>
- #else
- # include <curses.h>
- #endif
- int main(){
- /*GameManager& game = GameManager::getInstance();
- game.startUp();
- game.populateWorld();
- game.run();
- game.shutDown();*/
- GraphicsManager& gm = GraphicsManager::getInstance();
- LogManager& log = LogManager::getInstance();
- Position pos(3, 3);
- log.logWithTime(LOG_LEVEL_DEBUG, "Starting up GraphicsManager.");
- int result = gm.startUp();
- log.logWithTime(LOG_LEVEL_DEBUG, "Grabbing result: " + Utility::intToString(result));
- if (result < 0){
- log.logWithTime(LOG_LEVEL_DEBUG, "Encountered an error.");
- gm.shutDown();
- return 0;
- }
- log.logWithTime(LOG_LEVEL_DEBUG, "Drawing character in RED");
- gm.drawCharacter(pos, 'a', COLOR_RED);
- log.logWithTime(LOG_LEVEL_DEBUG, "Swapping buffers.");
- gm.swapBuffers();
- log.logWithTime(LOG_LEVEL_DEBUG, "Shutting down.");
- gm.shutDown();
- log.logWithTime(LOG_LEVEL_DEBUG, "COMPLETE!");
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement