20.02.2017, 20:37
Hello, so with a friend of mine we've decided to script a small race server, and we have decided to do the registration/login system with textdraws, as we have created the textdraws and made the needed ones selectable we've noticed that, the selections are very bugged!
So here's a picture of the textdraws:
So the arrows should be selectable and are actually the only ones that work correctly, the "Enter password here" should work but it's not, and same goes for the Register box and the Cancel box, so here's our code:
So the deal is that if I add PlayerTextDrawTextSize, the textdraw is no longer selectable, while when I remove it the textdraw is selectable BUT in all of the bottom right part of the textdraw that should be selectable..
I have ******d everything "textdraw offset bug" , "PlayerTextDrawTextSize problem", "textdraw selection problem", went on the samp wiki but I simply can't find the solution to this problem and so with that I would like to ask you, if you would help us out with this problem!
Thank you
EDIT: We have fixed it, the problem was that we had 0.0 on PlayerTextDrawSize
So here's a picture of the textdraws:
So the arrows should be selectable and are actually the only ones that work correctly, the "Enter password here" should work but it's not, and same goes for the Register box and the Cancel box, so here's our code:
pawn Код:
// Arrows
Register_PTD[playerid][5] = CreatePlayerTextDraw(playerid, 272.033508, 274.051879, "LD_BEAT:right");
PlayerTextDrawLetterSize(playerid, Register_PTD[playerid][5], 0.000000, 0.000000);
PlayerTextDrawTextSize(playerid, Register_PTD[playerid][5], 13.000000, 13.000000);
PlayerTextDrawAlignment(playerid, Register_PTD[playerid][5], 1);
PlayerTextDrawColor(playerid, Register_PTD[playerid][5], -1);
PlayerTextDrawSetShadow(playerid, Register_PTD[playerid][5], 0);
PlayerTextDrawSetOutline(playerid, Register_PTD[playerid][5], 0);
PlayerTextDrawBackgroundColor(playerid, Register_PTD[playerid][5], 255);
PlayerTextDrawFont(playerid, Register_PTD[playerid][5], 4);
PlayerTextDrawSetProportional(playerid, Register_PTD[playerid][5], 0);
PlayerTextDrawSetShadow(playerid, Register_PTD[playerid][5], 0);
PlayerTextDrawSetSelectable(playerid, Register_PTD[playerid][5], true);
Register_PTD[playerid][6] = CreatePlayerTextDraw(playerid, 216.530120, 274.051879, "LD_BEAT:left");
PlayerTextDrawLetterSize(playerid, Register_PTD[playerid][6], 0.000000, 0.000000);
PlayerTextDrawTextSize(playerid, Register_PTD[playerid][6], 13.000000, 13.000000);
PlayerTextDrawAlignment(playerid, Register_PTD[playerid][6], 1);
PlayerTextDrawColor(playerid, Register_PTD[playerid][6], -1);
PlayerTextDrawSetShadow(playerid, Register_PTD[playerid][6], 0);
PlayerTextDrawSetOutline(playerid, Register_PTD[playerid][6], 0);
PlayerTextDrawBackgroundColor(playerid, Register_PTD[playerid][6], 255);
PlayerTextDrawFont(playerid, Register_PTD[playerid][6], 4);
PlayerTextDrawSetProportional(playerid, Register_PTD[playerid][6], 0);
PlayerTextDrawSetShadow(playerid, Register_PTD[playerid][6], 0);
PlayerTextDrawSetSelectable(playerid, Register_PTD[playerid][6], true);
// Enter Pass..
Register_PTD[playerid][17] = CreatePlayerTextDraw(playerid, 299.933441, 202.217575, "Enter_password_here");
PlayerTextDrawLetterSize(playerid, Register_PTD[playerid][17], 0.160999, 0.815999);
PlayerTextDrawTextSize(playerid, Register_PTD[playerid][17], 410.000000, 0.079998);
PlayerTextDrawAlignment(playerid, Register_PTD[playerid][17], 1);
PlayerTextDrawColor(playerid, Register_PTD[playerid][17], -1);
PlayerTextDrawUseBox(playerid, Register_PTD[playerid][17], 1);
PlayerTextDrawBoxColor(playerid, Register_PTD[playerid][17], 0);
PlayerTextDrawSetShadow(playerid, Register_PTD[playerid][17], 0);
PlayerTextDrawSetOutline(playerid, Register_PTD[playerid][17], 1);
PlayerTextDrawBackgroundColor(playerid, Register_PTD[playerid][17], 255);
PlayerTextDrawFont(playerid, Register_PTD[playerid][17], 2);
PlayerTextDrawSetProportional(playerid, Register_PTD[playerid][17], 1);
PlayerTextDrawSetShadow(playerid, Register_PTD[playerid][17], 0);
PlayerTextDrawSetSelectable(playerid, Register_PTD[playerid][17], true);
// Register box
Register_PTD[playerid][18] = CreatePlayerTextDraw(playerid, 304.366119, 247.205764, "box");
PlayerTextDrawLetterSize(playerid, Register_PTD[playerid][18], 0.000000, 1.917999);
PlayerTextDrawTextSize(playerid, Register_PTD[playerid][18], 343.999816, 0.000000);
PlayerTextDrawAlignment(playerid, Register_PTD[playerid][18], 1);
PlayerTextDrawColor(playerid, Register_PTD[playerid][18], -1);
PlayerTextDrawUseBox(playerid, Register_PTD[playerid][18], 1);
PlayerTextDrawBoxColor(playerid, Register_PTD[playerid][18], -1061109505);
PlayerTextDrawSetShadow(playerid, Register_PTD[playerid][18], 0);
PlayerTextDrawSetOutline(playerid, Register_PTD[playerid][18], 0);
PlayerTextDrawBackgroundColor(playerid, Register_PTD[playerid][18], 255);
PlayerTextDrawFont(playerid, Register_PTD[playerid][18], 1);
PlayerTextDrawSetProportional(playerid, Register_PTD[playerid][18], 1);
PlayerTextDrawSetShadow(playerid, Register_PTD[playerid][18], 0);
PlayerTextDrawSetSelectable(playerid, Register_PTD[playerid][18], true);
// Cancel box
Register_PTD[playerid][19] = CreatePlayerTextDraw(playerid, 367.534179, 247.205764, "box");
PlayerTextDrawLetterSize(playerid, Register_PTD[playerid][19], 0.000000, 1.917999);
PlayerTextDrawTextSize(playerid, Register_PTD[playerid][19], 406.000000, 0.000000);
PlayerTextDrawAlignment(playerid, Register_PTD[playerid][19], 1);
PlayerTextDrawColor(playerid, Register_PTD[playerid][19], -1);
PlayerTextDrawUseBox(playerid, Register_PTD[playerid][19], 1);
PlayerTextDrawBoxColor(playerid, Register_PTD[playerid][19], -1061109505);
PlayerTextDrawSetShadow(playerid, Register_PTD[playerid][19], 0);
PlayerTextDrawSetOutline(playerid, Register_PTD[playerid][19], 0);
PlayerTextDrawBackgroundColor(playerid, Register_PTD[playerid][19], 255);
PlayerTextDrawFont(playerid, Register_PTD[playerid][19], 1);
PlayerTextDrawSetProportional(playerid, Register_PTD[playerid][19], 1);
PlayerTextDrawSetShadow(playerid, Register_PTD[playerid][19], 0);
PlayerTextDrawSetSelectable(playerid, Register_PTD[playerid][19], true);
I have ******d everything "textdraw offset bug" , "PlayerTextDrawTextSize problem", "textdraw selection problem", went on the samp wiki but I simply can't find the solution to this problem and so with that I would like to ask you, if you would help us out with this problem!
Thank you
EDIT: We have fixed it, the problem was that we had 0.0 on PlayerTextDrawSize