09.02.2015, 20:13
pawn Код:
new PlayerText3D: teks[MAX_PLAYERS], Float: Pos[3], texxt[32];
if(sscanf(params, "s[32]", texxt)) return SendClientMessage(playerid, WHITE, "USAGE:/txt [text]");
if(strlen(texxt) <= 3 || strlen(texxt) >= 20)
{
GetPlayerPos(playerid, Pos[0], Pos[1], Pos[2]);
teks[playerid] = CreatePlayer3DTextLabel(playerid, texxt, 0x33AA33AA, Pos[0], Pos[1], Pos[2]+2, 15.0, playerid, INVALID_VEHICLE_ID);
return 1;
}
the length of a string is checked by "strlen()" btw
https://sampwiki.blast.hk/wiki/Strlen