aboutsummaryrefslogtreecommitdiff
path: root/src/mapblockobject.cpp
diff options
context:
space:
mode:
authorPerttu Ahola <celeron55@gmail.com>2011-01-07 19:39:27 +0200
committerPerttu Ahola <celeron55@gmail.com>2011-01-07 19:39:27 +0200
commit6b6c2d37ea1f9075c4fbf0d7e2d52e527e1f86aa (patch)
tree16ab23387dc95d0f42e6519e500d4024e2a2f826 /src/mapblockobject.cpp
parentdc414091e736badc6fd2faa6a2583639a3458818 (diff)
downloadminetest-6b6c2d37ea1f9075c4fbf0d7e2d52e527e1f86aa.tar.gz
minetest-6b6c2d37ea1f9075c4fbf0d7e2d52e527e1f86aa.tar.bz2
minetest-6b6c2d37ea1f9075c4fbf0d7e2d52e527e1f86aa.zip
Added a more flexible path system (and fixed some minor stuff)
Diffstat (limited to 'src/mapblockobject.cpp')
-rw-r--r--src/mapblockobject.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/mapblockobject.cpp b/src/mapblockobject.cpp
index 653dbc332..ab12afc8e 100644
--- a/src/mapblockobject.cpp
+++ b/src/mapblockobject.cpp
@@ -282,7 +282,7 @@ void RatObject::addToScene(scene::ISceneManager *smgr)
buf->getMaterial().setFlag(video::EMF_LIGHTING, false);
buf->getMaterial().setFlag(video::EMF_BACK_FACE_CULLING, false);
buf->getMaterial().setTexture
- (0, driver->getTexture("../data/rat.png"));
+ (0, driver->getTexture(porting::getDataPath("rat.png").c_str()));
buf->getMaterial().setFlag(video::EMF_BILINEAR_FILTER, false);
buf->getMaterial().setFlag(video::EMF_FOG_ENABLE, true);
buf->getMaterial().MaterialType = video::EMT_TRANSPARENT_ALPHA_CHANNEL;
@@ -360,7 +360,7 @@ video::ITexture * ItemObject::getItemImage()
if(item)
texture = item->getImage();
/*else
- texture = g_irrlicht->getTexture("../data/cloud.png");*/
+ texture = g_irrlicht->getTexture(porting::getDataPath("cloud.png").c_str());*/
if(item)
delete item;
return texture;
@@ -414,7 +414,7 @@ void PlayerObject::addToScene(scene::ISceneManager *smgr)
// Set material
buf->getMaterial().setFlag(video::EMF_LIGHTING, false);
//buf->getMaterial().setFlag(video::EMF_BACK_FACE_CULLING, false);
- buf->getMaterial().setTexture(0, driver->getTexture("../data/player.png"));
+ buf->getMaterial().setTexture(0, driver->getTexture(porting::getDataPath("player.png").c_str()));
buf->getMaterial().setFlag(video::EMF_BILINEAR_FILTER, false);
buf->getMaterial().setFlag(video::EMF_FOG_ENABLE, true);
//buf->getMaterial().MaterialType = video::EMT_TRANSPARENT_ALPHA_CHANNEL;
@@ -438,7 +438,7 @@ void PlayerObject::addToScene(scene::ISceneManager *smgr)
// Set material
buf->getMaterial().setFlag(video::EMF_LIGHTING, false);
//buf->getMaterial().setFlag(video::EMF_BACK_FACE_CULLING, false);
- buf->getMaterial().setTexture(0, driver->getTexture("../data/player_back.png"));
+ buf->getMaterial().setTexture(0, driver->getTexture(porting::getDataPath("player_back.png").c_str()));
buf->getMaterial().setFlag(video::EMF_BILINEAR_FILTER, false);
buf->getMaterial().setFlag(video::EMF_FOG_ENABLE, true);
buf->getMaterial().MaterialType = video::EMT_TRANSPARENT_ALPHA_CHANNEL_REF;