diff options
author | Stijn Buys <ingar@osirion.org> | 2008-03-25 18:51:27 +0000 |
---|---|---|
committer | Stijn Buys <ingar@osirion.org> | 2008-03-25 18:51:27 +0000 |
commit | a29aa1ee2935857f616351a23578311f514516d4 (patch) | |
tree | 5d9f241b0bb1facc6dc31a4ae4e26a4182641c3b /src/client/input.cc | |
parent | f2c7b3846468461d3d88a797b4cc006ee4d3b624 (diff) |
screenshots
Diffstat (limited to 'src/client/input.cc')
-rw-r--r-- | src/client/input.cc | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/client/input.cc b/src/client/input.cc index 4d0f54b..1a61424 100644 --- a/src/client/input.cc +++ b/src/client/input.cc @@ -11,6 +11,7 @@ #include "client/console.h" #include "client/camera.h" #include "client/keyboard.h" +#include "client/video.h" #include "SDL/SDL.h" @@ -117,7 +118,9 @@ void frame(float seconds) switch (event.type) { case SDL_KEYUP: - if (!chat::visible() && !console::visible() && + if (event.key.keysym.sym == SDLK_PRINT) { + video::screenshot(); + } else if (!chat::visible() && !console::visible() && core::application()->connected() && core::localcontrol()) // send key events to the game world |