瀏覽代碼

Merge pull request #1391 from Azaezel/C4706

warning C4706: assignment within conditional expression
Daniel Buckmaster 10 年之前
父節點
當前提交
c0e82d72a2
共有 1 個文件被更改,包括 2 次插入2 次删除
  1. 2 2
      Engine/source/forest/forestWindEmitter.cpp

+ 2 - 2
Engine/source/forest/forestWindEmitter.cpp

@@ -521,8 +521,8 @@ void ForestWindEmitter::_renderEmitterInfo( ObjectRenderInst *ri, SceneRenderSta
    {
       // If the camera is close to the sphere, shrink the sphere so it remains visible.
       GameConnection* gc = GameConnection::getConnectionToServer();
-      GameBase* gb;
-      if ( gc && (gb = gc->getCameraObject()) )
+      GameBase *gb = gc ? gc->getCameraObject() : NULL;
+      if (gb)
       {
          F32 camDist = (gb->getPosition() - getPosition()).len();
          if ( camDist < mWindRadius )