07.08.2010, 20:23
i want to change this dcmd from text to dialog input
and i want it like this dialogs
dialog button next and button cancel
button next show the after dialog and this you know how
Код:
dcmd_0(playerid, params[]) { #pragma unused params dini_Create(file); dini_Set(file, "Name" , pname); TogglePlayerControllable(playerid, 0); SetCameraBehindPlayer(playerid); SendClientMessage(playerid, green,"Are you Male or Female ? (/1 [male] [female])"); return 1; } dcmd_1(playerid, params[]) { if(!strlen(params)) return SendClientMessage(playerid, red, "USAGE: (/1 [male] [female])"); dini_Set(file, "Gender", params); new string[128]; format(string, sizeof(string), "Ok, so you are %s.", params); SendClientMessage(playerid, green,string); SendClientMessage(playerid, green," "); SendClientMessage(playerid, green,"What's your age ? (/2 [Age])"); return 1; } dcmd_2(playerid, params[]) { if(!strlen(params)) return SendClientMessage(playerid, red, "USAGE: /2 [age]"); dini_Set(file, "Age", params); new string[128]; format(string, sizeof(string), "Ok, so you are %s years old.", params); SendClientMessage(playerid, green,string); SendClientMessage(playerid, green," "); SendClientMessage(playerid, green, "Ok. Where do you live ? (/3 [Country's name])"); return 1; } dcmd_3(playerid, params[]) { if(!strlen(params)) return SendClientMessage(playerid, red, "USAGE: (/3 [Country's name])"); dini_Set(file, "Country", params); new string[128]; format(string, sizeof(string), "Ok, so you live in %s.", params); SendClientMessage(playerid, green,string); SendClientMessage(playerid, green," "); SendClientMessage(playerid, green, "How will you deal a Cheater/Hacker ? (/4 [Message])"); return 1; } dcmd_4(playerid, params[]) { if(!strlen(params)) return SendClientMessage(playerid, red, "USAGE: (/4 [Message])"); dini_Set(file, "Dealing with Cheaters", params); SendClientMessage(playerid, green," "); SendClientMessage(playerid, green, "Ok, Why would you like to be a Administrator ? (/5 [Reason])"); return 1; } dcmd_5(playerid, params[]) { if(!strlen(params)) return SendClientMessage(playerid, red, "USAGE: (/5 [Reason])"); dini_Set(file, "Reason", params); SendClientMessage(playerid, green," "); SendClientMessage(playerid, green, "Ok, Thankyou. That was all the information we need right now!"); SendClientMessage(playerid, blue, "It might take some time, so please be patient!"); TogglePlayerControllable(playerid, 1); return 1; }
dialog button next and button cancel
button next show the after dialog and this you know how