title: why am I getting a "was not declared in this scope" error?
body: <p>I get 5 errors at the following snippet of code</p>
  
  <p>4 of the errors are </p>
  
  <blockquote>
    <p>expected unqualified-id before '('
    token|</p>
  </blockquote>
  
  <p>and 1 error  </p>
  
  <blockquote>
    <p>'GetEntityIterator' was not declared
    in this scope|</p>
  </blockquote>
  
  <p><code>GetEntityIterator()</code> returns <code>vector&lt;*Entity&gt;::iterator EntityIterator</code></p>
  
  <p><code>GetAABB()</code> returns an <code>AABB</code></p>
  
  <p>I can post more code if needed</p>
  
  <pre><code>    void Bomb::CreateExplosion(Game_Manager* EGame_Manager)
      {
      BombTexture-&gt;LoadTexture("Bomb.bmp");
      glTexEnvf(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_DECAL);
  
      for(int iteration = 1; iteration &lt;= 3; iteration++)
      {
          if(this-&gt;GetAABB()-&gt;CheckForCollision(this-&gt;GetAABB(), EGame_Manager-&gt;getEntityManager()-&gt;(*GetEntityIterator())-&gt;GetAABB()) == true)//check for collision against the unbreakable blocks or player and does what is necessary for each
          {
              if(EGame_Manager-&gt;getEntityManager()-&gt;(*GetEntityIterator())-&gt;GetType() == unbreakableblock)
              {
               break;
              }
              else if(EGame_Manager-&gt;getEntityManager()-&gt;(*GetEntityIterator())-&gt;GetType() == player)
              {
                  EGame_Manager-&gt;getEntityManager()-&gt;(*GetEntityIterator())-&gt;GetLives() -= 1;
              }
  
          }
          else
          glBegin(GL_QUADS);
              glColor4f(   1.0f,    0.0f, 0.0f, 0.0f); //color red
              glTexCoord2f(0.0, 0.0); //uv coordinates
              glVertex3f( -2.0f + x,2.0f  + y,  0.0f); //top left
              //----------------------------------------------------
              glColor4f(   0.0f,    1.0f, 0.0f, 0.0f); //color green
              glTexCoord2f(1, 0.0 ); //uv coordinates
              glVertex3f(  2.0f + x,2.0f  + y,  0.0f); //top right
              //----------------------------------------------------
              glColor4f(   0.0f,    0.0f, 1.0f, 0.0f); //color blue
              glTexCoord2f(1, 1);
              glVertex3f( 2.0f + x, -2.0f + y,  0.0f); //bottom right
              //----------------------------------------------------
              glColor4f(   1.0f,    1.0f, 0.0f, 0.0f); //color red
              glTexCoord2f(0.0, 1); //uv coordinates
              glVertex3f(-2.0f + x, -2.0f + y,  0.0f); //bottom left
          glEnd();
      }
  
      glDisable(GL_TEXTURE_2D); //disable 2d textures
  
  }
  </code></pre>