[Tutorial] Deduction - Anti-Weapon Hack
#11

Well if its scripted into the server to give the player weapons within the script.
Instead of:
pawn Code:
GivePlayerWeapon(playerid, weaponid, ammo);
Use:
pawn Code:
ServerWeapon(playerid, weaponid, ammo);
Parachutes don't count as cheat weapons, a golfstick is, so maybe OnPlayerExitVehicle use this:

pawn Code:
public OnPlayerExitVehicle(playerid, vehicleid)
{
    if(vehicleid == 457)
        {
        ResetPlayerWeaponsEx(playerid);
        }

    return 1;
}
Of course this will require another macro to restore all weapons.
So add in at the bottom of the script, this:
pawn Code:
ResetPlayerWeaponsEx(playerid)
{
ResetPlayerWeapons(playerid);
ServerWeapon(playerid, Weapons[playerid][Melee], 9999);
ServerWeapon(playerid, Weapons[playerid][Thrown], 9999);
ServerWeapon(playerid, Weapons[playerid][Pistols], 9999);
ServerWeapon(playerid, Weapons[playerid][Shotguns], 9999);
ServerWeapon(playerid, Weapons[playerid][SubMachine], 9999);
ServerWeapon(playerid, Weapons[playerid][Assault], 9999);
ServerWeapon(playerid, Weapons[playerid][Rifles], 9999);
ServerWeapon(playerid, Weapons[playerid][Heavy], 9999);
ServerWeapon(playerid, Weapons[playerid][Handheld], 9999);
return 1;
}
Reply


Messages In This Thread
Deduction - Anti-Weapon Hack - by Deduction - 20.02.2012, 13:09
Re: Deduction - Anti-Weapon Hack - by Not Applicable - 20.02.2012, 13:13
Re: Deduction - Anti-Weapon Hack - by Kaperstone - 20.02.2012, 15:17
Re: Deduction - Anti-Weapon Hack - by Hoborific - 20.02.2012, 15:17
Re: Deduction - Anti-Weapon Hack - by emokidx - 20.02.2012, 17:04
Re: Deduction - Anti-Weapon Hack - by rati555 - 20.02.2012, 17:28
Re: Deduction - Anti-Weapon Hack - by Pooh7 - 20.02.2012, 20:34
Re: Deduction - Anti-Weapon Hack - by Hoborific - 21.02.2012, 04:30
Re: Deduction - Anti-Weapon Hack - by Deduction - 21.02.2012, 05:28
Re: Deduction - Anti-Weapon Hack - by Meisternuke - 21.02.2012, 06:30
Re: Deduction - Anti-Weapon Hack - by Deduction - 21.02.2012, 10:09
Re: Deduction - Anti-Weapon Hack - by KyleSmith - 21.02.2012, 10:11
Re: Deduction - Anti-Weapon Hack - by Jeffry - 21.02.2012, 16:05
Re: Deduction - Anti-Weapon Hack - by Deduction - 21.02.2012, 19:33
Re: Deduction - Anti-Weapon Hack - by Jeffry - 22.02.2012, 10:05
Re: Deduction - Anti-Weapon Hack - by BaubaS - 22.02.2012, 12:03
Re: Deduction - Anti-Weapon Hack - by niyaz - 28.02.2012, 08:10
Re: Deduction - Anti-Weapon Hack - by gcw - 28.06.2012, 10:36
Re: Deduction - Anti-Weapon Hack - by ErzaNatsu - 30.06.2012, 00:59
Re: Deduction - Anti-Weapon Hack - by ilijas - 02.07.2012, 20:51
Re: Deduction - Anti-Weapon Hack - by ilijas - 03.07.2012, 11:30
Re: Deduction - Anti-Weapon Hack - by czop1223 - 23.04.2013, 14:52
Re: Deduction - Anti-Weapon Hack - by dEcooR - 14.06.2013, 16:00
Re: Deduction - Anti-Weapon Hack - by cyber_punk - 15.06.2013, 03:58
Re: Deduction - Anti-Weapon Hack - by Chrillzen - 18.10.2013, 20:23
Respuesta: Deduction - Anti-Weapon Hack - by Nitrome - 22.10.2013, 15:14
Re: Deduction - Anti-Weapon Hack - by cessil - 03.12.2013, 22:52
Re: Deduction - Anti-Weapon Hack - by Gastro - 04.12.2013, 01:18

Forum Jump:


Users browsing this thread: 1 Guest(s)