summaryrefslogtreecommitdiff
path: root/src/resources
diff options
context:
space:
mode:
Diffstat (limited to 'src/resources')
-rw-r--r--src/resources/item/item.cpp10
-rw-r--r--src/resources/map/map.cpp4
-rw-r--r--src/resources/sprite/spritedef.cpp2
3 files changed, 8 insertions, 8 deletions
diff --git a/src/resources/item/item.cpp b/src/resources/item/item.cpp
index 99fed928d..d738ca0e3 100644
--- a/src/resources/item/item.cpp
+++ b/src/resources/item/item.cpp
@@ -97,15 +97,15 @@ void Item::setId(const int id,
const ItemInfo &info = getInfo();
mTags = info.getTags();
- const std::string dye = combineDye2(paths.getStringValue(
- "itemIcons").append(info.getDisplay().image),
+ const std::string dye = combineDye2(pathJoin(
+ paths.getStringValue("itemIcons"), info.getDisplay().image),
info.getDyeIconColorsString(color));
mImage = Loader::getImage(dye);
if (!mImage)
{
mImage = Theme::getImageFromTheme(paths.getValue("unknownItemFile",
- "unknown-item.png"));
+ "unknown-item.png"));
}
}
@@ -121,8 +121,8 @@ Image *Item::getImage(const int id,
const ItemColor color)
{
const ItemInfo &info = ItemDB::get(id);
- Image *image = Loader::getImage(combineDye2(paths.getStringValue(
- "itemIcons").append(info.getDisplay().image),
+ Image *image = Loader::getImage(combineDye2(pathJoin(paths.getStringValue(
+ "itemIcons"), info.getDisplay().image),
info.getDyeIconColorsString(color)));
if (!image)
diff --git a/src/resources/map/map.cpp b/src/resources/map/map.cpp
index 571b19abd..b7e5d1fca 100644
--- a/src/resources/map/map.cpp
+++ b/src/resources/map/map.cpp
@@ -1250,8 +1250,8 @@ void Map::saveExtraLayer() const restrict2
std::string Map::getUserMapDirectory() const restrict2
{
- return settings.serverConfigDir +
- dirSeparator + getProperty("_realfilename");
+ return pathJoin(settings.serverConfigDir,
+ getProperty("_realfilename"));
}
void Map::addRange(const std::string &restrict name,
diff --git a/src/resources/sprite/spritedef.cpp b/src/resources/sprite/spritedef.cpp
index fc168b53f..59ac9d9f4 100644
--- a/src/resources/sprite/spritedef.cpp
+++ b/src/resources/sprite/spritedef.cpp
@@ -477,7 +477,7 @@ void SpriteDef::includeSprite(XmlNodeConstPtr includeNode, const int variant)
if (filename.empty())
return;
- filename = paths.getStringValue("sprites").append(filename);
+ filename = pathJoin(paths.getStringValue("sprites"), filename);
if (mProcessedFiles.find(filename) != mProcessedFiles.end())
{