Raised This Month: $ Target: $400
 0% 

What's the best way to detect entity type?


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Simon Logic
Senior Member
Join Date: Nov 2006
Location: RF
Old 12-27-2006 , 05:34   Re: What's the best way to detect entity type?
Reply With Quote #1

KWo, it's ok. I understand this. I tested it on THROWN weapon. Also i deactivated all plugins for sure on testing.

teame06, thank you very much!

Looks like this method can be very CPU intensive to scan through global_get(glb_maxEntities) instead of scanning an array with models, but reliable.

I think it's much faster to use engfunc(EngFunc_FindEntityByString, -1, "owner", strWeaponBoxID). I'll rewrite a script and test it.

But does weaponbox entity own only ONE entity always?
Simon Logic is offline
Send a message via Skype™ to Simon Logic
Orangutanz
Veteran Member
Join Date: Apr 2006
Old 12-27-2006 , 05:37   Re: What's the best way to detect entity type?
Reply With Quote #2

In CS yes 1 weaponbox = 1 containing weapon.

Why CS is designed like this we do not know, piss poor if you ask me. Since it means each weapon dropped = 2 entities instead of 1. I suppose in the cleanup code ie New Round they only search for weaponbox entities then remove them, still its a waste of entities IMHO.
__________________
|<-- Retired from everything Small/Pawn related -->|
You know when you've been Rango'd
Orangutanz 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 20:19.


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