PDA

View Full Version : How to disable weapon pickup?


Sc0pion
05/03/2015, 12:42 PM
Fixed!

CalvinC
05/03/2015, 12:43 PM
Well it's scripted in your script then, it's not a SAMP function by default, you'll have to find the script that does this, and delete it.
You should be able to find it's code in OnPlayerDeath.

Sc0pion
05/03/2015, 01:28 PM
Fixed!

Kaliber
05/03/2015, 01:29 PM
for(new w; w<13; w++)
{
GetPlayerWeaponData(playerid, w, _w, _a);
CreateAutoPickup(
( pX + random( 5 ) ),
pY,
pZ,
_w,
_a,
3,
GetPlayerInterior(playerid),
GetPlayerVirtualWorld(playerid));
}

this one ;)

CalvinC
05/03/2015, 01:31 PM
And the switch aswell.
if(GetPlayerWantedLevel(playerid) > 1)
{
switch( random(5) )
{
case 0: CreateAutoPickup(
( pX + random( 5 ) ),
pY,
pZ,
PICKUP_MODEL_HEALTH,
100,
3,
GetPlayerInterior(playerid),
GetPlayerVirtualWorld(playerid),
10000);
case 1: CreateAutoPickup(
( pX + random( 5 ) ),
pY,
pZ,
PICKUP_MODEL_ARMOR,
100,
3,
GetPlayerInterior(playerid),
GetPlayerVirtualWorld(playerid),
10000);
case 2: CreateAutoPickup(
( pX + random( 5 ) ),
pY,
pZ,
PICKUP_MODEL_CASH,
103 + random( 1000 ),
3,
GetPlayerInterior(playerid),
GetPlayerVirtualWorld(playerid),
10000);
case 3: CreateAutoPickup(
( pX + random( 5 ) ),
pY,
pZ,
PICKUP_MODEL_PARACHUTE,
1,
3,
GetPlayerInterior(playerid),
GetPlayerVirtualWorld(playerid),
10000);
case 4: CreateAutoPickup(
( pX + random( 5 ) ),
pY,
pZ,
PICKUP_MODEL_JETPACK,
1,
3,
GetPlayerInterior(playerid),
GetPlayerVirtualWorld(playerid),
10000);
}
}

Sc0pion
05/03/2015, 01:34 PM
Fixed!

CalvinC
05/03/2015, 01:36 PM
Oh okay, then just remove the bit Kaliber pointed out.

Sc0pion
05/03/2015, 01:39 PM
Fixed!

Kaliber
05/03/2015, 01:40 PM
When I remove only that this is what I receive

D:\Servers\San Andreas - Gang War\gamemodes\SA-GW.pwn(3737) : warning 203: symbol is never used: "_a"
D:\Servers\San Andreas - Gang War\gamemodes\SA-GW.pwn(3737) : warning 203: symbol is never used: "_w"

Look at this line:

new _w, _a, Float:pX, Float:pY, Float:pZ;

write it to this:

new Float:pX, Float:pY, Float:pZ;

Greekz 8)

Sc0pion
05/03/2015, 01:46 PM
Fixed!