UGH where exactly did someone ask for "compile help" in a thread about a decompiler.
PHP Code:
public PlVers:__version =
{
version = 5,
filevers = "1.8.0.5843",
date = "03/09/2016",
time = "22:05:49"
};
new Float:NULL_VECTOR[3];
new String:NULL_STRING[4];
public Extension:__ext_core =
{
name = "Core",
file = "core",
autoload = 0,
required = 0,
};
new MaxClients;
public Extension:__ext_sdktools =
{
name = "SDKTools",
file = "sdktools.ext",
autoload = 1,
required = 1,
};
public Extension:__ext_cstrike =
{
name = "cstrike",
file = "games/game.cstrike.ext",
autoload = 0,
required = 1,
};
new String:CTag[12][0];
new String:CTagCode[12][16] =
{
"\x01",
"\x02",
"\x04",
"\x03",
"\x03",
"\x03",
"\x05",
"",
"\x07",
"\x03",
"\x08",
" "
};
new bool:CTagReqSayText2[12] =
{
0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0
};
new bool:CEventIsHooked;
new bool:CSkipList[66];
new bool:CProfile_Colors[12] =
{
1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0
};
new CProfile_TeamIndex[10] =
{
-1, ...
};
new bool:CProfile_SayText2;
new Handle:sm_show_activity = 1635151433;
new Handle:CountdownTimer;
new ConVar:g_cvFriendlyFire;
new Menu:g_PrimaryWeapon;
new Menu:g_SecundaryWeapon;
new bool:CountdownActive;
new bool:ffAktif;
public Plugin:myinfo =
{
name = "FFMENU",
description = "dost atesi",
author = "EmreBulut",
version = "1.0",
url = "emrebulut"
};
public __ext_core_SetNTVOptional()
{
MarkNativeAsOptional("GetFeatureStatus");
MarkNativeAsOptional("RequireFeature");
MarkNativeAsOptional("AddCommandListener");
MarkNativeAsOptional("RemoveCommandListener");
MarkNativeAsOptional("BfWriteBool");
MarkNativeAsOptional("BfWriteByte");
MarkNativeAsOptional("BfWriteChar");
MarkNativeAsOptional("BfWriteShort");
MarkNativeAsOptional("BfWriteWord");
MarkNativeAsOptional("BfWriteNum");
MarkNativeAsOptional("BfWriteFloat");
MarkNativeAsOptional("BfWriteString");
MarkNativeAsOptional("BfWriteEntity");
MarkNativeAsOptional("BfWriteAngle");
MarkNativeAsOptional("BfWriteCoord");
MarkNativeAsOptional("BfWriteVecCoord");
MarkNativeAsOptional("BfWriteVecNormal");
MarkNativeAsOptional("BfWriteAngles");
MarkNativeAsOptional("BfReadBool");
MarkNativeAsOptional("BfReadByte");
MarkNativeAsOptional("BfReadChar");
MarkNativeAsOptional("BfReadShort");
MarkNativeAsOptional("BfReadWord");
MarkNativeAsOptional("BfReadNum");
MarkNativeAsOptional("BfReadFloat");
MarkNativeAsOptional("BfReadString");
MarkNativeAsOptional("BfReadEntity");
MarkNativeAsOptional("BfReadAngle");
MarkNativeAsOptional("BfReadCoord");
MarkNativeAsOptional("BfReadVecCoord");
MarkNativeAsOptional("BfReadVecNormal");
MarkNativeAsOptional("BfReadAngles");
MarkNativeAsOptional("BfGetNumBytesLeft");
MarkNativeAsOptional("BfWrite.WriteBool");
MarkNativeAsOptional("BfWrite.WriteByte");
MarkNativeAsOptional("BfWrite.WriteChar");
MarkNativeAsOptional("BfWrite.WriteShort");
MarkNativeAsOptional("BfWrite.WriteWord");
MarkNativeAsOptional("BfWrite.WriteNum");
MarkNativeAsOptional("BfWrite.WriteFloat");
MarkNativeAsOptional("BfWrite.WriteString");
MarkNativeAsOptional("BfWrite.WriteEntity");
MarkNativeAsOptional("BfWrite.WriteAngle");
MarkNativeAsOptional("BfWrite.WriteCoord");
MarkNativeAsOptional("BfWrite.WriteVecCoord");
MarkNativeAsOptional("BfWrite.WriteVecNormal");
MarkNativeAsOptional("BfWrite.WriteAngles");
MarkNativeAsOptional("BfRead.ReadBool");
MarkNativeAsOptional("BfRead.ReadByte");
MarkNativeAsOptional("BfRead.ReadChar");
MarkNativeAsOptional("BfRead.ReadShort");
MarkNativeAsOptional("BfRead.ReadWord");
MarkNativeAsOptional("BfRead.ReadNum");
MarkNativeAsOptional("BfRead.ReadFloat");
MarkNativeAsOptional("BfRead.ReadString");
MarkNativeAsOptional("BfRead.ReadEntity");
MarkNativeAsOptional("BfRead.ReadAngle");
MarkNativeAsOptional("BfRead.ReadCoord");
MarkNativeAsOptional("BfRead.ReadVecCoord");
MarkNativeAsOptional("BfRead.ReadVecNormal");
MarkNativeAsOptional("BfRead.ReadAngles");
MarkNativeAsOptional("BfRead.GetNumBytesLeft");
MarkNativeAsOptional("PbReadInt");
MarkNativeAsOptional("PbReadFloat");
MarkNativeAsOptional("PbReadBool");
MarkNativeAsOptional("PbReadString");
MarkNativeAsOptional("PbReadColor");
MarkNativeAsOptional("PbReadAngle");
MarkNativeAsOptional("PbReadVector");
MarkNativeAsOptional("PbReadVector2D");
MarkNativeAsOptional("PbGetRepeatedFieldCount");
MarkNativeAsOptional("PbSetInt");
MarkNativeAsOptional("PbSetFloat");
MarkNativeAsOptional("PbSetBool");
MarkNativeAsOptional("PbSetString");
MarkNativeAsOptional("PbSetColor");
MarkNativeAsOptional("PbSetAngle");
MarkNativeAsOptional("PbSetVector");
MarkNativeAsOptional("PbSetVector2D");
MarkNativeAsOptional("PbAddInt");
MarkNativeAsOptional("PbAddFloat");
MarkNativeAsOptional("PbAddBool");
MarkNativeAsOptional("PbAddString");
MarkNativeAsOptional("PbAddColor");
MarkNativeAsOptional("PbAddAngle");
MarkNativeAsOptional("PbAddVector");
MarkNativeAsOptional("PbAddVector2D");
MarkNativeAsOptional("PbRemoveRepeatedFieldValue");
MarkNativeAsOptional("PbReadMessage");
MarkNativeAsOptional("PbReadRepeatedMessage");
MarkNativeAsOptional("PbAddMessage");
MarkNativeAsOptional("Protobuf.ReadInt");
MarkNativeAsOptional("Protobuf.ReadFloat");
MarkNativeAsOptional("Protobuf.ReadBool");
MarkNativeAsOptional("Protobuf.ReadString");
MarkNativeAsOptional("Protobuf.ReadColor");
MarkNativeAsOptional("Protobuf.ReadAngle");
MarkNativeAsOptional("Protobuf.ReadVector");
MarkNativeAsOptional("Protobuf.ReadVector2D");
MarkNativeAsOptional("Protobuf.GetRepeatedFieldCount");
MarkNativeAsOptional("Protobuf.SetInt");
MarkNativeAsOptional("Protobuf.SetFloat");
MarkNativeAsOptional("Protobuf.SetBool");
MarkNativeAsOptional("Protobuf.SetString");
MarkNativeAsOptional("Protobuf.SetColor");
MarkNativeAsOptional("Protobuf.SetAngle");
MarkNativeAsOptional("Protobuf.SetVector");
MarkNativeAsOptional("Protobuf.SetVector2D");
MarkNativeAsOptional("Protobuf.AddInt");
MarkNativeAsOptional("Protobuf.AddFloat");
MarkNativeAsOptional("Protobuf.AddBool");
MarkNativeAsOptional("Protobuf.AddString");
MarkNativeAsOptional("Protobuf.AddColor");
MarkNativeAsOptional("Protobuf.AddAngle");
MarkNativeAsOptional("Protobuf.AddVector");
MarkNativeAsOptional("Protobuf.AddVector2D");
MarkNativeAsOptional("Protobuf.RemoveRepeatedFieldValue");
MarkNativeAsOptional("Protobuf.ReadMessage");
MarkNativeAsOptional("Protobuf.ReadRepeatedMessage");
MarkNativeAsOptional("Protobuf.AddMessage");
VerifyCoreVersion();
return 0;
}
public .2920.StrEqual(String:str1[], String:str2[], bool:caseSensitive)
{
return strcmp(str1, str2, caseSensitive) == 0;
}
public .2920.StrEqual(String:str1[], String:str2[], bool:caseSensitive)
{
return strcmp(str1, str2, caseSensitive) == 0;
}
public .2972.StartMessageOne(String:msgname[], client, flags)
{
new players[1];
players[0] = client;
return StartMessage(msgname, players, 1, flags);
}
public .2972.StartMessageOne(String:msgname[], client, flags)
{
new players[1];
players[0] = client;
return StartMessage(msgname, players, 1, flags);
}
public .3096.PrintHintTextToAll(String:format[])
{
decl String:buffer[256];
new i = 1;
while (i <= MaxClients)
{
if (IsClientInGame(i))
{
SetGlobalTransTarget(i);
VFormat(buffer, 254, format, 2);
PrintHintText(i, "%s", buffer);
}
i++;
}
return 0;
}
public .3096.PrintHintTextToAll(String:format[])
{
decl String:buffer[256];
new i = 1;
while (i <= MaxClients)
{
if (IsClientInGame(i))
{
SetGlobalTransTarget(i);
VFormat(buffer, 254, format, 2);
PrintHintText(i, "%s", buffer);
}
i++;
}
return 0;
}
public .3348.CPrintToChat(client, String:szMessage[])
{
new var1;
if (client <= 0 || client > MaxClients)
{
ThrowError(sm_show_activity, client);
}
if (!IsClientInGame(client))
{
ThrowError("Client %d is not in game", client);
}
new var2;
decl String:szBuffer[252];
SetGlobalTransTarget(client);
Format(szBuffer, 250, "\x01%s", szMessage);
VFormat(var2, 250, szBuffer, 3);
var2 = .4276.CFormat(var2, 250, -1);
if (var2 == -1)
{
PrintToChat(client, "%s", var2);
}
else
{
.6120.CSayText2(client, var2, var2);
}
return 0;
}
public .3348.CPrintToChat(client, String:szMessage[])
{
new var1;
if (client <= 0 || client > MaxClients)
{
ThrowError(sm_show_activity, client);
}
if (!IsClientInGame(client))
{
ThrowError("Client %d is not in game", client);
}
new var2;
decl String:szBuffer[252];
SetGlobalTransTarget(client);
Format(szBuffer, 250, "\x01%s", szMessage);
VFormat(var2, 250, szBuffer, 3);
var2 = .4276.CFormat(var2, 250, -1);
if (var2 == -1)
{
PrintToChat(client, "%s", var2);
}
else
{
.6120.CSayText2(client, var2, var2);
}
return 0;
}
public .3876.CPrintToChatAll(String:szMessage[])
{
decl String:szBuffer[252];
new i = 1;
while (i <= MaxClients)
{
new var1;
if (IsClientInGame(i) && !IsFakeClient(i) && !CSkipList[i])
{
SetGlobalTransTarget(i);
VFormat(szBuffer, 250, szMessage, 2);
.3348.CPrintToChat(i, "%s", szBuffer);
}
CSkipList[i] = 0;
i++;
}
return 0;
}
public .3876.CPrintToChatAll(String:szMessage[])
{
decl String:szBuffer[252];
new i = 1;
while (i <= MaxClients)
{
new var1;
if (IsClientInGame(i) && !IsFakeClient(i) && !CSkipList[i])
{
SetGlobalTransTarget(i);
VFormat(szBuffer, 250, szMessage, 2);
.3348.CPrintToChat(i, "%s", szBuffer);
}
CSkipList[i] = 0;
i++;
}
return 0;
}
public .4276.CFormat(String:szMessage[], maxlength, author)
{
decl String:szGameName[32];
GetGameFolderName(szGameName, 30);
if (!CEventIsHooked)
{
.6684.CSetupProfile();
HookEvent("server_spawn", CEvent_MapStart, EventHookMode:2);
CEventIsHooked = true;
}
new iRandomPlayer = -1;
if (.2920.StrEqual(szGameName, "csgo", false))
{
Format(szMessage, maxlength, " \x01\x01%s", szMessage);
}
if (author != -1)
{
if (CProfile_SayText2)
{
ReplaceString(szMessage, maxlength, "{teamcolor}", "\x03", false);
iRandomPlayer = author;
}
else
{
ReplaceString(szMessage, maxlength, "{teamcolor}", CTagCode[2], false);
}
}
else
{
ReplaceString(szMessage, maxlength, "{teamcolor}", "", false);
}
new i;
while (i < 12)
{
if (!(StrContains(szMessage, CTag[i], false) == -1))
{
if (!CProfile_Colors[i])
{
ReplaceString(szMessage, maxlength, CTag[i], CTagCode[2], false);
}
else
{
if (!CTagReqSayText2[i])
{
ReplaceString(szMessage, maxlength, CTag[i], CTagCode[i], false);
}
if (!CProfile_SayText2)
{
ReplaceString(szMessage, maxlength, CTag[i], CTagCode[2], false);
}
if (iRandomPlayer == -1)
{
iRandomPlayer = .5868.CFindRandomPlayerByTeam(CProfile_TeamIndex[i]);
if (iRandomPlayer == -2)
{
ReplaceString(szMessage, maxlength, CTag[i], CTagCode[2], false);
}
else
{
ReplaceString(szMessage, maxlength, CTag[i], CTagCode[i], false);
}
}
ThrowError("Using two team colors in one message is not allowed");
}
}
i++;
}
return iRandomPlayer;
}
public .4276.CFormat(String:szMessage[], maxlength, author)
{
decl String:szGameName[32];
GetGameFolderName(szGameName, 30);
if (!CEventIsHooked)
{
.6684.CSetupProfile();
HookEvent("server_spawn", CEvent_MapStart, EventHookMode:2);
CEventIsHooked = true;
}
new iRandomPlayer = -1;
if (.2920.StrEqual(szGameName, "csgo", false))
{
Format(szMessage, maxlength, " \x01\x01%s", szMessage);
}
if (author != -1)
{
if (CProfile_SayText2)
{
ReplaceString(szMessage, maxlength, "{teamcolor}", "\x03", false);
iRandomPlayer = author;
}
else
{
ReplaceString(szMessage, maxlength, "{teamcolor}", CTagCode[2], false);
}
}
else
{
ReplaceString(szMessage, maxlength, "{teamcolor}", "", false);
}
new i;
while (i < 12)
{
if (!(StrContains(szMessage, CTag[i], false) == -1))
{
if (!CProfile_Colors[i])
{
ReplaceString(szMessage, maxlength, CTag[i], CTagCode[2], false);
}
else
{
if (!CTagReqSayText2[i])
{
ReplaceString(szMessage, maxlength, CTag[i], CTagCode[i], false);
}
if (!CProfile_SayText2)
{
ReplaceString(szMessage, maxlength, CTag[i], CTagCode[2], false);
}
if (iRandomPlayer == -1)
{
iRandomPlayer = .5868.CFindRandomPlayerByTeam(CProfile_TeamIndex[i]);
if (iRandomPlayer == -2)
{
ReplaceString(szMessage, maxlength, CTag[i], CTagCode[2], false);
}
else
{
ReplaceString(szMessage, maxlength, CTag[i], CTagCode[i], false);
}
}
ThrowError("Using two team colors in one message is not allowed");
}
}
i++;
}
return iRandomPlayer;
}
public .5868.CFindRandomPlayerByTeam(color_team)
{
if (color_team)
{
new i = 1;
while (i <= MaxClients)
{
new var1;
if (IsClientInGame(i) && color_team == GetClientTeam(i))
{
return i;
}
i++;
}
return -2;
}
return 0;
}
public .5868.CFindRandomPlayerByTeam(color_team)
{
if (color_team)
{
new i = 1;
while (i <= MaxClients)
{
new var1;
if (IsClientInGame(i) && color_team == GetClientTeam(i))
{
return i;
}
i++;
}
return -2;
}
return 0;
}
public .6120.CSayText2(client, author, String:szMessage[])
{
new Handle:hBuffer = .2972.StartMessageOne("SayText2", client, 132);
new var1;
if (GetFeatureStatus(FeatureType:0, "GetUserMessageType") && GetUserMessageType() == 1)
{
PbSetInt(hBuffer, "ent_idx", author, -1);
PbSetBool(hBuffer, "chat", true, -1);
PbSetString(hBuffer, "msg_name", szMessage, -1);
PbAddString(hBuffer, "params", "");
PbAddString(hBuffer, "params", "");
PbAddString(hBuffer, "params", "");
PbAddString(hBuffer, "params", "");
}
else
{
BfWriteByte(hBuffer, author);
BfWriteByte(hBuffer, 1);
BfWriteString(hBuffer, szMessage);
}
EndMessage();
return 0;
}
public .6120.CSayText2(client, author, String:szMessage[])
{
new Handle:hBuffer = .2972.StartMessageOne("SayText2", client, 132);
new var1;
if (GetFeatureStatus(FeatureType:0, "GetUserMessageType") && GetUserMessageType() == 1)
{
PbSetInt(hBuffer, "ent_idx", author, -1);
PbSetBool(hBuffer, "chat", true, -1);
PbSetString(hBuffer, "msg_name", szMessage, -1);
PbAddString(hBuffer, "params", "");
PbAddString(hBuffer, "params", "");
PbAddString(hBuffer, "params", "");
PbAddString(hBuffer, "params", "");
}
else
{
BfWriteByte(hBuffer, author);
BfWriteByte(hBuffer, 1);
BfWriteString(hBuffer, szMessage);
}
EndMessage();
return 0;
}
public .6684.CSetupProfile()
{
decl String:szGameName[32];
GetGameFolderName(szGameName, 30);
if (.2920.StrEqual(szGameName, "cstrike", false))
{
CProfile_Colors[3] = 1;
CProfile_Colors[4] = 1;
CProfile_Colors[5] = 1;
CProfile_Colors[6] = 1;
CProfile_TeamIndex[3] = 0;
CProfile_TeamIndex[4] = 2;
CProfile_TeamIndex[5] = 3;
CProfile_SayText2 = true;
}
else
{
if (.2920.StrEqual(szGameName, "csgo", false))
{
CProfile_Colors[4] = 1;
CProfile_Colors[5] = 1;
CProfile_Colors[6] = 1;
CProfile_Colors[1] = 1;
CProfile_Colors[7] = 1;
CProfile_Colors[8] = 1;
CProfile_Colors[9] = 1;
CProfile_Colors[10] = 1;
CProfile_Colors[11] = 1;
CProfile_TeamIndex[4] = 2;
CProfile_TeamIndex[5] = 3;
CProfile_SayText2 = true;
}
if (.2920.StrEqual(szGameName, "tf", false))
{
CProfile_Colors[3] = 1;
CProfile_Colors[4] = 1;
CProfile_Colors[5] = 1;
CProfile_Colors[6] = 1;
CProfile_TeamIndex[3] = 0;
CProfile_TeamIndex[4] = 2;
CProfile_TeamIndex[5] = 3;
CProfile_SayText2 = true;
}
new var1;
if (.2920.StrEqual(szGameName, "left4dead", false) || .2920.StrEqual(szGameName, "left4dead2", false))
{
CProfile_Colors[3] = 1;
CProfile_Colors[4] = 1;
CProfile_Colors[5] = 1;
CProfile_Colors[6] = 1;
CProfile_TeamIndex[3] = 0;
CProfile_TeamIndex[4] = 3;
CProfile_TeamIndex[5] = 2;
CProfile_SayText2 = true;
}
if (.2920.StrEqual(szGameName, "hl2mp", false))
{
if (GetConVarBool(FindConVar("mp_teamplay")))
{
CProfile_Colors[4] = 1;
CProfile_Colors[5] = 1;
CProfile_Colors[6] = 1;
CProfile_TeamIndex[4] = 3;
CProfile_TeamIndex[5] = 2;
CProfile_SayText2 = true;
}
else
{
CProfile_SayText2 = false;
CProfile_Colors[6] = 1;
}
}
if (.2920.StrEqual(szGameName, "dod", false))
{
CProfile_Colors[6] = 1;
CProfile_SayText2 = false;
}
if (GetUserMessageId("SayText2") == -1)
{
CProfile_SayText2 = false;
}
CProfile_Colors[4] = 1;
CProfile_Colors[5] = 1;
CProfile_TeamIndex[4] = 2;
CProfile_TeamIndex[5] = 3;
CProfile_SayText2 = true;
}
return 0;
}
public .6684.CSetupProfile()
{
decl String:szGameName[32];
GetGameFolderName(szGameName, 30);
if (.2920.StrEqual(szGameName, "cstrike", false))
{
CProfile_Colors[3] = 1;
CProfile_Colors[4] = 1;
CProfile_Colors[5] = 1;
CProfile_Colors[6] = 1;
CProfile_TeamIndex[3] = 0;
CProfile_TeamIndex[4] = 2;
CProfile_TeamIndex[5] = 3;
CProfile_SayText2 = true;
}
else
{
if (.2920.StrEqual(szGameName, "csgo", false))
{
CProfile_Colors[4] = 1;
CProfile_Colors[5] = 1;
CProfile_Colors[6] = 1;
CProfile_Colors[1] = 1;
CProfile_Colors[7] = 1;
CProfile_Colors[8] = 1;
CProfile_Colors[9] = 1;
CProfile_Colors[10] = 1;
CProfile_Colors[11] = 1;
CProfile_TeamIndex[4] = 2;
CProfile_TeamIndex[5] = 3;
CProfile_SayText2 = true;
}
if (.2920.StrEqual(szGameName, "tf", false))
{
CProfile_Colors[3] = 1;
CProfile_Colors[4] = 1;
CProfile_Colors[5] = 1;
CProfile_Colors[6] = 1;
CProfile_TeamIndex[3] = 0;
CProfile_TeamIndex[4] = 2;
CProfile_TeamIndex[5] = 3;
CProfile_SayText2 = true;
}
new var1;
if (.2920.StrEqual(szGameName, "left4dead", false) || .2920.StrEqual(szGameName, "left4dead2", false))
{
CProfile_Colors[3] = 1;
CProfile_Colors[4] = 1;
CProfile_Colors[5] = 1;
CProfile_Colors[6] = 1;
CProfile_TeamIndex[3] = 0;
CProfile_TeamIndex[4] = 3;
CProfile_TeamIndex[5] = 2;
CProfile_SayText2 = true;
}
if (.2920.StrEqual(szGameName, "hl2mp", false))
{
if (GetConVarBool(FindConVar("mp_teamplay")))
{
CProfile_Colors[4] = 1;
CProfile_Colors[5] = 1;
CProfile_Colors[6] = 1;
CProfile_TeamIndex[4] = 3;
CProfile_TeamIndex[5] = 2;
CProfile_SayText2 = true;
}
else
{
CProfile_SayText2 = false;
CProfile_Colors[6] = 1;
}
}
if (.2920.StrEqual(szGameName, "dod", false))
{
CProfile_Colors[6] = 1;
CProfile_SayText2 = false;
}
if (GetUserMessageId("SayText2") == -1)
{
CProfile_SayText2 = false;
}
CProfile_Colors[4] = 1;
CProfile_Colors[5] = 1;
CProfile_TeamIndex[4] = 2;
CProfile_TeamIndex[5] = 3;
CProfile_SayText2 = true;
}
return 0;
}
public Action:CEvent_MapStart(Handle:event, String:name[], bool:dontBroadcast)
{
.6684.CSetupProfile();
new i = 1;
while (i <= MaxClients)
{
CSkipList[i] = 0;
i++;
}
return Action:0;
}
public void:OnPluginStart()
{
RegAdminCmd("sm_ffmenu", calistir, 128, "", "", 0);
HookEvent("round_end", OnRoundEnd, EventHookMode:1);
ServerCommand("mp_solid_teammates 0");
g_cvFriendlyFire = FindConVar("mp_teammates_are_enemies");
return void:0;
}
public void:OnMapStart()
{
g_PrimaryWeapon = .13228.BuildPrimaryWeaponMenu();
g_SecundaryWeapon = .14016.BuildSecundaryWeaponMenu();
return void:0;
}
public void:OnMapEnd()
{
if (g_PrimaryWeapon)
{
CloseHandle(g_PrimaryWeapon);
g_PrimaryWeapon = MissingTAG:0;
g_PrimaryWeapon = MissingTAG:0;
}
if (g_SecundaryWeapon)
{
CloseHandle(g_SecundaryWeapon);
g_SecundaryWeapon = MissingTAG:0;
g_SecundaryWeapon = MissingTAG:0;
}
return void:0;
}
public Action:OnRoundEnd(Handle:event, String:name[], bool:dontBroadcast)
{
new var1;
if (ffAktif || CountdownActive)
{
CloseHandle(CountdownTimer);
CountdownTimer = MissingTAG:0;
ConVar.IntValue.set(g_cvFriendlyFire, 0);
ffAktif = false;
CountdownActive = false;
ServerCommand("sm_cvar mp_teammates_are_enemies 0");
}
return Action:0;
}
public Action:calistir(client, args)
{
new maxClients = GetMaxClients();
new i = 1;
while (i <= maxClients)
{
new var1;
if (IsClientInGame(i) && IsPlayerAlive(i) && !IsFakeClient(i))
{
Menu.Display(g_PrimaryWeapon, i, 0);
}
i++;
}
new Handle:menu = CreateMenu(MenuDevam, MenuAction:28);
SetMenuTitle(menu, "FF MENU BY EMRE BULUT");
decl String:opcionmenu[124];
Format(opcionmenu, 124, "Hemen ff baslat");
AddMenuItem(menu, "option1", opcionmenu, 0);
Format(opcionmenu, 124, "FF kapat");
AddMenuItem(menu, "option2", opcionmenu, 0);
Format(opcionmenu, 124, "10 Sn. sonra ff baslat");
AddMenuItem(menu, "option3", opcionmenu, 0);
Format(opcionmenu, 124, "20 Sn. sonra ff baslat");
AddMenuItem(menu, "option4", opcionmenu, 0);
Format(opcionmenu, 124, "30 Sn. sonra ff baslat");
AddMenuItem(menu, "option5", opcionmenu, 0);
Format(opcionmenu, 124, "40 Sn. sonra ff baslat");
AddMenuItem(menu, "option6", opcionmenu, 0);
Format(opcionmenu, 124, "50 Sn. sonra ff baslat");
AddMenuItem(menu, "option7", opcionmenu, 0);
Format(opcionmenu, 124, "60 Sn. sonra ff baslat");
AddMenuItem(menu, "option8", opcionmenu, 0);
SetMenuExitButton(menu, true);
DisplayMenu(menu, client, 0);
return Action:3;
}
public MenuDevam(Handle:menu, MenuAction:action, client, itemNum)
{
if (action == MenuAction:4)
{
new String:info[32];
GetMenuItem(menu, itemNum, info, 32, 0, "", 0);
if (strcmp(info, "option1", true))
{
if (strcmp(info, "option2", true))
{
if (strcmp(info, "option3", true))
{
if (strcmp(info, "option4", true))
{
if (strcmp(info, "option5", true))
{
if (strcmp(info, "option6", true))
{
if (strcmp(info, "option7", true))
{
if (!(strcmp(info, "option8", true)))
{
CountdownActive = true;
CountdownTimer = CreateTimer(1.0, Countdown6, any:0, 1);
}
}
CountdownActive = true;
CountdownTimer = CreateTimer(1.0, Countdown5, any:0, 1);
}
CountdownActive = true;
CountdownTimer = CreateTimer(1.0, Countdown4, any:0, 1);
}
CountdownActive = true;
CountdownTimer = CreateTimer(1.0, Countdown3, any:0, 1);
}
CountdownActive = true;
CountdownTimer = CreateTimer(1.0, Countdown2, any:0, 1);
}
CountdownActive = true;
CountdownTimer = CreateTimer(1.0, Countdown, any:0, 1);
}
ServerCommand("sm_cvar mp_teammates_are_enemies 0");
.3876.CPrintToChatAll("{darkred}FF Kapatıldı !");
}
else
{
ServerCommand("sm_cvar mp_teammates_are_enemies 1");
.3876.CPrintToChatAll("{darkred}FF Acıldı Savas Baslasın !");
}
}
return 0;
}
public Action:Countdown(Handle:timer)
{
static numPrinted;
new timeleft = 10 - numPrinted;
.3096.PrintHintTextToAll("Dost atesi %i saniye icerisinde acilacak", timeleft);
if (timeleft)
{
numPrinted += 1;
return Action:0;
}
numPrinted = 0;
FFBaslat();
return Action:4;
}
public Action:Countdown2(Handle:timer)
{
static numPrinted;
new timeleft = 20 - numPrinted;
.3096.PrintHintTextToAll("Dost atesi %i saniye icerisinde acilacak", timeleft);
if (timeleft)
{
numPrinted += 1;
return Action:0;
}
numPrinted = 0;
FFBaslat();
return Action:4;
}
public Action:Countdown3(Handle:timer)
{
static numPrinted;
new timeleft = 30 - numPrinted;
.3096.PrintHintTextToAll("Dost atesi %i saniye icerisinde acilacak", timeleft);
if (timeleft)
{
numPrinted += 1;
return Action:0;
}
numPrinted = 0;
FFBaslat();
return Action:4;
}
public Action:Countdown4(Handle:timer)
{
static numPrinted;
new timeleft = 40 - numPrinted;
.3096.PrintHintTextToAll("Dost atesi %i saniye icerisinde acilacak", timeleft);
if (timeleft)
{
numPrinted += 1;
return Action:0;
}
numPrinted = 0;
FFBaslat();
return Action:4;
}
public Action:Countdown5(Handle:timer)
{
static numPrinted;
new timeleft = 50 - numPrinted;
.3096.PrintHintTextToAll("Dost atesi %i saniye icerisinde acilacak", timeleft);
if (timeleft)
{
numPrinted += 1;
return Action:0;
}
numPrinted = 0;
FFBaslat();
return Action:4;
}
public Action:Countdown6(Handle:timer)
{
static numPrinted;
new timeleft = 60 - numPrinted;
.3096.PrintHintTextToAll("Dost atesi %i saniye icerisinde acilacak", timeleft);
if (timeleft)
{
numPrinted += 1;
return Action:0;
}
numPrinted = 0;
FFBaslat();
return Action:4;
}
public FFBaslat()
{
ConVar.IntValue.set(g_cvFriendlyFire, 1);
.3096.PrintHintTextToAll("Dost atesi acildi! Savas baslasin!");
CountdownActive = false;
ffAktif = true;
CountdownTimer = MissingTAG:0;
return 0;
}
public .13228.BuildPrimaryWeaponMenu()
{
new Menu:menu1 = Menu.Menu(Menu_Primary, MenuAction:28);
Menu.AddItem(menu1, "weapon_ak47", "AK47", 0);
Menu.AddItem(menu1, "weapon_m4a1", "M4A4", 0);
Menu.AddItem(menu1, "weapon_m4a1_silencer", "M4A1-S", 0);
Menu.AddItem(menu1, "weapon_awp", "AWP", 0);
Menu.AddItem(menu1, "weapon_ssg08", "SCOUT", 0);
Menu.AddItem(menu1, "weapon_galilar", "GALIL", 0);
Menu.AddItem(menu1, "weapon_famas", "FAMAS", 0);
Menu.AddItem(menu1, "weapon_p90", "P90", 0);
Menu.AddItem(menu1, "weapon_aug", "AUG", 0);
Menu.AddItem(menu1, "weapon_sg553", "SG553", 0);
Menu.SetTitle(menu1, "Birincil silahinizi secin.");
return menu1;
}
public .13228.BuildPrimaryWeaponMenu()
{
new Menu:menu1 = Menu.Menu(Menu_Primary, MenuAction:28);
Menu.AddItem(menu1, "weapon_ak47", "AK47", 0);
Menu.AddItem(menu1, "weapon_m4a1", "M4A4", 0);
Menu.AddItem(menu1, "weapon_m4a1_silencer", "M4A1-S", 0);
Menu.AddItem(menu1, "weapon_awp", "AWP", 0);
Menu.AddItem(menu1, "weapon_ssg08", "SCOUT", 0);
Menu.AddItem(menu1, "weapon_galilar", "GALIL", 0);
Menu.AddItem(menu1, "weapon_famas", "FAMAS", 0);
Menu.AddItem(menu1, "weapon_p90", "P90", 0);
Menu.AddItem(menu1, "weapon_aug", "AUG", 0);
Menu.AddItem(menu1, "weapon_sg553", "SG553", 0);
Menu.SetTitle(menu1, "Birincil silahinizi secin.");
return menu1;
}
public Menu_Primary(Menu:menu1, MenuAction:action, param1, param2)
{
if (action == MenuAction:4)
{
new String:weapon_id[32];
Menu.GetItem(menu1, param2, weapon_id, 32, 0, "", 0);
GivePlayerItem(param1, weapon_id, 0);
Menu.Display(g_SecundaryWeapon, param1, 0);
}
return 0;
}
public .14016.BuildSecundaryWeaponMenu()
{
new Menu:menu2 = Menu.Menu(Menu_Secundary, MenuAction:28);
Menu.AddItem(menu2, "weapon_revolver", "R8 REVOLVER", 0);
Menu.AddItem(menu2, "weapon_deagle", "DEAGLE", 0);
Menu.AddItem(menu2, "weapon_usp_silencer", "USP-S", 0);
Menu.AddItem(menu2, "weapon_hkp2000", "P2000", 0);
Menu.AddItem(menu2, "weapon_glock", "GLOCK", 0);
Menu.AddItem(menu2, "weapon_fiveseven", "FIVESEVEN", 0);
Menu.AddItem(menu2, "weapon_tec9", "TEC9", 0);
Menu.AddItem(menu2, "weapon_elite", "CIFT BERETTA", 0);
Menu.AddItem(menu2, "weapon_p250", "P250", 0);
Menu.AddItem(menu2, "weapon_cz75a", "CZ75", 0);
Menu.SetTitle(menu2, "Ikincil silahinizi secin.");
return menu2;
}
public .14016.BuildSecundaryWeaponMenu()
{
new Menu:menu2 = Menu.Menu(Menu_Secundary, MenuAction:28);
Menu.AddItem(menu2, "weapon_revolver", "R8 REVOLVER", 0);
Menu.AddItem(menu2, "weapon_deagle", "DEAGLE", 0);
Menu.AddItem(menu2, "weapon_usp_silencer", "USP-S", 0);
Menu.AddItem(menu2, "weapon_hkp2000", "P2000", 0);
Menu.AddItem(menu2, "weapon_glock", "GLOCK", 0);
Menu.AddItem(menu2, "weapon_fiveseven", "FIVESEVEN", 0);
Menu.AddItem(menu2, "weapon_tec9", "TEC9", 0);
Menu.AddItem(menu2, "weapon_elite", "CIFT BERETTA", 0);
Menu.AddItem(menu2, "weapon_p250", "P250", 0);
Menu.AddItem(menu2, "weapon_cz75a", "CZ75", 0);
Menu.SetTitle(menu2, "Ikincil silahinizi secin.");
return menu2;
}
public Menu_Secundary(Menu:menu2, MenuAction:action, param1, param2)
{
if (action == MenuAction:4)
{
new String:weapon_id[32];
Menu.GetItem(menu2, param2, weapon_id, 32, 0, "", 0);
GivePlayerItem(param1, weapon_id, 0);
GivePlayerItem(param1, "weapon_hegrenade", 0);
}
return 0;
}