SelectableTextdraw Problem -_-
#1

hi so this is my textdraw:
Код:
//Player Textdraws:

new PlayerText:InputPass[MAX_PLAYERS][11];


InputPass[playerid][0] = CreatePlayerTextDraw(playerid, 379.199829, 253.119934, "ENTER");
PlayerTextDrawLetterSize(playerid, InputPass[playerid][0], 0.363599, 3.899734);
PlayerTextDrawAlignment(playerid, InputPass[playerid][0], 2);
PlayerTextDrawColor(playerid, InputPass[playerid][0], -1);
PlayerTextDrawSetShadow(playerid, InputPass[playerid][0], 0);
PlayerTextDrawSetOutline(playerid, InputPass[playerid][0], 1);
PlayerTextDrawBackgroundColor(playerid, InputPass[playerid][0], 51);
PlayerTextDrawFont(playerid, InputPass[playerid][0], 1);
PlayerTextDrawSetProportional(playerid, InputPass[playerid][0], 1);
PlayerTextDrawSetSelectable(playerid, InputPass[playerid][0], true);

InputPass[playerid][1] = CreatePlayerTextDraw(playerid, 241.800033, 244.413223, "4");
PlayerTextDrawLetterSize(playerid, InputPass[playerid][1], 0.449999, 1.600000);
PlayerTextDrawAlignment(playerid, InputPass[playerid][1], 1);
PlayerTextDrawColor(playerid, InputPass[playerid][1], -1);
PlayerTextDrawSetShadow(playerid, InputPass[playerid][1], 0);
PlayerTextDrawSetOutline(playerid, InputPass[playerid][1], 1);
PlayerTextDrawBackgroundColor(playerid, InputPass[playerid][1], 51);
PlayerTextDrawFont(playerid, InputPass[playerid][1], 1);
PlayerTextDrawSetProportional(playerid, InputPass[playerid][1], 1);
PlayerTextDrawSetSelectable(playerid, InputPass[playerid][1], true);

InputPass[playerid][2] = CreatePlayerTextDraw(playerid, 242.000030, 284.239929, "7");
PlayerTextDrawLetterSize(playerid, InputPass[playerid][2], 0.449999, 1.600000);
PlayerTextDrawAlignment(playerid, InputPass[playerid][2], 1);
PlayerTextDrawColor(playerid, InputPass[playerid][2], -1);
PlayerTextDrawSetShadow(playerid, InputPass[playerid][2], 0);
PlayerTextDrawSetOutline(playerid, InputPass[playerid][2], 1);
PlayerTextDrawBackgroundColor(playerid, InputPass[playerid][2], 51);
PlayerTextDrawFont(playerid, InputPass[playerid][2], 1);
PlayerTextDrawSetProportional(playerid, InputPass[playerid][2], 1);
PlayerTextDrawSetSelectable(playerid, InputPass[playerid][2], true);

InputPass[playerid][3] = CreatePlayerTextDraw(playerid, 285.399993, 283.746582, "8");
PlayerTextDrawLetterSize(playerid, InputPass[playerid][3], 0.449999, 1.600000);
PlayerTextDrawAlignment(playerid, InputPass[playerid][3], 1);
PlayerTextDrawColor(playerid, InputPass[playerid][3], -1);
PlayerTextDrawSetShadow(playerid, InputPass[playerid][3], 0);
PlayerTextDrawSetOutline(playerid, InputPass[playerid][3], 1);
PlayerTextDrawBackgroundColor(playerid, InputPass[playerid][3], 51);
PlayerTextDrawFont(playerid, InputPass[playerid][3], 1);
PlayerTextDrawSetProportional(playerid, InputPass[playerid][3], 1);
PlayerTextDrawSetSelectable(playerid, InputPass[playerid][3], true);

InputPass[playerid][4] = CreatePlayerTextDraw(playerid, 327.999969, 283.999908, "9");
PlayerTextDrawLetterSize(playerid, InputPass[playerid][4], 0.449999, 1.600000);
PlayerTextDrawAlignment(playerid, InputPass[playerid][4], 1);
PlayerTextDrawColor(playerid, InputPass[playerid][4], -1);
PlayerTextDrawSetShadow(playerid, InputPass[playerid][4], 0);
PlayerTextDrawSetOutline(playerid, InputPass[playerid][4], 1);
PlayerTextDrawBackgroundColor(playerid, InputPass[playerid][4], 51);
PlayerTextDrawFont(playerid, InputPass[playerid][4], 1);
PlayerTextDrawSetProportional(playerid, InputPass[playerid][4], 1);
PlayerTextDrawSetSelectable(playerid, InputPass[playerid][4], true);

