Change Details
src/surface.cpp |
26 | 26 | #include "surface.h" |
27 | 27 | #include "utilities.h" |
28 | 28 | #include "debug.h" |
| 29 | #include "surfacecollection.h" |
29 | 30 | |
30 | 31 | RGBAColor strtorgba(const string &strColor) { |
31 | 32 | RGBAColor c = {0,0,0,255}; |
... | ... | |
116 | 117 | free(); |
117 | 118 | |
118 | 119 | string skinpath; |
119 | | if (!skin.empty() && !img.empty() && img[0]!='/') { |
120 | | skinpath = "skins/"+skin+"/"+img; |
121 | | if (!fileExists(skinpath)) |
122 | | skinpath = "skins/Default/"+img; |
123 | | } else { |
124 | | skinpath = img; |
125 | | } |
| 120 | if (!skin.empty() && !img.empty() && img[0]!='/') |
| 121 | skinpath = SurfaceCollection::getSkinFilePath(skin, img); |
| 122 | else |
| 123 | skinpath = img; |
126 | 124 | |
127 | 125 | SDL_Surface *buf = IMG_Load(skinpath.c_str()); |
128 | 126 | if (buf!=NULL) { |
Download the corresponding diff file