i made a plugin, which checks for speed hackers, then i remembered that every car has its own top speed, i will most likly make an array of top speeds for every car :P
<?php
php
class Cheat extends Plugins {
const URL = 'http://lfsforum.net/forumdisplay.php?f=312';
const NAME = 'Cheat Protection';
const AUTHOR = 'T3charmy';
const VERSION = '0.1.0';
const DESCRIPTION = 'Does the dirty work for you!';
public function __construct() {
$this->registerPacket('onMCI', ISP_MCI);
}
public function onMCI($Packet) {
foreach ($Packet->Info as $PacketInfo) {
$PacketData = Plugins::getClientByPLID($PacketInfo->PLID);
$MPH = number_format($CompCar->Speed / 146.486067, 1);
if(isset($PacketData)){
if($MPH > 200){
$MST = new IS_MST;
$MST->Msg("/ban {$PacketData->UName} 999")->Send();
$MST->Msg("/msg ^1{$PacketData->UName} banned for Speed Hacking!")->Send();
}
}
}
}
}
?>