Raised This Month: $ Target: $400
 0% 

Detect brokeable things


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
NoobInAmxx
Senior Member
Join Date: Mar 2006
Location: Turku Finland
Old 02-26-2007 , 15:02   Re: Detect brokeable things
Reply With Quote #3

Quote:
Originally Posted by mysticssjgoku4 View Post
How do you want to detect them, and why?

----
The code below finds the breakable entity around a player, and returns the Entity ID of the first find.
Code:
stock find_breakable_thing(id) {     new ent, Float:origin[3],Float:radius = 64.0, classname[64]     entity_get_vector(id,EV_VEC_origin,origin)     while((ent = find_ent_in_sphere(ent,origin,radius)) != 0)     {         entity_get_string(ent,EV_SZ_classname,classname,63)         if(equali(classname,"func_breakable"))         {             //Code here                         return ent;         }     }     return 0 }
because i want blow them up when round starts in (freezetime) because if user got stripped out of weapons they can't broke them..
__________________
..Im not smart and im not stupid..
NoobInAmxx is offline
Send a message via MSN to NoobInAmxx
 



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 00:37.


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