PlayerTextDrawSetSelectable Issue
#1

Hi, I use this code and that for clicking textdraws but it's giving off false data:

Код:
for(new k = 0; k < MAX_ROWS; k++)
{
    Position = rc + (k * 9);

    bxOptions[playerid][k] = CreatePlayerTextDraw(playerid, 14.000000, Position, " ");
    PlayerTextDrawBackgroundColor(playerid, bxOptions[playerid][k], 255);
    PlayerTextDrawFont(playerid, bxOptions[playerid][k], 1);
    PlayerTextDrawLetterSize(playerid, bxOptions[playerid][k], 0.23, 0.93);
    PlayerTextDrawColor(playerid, bxOptions[playerid][k], -1);
    PlayerTextDrawSetOutline(playerid, bxOptions[playerid][k], 1);
    PlayerTextDrawSetProportional(playerid, bxOptions[playerid][k], 1);
    PlayerTextDrawSetSelectable(playerid, bxOptions[playerid][k], 1);
}

public OnPlayerClickPlayerTextDraw(playerid, PlayerText:playertextid)
{
    if(playertextid != INVALID_TEXT_DRAW_PLAYER)
    {
        for(new k = 0; k < MAX_ROWS; k++)
        {
	    if(playertextid == bxOptions[playerid][k])
	    {
	         if(k-1 <= 0) continue;

	        format(msg, 5, "%d", k-1);
       		CallRemoteFunction("OnPlayerText", "is", playerid, msg);
       	        break;
	    }
        }
    }
    return 1;
}
[ame]http://www.youtube.com/watch?v=cR7YYvdxLQg[/ame]

All of the other numbers work apart from option 5, water. When I click water it calls donut but all the others are fine.
Reply


Messages In This Thread
PlayerTextDrawSetSelectable Issue - by Kyle - 29.05.2012, 21:45
Re: PlayerTextDrawSetSelectable Issue - by ViniBorn - 29.05.2012, 21:49
Re: PlayerTextDrawSetSelectable Issue - by Kyle - 29.05.2012, 22:04
Re: PlayerTextDrawSetSelectable Issue - by ViniBorn - 29.05.2012, 22:18
Re: PlayerTextDrawSetSelectable Issue - by Kyle - 29.05.2012, 22:24
Re: PlayerTextDrawSetSelectable Issue - by ViniBorn - 29.05.2012, 22:29
Re: PlayerTextDrawSetSelectable Issue - by mati233 - 29.05.2012, 22:54
Re: PlayerTextDrawSetSelectable Issue - by MP2 - 29.05.2012, 23:48
Re: PlayerTextDrawSetSelectable Issue - by Kyle - 30.05.2012, 06:10

Forum Jump:


Users browsing this thread: 1 Guest(s)