[Pedido] ajuda com ati puxar de carros - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: Non-English (
https://sampforum.blast.hk/forumdisplay.php?fid=9)
+--- Forum: Languages (
https://sampforum.blast.hk/forumdisplay.php?fid=33)
+---- Forum: Português/Portuguese (
https://sampforum.blast.hk/forumdisplay.php?fid=34)
+---- Thread: [Pedido] ajuda com ati puxar de carros (
/showthread.php?tid=390179)
ajuda com ati puxar de carros -
rogerioexper - 05.11.2012
eu tava no meu server BLP e vi um cara puxando todos veiculos do server atй ele
pesso q me ajuden ai por favor colocar um anti puxar de carro contra estis FDM
Ajuda ai Mais RP se vc tiver um fs disso ajuda ai
Re: ajuda com ati puxar de carros -
Nill.Oliveira - 05.11.2012
pawn Код:
// Coded by Koma
#include <a_samp>
public OnFilterScriptInit()
{
print("Anti Car Spam by Koma loaded.");
return 1;
}
#define SCM SendClientMessage
new xacalaca[MAX_PLAYERS];
public OnPlayerStateChange(playerid, newstate, oldstate)
{
xacalaca[playerid] ++;
SetTimerEx("desxacalaca", 1000,false,"i",playerid);
return 1;
}
forward desxacalaca(playerid);
public desxacalaca(playerid)
{
xacalaca[playerid] --;
if(xacalaca[playerid] > 10)
{
new bibi[128], Nome[MAX_PLAYER_NAME];
SCM(playerid, -1, "Este servidor estб protegido pelo sistema Kocars e vocк foi banido por spam de veнculos");
GetPlayerName(playerid, Nome, sizeof(Nome));
format(bibi, sizeof(bibi), "[Koprotect]: %s foi banido pelo uso do mod cleo 4 car spam.", Nome);
SendClientMessageToAll(-1, bibi);
Ban(playerid);
}
//printf("xacalaca = %d", xacalaca[playerid]); // debug
return 1;
}
Re: ajuda com ati puxar de carros -
DrKaFuZo - 05.11.2012
e ai testou funcionou?
AW: ajuda com ati puxar de carros -
rogerioexper - 05.11.2012
eu ja tenho esti ele nem funciona mano
Re: ajuda com ati puxar de carros -
Nill.Oliveira - 05.11.2012
Isto й uma include ..
pawn Код:
/*
* Include S_AntiSpawn v1.0
* © Copyright 2012 by [S]trong
*
* @Autor : [S]trong
* @Data : 13 de janeiro de 2012
* @Requer : Include a_samp (por SA-MP Team)
*
*
* Include desenvolvida com fim de nao permitir o hack de puxar carros
*
*
*
*/
#include <a_samp>
new
vehicleTime[MAX_PLAYERS],
lastVehicle[MAX_PLAYERS]
;
forward S_OnPlayerUpdate(playerid);
public OnPlayerUpdate(playerid)
{
new vehicleID = GetPlayerVehicleID(playerid);
if(lastVehicle[playerid] != vehicleID)
{
lastVehicle[playerid] = vehicleID;
if(GetVehicleModel(vehicleID))
{
CallRemoteFunction("OnPlayerChangeVehicle","ii", playerid, vehicleID);
}
}
return CallRemoteFunction("OnPlayerUpdate","i", playerid);
}
forward OnPlayerChangeVehicle(playerid, vehicleid);
public OnPlayerChangeVehicle(playerid, vehicleid)
{
#pragma unused vehicleid
if((GetTickCount() - vehicleTime[playerid]) < 250)
{
Kick(playerid);
}
vehicleTime[playerid] = GetTickCount();
}
stock S_PutPlayerInVehicle(playerid, vehicleid, seatid)
{
vehicleTime[playerid] = GetTickCount();
return PutPlayerInVehicle(playerid, vehicleid, seatid);
}
#if defined _ALS_PutPlayerInVehicle
#undef PutPlayerInVehicle
#else
#define _ALS_PutPlayerInVehicle
#endif
#define PutPlayerInVehicle S_PutPlayerInVehicle
#if defined _ALS_OnPlayerUpdate
#undef OnPlayerUpdate
#else
#define _ALS_OnPlayerUpdate
#endif
#define OnPlayerUpdate S_OnPlayerUpdate
https://sampforum.blast.hk/showthread.php?tid=310341
Cara, й so pesquisar na net que tem varios , e ir testando qual йr compativel com seu servidor .!
@Edit.
Esse anti-Airbrake muito bom !
https://sampforum.blast.hk/showthread.php?tid=142302
AW: ajuda com ati puxar de carros -
rogerioexper - 05.11.2012
vo testar aqui vlw
Re: ajuda com ati puxar de carros -
Styfler_ZikaDaBalaDa - 11.12.2012
Quote:
Originally Posted by Nill.Oliveira
Isto й uma include ..
pawn Код:
/* * Include S_AntiSpawn v1.0 * © Copyright 2012 by [S]trong * * @Autor : [S]trong * @Data : 13 de janeiro de 2012 * @Requer : Include a_samp (por SA-MP Team) * * * Include desenvolvida com fim de nao permitir o hack de puxar carros * * * */ #include <a_samp> new vehicleTime[MAX_PLAYERS], lastVehicle[MAX_PLAYERS] ;
forward S_OnPlayerUpdate(playerid);
public OnPlayerUpdate(playerid) { new vehicleID = GetPlayerVehicleID(playerid); if(lastVehicle[playerid] != vehicleID) { lastVehicle[playerid] = vehicleID; if(GetVehicleModel(vehicleID)) { CallRemoteFunction("OnPlayerChangeVehicle","ii", playerid, vehicleID); } } return CallRemoteFunction("OnPlayerUpdate","i", playerid); }
forward OnPlayerChangeVehicle(playerid, vehicleid); public OnPlayerChangeVehicle(playerid, vehicleid) { #pragma unused vehicleid if((GetTickCount() - vehicleTime[playerid]) < 250) { Kick(playerid); } vehicleTime[playerid] = GetTickCount(); }
stock S_PutPlayerInVehicle(playerid, vehicleid, seatid) { vehicleTime[playerid] = GetTickCount(); return PutPlayerInVehicle(playerid, vehicleid, seatid); } #if defined _ALS_PutPlayerInVehicle #undef PutPlayerInVehicle #else #define _ALS_PutPlayerInVehicle #endif #define PutPlayerInVehicle S_PutPlayerInVehicle #if defined _ALS_OnPlayerUpdate #undef OnPlayerUpdate #else #define _ALS_OnPlayerUpdate #endif #define OnPlayerUpdate S_OnPlayerUpdate
https://sampforum.blast.hk/showthread.php?tid=310341
Cara, й so pesquisar na net que tem varios , e ir testando qual йr compativel com seu servidor .!
@Edit.
Esse anti-Airbrake muito bom !
https://sampforum.blast.hk/showthread.php?tid=142302
|
Esse ae bani o cara, ou spawna os carros q sгo Puxados? pq eu testei ele e n aconteceu nada!