Raised This Month: $ Target: $400
 0% 

Creating a zone box


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
stupok
Veteran Member
Join Date: Feb 2006
Old 06-25-2007 , 20:13   Re: Creating a zone box
Reply With Quote #1

Code:
1) #include <amxmodx> #include <fakemeta> //... new Float:origin[3] pev(entid, pev_origin, origin) new Float:mins[3], Float:maxs[3] mins[0] = origin[0] - 1.0 mins[1] = origin[1] - 1.0 mins[2] = origin[2] - 1.0 maxs[0] = origin[0] + 100.0 maxs[1] = origin[1] + 100.0 maxs[2] = origin[2] + 100.0 set_pev(entid, pev_absmin, mins) //or set_pev(entid, pev_mins, mins) set_pev(entid, pev_absmax, maxs) //or set_pev(entid, pev_maxs, maxs) 2) //... //from message_const.inc //#define TE_BOX                      31 // write_byte(TE_BOX) // write_coord(boxmins.x) // write_coord(boxmins.y) // write_coord(boxmins.z) // write_coord(boxmaxs.x) // write_coord(boxmaxs.y) // write_coord(boxmaxs.z) // write_short(life in 0.1 s) // write_byte(red) // write_byte(green) // write_byte(blue) 3) //... public plugin_init() {     register_forward(FM_Touch, "forward_Touch", 0) } public forward_Touch(ptr, ptd) {     new classname[32]     pev(ptd, pev_classname, classname, 31)         if(equal(classname, "class_name"))     {         //...     } }

That's the best I can do, I'm not sure if everything is actually correct. Hopefully someone can correct me or confirm that I'm right.
stupok 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 21:35.


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