summaryrefslogtreecommitdiff
path: root/inc
diff options
context:
space:
mode:
authortom <tom@ground-control>2016-05-02 15:39:22 -0500
committertom <tom@ground-control>2016-05-02 15:39:22 -0500
commit3a2f69b3f1082b2fbdf39bd2a4f7ad0020971eac (patch)
treec5961dcb6e1ccbdf5a478d97f7383028492140d4 /inc
parent1ddb996ac4a4fc78e5484acdadac2df95006b632 (diff)
spring cleaning, added framerate cap & started iterator replacement
Diffstat (limited to 'inc')
-rw-r--r--inc/main.hpp1
-rw-r--r--inc/timer.hpp25
2 files changed, 26 insertions, 0 deletions
diff --git a/inc/main.hpp b/inc/main.hpp
index c6f51e3..d20f7ef 100644
--- a/inc/main.hpp
+++ b/inc/main.hpp
@@ -8,5 +8,6 @@
#include "resource.hpp"
#include "list.hpp"
#include "location.hpp"
+#include "timer.hpp"
#endif
diff --git a/inc/timer.hpp b/inc/timer.hpp
new file mode 100644
index 0000000..1213311
--- /dev/null
+++ b/inc/timer.hpp
@@ -0,0 +1,25 @@
+#ifndef timer_h
+#define timer_h
+
+#include "window.hpp"
+
+class Timer
+{
+ public:
+ Timer();
+ void Start();
+ void Stop();
+ void Pause();
+ void unPause();
+ int getTicks();
+ bool isStarted(){return started;};
+ bool isPaused(){return paused;};
+
+ private:
+ int startTicks;
+ int pausedTicks;
+ bool paused;
+ bool started;
+};
+
+#endif