Register questions help
#1

I want to change this questions of the register

if(RegistrationStep[playerid] > 0)
{
if(RegistrationStep[playerid] == 1)
{
if (strcmp("male", text, true) == 0)
{
PlayerInfo[playerid][pSex] = 1;
SendClientMessageEx(playerid, COLOR_YELLOW2, "Alright, so you're a male.");
SendClientMessageEx(playerid, COLOR_LIGHTRED, ""OFICIAL_COLOR"What is your date of birth? {FFFFFF}(Use dd/mm/yyyy)");
RegistrationStep[playerid] = 2;
return 0;
}
else if (strcmp("female", text, true) == 0)
{
PlayerInfo[playerid][pSex] = 2;
SendClientMessageEx(playerid, COLOR_YELLOW2, "Alright, so you're a female.");
SendClientMessageEx(playerid, COLOR_LIGHTRED, ""OFICIAL_COLOR"What is your date of birth? {FFFFFF}(Use dd/mm/yyyy)");
RegistrationStep[playerid] = 2;
return 0;
}
else
{
SendClientMessageEx(playerid, COLOR_GREEN, "Are you a male or female? Type in your choice.");
}
return 0;
}
else if(RegistrationStep[playerid] == 2)
{
new year, month,day;
getdate(year, month, day);
new DateInfo[3][20];
splits(text, DateInfo, '/');
if(year - strval(DateInfo[2]) > 100 || strval(DateInfo[2]) < 1 || strval(DateInfo[2]) >= year)
{
SendClientMessageEx(playerid, COLOR_LIGHTRED, "What is your date of birth? (Use dd/mm/yyyy)");
return 0;
}
new check = year - strval(DateInfo[2]);
if(check == year)
{
SendClientMessageEx(playerid, COLOR_GREEN, "What is your date of birth? (Use dd/mm/yyyy)");
return 0;
}
if(strval(DateInfo[1]) > month)
{
check -= 1;
}
else if(strval(DateInfo[1]) == month && strval(DateInfo[0]) > day)
{
check -= 1;
}
PlayerInfo[playerid][pAge] = check;
PlayerInfo[playerid][pOrigin] = 0;
format(string, sizeof(string), "Ok, so you are %d year old.",PlayerInfo[playerid][pAge]);
SendClientMessageEx(playerid, COLOR_YELLOW2, string);
SendClientMessageEx(playerid, COLOR_LIGHTRED, "Thanks for filling in all the information, Welcome to Meneral Ganeration Gaming Roleplay!");
//SendClientMessageEx(playerid, TEAM_CYAN, "We Hope Your Enjoy Your Stay Make Sure To Check Out Are Fourms");
RegistrationStep[playerid] = 0;
SetPlayerVirtualWorld(playerid, 0);
ClearChatbox(playerid);
SendClientMessageEx(playerid, COLOR_WHITE, "Type "OFICIAL_COLOR"/start {FFFFFF}to start playing!");
SendClientMessageEx(playerid, COLOR_WHITE, ""OFICIAL_COLOR"After entering please leave and re-enter.!");
TutStep[playerid] = 1;
InsideTut[playerid] = 1;

/*Los Santos (Camera)
Streamer_UpdateEx(playerid, 1607.0160,-1510.8218,207.443;
SetPlayerPos(playerid, 1607.0160,-1510.8218,-10.0);
SetPlayerCameraPos(playerid, 1850.1813,-1765.7552,81.9271);
SetPlayerCameraLookAt(playerid, 1607.0160,-1510.8218,207.443;
return 0;*/
}
return 0;
}




to this


