From: ThorstenB Date: Sat, 7 Apr 2012 14:35:04 +0000 (+0200) Subject: Fix scenery reload issues. X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=da2ee04eeadf74f686e3f60d7ead5b550738a80f;p=flightgear.git Fix scenery reload issues. Aircraft could fall through the ground on scenery reload. --- diff --git a/src/Scenery/tilemgr.cxx b/src/Scenery/tilemgr.cxx index 876826d5f..0f566485b 100644 --- a/src/Scenery/tilemgr.cxx +++ b/src/Scenery/tilemgr.cxx @@ -101,8 +101,10 @@ void FGTileMgr::refresh_tile(void* tileMgr, long tileIndex) void FGTileMgr::reinit() { - // reset flag, stop FDM processing, otherwise aircraft fall through - // the ground while reloading scenery + // protect against multiple scenery reloads and properly reset flags, + // otherwise aircraft fall through the ground while reloading scenery + if (!fgGetBool("/sim/sceneryloaded",true)) + return; fgSetBool("/sim/sceneryloaded",false); fgSetDouble("/sim/startup/splash-alpha", 1.0);