19.01.2013, 23:13
Don't know why you would want a 3DTextLabel, the best way to do this would be with a chat bubble. The chat bubble is probably what you actually wanted but you mistook it for a 3DTextLabel. It does the same thing but it goes away by itself without being destroy. Here is the wiki link: https://sampwiki.blast.hk/wiki/SetPlayerChatBubble
And here is the code:
And here is the code:
pawn Код:
CMD:plant(playerid, params[])
{
if(PlayerInfo[playerid][pSeeds] > 2)
{
new Name[MAX_PLAYER_NAME],Float:x,Float:y,Float:z,string[128];
GetPlayerName(playerid, Name, sizeof(Name));
format(string, sizeof(string), "%s plants some canabis seeds.", Name);
SetPlayerChatBubble(playerid, string, COL_PURPLE, 100, 2000);
GetPlayerPos(playerid,x,y,z);
CreateObject(19473,x,y,z-2,0,0,0);
PlayerInfo[playerid][pSeeds]-=3;
}
else return SendClientMessage(playerid,COL_WHITE,"You don't have enough seeds!");
return 1;
}