From 27db32f69254589942ce75aaef59b33879eea176 Mon Sep 17 00:00:00 2001 From: TriantaTV Date: Fri, 6 May 2022 00:40:36 -0500 Subject: [PATCH] Added folder structure and default main layout --- app/main.cpp | 22 ++++++++++++++++++++++ src/main.cpp | 22 ++++++++++++++++++++++ 2 files changed, 44 insertions(+) create mode 100644 app/main.cpp create mode 100644 src/main.cpp diff --git a/app/main.cpp b/app/main.cpp new file mode 100644 index 0000000..4eacd53 --- /dev/null +++ b/app/main.cpp @@ -0,0 +1,22 @@ +#include +#include +#include +#include +#include +using namespace std; + +int main() +{ + int videoSizeHorizontal, videoSizeVertical; + videoSizeHorizontal = 1280; + videoSizeVertical = 720; + sf::RenderWindow window(sf::VideoMode(videoSizeHorizontal, videoSizeVertical), "SnakePlusPlus"); + while (window.isOpen()) + { + while (window.pollEvent(event)) + { + if ((event.type == sf::Event::Closed) || (sf::Keyboard::isKeyPressed(sf::Keyboard::Escape))) + window.close(); + } + } +} diff --git a/src/main.cpp b/src/main.cpp new file mode 100644 index 0000000..fda705d --- /dev/null +++ b/src/main.cpp @@ -0,0 +1,22 @@ +#include +#include +#include +#include +#include +using namespace std; + +int main() +{ + int videoSizeHorizontal, videoSizeVertical; + videoSizeHorizontal = 1280; + videoSizeVertical = 720; + sf::RenderWindow window(sf::VideoMode(videoSizeHorizontal, videoSizeVertical), "SnakePlusPlus"); + while (window.isOpen()) + { + while (window.pollEvent(event)) + { + if ((event.type == sf::Event::Closed) || (sf::Keyboard::isKeyPressed(sf::Keyboard::Escape))) + window.close(); + } + } +}