From 126d319a0312b8cee21921acae7b15a747785108 Mon Sep 17 00:00:00 2001 From: auria Date: Fri, 19 Nov 2010 22:00:14 +0000 Subject: [PATCH] When GFX are off, use static meshes instead of water nodes git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@6654 178a84e3-b1eb-0310-8ba1-8eac791a3b58 --- src/tracks/track.cpp | 19 +++++++++++++++---- 1 file changed, 15 insertions(+), 4 deletions(-) diff --git a/src/tracks/track.cpp b/src/tracks/track.cpp index 697ad6c74..78a7f3cc6 100644 --- a/src/tracks/track.cpp +++ b/src/tracks/track.cpp @@ -660,10 +660,21 @@ void Track::createWater(const XMLNode &node) node.get("height", &wave_height); node.get("speed", &wave_speed); node.get("length", &wave_length); - scene::ISceneNode* scene_node = irr_driver->addWaterNode(mesh, - wave_height, - wave_speed, - wave_length); + scene::ISceneNode* scene_node; + + + if (UserConfigParams::m_graphical_effects) + { + scene_node = irr_driver->addWaterNode(mesh, + wave_height, + wave_speed, + wave_length); + } + else + { + scene_node = irr_driver->addMesh(mesh); + } + #ifdef DEBUG std::string debug_name = model_name+"(water node)"; scene_node->setName(debug_name.c_str());