Balkan SA:MP

PAWN skriptanje, gamemodovi, filterskripte, include fajlovi, mape, pluginovi => Razgovor u vezi PAWN - skriptanja => Temu započeo: virtuozo poslato April 25, 2010, 18:50:40 POSLE PODNE

Naslov: Spol, Drzava itd...
Poruka od: virtuozo poslato April 25, 2010, 18:50:40 POSLE PODNE
Ovako uradio sam login i register sistem i sada kako da uradim ono isto u dialogu Muško da biram godine itd...uradio sam to parputa al sad ne moze uc u glavu da me krhness xD
Naslov: Odg: Spol, Drzava itd...
Poruka od: iYoko poslato April 25, 2010, 18:59:07 POSLE PODNE
To je prevelika skripta da bi ti netko sad radio.
Naslov: Odg: Spol, Drzava itd...
Poruka od: virtuozo poslato April 25, 2010, 21:23:17 POSLE PODNE
PA de ak nek ima nek posta...sta vam je mrsko :S pls
Naslov: Odg: Spol, Drzava itd...
Poruka od: FullSlaSh poslato April 26, 2010, 15:04:36 POSLE PODNE
Ovo ide na kraj skoro ispod skinova od mafija/bandi/organizacija
if(RegistrationStep[playerid] > 0)
{
    if(RegistrationStep[playerid] == 1)
    {
        new idx;
    tmp = strtok(text, idx);
    if((strcmp("male", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("male")))
{
    PlayerInfo[playerid][pSex] = 1;
    SendClientMessage(playerid, COLOR_YELLOW2, "Ok, so you are a Male.");
    SendClientMessage(playerid, COLOR_LIGHTRED, "What is your birthdate? (Use dd/mm/yyyy)");
    RegistrationStep[playerid] = 2;
    return 0;
}
else if((strcmp("female", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("female")))
{
    PlayerInfo[playerid][pSex] = 2;
    SendClientMessage(playerid, COLOR_YELLOW2, "Ok, so you are a Female.");
    SendClientMessage(playerid, COLOR_LIGHTRED, "What is your birthdate? (Use dd/mm/yyyy)");
    RegistrationStep[playerid] = 2;
    return 0;
}
else
{
    SendClientMessage(playerid, COLOR_LIGHTRED, "Are you a Male or Female? (Type in what you are).");
}
return 0;
}
else if(RegistrationStep[playerid] == 2)
    {
        new year, month,day;
getdate(year, month, day);
        new DateInfo[3][20];
split(text, DateInfo, '/');
if(year - strvalEx(DateInfo[2]) > 100 || strvalEx(DateInfo[2]) < 1 || strvalEx(DateInfo[2]) >= year)
{
    SendClientMessage(playerid, COLOR_LIGHTRED, "What is your Birthdate? (Use dd/mm/yyyy)");
    return 0;
}
new check = year - strval(DateInfo[2]);
if(check == year)
{
    SendClientMessage(playerid, COLOR_LIGHTRED, "What is your Birthdate? (Use dd/mm/yyyy)");
    return 0;
}
if(strvalEx(DateInfo[1]) > month)
{
    check -= 1;
}
else if(strvalEx(DateInfo[1]) == month && strvalEx(DateInfo[0]) > day)
{
    check -= 1;
}
PlayerInfo[playerid][pAge] = check;
format(string, sizeof(string), "Ok, znaci ti imas %d godina.",PlayerInfo[playerid][pAge]);
SendClientMessage(playerid, COLOR_YELLOW2, string);
RegistrationStep[playerid] = 3;
SendClientMessage(playerid, COLOR_LIGHTRED, "Odkud si? (Napisi: Hrvatska, Bosna ili Srbija)");
return 0;
    }
    else if(RegistrationStep[playerid] == 3)
    {
        new idx;
    tmp = strtok(text, idx);
    if((strcmp("Hrvatska", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("Hrvatska")))
{
    PlayerInfo[playerid][pOrigin] = 1;
    SendClientMessage(playerid, COLOR_YELLOW2, "Ok, so you are from the Hrvatska.");
    SendClientMessage(playerid, COLOR_LIGHTRED, "Thank you for filling in all the information, now you will proceed to the Tutorial.");
RegistrationStep[playerid] = 0;
    TutTime[playerid] = 1;
    return 0;
}
else if((strcmp("Bosna", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("Bosna")))
{
    PlayerInfo[playerid][pOrigin] = 2;
    SendClientMessage(playerid, COLOR_YELLOW2, "Ok, so you are from Bosna.");
    SendClientMessage(playerid, COLOR_LIGHTRED, "Thank you for filling in all the information, now you will proceed to the Tutorial.");
RegistrationStep[playerid] = 0;
    TutTime[playerid] = 1;
    return 0;
}
else if((strcmp("Srbija", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("Srbija")))
{
    PlayerInfo[playerid][pOrigin] = 3;
    SendClientMessage(playerid, COLOR_YELLOW2, "Ok, so you are from Srbija.");
    SendClientMessage(playerid, COLOR_LIGHTRED, "Thank you for filling in all the information, now you will proceed to the Tutorial.");
RegistrationStep[playerid] = 0;
    TutTime[playerid] = 1;
    return 0;
}
else
{
    SendClientMessage(playerid, COLOR_LIGHTRED, "Odkud si? (Napisi: Hrvatska, Srbija ili Bosna)");
}
return 0;
    }
return 0;
}


Zatim ovo ubaci pod if(IsPlayerConnected(playerid))
SetPlayerToTeamColor(playerid);
if(PlayerInfo[playerid][pOrigin] == 1)//Srbija
{
    SetPlayerPos(playerid,1129.0839,-1489.7538,22.7690);
SetPlayerFacingAngle(playerid, 46.8583);
SetPlayerInterior(playerid,0);
PlayerInfo[playerid][pInt] = 0;
}
else if(PlayerInfo[playerid][pOrigin] == 2)//Hrvatska
{
    SetPlayerPos(playerid,1129.0839,-1489.7538,22.7690);
SetPlayerFacingAngle(playerid, 262.9963);
SetPlayerInterior(playerid,0);
PlayerInfo[playerid][pInt] = 0;
}
else if(PlayerInfo[playerid][pOrigin] == 3)//Bosna
{
    SetPlayerPos(playerid,1129.0839,-1489.7538,22.7690);
SetPlayerFacingAngle(playerid, 272.3543);
SetPlayerInterior(playerid,0);
PlayerInfo[playerid][pInt] = 0;
}
else
{
rand = random(sizeof(gRandomPlayerSpawns));
SetPlayerPos(playerid, gRandomPlayerSpawns[rand][0], gRandomPlayerSpawns[rand][1], gRandomPlayerSpawns[rand][2]); // Warp the player
SetPlayerFacingAngle(playerid, 270.0);
SetPlayerInterior(playerid,15);
PlayerInfo[playerid][pInt] = 15;
}
return 1;
}
return 1;
}



Mozda sam nesto izostavio al ak si vec radio skuzit ces  ;)
Naslov: Odg: Spol, Drzava itd...
Poruka od: virtuozo poslato April 26, 2010, 15:46:52 POSLE PODNE
ne to xD...u dialogu da je uradjeno...:D
Naslov: Odg: Spol, Drzava itd...
Poruka od: r4z0r poslato April 26, 2010, 16:00:58 POSLE PODNE
Pa samo transformisi , 'oces i muzicku ?
Procitaj par puta za sto sluzimo , nismo ti obavezni dati gotovu scriptu .
Naslov: Odg: Spol, Drzava itd...
Poruka od: iYoko poslato April 27, 2010, 08:24:26 PRE PODNE
Cek ti oces to dosdat u GF Mode?
Naslov: Odg: Spol, Drzava itd...
Poruka od: [ED] ZicMortal poslato April 27, 2010, 08:39:18 PRE PODNE
Ak znas napravit dialog znat ces i to, nitko ti nece dat gotovu skriptu