Getting entity distance and hooking to USE
How can I figure out if someone (Anyone), is within 50 units of the entity I created, and how can I make it so that when they are, and when they press the USE key, a menu pops up?
|
Re: Getting entity distance and hooking to USE
You can use get_distance or get_distance_f to evaluate the distance between 2 origins.
About the USE, hook Ham_ObjectCaps and check if the button ( IN_USE ) is used. ( get_user_button ) Then you can your menu. |
Re: Getting entity distance and hooking to USE
I dont use ham often and I dont think I understand get_distance.
Mind showing me? (It's not that Im lazy and Im asking for the code to be handed to me, I am just interested in how to do it.) |
Re: Getting entity distance and hooking to USE
http://www.amxmodx.org/funcwiki.php?go=func&id=791
About Ham something like : Code:
|
| All times are GMT -4. The time now is 17:39. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.