if(dialogid == SEXMENU)
{
if(response)
{
if(listitem == 0) // Male
{
if(RegistrationStep[playerid] == 1)
{
PlayerInfo[playerid][pSex] = 1;
RegistrationStep[playerid] = 2;
ShowMainMenuGUI(playerid);
ShowPlayerDialog(playerid, AGEMENU, DIALOG_STYLE_LIST, "So you're a Male. Select Your IC Age","18\n19\n20\n21\n22\n23\n24\n25\n26\n27\n28\n 29\n30\n31\n32\n33\n34\n35\n36\n37\n38\n39\n40\n41 \n42\n43\n44\n45\n46\n47\n48\n49\n50\n51\n52\n53\n 54\n55\n56\n57\n58\n59\n60 ", "Select", "Cancel");
return 0;
}
}
if(listitem == 1) // Female
{
if(RegistrationStep[playerid] == 1)
{

PlayerInfo[playerid][pSex] = 2;
RegistrationStep[playerid] = 2;
ShowMainMenuGUI(playerid);
ShowPlayerDialog(playerid, AGEMENU, DIALOG_STYLE_LIST, "So you're a female. Select Your IC Age","18\n19\n20\n21\n22\n23\n24\n25\n26\n27\n28\n 29\n30\n31\n32\n33\n34\n35\n36\n37\n38\n39\n40\n41 \n42\n43\n44\n45\n46\n47\n48\n49\n50\n51\n52\n53\n 54\n55\n56\n57\n58\n59\n60 ", "Select", "Cancel");
return 0;
}
}
}
return 1;
}
/////tutorials confirmayion buy Thomasghazi//
if(dialogid == TUORILASGHAZI)
{
if(response)
{
if(listitem == 0) // Yes
{

SetPlayerVirtualWorld(playerid, 0);
ClearChatbox(playerid);
ShowTutGUIBox(playerid);
ShowTutGUIFrame(playerid, 1);
TutStep[playerid] = 1;

return 0;

}
if(listitem == 1) // No
{ HideMainMenuGUI(playerid);
SetPlayerVirtualWorld(playerid, 0);
SetPlayerInterior(playerid, 0);
ShowPlayerDialog(playerid, ICNATION, DIALOG_STYLE_LIST, "Select your IC Nation","Los Santos\nPalomino Creek ", "Spawn", "Cancel");
return 0;

}
}
return 1;
}


but can anyone change it for me plzzz and write it in the comment or send me pm on the forums


plzzz I need help in this

thnx
Reply
#2

first tip; Use [PHP] [ /PHP] for your script
Reply
#3

First use
Код:
I want to change this questions of the register

if(RegistrationStep[playerid] > 0)
{
if(RegistrationStep[playerid] == 1)
{
if (strcmp("male", text, true) == 0)
{
PlayerInfo[playerid][pSex] = 1;
SendClientMessageEx(playerid, COLOR_YELLOW2, "Alright, so you're a male.");
SendClientMessageEx(playerid, COLOR_LIGHTRED, ""OFICIAL_COLOR"What is your date of birth? {FFFFFF}(Use dd/mm/yyyy)");
RegistrationStep[playerid] = 2;
return 0;
}
else if (strcmp("female", text, true) == 0)
{
PlayerInfo[playerid][pSex] = 2;
SendClientMessageEx(playerid, COLOR_YELLOW2, "Alright, so you're a female.");
SendClientMessageEx(playerid, COLOR_LIGHTRED, ""OFICIAL_COLOR"What is your date of birth? {FFFFFF}(Use dd/mm/yyyy)");
RegistrationStep[playerid] = 2;
return 0;
}
else
{
SendClientMessageEx(playerid, COLOR_GREEN, "Are you a male or female? Type in your choice.");
}
return 0;
}
else if(RegistrationStep[playerid] == 2)
{
new year, month,day;
getdate(year, month, day);
new DateInfo[3][20];
splits(text, DateInfo, '/');
if(year - strval(DateInfo[2]) > 100 || strval(DateInfo[2]) < 1 || strval(DateInfo[2]) >= year)
{
SendClientMessageEx(playerid, COLOR_LIGHTRED, "What is your date of birth? (Use dd/mm/yyyy)");
return 0;
}
new check = year - strval(DateInfo[2]);
if(check == year)
{
SendClientMessageEx(playerid, COLOR_GREEN, "What is your date of birth? (Use dd/mm/yyyy)");
return 0;
}
if(strval(DateInfo[1]) > month)
{
check -= 1;
}
else if(strval(DateInfo[1]) == month && strval(DateInfo[0]) > day)
{
check -= 1;
}
PlayerInfo[playerid][pAge] = check;
PlayerInfo[playerid][pOrigin] = 0;
format(string, sizeof(string), "Ok, so you are %d year old.",PlayerInfo[playerid][pAge]);
SendClientMessageEx(playerid, COLOR_YELLOW2, string);
SendClientMessageEx(playerid, COLOR_LIGHTRED, "Thanks for filling in all the information, Welcome to Meneral Ganeration Gaming Roleplay!");
//SendClientMessageEx(playerid, TEAM_CYAN, "We Hope Your Enjoy Your Stay Make Sure To Check Out Are Fourms");
RegistrationStep[playerid] = 0;
SetPlayerVirtualWorld(playerid, 0);
ClearChatbox(playerid);
SendClientMessageEx(playerid, COLOR_WHITE, "Type "OFICIAL_COLOR"/start {FFFFFF}to start playing!");
SendClientMessageEx(playerid, COLOR_WHITE, ""OFICIAL_COLOR"After entering please leave and re-enter.!");
TutStep[playerid] = 1;
InsideTut[playerid] = 1;

/*Los Santos (Camera)
Streamer_UpdateEx(playerid, 1607.0160,-1510.8218,207.443;
SetPlayerPos(playerid, 1607.0160,-1510.8218,-10.0);
SetPlayerCameraPos(playerid, 1850.1813,-1765.7552,81.9271);
SetPlayerCameraLookAt(playerid, 1607.0160,-1510.8218,207.443;
return 0;*/
}
return 0;
}




