From c6cb97e693722aee47aef03e4ea0788037a6a633 Mon Sep 17 00:00:00 2001 From: "Esteban I. Ruiz Moreno" Date: Mon, 29 Jul 2013 23:18:11 -0300 Subject: [PATCH] Make bumpmapping compatible with irrlicht 1.8 --- src/game.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/game.cpp b/src/game.cpp index 0c7d15d0c..4f2d6650d 100644 --- a/src/game.cpp +++ b/src/game.cpp @@ -807,7 +807,12 @@ public: // Normal map texture layer int layer = 1; + // before 1.8 there isn't a "integer interface", only float +#if (IRRLICHT_VERSION_MAJOR == 1 && IRRLICHT_VERSION_MINOR < 8) services->setPixelShaderConstant("normalTexture" , (irr::f32*)&layer, 1); +#else + services->setPixelShaderConstant("normalTexture" , (irr::s32*)&layer, 1); +#endif } };