24.02.2012, 00:10
Hello there, im having the following trouble: GetPlayerMenu gets only the first one menu i used in game, and if im trying to use and exit other menu, GetPlayerMenu still says that i exited the first menu (Which i used before). Any ideas about what to do?
public OnPlayerExitedMenu(playerid)
{
new Menu:current = GetPlayerMenu(playerid);
if(current == vehd || col1 || col2)
{
DestroyVehicleEx(VehShow[playerid]);
SetPlayerVirtualWorld(playerid, 0);
TogglePlayerSpectating(playerid, 0);
}
else if(current == clos || gang)
{
SetPlayerSkin(playerid, GetPVarInt(playerid, "s"));
TogglePlayerControllable(playerid, 1);
SetCameraBehindPlayer(playerid);
}
return 1;
}
public OnPlayerExitedMenu(playerid)
{
new Menu:current = GetPlayerMenu(playerid);
if(current == vehd || col1 || col2)
{
DestroyVehicleEx(VehShow[playerid]);
SetPlayerVirtualWorld(playerid, 0);
TogglePlayerSpectating(playerid, 0);
}
else if(current == clos || gang)
{
SetPlayerSkin(playerid, GetPVarInt(playerid, "s"));
TogglePlayerControllable(playerid, 1);
SetCameraBehindPlayer(playerid);
}
return 1;
}