to this


if(dialogid == SEXMENU)
{
if(response)
{
if(listitem == 0) // Male
{
if(RegistrationStep[playerid] == 1)
{
PlayerInfo[playerid][pSex] = 1;
RegistrationStep[playerid] = 2;
ShowMainMenuGUI(playerid);
ShowPlayerDialog(playerid, AGEMENU, DIALOG_STYLE_LIST, "So you're a Male. Select Your IC Age","18\n19\n20\n21\n22\n23\n24\n25\n26\n27\n28\n 29\n30\n31\n32\n33\n34\n35\n36\n37\n38\n39\n40\n41 \n42\n43\n44\n45\n46\n47\n48\n49\n50\n51\n52\n53\n 54\n55\n56\n57\n58\n59\n60 ", "Select", "Cancel");
return 0;
}
}
if(listitem == 1) // Female
{
if(RegistrationStep[playerid] == 1)
{

PlayerInfo[playerid][pSex] = 2;
RegistrationStep[playerid] = 2;
ShowMainMenuGUI(playerid);
ShowPlayerDialog(playerid, AGEMENU, DIALOG_STYLE_LIST, "So you're a female. Select Your IC Age","18\n19\n20\n21\n22\n23\n24\n25\n26\n27\n28\n 29\n30\n31\n32\n33\n34\n35\n36\n37\n38\n39\n40\n41 \n42\n43\n44\n45\n46\n47\n48\n49\n50\n51\n52\n53\n 54\n55\n56\n57\n58\n59\n60 ", "Select", "Cancel");
return 0;
}
}
}
return 1;
}
/////tutorials confirmayion buy Thomasghazi//
if(dialogid == TUORILASGHAZI)
{
if(response)
{
if(listitem == 0) // Yes
{

SetPlayerVirtualWorld(playerid, 0);
ClearChatbox(playerid);
ShowTutGUIBox(playerid);
ShowTutGUIFrame(playerid, 1);
TutStep[playerid] = 1;

return 0;

}
if(listitem == 1) // No
{ HideMainMenuGUI(playerid);
SetPlayerVirtualWorld(playerid, 0);
SetPlayerInterior(playerid, 0);
ShowPlayerDialog(playerid, ICNATION, DIALOG_STYLE_LIST, "Select your IC Nation","Los Santos\nPalomino Creek ", "Spawn", "Cancel");
return 0;

}
}
return 1;
}
i dont know what do you want to change explain
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)