diff options
author | Andrei Karas <akaras@inbox.ru> | 2013-10-08 20:35:49 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2013-10-08 20:35:49 +0300 |
commit | a096b29db464950774e3f93c75b0f6b7e19e7aca (patch) | |
tree | 7454a7e66f561c73a62cbb44879ee49baf00761e | |
parent | 9a0da2510f9eed57e4bc974084bf54832ee4c33c (diff) | |
download | manaplus-a096b29db464950774e3f93c75b0f6b7e19e7aca.tar.gz manaplus-a096b29db464950774e3f93c75b0f6b7e19e7aca.tar.bz2 manaplus-a096b29db464950774e3f93c75b0f6b7e19e7aca.tar.xz manaplus-a096b29db464950774e3f93c75b0f6b7e19e7aca.zip |
fix target cursor loading in not default themes.
-rw-r--r-- | src/being/actorsprite.cpp | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/src/being/actorsprite.cpp b/src/being/actorsprite.cpp index 66b2b9f17..162d5d661 100644 --- a/src/being/actorsprite.cpp +++ b/src/being/actorsprite.cpp @@ -361,17 +361,18 @@ static const char *cursorSize(const int size) void ActorSprite::initTargetCursor() { - static const std::string targetCursorFile("%s/target-cursor-%s-%s.xml"); - const std::string path(Theme::getThemePath()); + static const std::string targetCursorFile("target-cursor-%s-%s.xml"); // Load target cursors for (int size = TC_SMALL; size < NUM_TC; size++) { for (int type = TCT_NORMAL; type < NUM_TCT; type++) { - targetCursor[type][size] = AnimatedSprite::load(strprintf( - targetCursorFile.c_str(), path.c_str(), cursorType(type), - cursorSize(size))); + targetCursor[type][size] = AnimatedSprite::load( + Theme::resolveThemePath(strprintf( + targetCursorFile.c_str(), + cursorType(type), + cursorSize(size)))); } } } |