12.06.2014, 16:16
try to add this at the bottom of gamemode init
and you should also have this
Код:
TextDrawSetSelectable(Login_Textdraw11, true); TextDrawSetSelectable(Login_Textdraw10, true); TextDrawSetSelectable(Login_Textdraw9, true); TextDrawSetSelectable(Login_Textdraw7, true); TextDrawSetSelectable(Login_Textdraw8, true);
Код:
public OnPlayerClickTextDraw(playerid, Text:clickedid) { if(_:clickedid != INVALID_TEXT_DRAW) // If the player clicked a valid textdraw, continue with the coding. (_:var removes the Text: tag, to avoid tag mismatch) { if(clickedid == Login_Textdraw11) { //write what you want the script to do when the click on the dialog } else if(clickedid == Login_Textdraw10) { //write what you want the script to do when the click on the dialog } else if(clickedid == Login_Textdraw9) { //write what you want the script to do when the click on the dialog } else if(clickedid == Login_Textdraw8) { //write what you want the script to do when the click on the dialog } else if(clickedid == Login_Textdraw7) { //write what you want the script to do when the click on the dialog } TextDrawHideForPlayer(playerid, Login_Textdraw11); TextDrawHideForPlayer(playerid, Login_Textdraw10); TextDrawHideForPlayer(playerid, Login_Textdraw9); TextDrawHideForPlayer(playerid, Login_Textdraw8); TextDrawHideForPlayer(playerid, Login_Textdraw7); CancelSelectTextDraw(playerid); // This will indeed call OnPlayerClickTextDraw again, but with an ID of 65535. The code above stops it from resulting in an eternal loop. } return 1; }