ok thx for the help...
but now i have a new problem ...
i just want to send it once...
not only me .. all players but i dono why
pawn Код:
public OnTutorialTimer()
{
new playername[MAX_PLAYER_NAME];
new string[256];
new fam;
for (new i=0; i<MAX_POINTS; i++)
{
if (Points[i][ClaimerId] != 255)
{
if (Points[i][TimeToClaim] > 0)
{
Points[i][TimeToClaim]--;
}
else
{
new claimer = Points[i][ClaimerId];
for(new ppl = 0; ppl < MAX_PLAYERS; ppl++)
{
if(PlayerInfo[ppl][pMember] == 5 || PlayerInfo[ppl][pLeader] == 5)
{
if (PlayerToPoint(60.0, claimer, Points[i][Pointx], Points[i][Pointy], Points[i][Pointz]))
{
fam = PlayerInfo[claimer][pLeader];
GetPlayerName(claimer, playername, sizeof(playername));
format(string, sizeof(string), "%s has successfully claimed %s for Blue Gangsta, it will be theirs in %d minutes!", playername, Points[i][Name], TIME_TO_TAKEOVER);
SendClientMessageToAll(COLOR_YELLOW, string);
Points[i][TakeOverTimerStarted] = 1;
Points[i][TakeOverTimer] = 0;
Points[i][ClaimerId] = 255;
Points[i][BeingClaimed] = 0;
Points[i][ClaimerTeam] = fam;
}
else
{
SendClientMessage(Points[i][ClaimerId], COLOR_LIGHTBLUE, "You must be standing at the point, you failed to claim");
Points[i][ClaimerId] = 255;
Points[i][ClaimerTeam] = 255;
Points[i][TakeOverTimer] = 0;
Points[i][TakeOverTimerStarted] = 0;
Points[i][BeingClaimed] = 0;
}
}
else if(PlayerInfo[ppl][pMember] == 6 || PlayerInfo[ppl][pLeader] == 6)
{
if (PlayerToPoint(60.0, claimer, Points[i][Pointx], Points[i][Pointy], Points[i][Pointz]))
{
fam = PlayerInfo[claimer][pLeader];
GetPlayerName(claimer, playername, sizeof(playername));
format(string, sizeof(string), "%s has successfully claimed %s for Mafia, it will be theirs in %d minutes!", playername, Points[i][Name], TIME_TO_TAKEOVER);
SendClientMessageToAll(COLOR_YELLOW, string);
Points[i][TakeOverTimerStarted] = 1;
Points[i][TakeOverTimer] = 0;
Points[i][ClaimerId] = 255;
Points[i][BeingClaimed] = 0;
Points[i][ClaimerTeam] = fam;
}
else
{
SendClientMessage(Points[i][ClaimerId], COLOR_LIGHTBLUE, "You must be standing at the point, you failed to claim");
Points[i][ClaimerId] = 255;
Points[i][ClaimerTeam] = 255;
Points[i][TakeOverTimer] = 0;
Points[i][TakeOverTimerStarted] = 0;
Points[i][BeingClaimed] = 0;
}
}
else if(PlayerInfo[ppl][pMember] == 10 || PlayerInfo[ppl][pLeader] == 10)
{
if (PlayerToPoint(60.0, claimer, Points[i][Pointx], Points[i][Pointy], Points[i][Pointz]))
{
fam = PlayerInfo[claimer][pLeader];
GetPlayerName(claimer, playername, sizeof(playername));
format(string, sizeof(string), "%s has successfully claimed %s for East Side Crips, it will be theirs in %d minutes!", playername, Points[i][Name], TIME_TO_TAKEOVER);
SendClientMessageToAll(COLOR_YELLOW, string);
Points[i][TakeOverTimerStarted] = 1;
Points[i][TakeOverTimer] = 0;
Points[i][ClaimerId] = 255;
Points[i][BeingClaimed] = 0;
Points[i][ClaimerTeam] = fam;
}
else
{
SendClientMessage(Points[i][ClaimerId], COLOR_LIGHTBLUE, "You must be standing at the point, you failed to claim");
Points[i][ClaimerId] = 255;
Points[i][ClaimerTeam] = 255;
Points[i][TakeOverTimer] = 0;
Points[i][TakeOverTimerStarted] = 0;
Points[i][BeingClaimed] = 0;
}
}
else if(PlayerInfo[ppl][pMember] == 11 || PlayerInfo[ppl][pLeader] == 11)
{
if (PlayerToPoint(60.0, claimer, Points[i][Pointx], Points[i][Pointy], Points[i][Pointz]))
{
fam = PlayerInfo[claimer][pLeader];
GetPlayerName(claimer, playername, sizeof(playername));
format(string, sizeof(string), "%s has successfully claimed %s for Latin Kings, it will be theirs in %d minutes!", playername, Points[i][Name], TIME_TO_TAKEOVER);
SendClientMessageToAll(COLOR_YELLOW, string);
Points[i][TakeOverTimerStarted] = 1;
Points[i][TakeOverTimer] = 0;
Points[i][ClaimerId] = 255;
Points[i][BeingClaimed] = 0;
Points[i][ClaimerTeam] = fam;
}
else
{
SendClientMessage(Points[i][ClaimerId], COLOR_LIGHTBLUE, "You must be standing at the point, you failed to claim");
Points[i][ClaimerId] = 255;
Points[i][ClaimerTeam] = 255;
Points[i][TakeOverTimer] = 0;
Points[i][TakeOverTimerStarted] = 0;
Points[i][BeingClaimed] = 0;
}
}
else if(PlayerInfo[ppl][pMember] == 12 || PlayerInfo[ppl][pLeader] == 12)
{
if (PlayerToPoint(60.0, claimer, Points[i][Pointx], Points[i][Pointy], Points[i][Pointz]))
{
fam = PlayerInfo[claimer][pLeader];
GetPlayerName(claimer, playername, sizeof(playername));
format(string, sizeof(string), "%s has successfully claimed %s for Ballas, it will be theirs in %d minutes!", playername, Points[i][Name], TIME_TO_TAKEOVER);
SendClientMessageToAll(COLOR_YELLOW, string);
Points[i][TakeOverTimerStarted] = 1;
Points[i][TakeOverTimer] = 0;
Points[i][ClaimerId] = 255;
Points[i][BeingClaimed] = 0;
Points[i][ClaimerTeam] = fam;
}
else
{
SendClientMessage(Points[i][ClaimerId], COLOR_LIGHTBLUE, "You must be standing at the point, you failed to claim");
Points[i][ClaimerId] = 255;
Points[i][ClaimerTeam] = 255;
Points[i][TakeOverTimer] = 0;
Points[i][TakeOverTimerStarted] = 0;
Points[i][BeingClaimed] = 0;
}
}
}
}
}
if (Points[i][TakeOverTimerStarted])
{
fam = Points[i][ClaimerTeam];
for(new ppl2 = 0; ppl2 < MAX_PLAYERS; ppl2++)
{
if(PlayerInfo[ppl2][pMember] == 5 || PlayerInfo[ppl2][pLeader] == 5)
{
if (Points[i][TakeOverTimer] < TIME_TO_TAKEOVER * 6)
{
Points[i][TakeOverTimer]++;
}
else
{
Points[i][ClaimerTeam] = 255;
Points[i][TakeOverTimer] = 0;
Points[i][TakeOverTimerStarted] = 0;
Points[i][Vulnerable] = NEW_VULNERABLE;
strmid(Points[i][Owner], "Blue Gangsta", 0, 32, 32);
format(string, sizeof(string), "Blue Gangsta has successfully claimed %s", Points[i][Name]);
SendClientMessageToAll(COLOR_YELLOW, string);
UpdatePoints();
}
}
else if(PlayerInfo[ppl2][pMember] == 6 || PlayerInfo[ppl2][pLeader] == 6)
{
if (Points[i][TakeOverTimer] < TIME_TO_TAKEOVER * 6)
{
Points[i][TakeOverTimer]++;
}
else
{
Points[i][ClaimerTeam] = 255;
Points[i][TakeOverTimer] = 0;
Points[i][TakeOverTimerStarted] = 0;
Points[i][Vulnerable] = NEW_VULNERABLE;
strmid(Points[i][Owner], "Mafia", 0, 32, 32);
format(string, sizeof(string), "Mafia has successfully claimed %s", Points[i][Name]);
SendClientMessageToAll(COLOR_YELLOW, string);
UpdatePoints();
}
}
else if(PlayerInfo[ppl2][pMember] == 10 || PlayerInfo[ppl2][pLeader] == 10)
{
if (Points[i][TakeOverTimer] < TIME_TO_TAKEOVER * 6)
{
Points[i][TakeOverTimer]++;
}
else
{
Points[i][ClaimerTeam] = 255;
Points[i][TakeOverTimer] = 0;
Points[i][TakeOverTimerStarted] = 0;
Points[i][Vulnerable] = NEW_VULNERABLE;
strmid(Points[i][Owner], "East Side", 0, 32, 32);
format(string, sizeof(string), "East Side Crips has successfully claimed %s", Points[i][Name]);
SendClientMessageToAll(COLOR_YELLOW, string);
UpdatePoints();
}
}
else if(PlayerInfo[ppl2][pMember] == 11 || PlayerInfo[ppl2][pLeader] == 11)
{
if (Points[i][TakeOverTimer] < TIME_TO_TAKEOVER * 6)
{
Points[i][TakeOverTimer]++;
}
else
{
Points[i][ClaimerTeam] = 255;
Points[i][TakeOverTimer] = 0;
Points[i][TakeOverTimerStarted] = 0;
Points[i][Vulnerable] = NEW_VULNERABLE;
strmid(Points[i][Owner], "Latin Kings", 0, 32, 32);
format(string, sizeof(string), "Latin Kings has successfully claimed %s", Points[i][Name]);
SendClientMessageToAll(COLOR_YELLOW, string);
UpdatePoints();
}
}
else if(PlayerInfo[ppl2][pMember] == 12 || PlayerInfo[ppl2][pLeader] == 12)
{
if (Points[i][TakeOverTimer] < TIME_TO_TAKEOVER * 6)
{
Points[i][TakeOverTimer]++;
}
else
{
Points[i][ClaimerTeam] = 255;
Points[i][TakeOverTimer] = 0;
Points[i][TakeOverTimerStarted] = 0;
Points[i][Vulnerable] = NEW_VULNERABLE;
strmid(Points[i][Owner], "Ballas", 0, 32, 32);
format(string, sizeof(string), "Ballas has successfully claimed %s", Points[i][Name]);
SendClientMessageToAll(COLOR_YELLOW, string);
UpdatePoints();
}
}
}
}
if (Points[i][Vulnerable] == 0 && Points[i][Type] > 0 && Points[i][Announced] == 0 && Points[i][ClaimerId] == 255)
{
format(string, sizeof(string), "%s has become vulnerable to takeover!", Points[i][Name]);
SendClientMessageToAll(COLOR_HITRED, string);
Points[i][Announced] = 1;
}
}
return 1;
}