uninitalized local variable

i am creating a menu for my pong game and i keep receiving the error c4700, but i believe i have iniitalizal my variable but its telling me that i haven't and i cant find a way to fix it also i have a warning saying that i will loss data from a conversion from an int to a float...execpt i dont have any ints used i think, any advice would be great i have pasted the codes of fault below and the lines of code near each error


the while(bcontineGame) is what VS is telling me it not working

//MAINMENU
{

if(currentstate = MAINMENU)
bool bcontinueGame = true;
if(currentstate = QUIT)
bool bcontinueGame = false;

{
while (bcontinueGame)

switch(currentstate)
{
case MAINMENU:
bcontinueGame = MAINMENU;
case SINGLEPLAYER:
bcontinueGame = SINGLEPLAYER;
case QUIT:
break;
default:
break;
};
}
}


and the lost of data is here

DrawSprite(ArrowX, 32, ArrowY, 32, Rot += 200.0f);

my varriable are below if needed

int Arrow = LoadTexture("./images/arrow.png");
float ArrowY = 250;
float ArrowX = 150;
float Rot = 0;

int currentstate;
const int MAINMENU = 1;
const int SINGLEPLAYER = 2;
const int QUIT = 3;
int bcontinueGame;


any help would be welcome.

bcontinueGame is in the scope of those if statements, and so the while() loop doesn't see it.
okay fixed it thanks =D
Topic archived. No new replies allowed.