diff options
author | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2009-04-16 11:37:34 +0200 |
---|---|---|
committer | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2009-04-16 11:37:34 +0200 |
commit | 86b5f4b9183a2567a2b9c486a00465446206bbba (patch) | |
tree | 697d443f2c01f06ca4361d05eda0c3ac2928914d | |
parent | d436967e4761b38714fd3410e4907fab829f925d (diff) | |
download | mana-client-86b5f4b9183a2567a2b9c486a00465446206bbba.tar.gz mana-client-86b5f4b9183a2567a2b9c486a00465446206bbba.tar.bz2 mana-client-86b5f4b9183a2567a2b9c486a00465446206bbba.tar.xz mana-client-86b5f4b9183a2567a2b9c486a00465446206bbba.zip |
Fixed compile warnings about signed/unsigned comparisons
-rw-r--r-- | tools/tmxcopy/map.cpp | 8 | ||||
-rw-r--r-- | tools/tmxcopy/map.hpp | 2 |
2 files changed, 5 insertions, 5 deletions
diff --git a/tools/tmxcopy/map.cpp b/tools/tmxcopy/map.cpp index 9e01944c..0fd764b4 100644 --- a/tools/tmxcopy/map.cpp +++ b/tools/tmxcopy/map.cpp @@ -260,7 +260,7 @@ bool Map::overwrite( Map* srcMap, } else { - for (int i = 0; i < srcMap->getNumberOfLayers(); i++) + for (size_t i = 0; i < srcMap->getNumberOfLayers(); i++) { Layer* srcLayer = srcMap->getLayer(i); Layer* destLayer = getLayer(srcLayer->getName()); @@ -280,7 +280,7 @@ bool Map::overwrite( Map* srcMap, //combining layer information - for (int i = 0; i < srcMap->getNumberOfLayers(); i++) + for (size_t i = 0; i < srcMap->getNumberOfLayers(); i++) { Layer* srcLayer = srcMap->getLayer(i); Layer* destLayer = NULL; @@ -543,7 +543,7 @@ int Map::save(std::string filename) //TODO: reorganize GIDs //add new tileset information to XML tree - for (int i = 0; i< mTilesets.size(); i++) + for (size_t i = 0; i< mTilesets.size(); i++) { xmlNodePtr newNode; @@ -563,7 +563,7 @@ int Map::save(std::string filename) } //add new layer information to XML tree - for (int i = 0; i < mLayers.size(); i++) + for (size_t i = 0; i < mLayers.size(); i++) { //lay out layer information in binary unsigned char* binData = (unsigned char*)malloc(mWidth * mHeight * 4); diff --git a/tools/tmxcopy/map.hpp b/tools/tmxcopy/map.hpp index 3be932ab..f3c0d1d4 100644 --- a/tools/tmxcopy/map.hpp +++ b/tools/tmxcopy/map.hpp @@ -159,7 +159,7 @@ class Map int save(std::string filename); - int getNumberOfLayers() { return mLayers.size(); } + size_t getNumberOfLayers() { return mLayers.size(); } Layer* getLayer(size_t num) { return mLayers.at(num); } Layer* getLayer(std::string name); |