04.04.2012, 17:58
Hello here is my problem ::
after I connect and fill in my age & sex info. it kicks me here is the code::
after I connect and fill in my age & sex info. it kicks me here is the code::
Код:
if(dialogid == DIALOG_AGE) { if(!response) { Kick(playerid); } else { if(strlen(inputtext)) { new age = strval(inputtext); if(age > 100 || age < 16) { ShowPlayerDialog(playerid, DIALOG_AGE, DIALOG_STYLE_INPUT, "Age ","How old are you?\n{FF0000}(( 16 - 100 ))","Answer","Quit"); } else { PlayerInfo[playerid][pAge] = age; new string[ 64 ] ; format(string, sizeof(string), "INFO: You're {3BB9FF}%d years old.",age); SendClientMessage(playerid, -1, string); SpawnPlayer(playerid); new file[100]; dini_Create(file); dini_IntSet(file, "SEX",PlayerInfo[playerid][pSex]); dini_IntSet(file, "AGE",PlayerInfo[playerid][pAge]); } } else { return 0; } } } if(dialogid == DIALOG_SEX) { if(!response) { Kick(playerid); } if(strlen(inputtext)) { PlayerInfo[playerid][pSex] = 1; SendClientMessage(playerid, -1, "INFO: You are {3BB9FF}male."); ShowPlayerDialog(playerid, DIALOG_SPAWN, DIALOG_STYLE_LIST, "Select Your Shelter", "Grove Street\nJefferson Motel\nMarket Station","Select","Quit"); SetPlayerSkin(playerid, 60); PlayerInfo[playerid][pSkin] = 60; ShowPlayerDialog(playerid, DIALOG_AGE, DIALOG_STYLE_INPUT, "- Age -","How old are you??\n{FF0000}(( 16 - 100 ))","Answer","Quit"); } else { PlayerInfo[playerid][pSex] = 2; SendClientMessage(playerid, -1, "INFO: You are {3BB9FF}female."); ShowPlayerDialog(playerid, DIALOG_SPAWN, DIALOG_STYLE_LIST, "Select Your Shelter", "Grove Street\nJefferson Motel\nMarket Station","Select","Quit"); SetPlayerSkin(playerid, 233); PlayerInfo[playerid][pSkin] = 233; ShowPlayerDialog(playerid, DIALOG_AGE, DIALOG_STYLE_INPUT, "- Age -","How old are you??\n{FF0000}(( 16 - 100 ))","Answer","Quit"); } }