AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   Prevent weapon pickup (https://forums.alliedmods.net/showthread.php?t=49298)

soccdoodcss 12-31-2006 19:25

Prevent weapon pickup
 
I was wondering if anyone knew how to prevent a weapon from being picked up for the terrorist team, but the counter terrorists are able to pick up the weapons still..

I know how to force a player to drop weapons but it causes the game to crash once in a while.

If anyone know how to help, please do!

stupok 12-31-2006 21:46

Re: Prevent weapon pickup
 
Code:
#include <amxmodx> public plugin_init() {      register_event("WeapPickup","check_weapon","b") } public check_weapon(id) {      client_cmd(id,"drop") }
Use search next time.

XxAvalanchexX 12-31-2006 21:48

Re: Prevent weapon pickup
 
Hook FM_Touch. Check to see if it is a player entity touching a weaponbox entity, and then check the player's team. If everything meets your conditions, return PLUGIN_HANDLED to stop it from occurring, otherwise return PLUGIN_CONTINUE.

soccdoodcss 12-31-2006 22:02

Re: Prevent weapon pickup
 
Quote:

I know how to force a player to drop weapons but it causes the game to crash once in a while.
Read the question next time.

@Avalanche = thanks ill try that:up:


All times are GMT -4. The time now is 22:21.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.