InputPass[playerid][5] = CreatePlayerTextDraw(playerid, 327.399993, 244.679809, "6");
PlayerTextDrawLetterSize(playerid, InputPass[playerid][5], 0.449999, 1.600000);
PlayerTextDrawAlignment(playerid, InputPass[playerid][5], 1);
PlayerTextDrawColor(playerid, InputPass[playerid][5], -1);
PlayerTextDrawSetShadow(playerid, InputPass[playerid][5], 0);
PlayerTextDrawSetOutline(playerid, InputPass[playerid][5], 1);
PlayerTextDrawBackgroundColor(playerid, InputPass[playerid][5], 51);
PlayerTextDrawFont(playerid, InputPass[playerid][5], 1);
PlayerTextDrawSetProportional(playerid, InputPass[playerid][5], 1);
PlayerTextDrawSetSelectable(playerid, InputPass[playerid][5], true);

InputPass[playerid][6] = CreatePlayerTextDraw(playerid, 284.399963, 244.933151, "5");
PlayerTextDrawLetterSize(playerid, InputPass[playerid][6], 0.449999, 1.600000);
PlayerTextDrawAlignment(playerid, InputPass[playerid][6], 1);
PlayerTextDrawColor(playerid, InputPass[playerid][6], -1);
PlayerTextDrawSetShadow(playerid, InputPass[playerid][6], 0);
PlayerTextDrawSetOutline(playerid, InputPass[playerid][6], 1);
PlayerTextDrawBackgroundColor(playerid, InputPass[playerid][6], 51);
PlayerTextDrawFont(playerid, InputPass[playerid][6], 1);
PlayerTextDrawSetProportional(playerid, InputPass[playerid][6], 1);
PlayerTextDrawSetSelectable(playerid, InputPass[playerid][6], true);

InputPass[playerid][7] = CreatePlayerTextDraw(playerid, 284.599975, 205.613037, "2");
PlayerTextDrawLetterSize(playerid, InputPass[playerid][7], 0.449999, 1.600000);
PlayerTextDrawAlignment(playerid, InputPass[playerid][7], 1);
PlayerTextDrawColor(playerid, InputPass[playerid][7], -1);
PlayerTextDrawSetShadow(playerid, InputPass[playerid][7], 0);
PlayerTextDrawSetOutline(playerid, InputPass[playerid][7], 1);
PlayerTextDrawBackgroundColor(playerid, InputPass[playerid][7], 51);
PlayerTextDrawFont(playerid, InputPass[playerid][7], 1);
PlayerTextDrawSetProportional(playerid, InputPass[playerid][7], 1);
PlayerTextDrawSetSelectable(playerid, InputPass[playerid][7], true);

InputPass[playerid][8] = CreatePlayerTextDraw(playerid, 327.199951, 205.866378, "3");
PlayerTextDrawLetterSize(playerid, InputPass[playerid][8], 0.449999, 1.600000);
PlayerTextDrawAlignment(playerid, InputPass[playerid][8], 1);
PlayerTextDrawColor(playerid, InputPass[playerid][8], -1);
PlayerTextDrawSetShadow(playerid, InputPass[playerid][8], 0);
PlayerTextDrawSetOutline(playerid, InputPass[playerid][8], 1);
PlayerTextDrawBackgroundColor(playerid, InputPass[playerid][8], 51);
PlayerTextDrawFont(playerid, InputPass[playerid][8], 1);
PlayerTextDrawSetProportional(playerid, InputPass[playerid][8], 1);
PlayerTextDrawSetSelectable(playerid, InputPass[playerid][8], true);

InputPass[playerid][9] = CreatePlayerTextDraw(playerid, 240.999938, 206.119720, "1");
PlayerTextDrawLetterSize(playerid, InputPass[playerid][9], 0.449999, 1.600000);
PlayerTextDrawAlignment(playerid, InputPass[playerid][9], 1);
PlayerTextDrawColor(playerid, InputPass[playerid][9], -1);
PlayerTextDrawSetShadow(playerid, InputPass[playerid][9], 0);
PlayerTextDrawSetOutline(playerid, InputPass[playerid][9], 1);
PlayerTextDrawBackgroundColor(playerid, InputPass[playerid][9], 51);
PlayerTextDrawFont(playerid, InputPass[playerid][9], 1);
PlayerTextDrawSetProportional(playerid, InputPass[playerid][9], 1);
PlayerTextDrawSetSelectable(playerid, InputPass[playerid][9], true);

