summaryrefslogtreecommitdiff
path: root/src/game.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/game.cpp')
-rw-r--r--src/game.cpp11
1 files changed, 3 insertions, 8 deletions
diff --git a/src/game.cpp b/src/game.cpp
index 4778dae7..5aaf1e8e 100644
--- a/src/game.cpp
+++ b/src/game.cpp
@@ -69,8 +69,6 @@
#include "net/network.h"
#include "net/protocol.h"
-#include "resources/imagewriter.h"
-
extern Graphics *graphics;
std::string map_path;
@@ -580,13 +578,10 @@ void do_input()
*/
// screenshot (picture, hence the p)
case SDLK_p:
+ //ImageWriter::writePNG(graphics->getScreenshot(), name.str());
+ if (!graphics->saveScreenshot())
{
- // TODO Fix the counting to start at a sane value.
- static int picCount = 1;
- std::stringstream name;
- name << "Screenshot-" << picCount << ".png";
- ImageWriter::writePNG(graphics->getScreenshot(), name.str());
- picCount++;
+ logger->log("Error: could not save Screenshot.");
}
break;
// Skill window