summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2016-05-20 19:24:42 +0300
committerAndrei Karas <akaras@inbox.ru>2016-05-20 19:24:42 +0300
commit9aae08f9e2f869b0f4bfa446404b01a8d3b2d60f (patch)
treec39820893e0acfb87c9442bbc1e371839518b02a /src
parent2cf3c1e9938d64fe7b2cf1cffca0ec8b12970e80 (diff)
downloadmv-9aae08f9e2f869b0f4bfa446404b01a8d3b2d60f.tar.gz
mv-9aae08f9e2f869b0f4bfa446404b01a8d3b2d60f.tar.bz2
mv-9aae08f9e2f869b0f4bfa446404b01a8d3b2d60f.tar.xz
mv-9aae08f9e2f869b0f4bfa446404b01a8d3b2d60f.zip
Fix code style.
Diffstat (limited to 'src')
-rw-r--r--src/being/localplayer.cpp2
-rw-r--r--src/net/ea/beingrecv.cpp4
-rw-r--r--src/render/vertexes/openglgraphicsvertexes.h2
-rw-r--r--src/resources/db/moddb.h2
-rw-r--r--src/resources/memorymanager.cpp7
-rw-r--r--src/resources/sprite/spritedef.cpp3
6 files changed, 9 insertions, 11 deletions
diff --git a/src/being/localplayer.cpp b/src/being/localplayer.cpp
index cb4426319..dd2b52838 100644
--- a/src/being/localplayer.cpp
+++ b/src/being/localplayer.cpp
@@ -2389,7 +2389,7 @@ void LocalPlayer::followMoveTo(const Being *const being,
{
if (being &&
!mPlayerFollowed.empty() &&
- being->mName == mPlayerFollowed)
+ being->mName == mPlayerFollowed)
{
mPickUpTarget = nullptr;
navigateTo(x, y);
diff --git a/src/net/ea/beingrecv.cpp b/src/net/ea/beingrecv.cpp
index 0a8168c6c..7b8d74328 100644
--- a/src/net/ea/beingrecv.cpp
+++ b/src/net/ea/beingrecv.cpp
@@ -477,8 +477,8 @@ void BeingRecv::processBeingMove3(Net::MessageIn &msg)
if (len > 0)
{
const unsigned char dir = moves[0];
- uint16_t x0 = x;
- uint16_t y0 = y;
+ int16_t x0 = x;
+ int16_t y0 = y;
if (dir <= 7)
{
diff --git a/src/render/vertexes/openglgraphicsvertexes.h b/src/render/vertexes/openglgraphicsvertexes.h
index b27ccb095..c5d7e3014 100644
--- a/src/render/vertexes/openglgraphicsvertexes.h
+++ b/src/render/vertexes/openglgraphicsvertexes.h
@@ -40,8 +40,6 @@
#include "localconsts.h"
-class Image;
-
#ifdef USE_OPENGL
class OpenGLGraphicsVertexes final
{
diff --git a/src/resources/db/moddb.h b/src/resources/db/moddb.h
index 66488c691..f87b7f254 100644
--- a/src/resources/db/moddb.h
+++ b/src/resources/db/moddb.h
@@ -29,8 +29,6 @@
#include "localconsts.h"
-class ModInfo;
-
namespace ModDB
{
void load();
diff --git a/src/resources/memorymanager.cpp b/src/resources/memorymanager.cpp
index e20faf3db..11fd40f4e 100644
--- a/src/resources/memorymanager.cpp
+++ b/src/resources/memorymanager.cpp
@@ -20,8 +20,6 @@
#include "resources/memorymanager.h"
-#include "logger.h"
-
#include "gui/widgets/tabs/chat/chattab.h"
#include "resources/resourcemanager.h"
@@ -82,10 +80,13 @@ void MemoryManager::printAllMemory(ChatTab *const tab A_DYECMD_UNUSED)
{
if (!logger)
return;
+#ifdef DYECMD
+ if (resourceManager)
+ resourceManager->calcMemory(0);
+#else
int sz = 0;
if (resourceManager)
sz += resourceManager->calcMemory(0);
-#ifndef DYECMD
if (tab)
{
// TRANSLATORS: memory usage chat message
diff --git a/src/resources/sprite/spritedef.cpp b/src/resources/sprite/spritedef.cpp
index edeff4c4f..01651bd80 100644
--- a/src/resources/sprite/spritedef.cpp
+++ b/src/resources/sprite/spritedef.cpp
@@ -100,7 +100,8 @@ SpriteDef *SpriteDef::load(const std::string &animationFile,
if (!rootNode || !xmlNameEqual(rootNode, "sprite"))
{
- reportAlways("Error, failed to parse sprite %s", animationFile.c_str());
+ reportAlways("Error, failed to parse sprite %s",
+ animationFile.c_str());
const std::string errorFile = paths.getStringValue("sprites").append(
paths.getStringValue("spriteErrorFile"));
BLOCK_END("SpriteDef::load")