CancelSelectTextDraw Bugged.
#5

Quote:
Originally Posted by [uL]Pottus
Посмотреть сообщение
Take a look at my code above.
Ye well that doesn't change a thing, now take a look at my code, and let me explain what is going on.

pawn Код:
public OnPlayerClickTextDraw(playerid,Text:clickedid)
{
    if(_:clickedid == INVALID_TEXT_DRAW)
    {
        if(pList[playerid][LIST_TYPE] != FALSE) ClosePlayerList(playerid);
        if(pList[playerid][OPTION_TYPE] != FALSE) ClosePlayerOptions(playerid);
    }
    return 1;
}
Now at some command this code is runned:
pawn Код:
ClosePlayerList(playerid);
ShowPlayerOptions(playerid,OPTION_FURNITURE);
Now inside ClosePlayerList there has been used a CancelSelectTextDraw call.
Inside ShowPlayerOptions the variable: pList[playerid][OPTION_TYPE] has been set on true

When CancelSelectTextDraw gets called in ClosePlayerList, this OPTION_TYPE variable is already set on true in ShowPlayerOptions., which makes my ShowPlayerOptions textdraws directly get destroyed because of CancelSelectTextDraw .

And I can't remove CancelSelectTextDraw from ClosePlayerList, because ClosePlayerList is used on alot of different locations in my script.
Reply


Messages In This Thread
CancelSelectTextDraw Bugged. - by Roel - 17.12.2013, 21:40
Re: CancelSelectTextDraw Bugged. - by Pottus - 17.12.2013, 21:40
Re: CancelSelectTextDraw Bugged. - by Roel - 17.12.2013, 21:44
Re: CancelSelectTextDraw Bugged. - by Pottus - 17.12.2013, 21:47
Re: CancelSelectTextDraw Bugged. - by Roel - 17.12.2013, 21:52

Forum Jump:


Users browsing this thread: 1 Guest(s)