29.10.2010, 05:18
Hola quisiera saver como pasar este pwn a fs
Aqui el codigo
Aqui el pwn
[mediafire]http://www.mediafire.com/?aa3k4vnijmpjvbn[/mediafire]
:adios: Muchas gracias a todos :adios:
Aqui el codigo
pawn Код:
//------------------------------------------------------------------------------
#include <a_samp>
//------------------------------------------------------------------------------
#define COLOR_ROJO 0xda3b3bff
#define COLOR_KICK 0xDABB3EAA
#define COLOR_PING 0x5cfa52ff
#define COLOR_INFO 0xeee756ff
#pragma tabsize 0
//------------------------------------------------------------------------------
forward AntiSpam(playerid);
forward OnPlayerUpdate(playerid);
forward PingCheck(playerid);
//------------------------------------------------------------------------------
new BotName[24] = "C-Bot";
new MensajeSpam[MAX_PLAYERS];
enum sInfo
{
MaxPing,
AntiVehicleKill
};
new ServerInfo[sInfo];
//------------------------------------------------------------------------------
public OnFilterScriptInit()
{
ServerInfo[MaxPing] = 1000;
ServerInfo[AntiVehicleKill] = 0;
SetTimer("PingCheck", 1000, 1);
return 1;
}
//------------------------------------------------------------------------------
public OnFilterScriptExit()
{
return 1;
}
//------------------------------------------------------------------------------
main()
{
print("\n-------------------------------------------------------");
print(" C-Bot");
print("[Bot Anti Spam - Matar con vehiculo - Armas no permitidas]");
print(" By Cacoby");
print("--------------------------------------------------------\n");
}
//------------------------------------------------------------------------------
public OnPlayerRequestClass(playerid, classid)
{
SetPlayerPos(playerid, 1958.3783, 1343.1572, 15.3746);
SetPlayerCameraPos(playerid, 1958.3783, 1343.1572, 15.3746);
SetPlayerCameraLookAt(playerid, 1958.3783, 1343.1572, 15.3746);
return 1;
}
//------------------------------------------------------------------------------
public OnPlayerDeath(playerid, killerid, reason)
{
new str[128];
new killername[MAX_PLAYER_NAME];
new killerstate = GetPlayerState(killerid);
if (ServerInfo[AntiVehicleKill] == 1)
{
if((IsPlayerInAnyVehicle(killerid) && !IsPlayerInAnyVehicle(playerid) && killerstate == PLAYER_STATE_DRIVER && reason != WEAPON_VEHICLE))
{
GetPlayerName(killerid, killername, sizeof(killername));
format(str, sizeof(str), "[ ! ] Administrador %s kikeo a %s | Razon: Matar en/con vehiculo",BotName,killername);
SendClientMessageToAll(COLOR_KICK, str);
Kick(killerid);
}
}
return 1;
}
//------------------------------------------------------------------------------
public OnPlayerText(playerid, text[])
{
new string[128];
new name[34];
MensajeSpam[playerid] ++;
if(MensajeSpam[playerid] == 5)
{
SendClientMessage(playerid,COLOR_ROJO,"[ ! ] No hagas Spam/Flood o seras kikeado");
SetTimerEx("AntiSpam",5000,false,"i",playerid);
return 0;
}
if(MensajeSpam[playerid] == 6)
{
GetPlayerName(playerid,name, sizeof(name));
format(string, sizeof(string), "[ ! ] Administrador %s a kikeado a %s | Razon: Spam/Flood ",BotName,name);
SendClientMessageToAll(COLOR_KICK,string);
Kick(playerid);
}
return 1;
}
//------------------------------------------------------------------------------
public AntiSpam(playerid)
{
MensajeSpam[playerid] = 0;
return 1;
}
//------------------------------------------------------------------------------
public OnPlayerUpdate(playerid)
{
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid, name, sizeof(name));
//------------------------------------------------------------------------------
if(GetPlayerWeapon(playerid) == WEAPON_MINIGUN || GetPlayerWeapon(playerid) == WEAPON_ROCKETLAUNCHER || GetPlayerWeapon(playerid) == WEAPON_HEATSEEKER || GetPlayerWeapon(playerid) == WEAPON_FLAMETHROWER)
{
new string1[256];
format(string1, sizeof(string1), "[ ! ] Administrador %s a baneado a %s | Razon: Arma no permitida", BotName,name);
SendClientMessageToAll(COLOR_KICK, string1);
Ban(playerid);
return 0;
}
//------------------------------------------------------------------------------
if(GetPlayerSpecialAction(playerid) == SPECIAL_ACTION_USEJETPACK)
{
new string2[256];
format(string2, sizeof(string2), "[ ! ] Administrador %s a baneado a %s | Razon: JetPack", BotName,name);
SendClientMessageToAll(COLOR_KICK, string2);
Ban(playerid);
return 0;
}
return 1;
}
//------------------------------------------------------------------------------
public PingCheck(playerid)
{
new string[256];
new ping = GetPlayerPing(playerid);
new playrname[MAX_PLAYER_NAME];
GetPlayerName(playerid, playrname, sizeof(playrname));
if(ping > ServerInfo[MaxPing])
{
format(string, sizeof(string), "[ ! ] %s a sido kikeado del servidor | Razon: Ping Alto | Ping: %d | Maximo: %d", playrname, ping, ServerInfo[MaxPing]);
SendClientMessageToAll(COLOR_KICK, string);
Kick(playerid);
}
}
//------------------------------------------------------------------------------
[mediafire]http://www.mediafire.com/?aa3k4vnijmpjvbn[/mediafire]
:adios: Muchas gracias a todos :adios: