Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include "pch.h"
- #include <iostream>
- #include <SFML/Graphics.hpp>
- #include <SFML/Window.hpp>
- using namespace std;
- int main()
- {
- sf::RenderWindow window(sf::VideoMode(800, 600), "Game In Development");
- sf::Texture character_sheet;
- character_sheet.loadFromFile("hero_spritesheet.png");
- sf::Time time = sf::seconds(0);
- sf::Clock clock; //Start clock
- cout << time.asSeconds() << endl;
- sf::Event event;
- while (window.isOpen())
- {
- while (window.pollEvent(event))
- {
- if (event.type == sf::Event::Closed)
- window.close();
- }
- window.clear(sf::Color::White);
- time = clock.getElapsedTime();
- cout << time.asSeconds() << endl;
- window.display();
- }
- int pause; cin >> pause; //Pause the program
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement