Raised This Month: $ Target: $400
 0% 

Hwo would I do this correctly?


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Styles
Veteran Member
Join Date: Jul 2004
Location: California
Old 02-27-2008 , 13:30   Hwo would I do this correctly?
Reply With Quote #1

Hey guys, I get the privilege of redoing Weapon Jam, since 1) the user is ban and 2) it needs an update.

Now, I wanted to go about doing this completely differently. What I want to see happen is when your weapon is Jamed, lets say you drop it, your next weapon isant jamed. So, how can I check this correctly? get weapon entid? Then save it as the primary weapon thats jamed? But what if they have multiple primary weapons? Things like this then I had made a stock to check if it was a Primary Weapoin or Secondary or None. It would return 1 2 or 3 depending on the results. and I could just switch it. Does this sound alright?

Thanks
Styles is offline
Send a message via AIM to Styles
pharse
Senior Member
Join Date: Jan 2008
Location: Germany, BW
Old 02-27-2008 , 15:28   Re: Hwo would I do this correctly?
Reply With Quote #2

I have no idea how it works now, but the most logical way is to store the entity ID of the jammed weapon in an array and check always on CurWeapon if the current weapon is jammed. Thus one could also pick up a jammed weapon.

PS: easy way to get the EntID with fakemeta_util.inc:

PHP Code:
new weapon[32]
        
get_weaponname(weaponID,weapon,31)
        
new 
ent fm_find_ent_by_owner(-1,weapon,id
__________________

Last edited by pharse; 02-27-2008 at 15:31.
pharse is offline
Reply



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:14.


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