@@ -364,14 +364,14 @@ class TextureSource : public IWritableTextureSource
364
364
// Gets a separate texture
365
365
video::ITexture* getTextureRaw (const std::string &name)
366
366
{
367
- AtlasPointer ap = getTexture (name + " ^[forcesingle " );
367
+ AtlasPointer ap = getTexture (name + m_forcesingle_suffix );
368
368
return ap.atlas ;
369
369
}
370
370
371
371
// Gets a separate texture atlas pointer
372
372
AtlasPointer getTextureRawAP (const AtlasPointer &ap)
373
373
{
374
- return getTexture (getTextureName (ap.id ) + " ^[forcesingle " );
374
+ return getTexture (getTextureName (ap.id ) + m_forcesingle_suffix );
375
375
}
376
376
377
377
// Returns a pointer to the irrlicht device
@@ -437,6 +437,7 @@ class TextureSource : public IWritableTextureSource
437
437
// Main texture atlas. This is filled at startup and is then not touched.
438
438
video::IImage *m_main_atlas_image;
439
439
video::ITexture *m_main_atlas_texture;
440
+ std::string m_forcesingle_suffix;
440
441
441
442
// Queued texture fetches (to be processed by the main thread)
442
443
RequestQueue<std::string, u32, u8, u8> m_get_texture_queue;
@@ -1137,6 +1138,8 @@ void TextureSource::buildMainAtlas(class IGameDef *gamedef)
1137
1138
<<atlaspath<<std::endl;
1138
1139
fs::RecursiveDelete(atlaspath);
1139
1140
driver->writeImageToFile(atlas_img, atlaspath.c_str());*/
1141
+
1142
+ m_forcesingle_suffix = " ^[forcesingle" ;
1140
1143
}
1141
1144
1142
1145
video::IImage* generate_image_from_scratch (std::string name,
0 commit comments