12345678910111213141516171819202122232425262728293031323334353637383940 |
- #include <ctime>
- #include <iostream>
- #include <Starlight.hpp>
- /**
- * @brief I can't code. Really. Don't look at this.
- * I code bad codes, and this one is exceptionally bad.
- * And bad c++ codes are very bad.
- * Really.
- * Git out.
- * @return segfaults
- */
- int main()
- {
- std::cout << "Hello, world!" << std::endl;
-
- ContextSettings settings;
- RenderWindow window;
- Music music;
-
- settings.antialiasingLevel = 8;
- window.create(VideoMode(768, 768, 32), "one room arena", Style::Titlebar | Style::Close, settings);
- window.setVerticalSyncEnabled(true);
-
- music.openFromFile("data/music.ogg");
- music.setLoop(true);
- music.play();
-
- std::srand(std::time(nullptr));
-
- bool keepRunning = false;
- do {
- Player::totalScore = 0;
- keepRunning = false;
- Starlight gaem(&window, &keepRunning);
- gaem.run();
- } while(keepRunning);
- return 0;
- }
|