24.10.2011, 13:11
(
Последний раз редактировалось Cr4zyR0d; 24.10.2011 в 13:43.
)
pawn Код:
public OnPlayerText(playerid, text[])
{
ApplyAnimation(playerid,"PED","IDLE_CHAT",4.1,1,1,1,1,1);
{
return 0;
}
if(FindIP(text)) return kick4IP(playerid, text);
new sendername[MAX_PLAYER_NAME];
new giveplayer[MAX_PLAYER_NAME];
new tmp[128];
new string[128];
if(PlayerInfo[playerid][pHospital] == 1 || CanTalk[playerid] == 0)
{
return 0;
}
if(PlayerInfo[playerid][pMuted] == 1)
{
SendClientMessage(playerid, COLOR_GREY, "You can't speak, you're muted.");
return 0;
}
if(IsPlayerInRangeOfPoint(playerid, 15.0, NPCX, NPCY, NPCZ) || IsPlayerInRangeOfPoint(playerid, 15.0, NPCXX, NPCYY, NPCZZ) || IsPlayerInRangeOfPoint(playerid, 15.0, NPCXXX, NPCYYY, NPCZZZ) || IsPlayerInRangeOfPoint(playerid, 15.0, NPCXXXX, NPCYYYY, NPCZZZZ) || IsPlayerInRangeOfPoint(playerid, 15.0, NPCXXXXX, NPCYYYYY, NPCZZZZZ))
{
new newnpc;
new npcname[MAX_PLAYER_NAME];
new playaname[MAX_PLAYER_NAME];
GetPlayerName(playerid, playaname, sizeof(playaname));
newnpc = GetClosestPlayer(playerid);
new idx;
tmp = strtok(text, idx);
if(IsPlayerNPC(newnpc))
{
GetPlayerName(newnpc, npcname, sizeof(npcname));
if((strcmp("hello", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("hello")))
{
new sstring[128];
format(sstring, sizeof(sstring), "Bus Driver says: Good day to you too.");
ProxDetector(30.0, playerid, sstring, COLOR_GRAD2,COLOR_GRAD2,COLOR_GRAD2,COLOR_GRAD2,COLOR_GRAD2);
return 0;
}
if((strcmp("Help", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("Help")))
{
new sstring[128];
format(sstring, sizeof(sstring), "Bus Driver says: Oh god? What's wrong? Should I call 911?!");
HasAsked[playerid] = 1;
ProxDetector(30.0, playerid, sstring, COLOR_GRAD2,COLOR_GRAD2,COLOR_GRAD2,COLOR_GRAD2,COLOR_GRAD2);
return 0;
}
if((strcmp("good", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("good")))
{
new sstring[128];
format(sstring, sizeof(sstring), "Bus Driver says: Great!");
ProxDetector(30.0, playerid, sstring, COLOR_GRAD2,COLOR_GRAD2,COLOR_GRAD2,COLOR_GRAD2,COLOR_GRAD2);
return 0;
}
if((strcmp("fuck", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("fuck")))
{
new sstring[128];
format(sstring, sizeof(sstring), "Bus Driver says: Please watch the language.");
ProxDetector(30.0, playerid, sstring, COLOR_GRAD2,COLOR_GRAD2,COLOR_GRAD2,COLOR_GRAD2,COLOR_GRAD2);
return 0;
}
if((strcmp("call", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("call")))
{
if(HasAsked[playerid] == 1)
{
new sstring[128];
new ssstring[128];
format(sstring, sizeof(sstring), "Bus Driver says: I called the paramedics! Be patient!");
format(ssstring, sizeof(ssstring), "All units: %s has called us. Please respond to him. Injured citizen: %s", npcname, playaname);
SendParaMessage(COLOR_RED, ssstring);
ProxDetector(30.0, playerid, sstring, COLOR_GRAD2, COLOR_GRAD2, COLOR_GRAD2,COLOR_GRAD2,COLOR_GRAD2);
}
else if(HasAsked[playerid] == 0)
{
new sstring[128];
format(sstring, sizeof(sstring), "Bus Driver says: Call who?");
ProxDetector(30.0, playerid, sstring, COLOR_GRAD2, COLOR_GRAD2, COLOR_GRAD2, COLOR_GRAD2, COLOR_GRAD2);
}
}
}
}
if(IsPlayerInRangeOfPoint(playerid, 10.0, NPCXXXXXX, NPCYYYYYY, NPCZZZZZZ) || IsPlayerInRangeOfPoint(playerid, 10.0, NPCXXXXXXX, NPCYYYYYYY, NPCZZZZZZZ) || IsPlayerInRangeOfPoint(playerid, 10.0, NPCXXXXXXXX, NPCYYYYYYYY, NPCZZZZZZZZ))
{
new newnpc;
new npcname[MAX_PLAYER_NAME];
new playaname[MAX_PLAYER_NAME];
GetPlayerName(playerid, playaname, sizeof(playaname));
newnpc = GetClosestPlayer(playerid);
new idx;
tmp = strtok(text, idx);
if(IsPlayerNPC(newnpc))
{
GetPlayerName(newnpc, npcname, sizeof(npcname));
if((strcmp("hello", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("hello")))
{
new sstring[128];
format(sstring, sizeof(sstring), "Taxi Driver says: Good day.");
ProxDetector(30.0, playerid, sstring, COLOR_GRAD2,COLOR_GRAD2,COLOR_GRAD2,COLOR_GRAD2,COLOR_GRAD2);
return 0;
}
if((strcmp("Help", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("Help")))
{
new sstring[128];
format(sstring, sizeof(sstring), "Taxi Driver says: Oh god? What's wrong? Should I call 911?!");
HasAsked[playerid] = 1;
ProxDetector(30.0, playerid, sstring, COLOR_GRAD2,COLOR_GRAD2,COLOR_GRAD2,COLOR_GRAD2,COLOR_GRAD2);
return 0;
}
if((strcmp("good", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("good")))
{
new sstring[128];
format(sstring, sizeof(sstring), "Taxi Driver says: Great!");
ProxDetector(30.0, playerid, sstring, COLOR_GRAD2,COLOR_GRAD2,COLOR_GRAD2,COLOR_GRAD2,COLOR_GRAD2);
return 0;
}
if((strcmp("fuck", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("fuck")))
{
new sstring[128];
format(sstring, sizeof(sstring), "Taxi Driver says: Please watch the language.");
ProxDetector(30.0, playerid, sstring, COLOR_GRAD2,COLOR_GRAD2,COLOR_GRAD2,COLOR_GRAD2,COLOR_GRAD2);
return 0;
}
if((strcmp("call", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("call")))
{
if(HasAsked[playerid] == 1)
{
new sstring[128];
new ssstring[128];
format(sstring, sizeof(sstring), "Taxi Driver says: I called the paramedics! Be patient!");
format(ssstring, sizeof(ssstring), "All units: %s has called us. Please respond to him. Injured citizen: %s", npcname, playaname);
SendParaMessage(COLOR_RED, ssstring);
ProxDetector(30.0, playerid, sstring, COLOR_GRAD2, COLOR_GRAD2, COLOR_GRAD2,COLOR_GRAD2,COLOR_GRAD2);
}
else if(HasAsked[playerid] == 0)
{
new sstring[128];
format(sstring, sizeof(sstring), "Bus Driver says: Call who?");
ProxDetector(30.0, playerid, sstring, COLOR_GRAD2, COLOR_GRAD2, COLOR_GRAD2, COLOR_GRAD2, COLOR_GRAD2);
}
}
}
}
if(SelectChar[playerid] == 255)
{
new idx;
tmp = strtok(text, idx);
if((strcmp("next", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("next")))
{
switch (SelectCharID[playerid])
{
case 1: //Police Force
{
if(SelectCharPlace[playerid] == 1) { SetPlayerSkin(playerid, FactSkins1[0][0]); SelectCharPlace[playerid] = 2; ChosenSkin[playerid] = FactSkins1[0][0]; }
else if(SelectCharPlace[playerid] == 2) { SetPlayerSkin(playerid, FactSkins1[1][0]); SelectCharPlace[playerid] = 3; ChosenSkin[playerid] = FactSkins1[1][0]; }
else if(SelectCharPlace[playerid] == 3) { SetPlayerSkin(playerid, FactSkins1[2][0]); SelectCharPlace[playerid] = 4; ChosenSkin[playerid] = FactSkins1[2][0]; }
else if(SelectCharPlace[playerid] == 4) { SetPlayerSkin(playerid, FactSkins1[3][0]); SelectCharPlace[playerid] = 5; ChosenSkin[playerid] = FactSkins1[3][0]; }
else if(SelectCharPlace[playerid] == 5) { SetPlayerSkin(playerid, FactSkins1[4][0]); SelectCharPlace[playerid] = 6; ChosenSkin[playerid] = FactSkins1[4][0]; }
else if(SelectCharPlace[playerid] == 6) { SetPlayerSkin(playerid, FactSkins1[5][0]); SelectCharPlace[playerid] = 7; ChosenSkin[playerid] = FactSkins1[5][0]; }
else if(SelectCharPlace[playerid] == 7) { SetPlayerSkin(playerid, FactSkins1[6][0]); SelectCharPlace[playerid] = 8; ChosenSkin[playerid] = FactSkins1[6][0]; }
else if(SelectCharPlace[playerid] == 8) { SetPlayerSkin(playerid, FactSkins1[7][0]); SelectCharPlace[playerid] = 9; ChosenSkin[playerid] = FactSkins1[7][0]; }
else if(SelectCharPlace[playerid] == 9) { SetPlayerSkin(playerid, FactSkins1[8][0]); SelectCharPlace[playerid] = 10; ChosenSkin[playerid] = FactSkins1[8][0]; }
else if(SelectCharPlace[playerid] == 10) { SetPlayerSkin(playerid, FactSkins1[9][0]); SelectCharPlace[playerid] = 11; ChosenSkin[playerid] = FactSkins1[9][0]; }
else if(SelectCharPlace[playerid] == 11) { SetPlayerSkin(playerid, FactSkins1[10][0]); SelectCharPlace[playerid] = 1; ChosenSkin[playerid] = FactSkins1[10][0]; }
}
case 2: //FBI
{
if(SelectCharPlace[playerid] == 1) { SetPlayerSkin(playerid, FactSkins2[0][0]); SelectCharPlace[playerid] = 2; ChosenSkin[playerid] = FactSkins2[0][0]; }
else if(SelectCharPlace[playerid] == 2) { SetPlayerSkin(playerid, FactSkins2[1][0]); SelectCharPlace[playerid] = 3; ChosenSkin[playerid] = FactSkins2[1][0]; }
else if(SelectCharPlace[playerid] == 3) { SetPlayerSkin(playerid, FactSkins2[2][0]); SelectCharPlace[playerid] = 1; ChosenSkin[playerid] = FactSkins2[2][0]; }
}
case 3: //Sheriffs Department
{
if(SelectCharPlace[playerid] == 1) { SetPlayerSkin(playerid, FactSkins3[0][0]); SelectCharPlace[playerid] = 2; ChosenSkin[playerid] = FactSkins3[0][0]; }
else if(SelectCharPlace[playerid] == 2) { SetPlayerSkin(playerid, FactSkins3[1][0]); SelectCharPlace[playerid] = 3; ChosenSkin[playerid] = FactSkins3[1][0]; }
else if(SelectCharPlace[playerid] == 3) { SetPlayerSkin(playerid, FactSkins3[2][0]); SelectCharPlace[playerid] = 4; ChosenSkin[playerid] = FactSkins3[2][0]; }
else if(SelectCharPlace[playerid] == 4) { SetPlayerSkin(playerid, FactSkins3[3][0]); SelectCharPlace[playerid] = 5; ChosenSkin[playerid] = FactSkins3[3][0]; }
else if(SelectCharPlace[playerid] == 5) { SetPlayerSkin(playerid, FactSkins3[4][0]); SelectCharPlace[playerid] = 6; ChosenSkin[playerid] = FactSkins3[4][0]; }
else if(SelectCharPlace[playerid] == 6) { SetPlayerSkin(playerid, FactSkins3[5][0]); SelectCharPlace[playerid] = 1; ChosenSkin[playerid] = FactSkins3[5][0]; }
}
case 4: //Fire&Ambulance
{
if(SelectCharPlace[playerid] == 1) { SetPlayerSkin(playerid, FactSkins4[0][0]); SelectCharPlace[playerid] = 2; ChosenSkin[playerid] = FactSkins4[0][0]; }
else if(SelectCharPlace[playerid] == 2) { SetPlayerSkin(playerid, FactSkins4[1][0]); SelectCharPlace[playerid] = 3; ChosenSkin[playerid] = FactSkins4[1][0]; }
else if(SelectCharPlace[playerid] == 3) { SetPlayerSkin(playerid, FactSkins4[2][0]); SelectCharPlace[playerid] = 4; ChosenSkin[playerid] = FactSkins4[2][0]; }
else if(SelectCharPlace[playerid] == 4) { SetPlayerSkin(playerid, FactSkins4[3][0]); SelectCharPlace[playerid] = 5; ChosenSkin[playerid] = FactSkins4[3][0]; }
else if(SelectCharPlace[playerid] == 5) { SetPlayerSkin(playerid, FactSkins4[4][0]); SelectCharPlace[playerid] = 6; ChosenSkin[playerid] = FactSkins4[4][0]; }
else if(SelectCharPlace[playerid] == 6) { SetPlayerSkin(playerid, FactSkins4[5][0]); SelectCharPlace[playerid] = 1; ChosenSkin[playerid] = FactSkins4[5][0]; }
}
case 5: //National Guards
{
if(SelectCharPlace[playerid] == 1) { SetPlayerSkin(playerid, FactSkins5[0][0]); SelectCharPlace[playerid] = 2; ChosenSkin[playerid] = FactSkins5[0][0]; }
}
case 6: //Senate
{
if(SelectCharPlace[playerid] == 1) { SetPlayerSkin(playerid, FactSkins6[0][0]); SelectCharPlace[playerid] = 2; ChosenSkin[playerid] = FactSkins6[0][0]; }
else if(SelectCharPlace[playerid] == 2) { SetPlayerSkin(playerid, FactSkins6[1][0]); SelectCharPlace[playerid] = 3; ChosenSkin[playerid] = FactSkins6[1][0]; }
else if(SelectCharPlace[playerid] == 3) { SetPlayerSkin(playerid, FactSkins6[2][0]); SelectCharPlace[playerid] = 4; ChosenSkin[playerid] = FactSkins6[2][0]; }
else if(SelectCharPlace[playerid] == 4) { SetPlayerSkin(playerid, FactSkins6[3][0]); SelectCharPlace[playerid] = 5; ChosenSkin[playerid] = FactSkins6[3][0]; }
else if(SelectCharPlace[playerid] == 5) { SetPlayerSkin(playerid, FactSkins6[4][0]); SelectCharPlace[playerid] = 6; ChosenSkin[playerid] = FactSkins6[4][0]; }
else if(SelectCharPlace[playerid] == 6) { SetPlayerSkin(playerid, FactSkins6[5][0]); SelectCharPlace[playerid] = 7; ChosenSkin[playerid] = FactSkins6[5][0]; }
else if(SelectCharPlace[playerid] == 7) { SetPlayerSkin(playerid, FactSkins6[6][0]); SelectCharPlace[playerid] = 8; ChosenSkin[playerid] = FactSkins6[6][0]; }
else if(SelectCharPlace[playerid] == 8) { SetPlayerSkin(playerid, FactSkins6[7][0]); SelectCharPlace[playerid] = 1; ChosenSkin[playerid] = FactSkins6[7][0]; }
}
case 7: //SS
{
if(SelectCharPlace[playerid] == 1) { SetPlayerSkin(playerid, FactSkins7[0][0]); SelectCharPlace[playerid] = 2; ChosenSkin[playerid] = FactSkins7[0][0]; }
else if(SelectCharPlace[playerid] == 2) { SetPlayerSkin(playerid, FactSkins7[1][0]); SelectCharPlace[playerid] = 3; ChosenSkin[playerid] = FactSkins7[1][0]; }
else if(SelectCharPlace[playerid] == 3) { SetPlayerSkin(playerid, FactSkins7[2][0]); SelectCharPlace[playerid] = 1; ChosenSkin[playerid] = FactSkins7[2][0]; }
}
case 8: //Hitman Agency
{
if(SelectCharPlace[playerid] == 1) { SetPlayerSkin(playerid, FactSkins8[0][0]); SelectCharPlace[playerid] = 2; ChosenSkin[playerid] = FactSkins8[0][0]; }
else if(SelectCharPlace[playerid] == 2) { SetPlayerSkin(playerid, FactSkins8[1][0]); SelectCharPlace[playerid] = 3; ChosenSkin[playerid] = FactSkins8[1][0]; }
else if(SelectCharPlace[playerid] == 3) { SetPlayerSkin(playerid, FactSkins8[2][0]); SelectCharPlace[playerid] = 4; ChosenSkin[playerid] = FactSkins8[2][0]; }
else if(SelectCharPlace[playerid] == 4) { SetPlayerSkin(playerid, FactSkins8[3][0]); SelectCharPlace[playerid] = 5; ChosenSkin[playerid] = FactSkins8[3][0]; }
else if(SelectCharPlace[playerid] == 5) { SetPlayerSkin(playerid, FactSkins8[4][0]); SelectCharPlace[playerid] = 6; ChosenSkin[playerid] = FactSkins8[4][0]; }
else if(SelectCharPlace[playerid] == 6) { SetPlayerSkin(playerid, FactSkins8[5][0]); SelectCharPlace[playerid] = 7; ChosenSkin[playerid] = FactSkins8[5][0]; }
else if(SelectCharPlace[playerid] == 7) { SetPlayerSkin(playerid, FactSkins8[6][0]); SelectCharPlace[playerid] = 8; ChosenSkin[playerid] = FactSkins8[6][0]; }
else if(SelectCharPlace[playerid] == 8) { SetPlayerSkin(playerid, FactSkins8[7][0]); SelectCharPlace[playerid] = 9; ChosenSkin[playerid] = FactSkins8[7][0]; }
else if(SelectCharPlace[playerid] == 9) { SetPlayerSkin(playerid, FactSkins8[8][0]); SelectCharPlace[playerid] = 10; ChosenSkin[playerid] = FactSkins8[8][0]; }
else if(SelectCharPlace[playerid] == 10) { SetPlayerSkin(playerid, FactSkins8[9][0]); SelectCharPlace[playerid] = 11; ChosenSkin[playerid] = FactSkins8[9][0]; }
else if(SelectCharPlace[playerid] == 11) { SetPlayerSkin(playerid, FactSkins8[10][0]); SelectCharPlace[playerid] = 12; ChosenSkin[playerid] = FactSkins8[10][0]; }
else if(SelectCharPlace[playerid] == 12) { SetPlayerSkin(playerid, FactSkins8[11][0]); SelectCharPlace[playerid] = 13; ChosenSkin[playerid] = FactSkins8[11][0]; }
else if(SelectCharPlace[playerid] == 13) { SetPlayerSkin(playerid, FactSkins8[12][0]); SelectCharPlace[playerid] = 14; ChosenSkin[playerid] = FactSkins8[12][0]; }
else if(SelectCharPlace[playerid] == 14) { SetPlayerSkin(playerid, FactSkins8[13][0]); SelectCharPlace[playerid] = 15; ChosenSkin[playerid] = FactSkins8[13][0]; }
else if(SelectCharPlace[playerid] == 15) { SetPlayerSkin(playerid, FactSkins8[14][0]); SelectCharPlace[playerid] = 16; ChosenSkin[playerid] = FactSkins8[14][0]; }
else if(SelectCharPlace[playerid] == 16) { SetPlayerSkin(playerid, FactSkins8[15][0]); SelectCharPlace[playerid] = 17; ChosenSkin[playerid] = FactSkins8[15][0]; }
else if(SelectCharPlace[playerid] == 17) { SetPlayerSkin(playerid, FactSkins8[16][0]); SelectCharPlace[playerid] = 18; ChosenSkin[playerid] = FactSkins8[16][0]; }
else if(SelectCharPlace[playerid] == 18) { SetPlayerSkin(playerid, FactSkins8[17][0]); SelectCharPlace[playerid] = 19; ChosenSkin[playerid] = FactSkins8[17][0]; }
else if(SelectCharPlace[playerid] == 19) { SetPlayerSkin(playerid, FactSkins8[18][0]); SelectCharPlace[playerid] = 20; ChosenSkin[playerid] = FactSkins8[18][0]; }
else if(SelectCharPlace[playerid] == 20) { SetPlayerSkin(playerid, FactSkins8[19][0]); SelectCharPlace[playerid] = 21; ChosenSkin[playerid] = FactSkins8[19][0]; }
else if(SelectCharPlace[playerid] == 21) { SetPlayerSkin(playerid, FactSkins8[20][0]); SelectCharPlace[playerid] = 22; ChosenSkin[playerid] = FactSkins8[20][0]; }
else if(SelectCharPlace[playerid] == 22) { SetPlayerSkin(playerid, FactSkins8[21][0]); SelectCharPlace[playerid] = 23; ChosenSkin[playerid] = FactSkins8[21][0]; }
else if(SelectCharPlace[playerid] == 23) { SetPlayerSkin(playerid, FactSkins8[22][0]); SelectCharPlace[playerid] = 24; ChosenSkin[playerid] = FactSkins8[22][0]; }
else if(SelectCharPlace[playerid] == 24) { SetPlayerSkin(playerid, FactSkins8[23][0]); SelectCharPlace[playerid] = 25; ChosenSkin[playerid] = FactSkins8[23][0]; }
else if(SelectCharPlace[playerid] == 25) { SetPlayerSkin(playerid, FactSkins8[24][0]); SelectCharPlace[playerid] = 1; ChosenSkin[playerid] = FactSkins8[24][0]; }
}
case 9: //News Reporters
{
if(SelectCharPlace[playerid] == 1) { SetPlayerSkin(playerid, FactSkins9[0][0]); SelectCharPlace[playerid] = 2; ChosenSkin[playerid] = FactSkins9[0][0]; }
else if(SelectCharPlace[playerid] == 2) { SetPlayerSkin(playerid, FactSkins9[1][0]); SelectCharPlace[playerid] = 3; ChosenSkin[playerid] = FactSkins9[1][0]; }
else if(SelectCharPlace[playerid] == 3) { SetPlayerSkin(playerid, FactSkins9[2][0]); SelectCharPlace[playerid] = 4; ChosenSkin[playerid] = FactSkins9[2][0]; }
else if(SelectCharPlace[playerid] == 4) { SetPlayerSkin(playerid, FactSkins9[3][0]); SelectCharPlace[playerid] = 1; ChosenSkin[playerid] = FactSkins9[3][0]; }
}
case 10: //Taxi Cab Company
{
if(SelectCharPlace[playerid] == 1) { SetPlayerSkin(playerid, FactSkins10[0][0]); SelectCharPlace[playerid] = 2; ChosenSkin[playerid] = FactSkins10[0][0]; }
else if(SelectCharPlace[playerid] == 2) { SetPlayerSkin(playerid, FactSkins10[1][0]); SelectCharPlace[playerid] = 3; ChosenSkin[playerid] = FactSkins10[1][0]; }
else if(SelectCharPlace[playerid] == 3) { SetPlayerSkin(playerid, FactSkins10[2][0]); SelectCharPlace[playerid] = 1; ChosenSkin[playerid] = FactSkins10[2][0]; }
}
case 11: //Families
{
new family = PlayerInfo[playerid][pFMember];
if(SelectCharPlace[playerid] < FamilyInfo[family][FamilySkins])
{
if(SelectCharPlace[playerid] == 1) { SetPlayerSkin(playerid, FamilyInfo[family][FamilySkin2]); SelectCharPlace[playerid] = 2; ChosenSkin[playerid] = FamilyInfo[family][FamilySkin2]; }
else if(SelectCharPlace[playerid] == 2) { SetPlayerSkin(playerid, FamilyInfo[family][FamilySkin3]); SelectCharPlace[playerid] = 3; ChosenSkin[playerid] = FamilyInfo[family][FamilySkin3]; }
else if(SelectCharPlace[playerid] == 3) { SetPlayerSkin(playerid, FamilyInfo[family][FamilySkin4]); SelectCharPlace[playerid] = 4; ChosenSkin[playerid] = FamilyInfo[family][FamilySkin4]; }
else if(SelectCharPlace[playerid] == 4) { SetPlayerSkin(playerid, FamilyInfo[family][FamilySkin5]); SelectCharPlace[playerid] = 5; ChosenSkin[playerid] = FamilyInfo[family][FamilySkin5]; }
else if(SelectCharPlace[playerid] == 5) { SetPlayerSkin(playerid, FamilyInfo[family][FamilySkin6]); SelectCharPlace[playerid] = 6; ChosenSkin[playerid] = FamilyInfo[family][FamilySkin6]; }
else if(SelectCharPlace[playerid] == 6) { SetPlayerSkin(playerid, FamilyInfo[family][FamilySkin7]); SelectCharPlace[playerid] = 7; ChosenSkin[playerid] = FamilyInfo[family][FamilySkin7]; }
else if(SelectCharPlace[playerid] == 7) { SetPlayerSkin(playerid, FamilyInfo[family][FamilySkin8]); SelectCharPlace[playerid] = 8; ChosenSkin[playerid] = FamilyInfo[family][FamilySkin8]; }
else if(SelectCharPlace[playerid] == 8) { SetPlayerSkin(playerid, FamilyInfo[family][FamilySkin1]); SelectCharPlace[playerid] = 1; ChosenSkin[playerid] = FamilyInfo[family][FamilySkin1]; }
}
else
{
SetPlayerSkin(playerid, FamilyInfo[family][FamilySkin1]); SelectCharPlace[playerid] = 1; ChosenSkin[playerid] = FamilyInfo[family][FamilySkin1];
}
}
}
return 0;
}
else if((strcmp("done", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("done")))
{
if(ChangeUniform[playerid] == 1) //lspd
{
PlayerInfo[playerid][pModel] = ChosenSkin[playerid];
SelectCharPlace[playerid] = 0;
SelectCharID[playerid] = 0;
SelectChar[playerid] = 0;
ChangeUniform[playerid] = 0;
TogglePlayerControllable(playerid,1);
return 0;
}
PlayerInfo[playerid][pModel] = ChosenSkin[playerid];
SelectCharPlace[playerid] = 0;
SelectCharID[playerid] = 0;
SelectChar[playerid] = 0;
SetPlayerToTeamColor(playerid);
SpawnPlayer(playerid);
return 0;
}
else
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "* Use 'next', or 'done'.");
return 0;
}
}
if(RegistrationStep[playerid] > 0)
{
if(RegistrationStep[playerid] == 1)
{
new idx;
tmp = strtok(text, idx);
//if(PlayerInfo[playerid][pLanguage] == 2)
//{
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).");
}
//}
/*if(PlayerInfo[playerid][pLanguage] == 1)
{
if((strcmp("man", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("man")))
{
PlayerInfo[playerid][pSex] = 1;
SendClientMessage(playerid, COLOR_YELLOW2, "Ok, dus je bent een man.");
SendClientMessage(playerid, COLOR_LIGHTRED, "Wanneer ben je jarig? (Use dd/mm/jjjj)");
RegistrationStep[playerid] = 2;
return 0;
}
else if((strcmp("vrouw", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("vrouw")))
{
PlayerInfo[playerid][pSex] = 2;
SendClientMessage(playerid, COLOR_YELLOW2, "Ok, dus je bent een vrouw");
SendClientMessage(playerid, COLOR_LIGHTRED, "Wanneer ben je jarig? (Use dd/mm/jjjj)");
RegistrationStep[playerid] = 2;
return 0;
}
else
{
SendClientMessage(playerid, COLOR_LIGHTRED, "Ben je een man of een vrouw? (Typ in wat je bent).");
}
}*/
return 0;
}
else if(RegistrationStep[playerid] == 2)
{
new year, month, day;
getdate(year, month, day);
new DateInfo[3][20];
//if(PlayerInfo[playerid][pLanguage] == 2)
//{
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 - strvalEx(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, so you are %d years old.",PlayerInfo[playerid][pAge]);
SendClientMessage(playerid, COLOR_YELLOW2, string);
//SendClientMessage(playerid, COLOR_LIGHTRED, "What language do you speak? ( Dutch, English ) If none of these type english.");
RegistrationStep[playerid] = 0;
PlayerInfo[playerid][pOrigin] = 3;
TutTime[playerid] = 1;
CanTalk[playerid] = 0;
//}
/*if(PlayerInfo[playerid][pLanguage] == 1)
{
split(text, DateInfo, '/');
if(year - strvalEx(DateInfo[2]) > 100 || strvalEx(DateInfo[2]) < 1 || strvalEx(DateInfo[2]) >= year)
{
SendClientMessage(playerid, COLOR_LIGHTRED, "Wanneer ben je jarig? (Use dd/mm/jjjj)");
return 0;
}
new check = year - strvalEx(DateInfo[2]);
if(check == year)
{
SendClientMessage(playerid, COLOR_LIGHTRED, "Wanneer ben je jarig? (Use dd/mm/jjjj)");
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, dus je bent %d jaar oud.",PlayerInfo[playerid][pAge]);
SendClientMessage(playerid, COLOR_YELLOW2, string);
SendClientMessage(playerid, COLOR_LIGHTRED, "Welke taal spreek je? ( Nederlands, Engels ) Als geen van beiden kies engels.");
RegistrationStep[playerid] = 0;
PlayerInfo[playerid][pOrigin] = 3;
//TutTime[playerid] = 1;
CanTalk[playerid] = 0;
}*/
return 0;
}
/*else if(RegistrationStep[playerid] == 3)
{
new idx;
tmp = strtok(text, idx);
if((strcmp("dutch", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("dutch")))
{
PlayerInfo[playerid][pLanguage] = 1;
SendClientMessage(playerid, COLOR_YELLOW2, "Ok, dus je bent nederlands.");
SendClientMessage(playerid, COLOR_LIGHTRED, "Je word nu naar de tutorial gebracht.");
RegistrationStep[playerid] = 0;
TutTime[playerid] = 1;
return 0;
}
else if((strcmp("english", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("english")))
{
PlayerInfo[playerid][pLanguage] = 2;
SendClientMessage(playerid, COLOR_YELLOW2, "Ok, so you are english");
SendClientMessage(playerid, COLOR_LIGHTRED, "You're now being taken to the tutorial");
RegistrationStep[playerid] = 0;
TutTime[playerid] = 1;
return 0;
}
else
{
SendClientMessage(playerid, COLOR_LIGHTRED, "What language do you speak? (dutch or english).");
}
}*/
}
pawn Код:
ApplyAnimation(playerid,"PED","IDLE_CHAT",4.1,1,1,1,1,1);
{
return 0;
}
And the Animation isn't working..
Please please I need help with this, I'm about to buy the hosted tab but now with this Bug I can't do it :/