Skip to content

Commit 8be2cbb

Browse files
committed
code tidy for consistency
1 parent 849bcd9 commit 8be2cbb

3 files changed

Lines changed: 9 additions & 5 deletions

File tree

ParseTest/ParseTest.vcxproj

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,7 @@
8888
<Optimization>Disabled</Optimization>
8989
<SDLCheck>true</SDLCheck>
9090
<AdditionalIncludeDirectories>..\tmxlite\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
91+
<PreprocessorDefinitions>_MBCS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
9192
</ClCompile>
9293
<Link>
9394
<AdditionalLibraryDirectories>..\tmxlite\x64\bin\DebugStatic;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
@@ -126,6 +127,8 @@
126127
<Link>
127128
<EnableCOMDATFolding>true</EnableCOMDATFolding>
128129
<OptimizeReferences>true</OptimizeReferences>
130+
<AdditionalLibraryDirectories>..\tmxlite\x64\bin\ReleaseStatic;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
131+
<AdditionalDependencies>libtmxlite-s.lib;%(AdditionalDependencies)</AdditionalDependencies>
129132
</Link>
130133
</ItemDefinitionGroup>
131134
<ItemGroup>

tmxlite.sln

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@ Global
5050
{4C5C8EE4-25F6-4121-B23D-89CD8D9FD74E}.Release|ARM.ActiveCfg = Release|Win32
5151
{4C5C8EE4-25F6-4121-B23D-89CD8D9FD74E}.Release|ARM64.ActiveCfg = Release|Win32
5252
{4C5C8EE4-25F6-4121-B23D-89CD8D9FD74E}.Release|x64.ActiveCfg = Release|x64
53+
{4C5C8EE4-25F6-4121-B23D-89CD8D9FD74E}.Release|x64.Build.0 = Release|x64
5354
{4C5C8EE4-25F6-4121-B23D-89CD8D9FD74E}.Release|x86.ActiveCfg = Release|Win32
5455
{4C5C8EE4-25F6-4121-B23D-89CD8D9FD74E}.Release|x86.Build.0 = Release|Win32
5556
{0A9268A4-1086-4562-9F44-4BE1CE5D4F03}.Debug|ARM.ActiveCfg = Debug|ARM
@@ -67,13 +68,11 @@ Global
6768
{2298A657-D09A-438E-B976-5EE827966124}.Debug|ARM.ActiveCfg = Debug|Win32
6869
{2298A657-D09A-438E-B976-5EE827966124}.Debug|ARM64.ActiveCfg = Debug|Win32
6970
{2298A657-D09A-438E-B976-5EE827966124}.Debug|x64.ActiveCfg = Debug|x64
70-
{2298A657-D09A-438E-B976-5EE827966124}.Debug|x64.Build.0 = Debug|x64
7171
{2298A657-D09A-438E-B976-5EE827966124}.Debug|x86.ActiveCfg = Debug|Win32
7272
{2298A657-D09A-438E-B976-5EE827966124}.Debug|x86.Build.0 = Debug|Win32
7373
{2298A657-D09A-438E-B976-5EE827966124}.Release|ARM.ActiveCfg = Release|Win32
7474
{2298A657-D09A-438E-B976-5EE827966124}.Release|ARM64.ActiveCfg = Release|Win32
7575
{2298A657-D09A-438E-B976-5EE827966124}.Release|x64.ActiveCfg = Release|x64
76-
{2298A657-D09A-438E-B976-5EE827966124}.Release|x64.Build.0 = Release|x64
7776
{2298A657-D09A-438E-B976-5EE827966124}.Release|x86.ActiveCfg = Release|Win32
7877
{2298A657-D09A-438E-B976-5EE827966124}.Release|x86.Build.0 = Release|Win32
7978
EndGlobalSection

tmxlite/src/Tileset.cpp

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ void Tileset::parse(pugi::xml_node node, Map* map)
163163
}
164164
}
165165

166-
// If the tsx file does not declare every tile, we create the missing ones
166+
//if the tsx file does not declare every tile, we create the missing ones
167167
if (m_tiles.size() != getTileCount())
168168
{
169169
for (std::uint32_t ID = 0 ; ID < getTileCount() ; ID++)
@@ -375,11 +375,13 @@ void Tileset::parseTileNode(const pugi::xml_node& node, Map* map)
375375

376376
void Tileset::createMissingTile(std::uint32_t ID)
377377
{
378-
// First, we check if the tile does not yet exist
379-
for (auto &tile : m_tiles)
378+
//first, we check if the tile does not yet exist
379+
for (const auto& tile : m_tiles)
380380
{
381381
if (tile.ID == ID)
382+
{
382383
return;
384+
}
383385
}
384386

385387
Tile tile;

0 commit comments

Comments
 (0)