projects
/
physics.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
created key system, not yet used as there's a static bug
[physics.git]
/
src
/
config
/
config.cpp
diff --git
a/src/config/config.cpp
b/src/config/config.cpp
index
ae569fa
..
7d71e8a
100644
(file)
--- a/
src/config/config.cpp
+++ b/
src/config/config.cpp
@@
-16,6
+16,11
@@
*/
#include "config.h"
*/
#include "config.h"
+
+#include <SDL/SDL.h>
+#include "keys.h"
+
+#include "reader.h"
#include "../input/inputManager.h"
/// ***** Private Method Headers *****
#include "../input/inputManager.h"
/// ***** Private Method Headers *****
@@
-25,11
+30,17
@@
void cfg::init()
{
void cfg::init()
{
+ readConfigs(NULL);
+
// TODO read in config files
// TODO read in config files
+
+ key::init();
}
void cfg::clean()
{
// TODO save to config files?
}
void cfg::clean()
{
// TODO save to config files?
+
+ key::clean();
}
/// ***** Public Methods *****
}
/// ***** Public Methods *****
@@
-48,4
+59,17
@@
bool cfg::endGame()
return input::wasReleased(SDLK_ESCAPE);
}
return input::wasReleased(SDLK_ESCAPE);
}
+bool cfg::mouseWellFollow()
+{
+ return input::isPressed(SDLK_f);
+}
+bool cfg::mouseWellOn()
+{
+ return input::wasPressed(SDLK_SPACE);
+}
+bool cfg::mouseWellOff()
+{
+ return input::wasReleased(SDLK_SPACE);
+}
+
/// ***** Private Methods *****
/// ***** Private Methods *****