TDE help
#1

Hello everyone, i am using TDE TextDraw Editor to create textdraws. i created a textdraw in it. so now, i am wondering that how to use it in PlayerTextDrawShow? cuz it is creating txds under same variable TDEditor_PTD[MAX_PLAYERS][4].

here is the code:
PHP код:
//Player TextDraws: 
new Text:TDEditor_PTD[MAX_PLAYERS][4];
TDEditor_PTD[playerid][0] = CreatePlayerTextDraw(playerid162.799987136.986572"box");
PlayerTextDrawLetterSize(playeridTDEditor_PTD[playerid][0], 0.00000020.079992);
PlayerTextDrawTextSize(playeridTDEditor_PTD[playerid][0], 490.0000000.000000);
PlayerTextDrawAlignment(playeridTDEditor_PTD[playerid][0], 1);
PlayerTextDrawColor(playeridTDEditor_PTD[playerid][0], -1);
PlayerTextDrawUseBox(playeridTDEditor_PTD[playerid][0], 1);
PlayerTextDrawBoxColor(playeridTDEditor_PTD[playerid][0], 255);
PlayerTextDrawSetShadow(playeridTDEditor_PTD[playerid][0], 0);
PlayerTextDrawSetOutline(playeridTDEditor_PTD[playerid][0], 0);
PlayerTextDrawBackgroundColor(playeridTDEditor_PTD[playerid][0], 255);
PlayerTextDrawFont(playeridTDEditor_PTD[playerid][0], 1);
PlayerTextDrawSetProportional(playeridTDEditor_PTD[playerid][0], 1);
PlayerTextDrawSetShadow(playeridTDEditor_PTD[playerid][0], 0);
PlayerTextDrawSetSelectable(playeridTDEditor_PTD[playerid][0], true);
TDEditor_PTD[playerid][1] = CreatePlayerTextDraw(playerid412.200012136.333358"");
PlayerTextDrawLetterSize(playeridTDEditor_PTD[playerid][1], 0.0000000.000000);
PlayerTextDrawTextSize(playeridTDEditor_PTD[playerid][1], 79.000000100.000000);
PlayerTextDrawAlignment(playeridTDEditor_PTD[playerid][1], 1);
PlayerTextDrawColor(playeridTDEditor_PTD[playerid][1], -1);
PlayerTextDrawSetShadow(playeridTDEditor_PTD[playerid][1], 0);
PlayerTextDrawSetOutline(playeridTDEditor_PTD[playerid][1], 0);
PlayerTextDrawBackgroundColor(playeridTDEditor_PTD[playerid][1], 255);
PlayerTextDrawFont(playeridTDEditor_PTD[playerid][1], 5);
PlayerTextDrawSetProportional(playeridTDEditor_PTD[playerid][1], 0);
PlayerTextDrawSetShadow(playeridTDEditor_PTD[playerid][1], 0);
PlayerTextDrawSetPreviewModel(playeridTDEditor_PTD[playerid][1], 0);
PlayerTextDrawSetPreviewRot(playeridTDEditor_PTD[playerid][1], 0.0000000.0000000.0000001.000000);
TDEditor_PTD[playerid][2] = CreatePlayerTextDraw(playerid162.000076141.466629"Name");
PlayerTextDrawLetterSize(playeridTDEditor_PTD[playerid][12], 0.4000001.600000);
PlayerTextDrawAlignment(playeridTDEditor_PTD[playerid][12], 1);
PlayerTextDrawColor(playeridTDEditor_PTD[playerid][12], -1);
PlayerTextDrawSetShadow(playeridTDEditor_PTD[playerid][12], 0);
PlayerTextDrawSetOutline(playeridTDEditor_PTD[playerid][12], 0);
PlayerTextDrawBackgroundColor(playeridTDEditor_PTD[playerid][12], 255);
PlayerTextDrawFont(playeridTDEditor_PTD[playerid][12], 1);
PlayerTextDrawSetProportional(playeridTDEditor_PTD[playerid][12], 1);
PlayerTextDrawSetShadow(playeridTDEditor_PTD[playerid][12], 0);
TDEditor_PTD[playerid][3] = CreatePlayerTextDraw(playerid216.676406142.143295"NAMEHERE");
PlayerTextDrawLetterSize(playeridTDEditor_PTD[playerid][13], 0.4000001.600000);
PlayerTextDrawAlignment(playeridTDEditor_PTD[playerid][13], 1);
PlayerTextDrawColor(playeridTDEditor_PTD[playerid][13], -1);
PlayerTextDrawSetShadow(playeridTDEditor_PTD[playerid][13], 0);
PlayerTextDrawSetOutline(playeridTDEditor_PTD[playerid][13], 0);
PlayerTextDrawBackgroundColor(playeridTDEditor_PTD[playerid][13], 255);
PlayerTextDrawFont(playeridTDEditor_PTD[playerid][13], 1);
PlayerTextDrawSetProportional(playeridTDEditor_PTD[playerid][13], 1);
PlayerTextDrawSetShadow(playeridTDEditor_PTD[playerid][13], 0);
//Total textdraws exported: 4 (0 global textdraws /14 player textdraws) ~ 30/4/2016 ~ 13:44:25
TDEditor V1.16 by adri1 
so how to use it to show it to player?

Also, why when i press Delete button, in place of deleting, it is duplicating the textdraw?
Reply
#2

Well SA:MP has 2 types of textdraws. Global ones, the ones that r the same for every player on th esrver, and player ones, the ones uniq for every player. U r creating global ones, and try to use function that is intended to show player ones. So, u either want to swtich to player text draws, whic r more suitable to u scrip, atleast of waht I can see, or use TextDrawShowForPlayer function instead of PlayerTextDrawShow.
Reply
#3

hey mate, i guess you didnt see but i am making Player Textdraws. now my doubt is how to show it to player, as each text draw has same name with diffrent arreys. like new TDE_test[MAX_PLAYERS][4] means i can use that variable for 4 times starting from 0 to 3. so if i want to show it to player, what do i have to do.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)