Jump to content

Recommended Posts

Posted

Salut, de vreo 2 zile incerc sa fac un sistem loto
si imi da cu virgula ceva nu merg gen daca le fac clickable sa pot fi apasate 
pun asa: (butonul de iesire din meniu de loto)
 

public OnPlayerClickPlayerTextDraw(playerid, PlayerText:playertextid)
{
	if(playertextid == PlayerTD[playerid][15]) {
		PlayerTextDrawHide(playerid, PlayerTD[playerid][3]);
		PlayerTextDrawHide(playerid, PlayerTD[playerid][4]);
		PlayerTextDrawHide(playerid, PlayerTD[playerid][5]);
		PlayerTextDrawHide(playerid, PlayerTD[playerid][6]);
		PlayerTextDrawHide(playerid, PlayerTD[playerid][7]);
		PlayerTextDrawHide(playerid, PlayerTD[playerid][8]);
		PlayerTextDrawHide(playerid, PlayerTD[playerid][9]);
		PlayerTextDrawHide(playerid, PlayerTD[playerid][10]);
		PlayerTextDrawHide(playerid, PlayerTD[playerid][11]);
		PlayerTextDrawHide(playerid, PlayerTD[playerid][12]);
		PlayerTextDrawHide(playerid, PlayerTD[playerid][13]);
		PlayerTextDrawHide(playerid, PlayerTD[playerid][14]);
		PlayerTextDrawHide(playerid, PlayerTD[playerid][15]);
	}
	return 1;
}

si gen nu merge apasat 
 

PlayerTextDrawSetSelectable(playerid, PlayerTD[playerid][15], 1);

am pus si asta la fiecare (fiecare cu nr lui din [])
si tot nu inteleg am incercat prin n moduri

Posted (edited)

PlayerTD[playerid][15] = CreatePlayerTextDraw(playerid, 416.000000, 104.000000, "X");
    PlayerTextDrawFont(playerid, PlayerTD[playerid][15], 3);
    PlayerTextDrawLetterSize(playerid, PlayerTD[playerid][15], 0.600000, 2.000000);
    PlayerTextDrawTextSize(playerid, PlayerTD[playerid][15], 400.000000, 17.000000);
    PlayerTextDrawSetOutline(playerid, PlayerTD[playerid][15], 1);
    PlayerTextDrawSetShadow(playerid, PlayerTD[playerid][15], 0);
    PlayerTextDrawAlignment(playerid, PlayerTD[playerid][15], 1);
    PlayerTextDrawColor(playerid, PlayerTD[playerid][15], -16776961);
    PlayerTextDrawBackgroundColor(playerid, PlayerTD[playerid][15], 255);
    PlayerTextDrawBoxColor(playerid, PlayerTD[playerid][15], 50);
    PlayerTextDrawUseBox(playerid, PlayerTD[playerid][15], 0);
    PlayerTextDrawSetProportional(playerid, PlayerTD[playerid][15], 1);
    PlayerTextDrawSetSelectable(playerid, PlayerTD[playerid][15], 1);

10 minutes ago, ionut1337adv said:

vezi daca PlayerTD[playerid][15] este selectabil

 

PlayerTextDrawSetSelectable(playerid,PlayerTD[playerid][15], 1); << - asa ar trebui sa fie

degeaba, nu merge

@ionut1337adv

Edited by Divil.Scorpiono
Posted

logic:

public OnPlayerCommandText(playerid, cmdtext[])
{
    if(!strcmp(cmdtext, "/lotto", true))
    {
        PlayerTextDrawShow(playerid, PlayerTD[playerid][2]);
        PlayerTextDrawShow(playerid, PlayerTD[playerid][3]);
        PlayerTextDrawShow(playerid, PlayerTD[playerid][4]);
        PlayerTextDrawShow(playerid, PlayerTD[playerid][5]);
        PlayerTextDrawShow(playerid, PlayerTD[playerid][6]);
        PlayerTextDrawShow(playerid, PlayerTD[playerid][7]);
        PlayerTextDrawShow(playerid, PlayerTD[playerid][8]);
        PlayerTextDrawShow(playerid, PlayerTD[playerid][9]);
        PlayerTextDrawShow(playerid, PlayerTD[playerid][10]);
        PlayerTextDrawShow(playerid, PlayerTD[playerid][11]);
        PlayerTextDrawShow(playerid, PlayerTD[playerid][12]);
        PlayerTextDrawShow(playerid, PlayerTD[playerid][13]);
        PlayerTextDrawShow(playerid, PlayerTD[playerid][14]);
        PlayerTextDrawShow(playerid, PlayerTD[playerid][15]);
        SelectTextDraw(playerid, 0xFF0000FF);
        return 1;
    }
    return 1;
}

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more details you can also review our Terms of Use and Privacy Policy.