[SOLVED] find entity by "gibmodel" value
Is it possible to find entities by their gibmodel value?
The code below is the properties of a func_breakable entity in a map. I'd like to do some stuff to these entities and they all share one same property, which is the "gibmodel". Code:
{PHP Code:
|
Re: find entity by "gibmodel" value
PHP Code:
|
Re: find entity by "gibmodel" value
Thanks ConnorMcLeod, it works flawlessly
EDIT: I need one more thing, I'd like to get all the trigger_hurt entities indexes in a map that has "damagetype" of DMG_FALL (32) Bad English. Let me rephrase: I'd like to loop all trigger_hurt entities, and if their damagetype is 32, then do something to them. Right now I'm stuck at getting the damagetype value. |
Re: find entity by "gibmodel" value
You are in the scripting section, it's a good idea to show what you've done, so people can correct you and you can learn from that.
|
Re: find entity by "gibmodel" value
Quote:
PHP Code:
|
Re: find entity by "gibmodel" value
check pdata m_bitsDamageInflict if it contains DMG_FALL, but i doubt it can be possible :)
PHP Code:
PHP Code:
|
Re: find entity by "gibmodel" value
Yea, it's not working. Do you have another way that you think could pull it off?
|
Re: find entity by "gibmodel" value
Code is ok, it's just that i don't think that DMG_FALL is set on trigger_hurt
|
Re: find entity by "gibmodel" value
#define DMG_FALL (1<<5)
1<<5 equals to 32 (assuming my calculation is correct) What I think is the pdata 71 is for something else (totally a blind guess). |
Re: find entity by "gibmodel" value
You don't understand, seems that damage is different from DMG_FALL, also i've never seen a trigger_hurt with DMG_FALL so far.
Which map it is ? |
| All times are GMT -4. The time now is 18:59. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.