Raised This Month: $ Target: $400
 0% 

JB Shot4Shot


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
hornet
AMX Mod X Plugin Approver
Join Date: Mar 2010
Location: Australia
Old 01-21-2014 , 06:05   Re: JB Shot4Shot
Reply With Quote #4

For starters, you really need to use a better method than CurWeapon to restrict the player's weapons, such as stripping them upon game start.

When you give the player a deagle you can do something like this:
Code:
cs_set_weapon_ammo( give_item( iGuard, "weapon_deagle" ), 1 );

And if you wanted to restrict the Guard from shooting ( and allow the Prisoner to shoot first ), you could extend this to:
Code:
const XO_WEAPON         =   4; const m_flNextPrimaryAttack =   46; // new iEnt; cs_set_weapon_ammo( iEnt = give_item( iGuard, "weapon_deagle" ), 1 ); set_pdata_float( iEnt, m_flNextPrimaryAttack, 9999.0, XO_WEAPON );
Also, not sure what's made you want to use FM Utility, but I assure you that it would be more efficient to use the natives from the Fun module. I would only recommend FM Utility for learning purposes.
__________________
Quote:
vBulletin Tip #42: Not much would be accomplished by merging this item with itself.
hornet is offline
 



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 10:15.


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