Warning on a variable
#1

pawn Код:
if(listitem == 0)
        {
            if(PlayerInfo[playerid][pCarLic] == 0)
            {
                if(GetPlayerMoney(playerid) < 4999)
                {
                    SendClientMessage(playerid, COLOR_GREY, "No enough money!");
                    return 1;
                }
                else
                {
                    SendClientMessage(playerid, COLOR_WHITE, "- Instructor: Sit in a car outside to take the driving test.");
                    TakingLesson[playerid] == 1;
                    return 1;
                    /*SendClientMessage(playerid, COLOR_LIGHTBLUE, "You bought a driving license for 5000$.");
                    SafeGivePlayerMoney(playerid, -5000);
                    PlayerInfo[playerid][pCarLic] = 1;
                    OnPlayerUpdate(playerid);*/

                }
            }
            else
            {
                SendClientMessage(playerid, COLOR_LIGHTBLUE, "You already have a driving license!");
                return 1;
            }
        }
Why do I get a warning on the line 'TakingLesson[playerid] == 1;' saying 'Expression has no effect'?
Reply
#2

Change

Код:
TakingLesson[playerid] == 1;
to...

Код:
TakingLesson[playerid] = 1;
Reply
#3

w00t I didn't pay attention to it, thanks)
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)