Textdraw selectable box
#1

Code:
Textdraw1[playerid] = CreatePlayerTextDraw(playerid, 500.200000, 320.699981, "usebox");
PlayerTextDrawLetterSize(playerid, Textdraw1[playerid], 0.000000, 2.103088);
PlayerTextDrawTextSize(playerid, Textdraw1[playerid], 340.500000, 0.000000);
PlayerTextDrawAlignment(playerid, Textdraw1[playerid], 1);
PlayerTextDrawColor(playerid, Textdraw1[playerid], 0);
PlayerTextDrawUseBox(playerid, Textdraw1[playerid], true);
PlayerTextDrawBoxColor(playerid, Textdraw1[playerid], 102);
PlayerTextDrawSetShadow(playerid, Textdraw1[playerid], 0);
PlayerTextDrawSetOutline(playerid, Textdraw1[playerid], 0);
PlayerTextDrawFont(playerid, Textdraw1[playerid], 0);
PlayerTextDrawSetSelectable(playerid, Textdraw1[playerid], true);
It's selectable textdraw box. But when I enter selectable mod, I can't select it. What's wrong?
Reply
#2

https://sampwiki.blast.hk/wiki/PlayerTextDrawSetSelectable
https://sampwiki.blast.hk/wiki/SelectTextDraw

Quote:

TextDrawSetSelectable or PlayerTextDrawSetSelectable MUST be used first, to allow a textdraw to be selectable.

Quote:

PlayerTextDrawSetSelectable MUST be used BEFORE the textdraw is shown to the player.

Reply
#3

Already done that. Same

Code:
public OnPlayerConnect(playerid)
{

Textdraw1[playerid] = CreatePlayerTextDraw(playerid, 500.200000, 320.699981, "usebox");
PlayerTextDrawLetterSize(playerid, Textdraw1[playerid], 0.000000, 2.103088);
PlayerTextDrawTextSize(playerid, Textdraw1[playerid], 340.500000, 0.000000);
PlayerTextDrawAlignment(playerid, Textdraw1[playerid], 1);
PlayerTextDrawColor(playerid, Textdraw1[playerid], 0);
PlayerTextDrawUseBox(playerid, Textdraw1[playerid], true);
PlayerTextDrawBoxColor(playerid, Textdraw1[playerid], 102);
PlayerTextDrawSetShadow(playerid, Textdraw1[playerid], 0);
PlayerTextDrawSetOutline(playerid, Textdraw1[playerid], 0);
PlayerTextDrawFont(playerid, Textdraw1[playerid], 0);
PlayerTextDrawSetSelectable(playerid, Textdraw1[playerid], true);

return 1;
}

public OnPlayerSpawn(playerid)
{

SelectTextDraw(playerid, 0x9999BBBB);
PlayerTextDrawShow(playerid, Textdraw1[playerid]);

	return 1;
}
Reply
#4

guys?
Reply
#5

I think someone said that TextSize can't be 0
Reply
#6

Quote:
Originally Posted by Joe Staff
View Post
I think someone said that TextSize can't be 0
I tried to increase it, still same
Reply
#7

Bump
Reply
#8

Or could anyone give me an example code where you create selectable textdraw box?
Reply
#9

Guys i got this error and idk how to post on the forums
help me plz

native mysql_retrieve_row(connectionHandle = 1);

D:\Program Files\games1\Rockstar Games\Cops and robbers Beta\gamemodes\cnr.pwn(6569) : error 029: invalid expression, assumed zero
D:\Program Files\games1\Rockstar Games\Cops and robbers Beta\gamemodes\cnr.pwn(6569) : error 017: undefined symbol "mysql_retrieve_row"
D:\Program Files\games1\Rockstar Games\Cops and robbers Beta\gamemodes\cnr.pwn(6569) : warning 215: expression has no effect
D:\Program Files\games1\Rockstar Games\Cops and robbers Beta\gamemodes\cnr.pwn(6569) : error 001: expected token: ";", but found ")"
D:\Program Files\games1\Rockstar Games\Cops and robbers Beta\gamemodes\cnr.pwn(6569) : fatal error 107: too many error messages on one line

and if i delete it i get it from a another native mysql_retrieve_row(connectionHandle = 1); so plz help me
Reply
#10

Quote:
Originally Posted by Unkowusername
View Post
Guys i got this error and idk how to post on the forums
help me plz

native mysql_retrieve_row(connectionHandle = 1);

D:\Program Files\games1\Rockstar Games\Cops and robbers Beta\gamemodes\cnr.pwn(6569) : error 029: invalid expression, assumed zero
D:\Program Files\games1\Rockstar Games\Cops and robbers Beta\gamemodes\cnr.pwn(6569) : error 017: undefined symbol "mysql_retrieve_row"
D:\Program Files\games1\Rockstar Games\Cops and robbers Beta\gamemodes\cnr.pwn(6569) : warning 215: expression has no effect
D:\Program Files\games1\Rockstar Games\Cops and robbers Beta\gamemodes\cnr.pwn(6569) : error 001: expected token: ";", but found ")"
D:\Program Files\games1\Rockstar Games\Cops and robbers Beta\gamemodes\cnr.pwn(6569) : fatal error 107: too many error messages on one line

and if i delete it i get it from a another native mysql_retrieve_row(connectionHandle = 1); so plz help me
Just create new thread. Btw I still need halp
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)