25.12.2012, 10:04
OnGameModeInit
OnPlayerConnect
It show me the TextDraw but i cant to click him...
Код:
Textdraw0 = TextDrawCreate(560.000000, 130.000000, "."); TextDrawBackgroundColor(Textdraw0, 255); TextDrawFont(Textdraw0, 1); TextDrawLetterSize(Textdraw0, 1.800000, 23.000000); TextDrawColor(Textdraw0, -1); TextDrawSetOutline(Textdraw0, 0); TextDrawSetProportional(Textdraw0, 1); TextDrawSetShadow(Textdraw0, 1); TextDrawUseBox(Textdraw0, 1); TextDrawBoxColor(Textdraw0, 255); TextDrawTextSize(Textdraw0, 440.000000, -10.000000); TextDrawSetSelectable(Textdraw0, 1);
Код:
TextDrawShowForPlayer(playerid, Textdraw0);
Код:
public OnPlayerClickTextDraw(playerid, Text:clickedid) { if(clickedid == Textdraw0) { SendClientMessage(playerid, 0xFFFFFFAA, "You clicked on a textdraw."); CancelSelectTextDraw(playerid); } return 1; }
Код:
public OnPlayerKeyStateChange(playerid, newkeys, oldkeys) { if(newkeys == KEY_SUBMISSION) { SelectTextDraw(playerid, 0xFF4040AA); } return 1; }