rendered paste body// noms de zones etc
new warzone;
new gangkillcount[MAX_PLAYERS];
new teamkillcount[MAX_PLAYERS];
new taketurfbackcount[MAX_PLAYERS];
new MyKills[MAX_PLAYERS];
new MyDeaths[MAX_PLAYERS];
new TeamKills[MAX_PLAYERS];
new IsPlayerInJail[MAX_PLAYERS];
//==================onplayerdeath===================//
public OnPlayerConnect(playerid)
{
new Text:text = TextDrawCreate(50, 100.0,"~y~ Bienvenu sur World Public Enemy ~n~~y~~n~~g~~n~1.Respect other players and admin ~n~~y~~n~~g~~n~2.Please Don't spam ~n~~y~~n~~g~~n~3.Spawn and DriveBy kill is not allowed ~n~~y~~n~~g~~n~4.Don't hack/cheat~n~");
TextDrawUseBox(text, 2);
TextDrawBoxColor(text, 0x000000AA);
TextDrawFont(text, 1);
TextDrawSetShadow(text,0);
TextDrawSetOutline(text,0);
TextDrawBackgroundColor(text,0x000000FF);
TextDrawColor(text,0xFFFFFFFF);
TimeTextForPlayer(playerid,text,10000);
text = TextDrawCreate(50, 244.5,"~n~~r~Please obey all rules or get kick/ban ~r~~n~~r~~n~Type /rules for read rules ~r~~n~~r~~n~Thanks for playing on Our server enjoy your stay");
TextDrawUseBox(text, 2);
TextDrawBoxColor(text, 0x000000AA);
TextDrawFont(text, 0);
TextDrawSetShadow(text,0);
TextDrawSetOutline(text,0);
TextDrawBackgroundColor(text,0x000000FF);
TextDrawColor(text,0xFFFFFFFF);
TimeTextForPlayer(playerid,text,10000);
//==============================================================================
if (gdebug >= 1){printf("DEBUG OnPlayerConnect(%d)", playerid);}
new bitch[256];
GetPlayerName(playerid,bitch,sizeof(bitch));
format(bitch,sizeof(bitch),"*** %s joined the server",bitch);
SendClientMessageToAll(COLOR_GRAD1,bitch);
gActivePlayers[playerid]++;
numplayers++;
//TelePos[playerid][0] = 0;
//TelePos[playerid][1] = 0;
//TelePos[playerid][2] = 0;
//new playerid[MAX_PLAYERS];
for (new i=1;i<=gGangZoneCount;i++) {
GangZoneShowForPlayer(playerid, gGangZone[i], COLOR_GANGZONE_RED);
}
SafeTime[playerid] = 60;
BetRace[playerid][0] = 255;
BetRace[playerid][1] = 0;
BetDm[playerid][0] = 255;
BetDm[playerid][1] = 0;
//HidePM[playerid] = 0;
gPlayerFighter[playerid] = 0;
DmScore[playerid] = 0;
Mobile[playerid] = 255;
Spectate[playerid] = 255;
Unspec[playerid][sLocal] = 255;
gSkyDive[playerid] = 0;
TVMode[playerid] = 0;
gLastCar[playerid] = 0;
FirstSpawn[playerid] = 0;
gPlayerLapStatus[playerid] = 0;
gOoc[playerid] = 0;
BigEar[playerid] = 0;
FlashTime[playerid] = 0;
gDice[playerid] = 0;
gSpeedo[playerid] = 0;
gPlayerLogged[playerid] = 0;
gPlayerAccount[playerid] = 0;
gPlayerSpawned[playerid] = 0;
LapCount[playerid] = 0;
Mute[playerid] = 0;
StartTime[playerid] = 0;
gRaceGuy[playerid] = 0;
Contract[playerid] = 0;
gPlayerMission[playerid] = 0;
PlayerInfo[playerid][pCash] = dollah;
KickVote[playerid] = 0;
VoteKick[playerid] = 0;
LastVote[playerid] = 255;
HireCar[playerid] = 299;
Hidden[playerid] = 0;
Locator[playerid] = 0;
PLicence[playerid] = 0;
gPhoneBook[playerid] = 0;
//PlayerPos[playerid][3] = 1.0;
//PlayerPos[playerid][4] = 1.0;
//PlayerPos[playerid][5] = 1.0;
GivePlayerMoney(playerid,PlayerInfo[playerid][pCash]);
PlayerInfo[playerid][pAccount] = 0;
PlayerInfo[playerid][pAdmin] = 0;
PlayerInfo[playerid][pLevel] = 1;
PlayerInfo[playerid][pExp] = 0;
PlayerInfo[playerid][gPupgrade] = 0;
PlayerInfo[playerid][pKills] = 0;
PlayerInfo[playerid][pCB] = 0;
PlayerInfo[playerid][pHW] = 0;
PlayerInfo[playerid][pSR] = 0;
PlayerInfo[playerid][pWA] = 0;
PlayerInfo[playerid][pPEN] = 0;
PlayerInfo[playerid][pGun1] = 0;
PlayerInfo[playerid][pGun2] = 0;
PlayerInfo[playerid][pGun3] = 0;
PlayerInfo[playerid][pGun4] = 0;
PlayerInfo[playerid][pGun5] = 0;
PlayerInfo[playerid][pGun6] = 0;
PlayerInfo[playerid][pAmmo1] = 200;
PlayerInfo[playerid][pAmmo2] = 8;
PlayerInfo[playerid][pAmmo3] = 30;
PlayerInfo[playerid][pAmmo4] = 30;
PlayerInfo[playerid][pAmmo5] = 10;
PlayerInfo[playerid][pAmmo6] = 10;
PlayerInfo[playerid][pSHealth] = 0.0;
PlayerInfo[playerid][pHealth] = 50.0;
PlayerInfo[playerid][pPos_x] = 2246.6;
PlayerInfo[playerid][pPos_y] = -1161.9;
PlayerInfo[playerid][pPos_z] = 1029.7;
PlayerInfo[playerid][pInt] = 15;
PlayerInfo[playerid][pLocal] = 255;
PlayerInfo[playerid][pTeam] = 1;
PlayerInfo[playerid][pModel] = 264;
new randphone = 1000 + random(8999);//minimum 1000 max 9999 //giving one at the start
PlayerInfo[playerid][pPnumber] = randphone;
PlayerInfo[playerid][pPhousekey] = 255;
PlayerInfo[playerid][pPbiskey] = 255;
PlayerInfo[playerid][pLottoNr] = 0;
PlayerInfo[playerid][pDrugs] = 0;
PlayerInfo[playerid][pDrugPerk] = 0;
PlayerInfo[playerid][pPayCheck] = 0;
//----------------------------------------- zone script
MyDeaths[playerid] = 0;
MyKills[playerid] = 0;
TeamKills[playerid] = 0;
IsPlayerInJail[playerid] = 0;
taketurfbackcount[playerid] = 0;
gangkillcount[playerid] = 0;
teamkillcount[playerid] = 0;
//------------------------------------------
ClearCrime(playerid);
printf("Player Connecting as (%d)", playerid);
SetPlayerColor(playerid,COLOR_GRAD2);
GetPlayerName(playerid, plname, sizeof(plname));
//SetPlayerCameraPos(playerid,1460.0, -1324.0, 287.2);
//SetPlayerCameraLookAt(playerid,1374.5, -1291.1, 239.0);
format(string, sizeof(string), "%s.cer", plname);
if(fexist(string))
{
gPlayerAccount[playerid] = 1;
SendClientMessage(playerid, COLOR_GREEN, "SERVER: That nick is registered, You have 60 seconds to login");
SendClientMessage(playerid, COLOR_GREEN, "SERVER: Ce nick est enregistré, Vous avez 60 seconds pour vous loger");
SendClientMessage(playerid, COLOR_PURPLE, "HINT: You can now login by typing /login <password>");
SendClientMessage(playerid, COLOR_PURPLE, "HINT: Vous pouvez maintenant vous loger, Tapez /login <password>");
SendClientMessage(playerid, COLOR_TB, "FORUM : www.gta-worldpen1.com");
SendClientMessage(playerid, COLOR_TB, "MENU : /welcom & /fr");
SendClientMessage(playerid, COLOR_ORANGE, "Tip 0f Day: Kill Orange icon Criminal");
return 1;
}
else
{
gPlayerAccount[playerid] = 0;
SendClientMessage(playerid, COLOR_GREEN, "SERVER: Welcome on our server! Save account! Experience! Gang! Mission!");
SendClientMessage(playerid, COLOR_GREEN, "SERVER: Bienvenu sur notre server! Sauvegarde! Experience! Gang! Mission!");
SendClientMessage(playerid, COLOR_PURPLE, "SERVER: Type /regnick <password> to create and account or /help for help");
SendClientMessage(playerid, COLOR_PURPLE, "SERVER: Taper /regnick <password> pour creer un account et /help pour l'aide");
SendClientMessage(playerid, COLOR_TB, "FORUM : www.gta-worldpen1.com");
SendClientMessage(playerid, COLOR_TB, "MENU : /welcom & /fr");
SendClientMessage(playerid, COLOR_ORANGE, "Tip 0f Day: Kill Orange icon Criminal");
//return 1;
}
/* new playerip[24];
GetPlayerIp(playerid,playerip,24);
//new playerip[256];
//GetPlayerIp(playerid, playerip, sizeof(playerip))
//if(playerip == "127.0.0.1")
if(strfind(PlayerIP(playerid), "x.x.x.x", true) != -1)
{
SendClientMessage(playerid, 0x10F441AA, "You are logged in as an admin!");
IsPlayerAdmin = 1;
}*/
//----------------------- zone script
GangZoneShowForPlayer(playerid, warzone, COLOR_RED);
return 1;
}
//===============Onplayerdeaath========/
public OnPlayerDeath(playerid, killerid, reason)
{
if (gdebug >=0){printf("OnPlayerDeath Playerid:%d killerid:%d reason:%d", playerid, killerid, reason);}
new name[MAX_PLAYER_NAME];
new string[256];
new dmessage[128];
new deathreason[20];
new playercash;
new victimteam;
new Float:px,Float:py,Float:pz;
//new killerteam;
victimteam = (gTeam[playerid]);
//killerteam = (gTeam[killerid]);
gPlayerSpawned[playerid] = 0;
GetPlayerName(playerid, name, sizeof(name));
PlayerInfo[playerid][pLocal] = 255;
GetPlayerPos(playerid, px, py, pz);
DeathCount[playerid]++;
frags[playerid]++;
//WantedLevel[killerid]++;
SendDeathMessage(killerid,playerid,reason);
if(GetPlayerState(killerid) == 2 && playerid != gPublicEnemy)
{
SendClientMessage(killerid, COLOR_YELLOW, "DriveBy Kill, Gets You Fuck all, Dont Abuse it, On foot gets you $$$");
//SendDeathMessage(killerid,playerid,reason);
GetPlayerName(killerid, string, MAX_PLAYER_NAME);
format(string, sizeof(string),"Warning: [%d]%s Drive-by Spotted",killerid,string);
SendClientMessageToAll(COLOR_RED,string);
points[killerid]--;
return 1;
}
}
if(reason == 38)
{
new kstring[128];
new kickname[MAX_PLAYER_NAME];
GetPlayerName(killerid, kickname, sizeof(kickname));
format(kstring, sizeof(kstring), "AdminSweep: Player [%d]%s Has Been Banned, Cheat Detected",killerid,kickname);
printf("%s", kstring);
SendClientMessageToAll(COLOR_RED, kstring);
Ban(killerid);
}
/* new str[130],player[24],killer[24],Float:x,Float:y,Float:z;
new bWeapons[5][1] = { {34}, {35}, {36}, {19}, {20} };
GetPlayerName(playerid,player,24);
for(new s=0; s<5; s++)
if(reason == bWeapons[s][0])
{
format(str,sizeof(str),"..:: xServerx - Player %s has been [Possibly] detected |Fake Kill| ::..",player);
//Report(str);
}
if(z > 700)
{
format(str,sizeof(str),"..:: xServerx - Player %s has been [Possibly] detected |Indoor Weapons| ::..",killer);
//Report(str);
}
*/
if(gPlayerFighter[playerid] == 1)
{
DmScore[playerid]--;
if(killerid != INVALID_PLAYER_ID)
{
DmScore[killerid]++;
if(DmScore[killerid] > DmHiScore)
{
new dmname[MAX_PLAYER_NAME];
GetPlayerName(killerid, dmname, sizeof(dmname));
DmHiPlayer = killerid;
DmHiScore = DmScore[killerid];
format(string, sizeof(string), "DMNEWS: %s Is now in the lead with %d ", dmname,DmHiScore);
BroadCast(COLOR_WHITE, string);
format(string, sizeof(string), " ~g~%d~w~|~g~%d",DmScore[killerid],DmHiScore);
}
else
{
format(string, sizeof(string), " ~r~%d~w~|~g~%d",DmScore[killerid],DmHiScore);
}
GameTextForPlayer(killerid, string, 5000, 6);
}
}
GetWeaponName(reason, deathreason, 20);
format(dmessage, sizeof(dmessage), "You Got Pwned");
if (strlen(deathreason) == 0)
{
format(deathreason, sizeof(deathreason), "Fists");
}
if (reason == 41)
{
format(deathreason, sizeof(deathreason), "Pepper Spray");
}
if (gPlayerCheckpointStatus[playerid] == CHECKPOINT_DROPOFF)
{
if (gdebug){print("DEBUG test6");}
DisablePlayerCheckpoint(playerid);
gPlayerCheckpointStatus[playerid] = CHECKPOINT_NONE;
new check;
check = gPlayerCheckpointStatus[playerid];
if (gdebug){printf("DEBUG check %d" ,check);}
OnPlayerDropCashBox(playerid);
}
if (gPlayerCheckpointStatus[playerid] == CHECKPOINT_SFDROPOFF)
{
if (gdebug){print("DEBUG test6");}
DisablePlayerCheckpoint(playerid);
gPlayerCheckpointStatus[playerid] = CHECKPOINT_NONE;
new check;
check = gPlayerCheckpointStatus[playerid];
if (gdebug){printf("DEBUG check %d" ,check);}
OnPlayerDropCashBoxSF(playerid);
}
if (gPlayerCheckpointStatus[playerid] > 4 && gPlayerCheckpointStatus[playerid] < 11)
{
DisablePlayerCheckpoint(playerid);
gPlayerCheckpointStatus[playerid] = CHECKPOINT_NONE;
LapCount[playerid] = 0;
}
/*
if((PlayerInfo[playerid][pPhousekey]+1 != gLastCar[playerid] && gLastCar[playerid] != 0) || HireCar[playerid] != gLastCar[playerid] && gLastCar[playerid] != 0)
{
printf("DEBUG PlayerInfo[playerid][pPhousekey](%d) gLastCar[playerid]-1(%d) HireCar[playerid](%d)", PlayerInfo[playerid][pPhousekey],gLastCar[playerid]-1,HireCar[playerid]);
UnLockCar(gLastCar[playerid]);
gCarLock[gLastCar[playerid]] = 0;
gLastDriver[gLastCar[playerid]] = 300;
gLastCar[playerid] = 0;
}
*/
new caller = Mobile[playerid];
if(caller != 255)
{
if(caller < 255)
{
SendClientMessage(caller, COLOR_GRAD2, " The line just went dead....");
CellTime[caller] = 0;
CellTime[playerid] = 0;
Mobile[caller] = 255;
}
Mobile[playerid] = 255;
CellTime[playerid] = 0;
}
ClearCrime(playerid);
if (killerid == INVALID_PLAYER_ID)
{
for(new i = 0; i <= MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i) && gTeam[i] != gTeam[playerid] && CrimInRange(20.0, playerid,i) && GetPlayerState(i) != 2)
{
killerid = i;
format(deathreason, sizeof(deathreason), "Intimidation");
suicides[playerid]++;
}
}
}
if (killerid == INVALID_PLAYER_ID)
{
if ((gTeam[playerid]) == 0){return 1;}
new slice = ((PlayerInfo[playerid][pLevel]*deathcost)+(basedcost)); //1k +your level
GivePlayerMoney(playerid, -slice);
format(string, sizeof(string), "DOC: Your Medical Bill Comes To $%d, Have A Nice Day.", slice);
SendClientMessage(playerid, TEAM_CYAN_COLOR, string);
WantedLevel[playerid] = 0;//wantedlvl ok Wanted loose Wtdpts
SetPlayerWantedLevel(playerid,0);
//Kills[playerid] = 0;
//deaths[playerid]++;//top
switch (reason)
{
case WEAPON_DROWN:
{
format(string, sizeof(string), ".: %s drowned :.", name);
BroadCast(COLOR_RED, string);
GameTextForPlayer(playerid, dmessage, 5000, 2);
//SendDeathMessage(killerid,playerid,reason);
suicides[playerid]++;//top
deaths[playerid]++;
}
case WEAPON_COLLISION:
{
format(string, sizeof(string), ".: %s cratered :.", name);
BroadCast(COLOR_RED, string);
GameTextForPlayer(playerid, dmessage, 5000, 2);
//SendDeathMessage(killerid,playerid,reason);
suicides[playerid]++;//top
deaths[playerid]++;
}
default:
{
/*
if (strlen(deathreason) > 0)
{
format(string, sizeof(string), ".: %s died. (%s) :.", name, deathreason);
}*/
// else
// {
format(string, sizeof(string), ".: %s died :.", name);
//SendDeathMessage(killerid,playerid,reason);
suicides[playerid]++;//top
deaths[playerid]++;
// }
BroadCast(COLOR_RED, string);
GameTextForPlayer(playerid, dmessage, 5000, 2);
}
}
if (gTeam[playerid] == 4)
{
gTeam[playerid] = PlayerInfo[playerid][pTeam];
}
if (gPublicEnemy == playerid)
{
if(killerid == 255)
{
gPublicEnemy = INVALID_PLAYER_ID;
GivePlayerMoney(playerid, -preward);
format(string, sizeof(string), "SMS: %s, The Ambulance Driver Took Your Last Payment $%d, Sender: MOLE (555)",name,preward);
RingTone[playerid] = 20;
SendClientMessage(playerid, COLOR_YELLOW, string);
WantedLevel[playerid] = 0;//wantedlvl ok Wanted loose Wtdpts
SetPlayerWantedLevel(playerid,0);
Kills[playerid] = 0;
KillTimer(offhook);
points[playerid]--;//top
deaths[playerid]++;//top
points[killerid]++;
sCount2--;
new sstring[256], sstring2[256];
SendClientMessageToAll(COLOR_ORANGE,"______-=TEAM STATS=-______");
format(sstring, sizeof(sstring), "COP FORCES: %d ", sCount1);
format(sstring2, sizeof(sstring2), "CRIMINAL : %d ", sCount2);
SendClientMessageToAll(COLOR_TB, sstring);
SendClientMessageToAll(COLOR_TB, sstring2);
SendClientMessageToAll(COLOR_ORANGE,"____________________________");
new tmpmed;
for(new i = 0; i <= MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i) == 1 && gTeam[i] == TEAM_CYAN)
{
tmpmed++;
}
}
for(new i = 0; i <= MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i) == 1 && gTeam[i] == TEAM_CYAN)
{
GivePlayerMoney(i, preward/tmpmed);
}
}
}
}
return 1;
}
if (Contract[playerid] > 0)
{
new killer[MAX_PLAYER_NAME];
GetPlayerName(killerid, killer, sizeof(killer));
GivePlayerMoney(killerid, Contract[playerid]);
format(string,128,"<< %s has fulfilled the contract on %s and collected $%d >>",killer,name,Contract[playerid]);
BroadCast(COLOR_YELLOW, string);
PayLog(string);
Contract[playerid] = 0;
}
if (victimteam >= 4)
{
//----- zone script
new KillSpreeName[30], ksmsg[256];
if(GetPlayerScore(killerid) ==25)
{
GetPlayerName(killerid, KillSpreeName, 30);
SendClientMessageToAll(COLOR_RED,"____________________________");
format(ksmsg, 256, "KILLING SPREE ! [%s] has 25 Kills", KillSpreeName);
SendClientMessageToAll(GetPlayerColor(killerid), ksmsg);
}
else if(GetPlayerScore(killerid) ==50)
{
GetPlayerName(killerid, KillSpreeName, 30);
SendClientMessageToAll(COLOR_RED,"____________________________");
format(ksmsg, 256, "KILLING SPREE ! [%s] has 50 Kills", KillSpreeName);
SendClientMessageToAll(GetPlayerColor(killerid), ksmsg);
}
else if(GetPlayerScore(killerid) ==75)
{
GetPlayerName(killerid, KillSpreeName, 30);
SendClientMessageToAll(COLOR_RED,"____________________________");
format(ksmsg, 256, "KILLING SPREE ! [%s] has 75 Kills", KillSpreeName);
SendClientMessageToAll(GetPlayerColor(killerid), ksmsg);
}
else if(GetPlayerScore(killerid) ==100)
{
GetPlayerName(killerid, KillSpreeName, 30);
SendClientMessageToAll(COLOR_RED,"____________________________");
format(ksmsg, 256, "KILLING SPREE ! [%s] has 100 Kills", KillSpreeName);
SendClientMessageToAll(GetPlayerColor(killerid), ksmsg);
}
MyDeaths[playerid]++;
MyKills[killerid]++;
//=============== [LE GANG PREND UNE ZONE ADVERSE] ====================================
//==============================================================================
if(gTeam[playerid] == TEAM_BALLAS) {//====================================
gangkillcount[playerid]++;
if(gangkillcount[playerid] == GANGAREA_WARNINGS) {
SendClientMessageToAll(COLOR_RED,"GangZone Message: Team BALLAS are being attacked");
GangZoneFlashForAll(warzone,GetPlayerColor(killerid));
}
if(gangkillcount[playerid] == GANGAREA_TAKE){
new KillerName[30], str[256];
GetPlayerName(killerid, KillerName, 30);
format(str, 256, "GangZone Message: %s has Taken BALLAS's Turf", KillerName);
SendClientMessageToAll(0xFFDAB9C8, str);
GangZoneStopFlashForAll(warzone);
GangZoneHideForAll(warzone);
GangZoneShowForAll(warzone, GetPlayerColor(killerid));
gangkillcount[playerid]=0;
}
}
if(gTeam[playerid] == TEAM_GROVE) {//====================================
gangkillcount[playerid]++;
if(gangkillcount[playerid] == GANGAREA_WARNINGS) {
SendClientMessageToAll(COLOR_RED,"GangZone Message: Team GROVE are being attacked");
GangZoneFlashForAll(warzone,GetPlayerColor(killerid));
}
if(gangkillcount[playerid] == GANGAREA_TAKE){
new KillerName[30], str[256];
GetPlayerName(killerid, KillerName, 30);
format(str, 256, "GangZone Message: %s has Taken GROVE's Turf", KillerName);
SendClientMessageToAll(0xFFDAB9C8, str);
GangZoneStopFlashForAll(warzone);
GangZoneHideForAll(warzone);
GangZoneShowForAll(warzone, GetPlayerColor(killerid));
gangkillcount[playerid]=0;
}
}
if(gTeam[playerid] == TEAM_VAGOS) {//====================================
gangkillcount[playerid]++;
if(gangkillcount[playerid] == GANGAREA_WARNINGS) {
SendClientMessageToAll(COLOR_RED,"GangZone Message: Team VAGOS are being attacked");
GangZoneFlashForAll(warzone,GetPlayerColor(killerid));
}
if(gangkillcount[playerid] == GANGAREA_TAKE){
new KillerName[30], str[256];
GetPlayerName(killerid, KillerName, 30);
format(str, 256, "GangZone Message: %s has Taken VAGOS's Turf", KillerName);
SendClientMessageToAll(0xFFDAB9C8, str);
GangZoneStopFlashForAll(warzone);
GangZoneHideForAll(warzone);
GangZoneShowForAll(warzone, GetPlayerColor(killerid));
gangkillcount[playerid]=0;
}
}
if(gTeam[playerid] == TEAM_GANGSTA) {//====================================
gangkillcount[playerid]++;
if(gangkillcount[playerid] == GANGAREA_WARNINGS) {
SendClientMessageToAll(COLOR_RED,"GangZone Message: Team GANGSTA are being attacked");
GangZoneFlashForAll(warzone,GetPlayerColor(killerid));
}
if(gangkillcount[playerid] == GANGAREA_TAKE){
new KillerName[30], str[256];
GetPlayerName(killerid, KillerName, 30);
format(str, 256, "GangZone Message: %s has Taken GANGSTA's Turf", KillerName);
SendClientMessageToAll(0xFFDAB9C8, str);
GangZoneStopFlashForAll(GANGSTA);
GangZoneHideForAll(warzone);
GangZoneShowForAll(warzone, GetPlayerColor(killerid));
gangkillcount[playerid]=0;
}
}
if(gTeam[playerid] == TEAM_RIFA) {//====================================
gangkillcount[playerid]++;
if(gangkillcount[playerid] == GANGAREA_WARNINGS) {
SendClientMessageToAll(COLOR_RED,"GangZone Message: Team Rifa are being attacked");
GangZoneFlashForAll(warzone,GetPlayerColor(killerid));
}
if(gangkillcount[playerid] == GANGAREA_TAKE){
new KillerName[30], str[256];
GetPlayerName(killerid, KillerName, 30);
format(str, 256, "GangZone Message: %s has Taken Rifa Turf", KillerName);
SendClientMessageToAll(0xFFDAB9C8, str);
GangZoneStopFlashForAll(Rifa);
GangZoneHideForAll(warzone);
GangZoneShowForAll(warzone, GetPlayerColor(killerid));
gangkillcount[playerid]=0;
}
}
if(gTeam[playerid] == TEAM_RMAFIA) {//====================================
gangkillcount[playerid]++;
if(gangkillcount[playerid] == GANGAREA_WARNINGS) {
SendClientMessageToAll(COLOR_RED,"GangZone Message: Team RMafia are being attacked");
GangZoneFlashForAll(warzone,GetPlayerColor(killerid) );
}
if(gangkillcount[playerid] == GANGAREA_TAKE) {
new KillerName[30], str[256];
GetPlayerName(killerid, KillerName, 30);
format(str, 256, "GangZone Message: %s has Taken RMafia Turf", KillerName);
SendClientMessageToAll(0xFFDAB9C8, str);
GangZoneStopFlashForAll(warzone);
GangZoneHideForAll(warzone);
GangZoneShowForAll(warzone, GetPlayerColor(killerid) );
gangkillcount[playerid]=0;
}
}
if(gTeam[playerid] == TEAM_MAFIA) {//==============================
gangkillcount[playerid]++;
if(gangkillcount[playerid] == GANGAREA_WARNINGS) {
SendClientMessageToAll(COLOR_RED,"GangZone Message: Team Mafia are being attacked");
GangZoneFlashForAll(warzone,GetPlayerColor(killerid) );
}
if(gangkillcount[playerid] == GANGAREA_TAKE) {
new KillerName[30], str[256];
GetPlayerName(killerid, KillerName, 30);
format(str, 256, "GangZone Message: %s has Taken Mafia Turf", KillerName);
SendClientMessageToAll(0xFFDAB9C8, str);
GangZoneStopFlashForAll(warzone);
GangZoneHideForAll(warzone);
GangZoneShowForAll(warzone, GetPlayerColor(killerid) );
gangkillcount[playerid]=0;
}
}
if(gTeam[playerid] == TEAM_BIKERS) {//===================================
gangkillcount[playerid]++;
if(gangkillcount[playerid] == GANGAREA_WARNINGS) {
SendClientMessageToAll(COLOR_RED,"GangZone Message: Team Bikers are being attacked");
GangZoneFlashForAll(warzone,GetPlayerColor(killerid) );
}
if(gangkillcount[playerid] == GANGAREA_TAKE) {
new KillerName[30], str[256];
GetPlayerName(killerid, KillerName, 30);
format(str, 256, "GangZone Message: %s has Taken Bikers Turf", KillerName);
SendClientMessageToAll(0xFFDAB9C8, str);
GangZoneStopFlashForAll(warzone);
GangZoneHideForAll(warzone);
GangZoneShowForAll(warzone, GetPlayerColor(killerid) );
gangkillcount[playerid]=0;
}
}
if(gTeam[playerid] == TEAM_TRIADS) {//===================================
gangkillcount[playerid]++;
if(gangkillcount[playerid] == GANGAREA_WARNINGS) {
SendClientMessageToAll(COLOR_RED,"GangZone Message: Team Triads are being attacked");
GangZoneFlashForAll(warzone,GetPlayerColor(killerid) );
}
if(gangkillcount[playerid] == GANGAREA_TAKE) {
new KillerName[30], str[256];
GetPlayerName(killerid, KillerName, 30);
format(str, 256, "GangZone Message: %s has Taken Triads Turf", KillerName);
SendClientMessageToAll(0xFFDAB9C8, str);
GangZoneStopFlashForAll(warzone);
GangZoneHideForAll(warzone);
GangZoneShowForAll(warzone, GetPlayerColor(killerid) );
gangkillcount[playerid]=0;
}
}
if(gTeam[playerid] == TEAM_AZTECAS) {//===================================
gangkillcount[playerid]++;
if(gangkillcount[playerid] == GANGAREA_WARNINGS) {
SendClientMessageToAll(COLOR_RED,"GangZone Message: Team AZTECAS are being attacked");
GangZoneFlashForAll(warzone,GetPlayerColor(killerid) );
}
if(gangkillcount[playerid] == GANGAREA_TAKE) {
new KillerName[30], str[256];
GetPlayerName(killerid, KillerName, 30);
format(str, 256, "GangZone Message: %s has Taken AZTECAS Turf", KillerName);
SendClientMessageToAll(0xFFDAB9C8, str);
GangZoneStopFlashForAll(warzone);
GangZoneHideForAll(warzone);
GangZoneShowForAll(warzone, GetPlayerColor(killerid) );
gangkillcount[playerid]=0;
}
}
if(gTeam[playerid] == TEAM_NANG) {//===================================
gangkillcount[playerid]++;
if(gangkillcount[playerid] == GANGAREA_WARNINGS) {
SendClientMessageToAll(COLOR_RED,"GangZone Message: Team NANG are being attacked");
GangZoneFlashForAll(warzone,GetPlayerColor(killerid) );
}
if(gangkillcount[playerid] == GANGAREA_TAKE) {
new KillerName[30], str[256];
GetPlayerName(killerid, KillerName, 30);
format(str, 256, "GangZone Message: %s has Taken NANG Turf", KillerName);
SendClientMessageToAll(0xFFDAB9C8, str);
GangZoneStopFlashForAll(warzone);
GangZoneHideForAll(warzone);
GangZoneShowForAll(warzone, GetPlayerColor(killerid) );
gangkillcount[playerid]=0;
}
}
if(gTeam[playerid] == TEAM_CS) {//===================================
gangkillcount[playerid]++;
if(gangkillcount[playerid] == GANGAREA_WARNINGS) {
SendClientMessageToAll(COLOR_RED,"GangZone Message: Team CS are being attacked");
GangZoneFlashForAll(warzone,GetPlayerColor(killerid) );
}
if(gangkillcount[playerid] == GANGAREA_TAKE) {
new KillerName[30], str[256];
GetPlayerName(killerid, KillerName, 30);
format(str, 256, "GangZone Message: %s has Taken CS Turf", KillerName);
SendClientMessageToAll(0xFFDAB9C8, str);
GangZoneStopFlashForAll(warzone);
GangZoneHideForAll(warzone);
GangZoneShowForAll(warzone, GetPlayerColor(killerid) );
gangkillcount[playerid]=0;
}
}
if(gTeam[playerid] == TEAM_BITCHS) {//===================================
gangkillcount[playerid]++;
if(gangkillcount[playerid] == GANGAREA_WARNINGS) {
SendClientMessageToAll(COLOR_RED,"GangZone Message: Team BITCHS are being attacked");
GangZoneFlashForAll(warzone,GetPlayerColor(killerid) );
}
if(gangkillcount[playerid] == GANGAREA_TAKE) {
new KillerName[30], str[256];
GetPlayerName(killerid, KillerName, 30);
format(str, 256, "GangZone Message: %s has Taken BITCHS's Turf", KillerName);
SendClientMessageToAll(0xFFDAB9C8, str);
GangZoneStopFlashForAll(warzone);
GangZoneHideForAll(warzone);
GangZoneShowForAll(warzone, GetPlayerColor(killerid) );
gangkillcount[playerid]=0;
}
}
// Valid kill
if(gTeam[killerid] != gTeam[playerid]) {
SetPlayerScore(killerid,GetPlayerScore(killerid)+1);
GivePlayerMoney(killerid, 1000);
GivePlayerMoney(playerid, -700);
//GameTextForPlayer(killerid,"~r~OWNED",1500,1);
//GameTextForPlayer(playerid,"~r~WASTED",4000,1);
}
else
{
//Team Killer
TeamKills[killerid]++;
new plname[MAX_PLAYER_NAME];
GetPlayerName(killerid, plname, MAX_PLAYER_NAME);
format(string, sizeof(string), "Warning! %s you have been punished for teamkilling.", plname);
SendClientMessage(killerid, 0xFFFF00AA, string);
GivePlayerMoney(killerid, -1000);
SetPlayerScore(killerid, GetPlayerScore(killerid) - 1);
GameTextForPlayer(killerid,"~r~TEAM KILLER",5000,3);
teamkillcount[killerid]++;
if(teamkillcount[killerid] >= MAX_TEAMKILLS_FORJAIL)
{
SetPlayerPos(killerid,-1435.377,931.6247,1041.531);
SetPlayerInterior(killerid,15);
SetTimerEx("jailrelease",JAIL_TIME_LENGTH,0,"d",killerid);
IsPlayerInJail[killerid] = 1;
//TextDrawShowForPlayer(killerid, jailcounter);
GivePlayerMoney(killerid, -2000);
//SetPlayerScore(killerid, GetPlayerScore(killerid) - 2);
}
if(teamkillcount[killerid] >= MAX_TEAMKILLS)
{
new teamkillername[30], tkmsg[256];
GetPlayerName(killerid, teamkillername, 30);
format(tkmsg, 256, "***[ %s ] has been kicked for teamkilling", teamkillername);
SendClientMessageToAll(0xAFAFAFAA, tkmsg);
SendClientMessage(killerid, 0xAFAFAFAA, "You have been kicked for teamkilling");
Kick(killerid);
}
}
}
//============================================== FIN DU SCRIPT POUR LES ZONE !!!
new killer[MAX_PLAYER_NAME];
GetPlayerName(killerid, killer, sizeof(killer));
new slice = ((PlayerInfo[playerid][pLevel]*deathcost)+(basedcost)); //1k +your level
playercash = GetPlayerMoney(playerid);
if(SafeTime[playerid] <= 0 || gPlayerFighter[playerid] == 1)
{
if(gTeam[killerid] != gTeam[playerid])
{
if(GetPlayerState(killerid) == 1)
{
PlayerInfo[killerid][pKills] = PlayerInfo[killerid][pKills]+2;
}
else
{
PlayerInfo[killerid][pKills]++;
}
PlayerInfo[playerid][pKills]--;
if(PlayerInfo[killerid][pKills] >= 30)
{
PlayerInfo[killerid][pExp]++;
PlayerInfo[killerid][pKills] = 0;
SendClientMessage(killerid, COLOR_YELLOW, "You are getting stronger Exp +1");
}
}
}
if (strlen(deathreason) > 0)// patch
{
if (((gTeam[killerid]) == 1) || ((gTeam[killerid]) == 3 && civnokill) || gTeam[killerid] == gTeam[playerid])//med kill criminal
{
format(string, sizeof(string), ".: %s murdered %s. (%s) :.", killer, name, deathreason);
WantedLevel[playerid] = 0;//wantedlvl ok Wanted loose Wtdpts
SetPlayerWantedLevel(playerid,0);
Kills[playerid] = 0;
deaths[playerid]++;//top
}
else
{
format(string, sizeof(string), ".: %s murdered %s. (%s) for $%d :.", killer, name, deathreason, slice);
WantedLevel[playerid] = 0;//wantedlvl ok Wanted loose Wtdpts
SetPlayerWantedLevel(playerid,0);
Kills[playerid] = 0;
deaths[playerid]++;//top
}
if (gdebug){print("DEBUG Deathtest3");}
}
else
{
if (gdebug){print("DEBUG Deathtest4");}
if (((gTeam[killerid]) == 1) || ((gTeam[killerid]) == 3 && civnokill || gTeam[killerid] == gTeam[playerid]))
{
format(string, sizeof(string), ".: %s murdered %s :.", killer, name);
WantedLevel[playerid] = 0;//wantedlvl ok Wanted loose Wtdpts
SetPlayerWantedLevel(playerid,0);
Kills[playerid] = 0;
deaths[playerid]++;//top
}
else
{
format(string, sizeof(string), ".: %s murdered %s for $%d :.", killer, name, slice);
WantedLevel[playerid] = 0;//wantedlvl ok Wanted loose Wtdpts
SetPlayerWantedLevel(playerid,0);
Kills[playerid] = 0;
deaths[playerid]++;//top
}
}
if ((gTeam[killerid]) == 2)//cops kill criminal
{
format(string, sizeof(string), ".: %s was arrested by Officer %s (%s) and fined $%d :.", name, killer, deathreason, slice);
format(dmessage, sizeof(dmessage), "Busted");
WantedLevel[playerid] = 0;//wantedlvl ok Wanted loose Wtdpts
SetPlayerWantedLevel(playerid,0);
Kills[playerid] = 0;
deaths[playerid]++;//top
sCount1++;//score
if(IsACopCar(gLastCar[killerid]))
{
GivePlayerMoney(killerid, 2000);
SendClientMessage(killerid, TEAM_BLUE_COLOR, "Vehicle Bonus $2000");
}
}
if (((gTeam[killerid]) == 1) || ((gTeam[killerid]) == 3 && civnokill) || (gTeam[killerid] == gTeam[playerid] && gTeam[playerid] != 4))
{
slice = 0;
}
if (((gTeam[killerid]) != 4) && ((gTeam[killerid]) == gTeam[playerid]))//no team kill
{
slice = 0;
teamkills[killerid]++;//top
frags[killerid]--;
}
if (playercash > 0)
{
if (gdebug){print("DEBUG Deathtest1");}
GivePlayerMoney(playerid, -slice);
}
else
{
if (gdebug){print("DEBUG Deathtest2");}
slice = slice+500;
}
GivePlayerMoney(killerid, slice);
GameTextForPlayer(playerid, dmessage, 5000, 2);
PlayerPlaySound(killerid, 1083, 0.0, 0.0, 0.0);
if (((gTeam[killerid]) == 3) && reason != 49)
{
SetPlayerCriminal(killerid,255, "First Degree Murder",0,0);
WantedLevel[playerid] = 0;//wantedlvl ok Wanted loose Wtdpts
SetPlayerWantedLevel(playerid,0);
//SendDeathMessage(killerid,playerid,reason);
Kills[playerid] = 0;
deaths[playerid]++;//top
if(FlashTime[killerid] == 0){FlashTime[killerid] = 10;}
}
else if (((gTeam[killerid]) == 3) && reason == 49)
{
SetPlayerCriminal(killerid,255, "Hit And Run",0,0);
WantedLevel[playerid] = 0;//wantedlvl ok Wanted loose Wtdpts
SetPlayerWantedLevel(playerid,0);
//SendDeathMessage(killerid,playerid,reason);
Kills[playerid] = 0;
deaths[playerid]++;//top
if(FlashTime[killerid] == 0){FlashTime[killerid] = 10;}
}
if (gPublicEnemy == playerid)
{
//SendClientMessage(killerid, TEAM_BLUE_COLOR, "HQ: You Have Arrested Public Enemy No.1, $5000 Bonus PayCheck");
WantedLevel[playerid] = 0;//wantedlvl ok Wanted loose Wtdpts
SetPlayerWantedLevel(playerid,0);
Kills[playerid] = 0;
deaths[playerid]++;//top
GivePlayerMoney(killerid, preward);
GivePlayerMoney(playerid, -preward);
KillTimer(offhook);
format(string, sizeof(string), "SMS: %s, %s Stole Your Last Payment $%d, Sender: MOLE (555)", name, killer,preward);
SendClientMessage(playerid, COLOR_YELLOW, string);
RingTone[playerid] = 20;
format(string, sizeof(string), ".:Public Enemy No.1 %s was killed by %s (%s) and lost $%d :.", name, killer, deathreason, slice);
sCount1++;//score
PlayerInfo[killerid][pPEN]++;
if(PlayerInfo[killerid][pPEN] >= 4)
{
PlayerInfo[killerid][pExp]++;
PlayerInfo[killerid][pPEN] = 0;
SendClientMessage(killerid, COLOR_YELLOW, "You are getting stronger Exp +1");
}
PlayerPlayMusic(killerid);
}
BroadCast(COLOR_RED, string);
if (gPublicEnemy != playerid)
{
if(gPlayerFighter[killerid] != 1)
{
format(string, sizeof(string), "~g~$%d", slice);
GameTextForPlayer(killerid, string, 5000, 1);
}
}
else
{
format(string, sizeof(string), "~p~P.E.No.1 ~w~Killed~n~You Take The ~g~$%d", preward);
GameTextForPlayer(killerid, string, 5000, 1);
gPublicEnemy = INVALID_PLAYER_ID;
}
}
else if (victimteam == 2)
{
new killer[MAX_PLAYER_NAME];
GetPlayerName(killerid, killer, sizeof(killer));
// Cop kill
if (gdebug){print("DEBUG test5");}
PlayerInfo[playerid][pKills]--;
//sCount1--;//score
if (gTeam[killerid] == 2)//cops kill cop
{
format(string,128,".: Officer %s murdered Officer %s (%s) and was sued for $%d :.",killer,name,deathreason,suecost);
PlayerPlaySound(killerid, 1084, 0.0, 0.0, 0.0);
//SendDeathMessage(killerid,playerid,reason);
GivePlayerMoney(killerid, -suecost);
GivePlayerMoney(playerid, suecost+100);//+100pays hospital bill
teamkills[killerid]++;
}
else
{
format(string,128,".: %s murdered Officer %s (%s) :.",killer,name,deathreason);
//SendDeathMessage(killerid,playerid,reason);
sCount2++;//score
}
if (gTeam[killerid] == 3)
{
if(reason != 49)
{
SetPlayerCriminal(killerid,255, "First Degree Murder",0,0);
//SendDeathMessage(killerid,playerid,reason);
}
else if (reason == 49)
{
SetPlayerCriminal(killerid,255, "Hit And Run",0,0);
//SendDeathMessage(killerid,playerid,reason);
}
if(FlashTime[killerid] == 0){FlashTime[killerid] = 10;}
}
if(gTeam[killerid] >= 5 && SafeTime[playerid] <= 0)
{
if(GetPlayerState(killerid) == 1)
{
PlayerInfo[killerid][pKills] = PlayerInfo[killerid][pKills]+2;
}
else
{
PlayerInfo[killerid][pKills]++;
}
if(PlayerInfo[killerid][pKills] >= 30)
{
PlayerInfo[killerid][pExp]++;
PlayerInfo[killerid][pKills] = 0;
SendClientMessage(killerid, COLOR_YELLOW, "You are getting stronger Exp +1");
}
}
BroadCast(COLOR_RED, string);
}
else if (victimteam == 3)
{
if (gdebug){print("DEBUG test6");}
new killer[MAX_PLAYER_NAME];
GetPlayerName(killerid, killer, sizeof(killer));
// Civ kill
if ((gTeam[killerid]) == 2)//cops kill civ
{
format(string,128,".: Officer %s murdered %s (%s) and was sued for $%d :.",killer,name,deathreason,suecost);
PlayerPlaySound(killerid, 1084, 0.0, 0.0, 0.0);
GivePlayerMoney(killerid, -suecost);
GivePlayerMoney(playerid, suecost+100);//+100pays hospital bill
WantedLevel[playerid] = 0;//wantedlvl ok Wanted loose Wtdpts
//SendDeathMessage(killerid,playerid,reason);
SetPlayerWantedLevel(playerid,0);
Kills[playerid] = 0;
deaths[playerid]++;//top
}
else
{
format(string,128,".: %s murdered %s (%s) :.",killer,name,deathreason);
WantedLevel[playerid] = 0;//wantedlvl ok Wanted loose Wtdpts
SetPlayerWantedLevel(playerid,0);
//SendDeathMessage(killerid,playerid,reason);
Kills[playerid] = 0;
deaths[playerid]++;//top
}
if (((gTeam[killerid]) == 3 || (gTeam[killerid]) == 1) && reason != 49)
{
SetPlayerCriminal(killerid,255, "First Degree Murder",0,0);
WantedLevel[playerid] = 0;//wantedlvl ok Wanted loose Wtdpts
SetPlayerWantedLevel(playerid,0);
//SendDeathMessage(killerid,playerid,reason);
Kills[playerid] = 0;
deaths[playerid]++;//top
if(FlashTime[killerid] == 0){FlashTime[killerid] = 10;}
}
else if (((gTeam[killerid]) == 3 || (gTeam[killerid]) == 1) && reason == 49)
{
SetPlayerCriminal(killerid,255, "Hit And Run",0,0);
WantedLevel[playerid] = 0;//wantedlvl ok Wanted loose Wtdpts
SetPlayerWantedLevel(playerid,0);
//SendDeathMessage(killerid,playerid,reason);
Kills[playerid] = 0;
deaths[playerid]++;//top
if(FlashTime[killerid] == 0){FlashTime[killerid] = 10;}
}
BroadCast(COLOR_RED, string);
}
else if (victimteam == 1)
{
if (gdebug){print("DEBUG test6");}
new killer[MAX_PLAYER_NAME];
GetPlayerName(killerid, killer, sizeof(killer));
// Civ kill
if ((gTeam[killerid]) == 2)//cops kill medic
{
format(string,128,".: Officer %s murdered Paramedic %s (%s) and was sued for $%d :.",killer,name,deathreason,suecost);
PlayerPlaySound(killerid, 1084, 0.0, 0.0, 0.0);
GivePlayerMoney(killerid, -suecost);
GivePlayerMoney(playerid, suecost+100);//+100pays hospital bill
WantedLevel[playerid] = 0;//wantedlvl ok Wanted loose Wtdpts
SetPlayerWantedLevel(playerid,0);
//SendDeathMessage(killerid,playerid,reason);
Kills[playerid] = 0;
deaths[playerid]++;//top
//SetPlayerPos(killerid,264.395200,77.564040,1001.039000);
/*SetPlayerInterior(killerid,6);
PlayerInfo[killerid][pInt] = 6;
SetPlayerPos(killerid,264.395200,77.564040,1001.039000);
//format(string, sizeof(string), " You have sent %s(player: %d) to jail.", giveplayer,giveplayerid);
//printf("AdmCmd: %s has jailed %s.", sendername, giveplayer);
//SendClientMessage(playerid, COLOR_GRAD1, string);
//SendClientMessage(giveplayerid, COLOR_GRAD1," You have been jailed for misconduct.");
PlayJailSound(1153 , 1154, 2000,264.395200, 77.564040, 1001.039000);
JailTime[killerid] = 10;
SendClientMessage(killerid, COLOR_RED, "Warning: You have been jailed for misconduct.");*/
}
else if ((gTeam[killerid]) == 1)//med kill medic
{
format(string,128,".: Paramedic %s murdered %s (%s) and was sued for $%d :.",killer,name,deathreason,suecost);
PlayerPlaySound(killerid, 1084, 0.0, 0.0, 0.0);
GivePlayerMoney(killerid, -suecost);
GivePlayerMoney(playerid, suecost+100);//+100pays hospital bill
WantedLevel[playerid] = 0;//wantedlvl ok Wanted loose Wtdpts
//SendDeathMessage(killerid,playerid,reason);
SetPlayerWantedLevel(playerid,0);
Kills[playerid] = 0;
deaths[playerid]++;//top
//SetPlayerPos(killerid,264.395200,77.564040,1001.039000);
/*SetPlayerInterior(killerid,6);
PlayerInfo[killerid][pInt] = 6;
SetPlayerPos(killerid,264.395200,77.564040,1001.039000);
PlayJailSound(1153 , 1154, 2000,264.395200, 77.564040, 1001.039000);
JailTime[killerid] = 60;
SendClientMessage(killerid, COLOR_RED, "Warning: You have been jailed for misconduct.");*/
}
else
{
format(string,128,".: %s murdered %s (%s) :.",killer,name,deathreason);
WantedLevel[playerid] = 0;//wantedlvl ok Wanted loose Wtdpts
//SendDeathMessage(killerid,playerid,reason);
SetPlayerWantedLevel(playerid,0);
Kills[playerid] = 0;
deaths[playerid]++;//top
//SetPlayerPos(killerid,264.395200,77.564040,1001.039000);
/*SetPlayerInterior(killerid,6);
PlayerInfo[killerid][pInt] = 6;
SetPlayerPos(killerid,264.395200,77.564040,1001.039000);
PlayJailSound(1153 , 1154, 2000,264.395200, 77.564040, 1001.039000);
JailTime[killerid] = 60;
SendClientMessage(killerid, COLOR_RED, "Warning: You have been jailed for misconduct.");*/
}
if (((gTeam[killerid]) == 4) && reason != 49)
{
SetPlayerCriminal(killerid,255, "First Degree Murder",0,0);
WantedLevel[playerid] = 0;//wantedlvl ok Wanted loose Wtdpts
//SendDeathMessage(killerid,playerid,reason);
SetPlayerWantedLevel(playerid,0);
Kills[playerid] = 0;
deaths[playerid]++;//top
//SetPlayerPos(killerid,264.395200,77.564040,1001.039000);
/*SetPlayerInterior(killerid,6);
PlayerInfo[killerid][pInt] = 6;
SetPlayerPos(killerid,264.395200,77.564040,1001.039000);
PlayJailSound(1153 , 1154, 2000,264.395200, 77.564040, 1001.039000);
JailTime[killerid] = 60;
SendClientMessage(killerid, COLOR_RED, "Warning: You have been jailed for misconduct.");*/
if(FlashTime[killerid] == 0){FlashTime[killerid] = 10;}
}
else if (((gTeam[killerid]) == 3) && reason == 49)
{
SetPlayerCriminal(killerid,255, "Hit And Run",0,0);
WantedLevel[playerid] = 0;//wantedlvl ok Wanted loose Wtdpts
//SendDeathMessage(killerid,playerid,reason);
SetPlayerWantedLevel(playerid,0);
Kills[playerid] = 0;
deaths[playerid]++;//top
//SetPlayerPos(killerid,264.395200,77.564040,1001.039000);
/*SetPlayerInterior(killerid,6);
PlayerInfo[killerid][pInt] = 6;
SetPlayerPos(killerid,264.395200,77.564040,1001.039000);
PlayJailSound(1153 , 1154, 2000,264.395200, 77.564040, 1001.039000);
JailTime[killerid] = 60;
SendClientMessage(killerid, COLOR_RED, "Warning: You have been jailed for misconduct.");*/
if(FlashTime[killerid] == 0){FlashTime[killerid] = 10;}
}
BroadCast(COLOR_RED, string);
}
if (gSuperCop == playerid)
{
gSuperCop = INVALID_PLAYER_ID;
}
if(GetPlayerState(killerid) == 1)
{
lastkiller = killerid;
}
killerid = INVALID_PLAYER_ID;
SetPlayerColor(playerid,COLOR_GRAD2);
WantedLevel[playerid] = 0;//wantedlvl ok Wanted loose Wtdpts
SetPlayerWantedLevel(playerid,0);
//SendDeathMessage(killerid,playerid,reason);
Kills[playerid] = 0;
deaths[playerid]++;//top
return 1;
}
public jailrelease(killerid)
{
SpawnPlayer(killerid);
SetPlayerInterior(killerid,0);
IsPlayerInJail[killerid] = 0;
ResetPlayerWeapons(killerid);
GivePlayerWeapon(killerid,24,300);
}
//========================gamemodeinit============================================//
warzone = GangZoneCreate(1195.1074,-1400.1536,917.5000,-1571.2161);
SetTimer("CheckArea", 250, 1); // Timer for DM Zones
public CheckArea(playerid) //<------------------ ATTENTION C CHECKAREA(playerid) et PAS CHECKAREA() !!! Fait gaffe a ton forward CheckArea(playerid); aussi!
{
for(new i = 0; i <= MAX_PLAYERS; i++)
{
if(IsPlayerInArea(i, 917.5000, 1195.1074, -1571.2161, -1400.1536))//DM Zone LS Hospital
{
GameTextForPlayer(i,"~r~WARNING!! ~w~DM ZONE!!!!",5000,1);
}
}
return 1;
}