X-Git-Url: https://git.lizzy.rs/?a=blobdiff_plain;f=src%2Ffarmesh.cpp;h=fdc81057bc27fe52897fbf0282e984b748e74864;hb=581f950e10b40f2af4ede56c3fa78f13eccb610b;hp=72dbe11c21e60305c05fcd4dccf99591f4c8df9a;hpb=9d09103e481c4979ebb0130a9dee6265d0d6223b;p=dragonfireclient.git diff --git a/src/farmesh.cpp b/src/farmesh.cpp index 72dbe11c2..fdc81057b 100644 --- a/src/farmesh.cpp +++ b/src/farmesh.cpp @@ -23,13 +23,15 @@ with this program; if not, write to the Free Software Foundation, Inc., */ #include "farmesh.h" + #include "constants.h" #include "debug.h" #include "noise.h" #include "map.h" #include "client.h" +#include "tile.h" // ITextureSource -#include "mapgen.h" +#include "mapgen.h" // Shouldn't really be done this way FarMesh::FarMesh( scene::ISceneNode* parent, @@ -47,7 +49,7 @@ FarMesh::FarMesh( { dstream<<__FUNCTION_NAME<getVideoDriver(); + //video::IVideoDriver* driver = mgr->getVideoDriver(); m_materials[0].setFlag(video::EMF_LIGHTING, false); m_materials[0].setFlag(video::EMF_BACK_FACE_CULLING, true); @@ -62,8 +64,7 @@ FarMesh::FarMesh( m_materials[1].setFlag(video::EMF_BACK_FACE_CULLING, false); m_materials[1].setFlag(video::EMF_BILINEAR_FILTER, false); m_materials[1].setFlag(video::EMF_FOG_ENABLE, false); - m_materials[1].setTexture - (0, driver->getTexture(getTexturePath("treeprop.png").c_str())); + m_materials[1].setTexture(0, client->tsrc()->getTextureRaw("treeprop.png")); m_materials[1].MaterialType = video::EMT_TRANSPARENT_ALPHA_CHANNEL_REF; m_materials[1].setFlag(video::EMF_FOG_ENABLE, true); @@ -279,7 +280,8 @@ void FarMesh::render() if(h_avg < WATER_LEVEL*BS && h_max < (WATER_LEVEL+5)*BS) { //c = video::SColor(255,59,86,146); - c = video::SColor(255,82,120,204); + //c = video::SColor(255,82,120,204); + c = video::SColor(255,74,105,170); /*// Set to water level for(u32 i=0; i<4; i++)