PDA

View Full Version : a Help?


RathTheBeast
13/04/2017, 05:41 AM
SOrry For trouble
I wanna use THIS (http://forum.sa-mp.com/showthread.php?t=59872) Gamemode.
BUt when I edit it Its Shows An Error:
D:\Stunt Universe\gamemodes\SU.pwn(213) : error 017: undefined symbol "SetDisabledWeapons"
A added all the includes(in the rar file) in my pawno/include folder

Help!

Mencent
13/04/2017, 05:44 AM
Hello!

http://wiki.sa-mp.com/wiki/SetDisabledWeapons
Read this link. ;)

Celmir
13/04/2017, 05:49 AM
That function has been disabled. You cannot use it.

RathTheBeast
14/04/2017, 12:03 PM
So what now?

LEOTorres
14/04/2017, 12:09 PM
So what now?

Well, as stated by the wiki; you can detect weapons upon the OnPlayerUpdate callback instead and disable them through there.

So, the first thing you would need to do, is remove all instances of the depreciated function you are using, and instead use something of this nature:

public OnPlayerUpdate (playerid)
{
new weapon = GetPlayerWeapon (playerid);

if (weapon == 38 || weapon == 35) //disables minigun and RPG
{
SetPlayerArmedWeapon(playerid, 0);
}

return 1;
}

To get a list of weapon ID's, check out: http://wiki.sa-mp.com/wiki/Weapons