summaryrefslogtreecommitdiff
path: root/input.cpp
diff options
context:
space:
mode:
authorVegard Storheil Eriksen <zyp@jvnv.net>2010-10-05 08:34:46 +0200
committerVegard Storheil Eriksen <zyp@jvnv.net>2010-10-05 08:34:46 +0200
commit7ebb0e91f63203753420b5a4b75d09d170f204f4 (patch)
tree7acc39bcbb3970e9112834c6082581e882517c87 /input.cpp
parentf88411abc7150ed209efcb6180503f0c6f7c8ef6 (diff)
Added wriggle/input.
Diffstat (limited to 'input.cpp')
-rw-r--r--input.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/input.cpp b/input.cpp
new file mode 100644
index 0000000..caeae82
--- /dev/null
+++ b/input.cpp
@@ -0,0 +1,10 @@
+#include "input.h"
+
+const sf::Input* input_backend = 0;
+
+bool Input::key_pressed(Key::Code key) {
+ if(!input_backend) {
+ return false;
+ }
+ return input_backend->IsKeyDown(key);
+}