InputPass[playerid][10] = CreatePlayerTextDraw(playerid, 286.000000, 324.346343, "0");
PlayerTextDrawLetterSize(playerid, InputPass[playerid][10], 0.449999, 1.600000);
PlayerTextDrawAlignment(playerid, InputPass[playerid][10], 1);
PlayerTextDrawColor(playerid, InputPass[playerid][10], -1);
PlayerTextDrawSetShadow(playerid, InputPass[playerid][10], 0);
PlayerTextDrawSetOutline(playerid, InputPass[playerid][10], 1);
PlayerTextDrawBackgroundColor(playerid, InputPass[playerid][10], 51);
PlayerTextDrawFont(playerid, InputPass[playerid][10], 1);
PlayerTextDrawSetProportional(playerid, InputPass[playerid][10], 1);
PlayerTextDrawSetSelectable(playerid, InputPass[playerid][10], true);
when i want to select a number it will hover all over the other numbers , and yes i searched on the forum i think it's about PlayerTextDrawTextSize , i added this to codes to but now it will just hover on "3" and some where "3" + "Enter" ! what should i do? can you please edit this for me?

i put this under them : PlayerTextDrawTextSize(playerid, InputPass[playerid][...], 100.000000,20.00000);
Reply
#2

Use iPLEOMAX`s Textdraw Editor to set the correct size.
Reply
#3

Already using ipleomax editor, created this txtdraws with that it will not set their size automaticlly
Reply
#4

Hello PoniStar, first of all put the "PlayerTextDrawTextSize" in your code, do not need to use iPLEOMAX (really do not recommend it, but it is possible) you can do manually, as an example I did in your TXD:

PHP код:
InputPass[playerid][0] = CreatePlayerTextDraw(playerid379.199829253.119934"ENTER");
PlayerTextDrawLetterSize(playeridInputPass[playerid][0], 0.3635993.899734);
PlayerTextDrawTextSize(playeridInputPass[playerid][0], 390.00000010.000000);
PlayerTextDrawAlignment(playeridInputPass[playerid][0], 2);
PlayerTextDrawColor(playeridInputPass[playerid][0], -1);
PlayerTextDrawSetShadow(playeridInputPass[playerid][0], 0);
PlayerTextDrawSetOutline(playeridInputPass[playerid][0], 1);
PlayerTextDrawBackgroundColor(playeridInputPass[playerid][0], 51);
PlayerTextDrawFont(playeridInputPass[playerid][0], 1);
PlayerTextDrawSetProportional(playeridInputPass[playerid][0], 1);
PlayerTextDrawSetSelectable(playeridInputPass[playerid][0], true); 
In those times I've been working with TXD's I realized one thing, I do not know why but it always works:
TextDrawSize X parameter has to be higher than textdraw's X position (So less than 379 is not correct).

Put and test your game, see how it went, and report back to us.
Reply
#5

Quote:
Originally Posted by ApolloScripter
Посмотреть сообщение
Hello PoniStar, first of all put the "PlayerTextDrawTextSize" in your code, do not need to use iPLEOMAX (really do not recommend it, but it is possible) you can do manually, as an example I did in your TXD:

PHP код:
InputPass[playerid][0] = CreatePlayerTextDraw(playerid379.199829253.119934"ENTER");
PlayerTextDrawLetterSize(playeridInputPass[playerid][0], 0.3635993.899734);
PlayerTextDrawTextSize(playeridInputPass[playerid][0], 390.00000010.000000);
PlayerTextDrawAlignment(playeridInputPass[playerid][0], 2);
PlayerTextDrawColor(playeridInputPass[playerid][0], -1);
PlayerTextDrawSetShadow(playeridInputPass[playerid][0], 0);
PlayerTextDrawSetOutline(playeridInputPass[playerid][0], 1);
PlayerTextDrawBackgroundColor(playeridInputPass[playerid][0], 51);
PlayerTextDrawFont(playeridInputPass[playerid][0], 1);
PlayerTextDrawSetProportional(playeridInputPass[playerid][0], 1);
PlayerTextDrawSetSelectable(playeridInputPass[playerid][0], true); 
In those times I've been working with TXD's I realized one thing, I do not know why but it always works:
TextDrawSize X parameter has to be higher than textdraw's X position (So less than 379 is not correct).

Put and test your game, see how it went, and report back to us.
Thnx i will try that !
Reply
#6

Worked! Thnx +rep
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)