Hide custom entity, Game not loading functions first time, Entity ID problems
Hi,
1. Is there a way to hide custom entities same as we hide armoury_entity entities? By setting m_iCount to 0? When I mean 'hide' I don't mean remove. 2. Every time I get into the game for the first time and open a listen server, a lot of things don't load properly, such as: - It doesn't properly load WeaponList, so my weaponbox entities don't get any ammo, until I restart the listen server and it works. etc.. 3. And last, this code is not glowing the weapons I drop because of entity indexes getting messed up for some reason. PHP Code:
Quote:
I create a weaponbox whose ID is 544, assign pev_iuser2 a value of 4, then hook FM_SetModel, and for the same weapon, the ID is 113? And of course the value is 0 because it's unassigned. Why does this happen? |
Re: Hide custom entity, Game not loading functions first time, Entity ID problems
1. Ef_nodraw?
|
Re: Hide custom entity, Game not loading functions first time, Entity ID problems
Quote:
|
Re: Hide custom entity, Game not loading functions first time, Entity ID problems
1. No, but you can check if EF_NODRAW is set and block touch.
3. I'm not sure I see something wrong. The forward can be called for other weaponboxs too, not only the one you created. Explain better or provide more code. 113 is simply another entity. |
Re: Hide custom entity, Game not loading functions first time, Entity ID problems
Quote:
- I create a weaponbox entity, and I want it to glow for example GREEN (value=1), also set pev_iuser2 value to GREEN so we can retrieve what color we set later on. - So now I want weaponboxes to keep that glow even when a player picks it up and drops it, so I hook FM_SetModel and retrieve pev_iuser2, get the color that we set before on the weaponbox and set it again. But unfortunately none of the IDs in FM_SetModel match the IDs of the weaponboxes that I create, as you can see in the debug log. EDIT: FM_SetModel apparently isn't the right event to do this, but what else can I use? |
Re: Hide custom entity, Game not loading functions first time, Entity ID problems
Quote:
What you can do is when the player will touch the weaponbox apply the same flag from pev_iuser2 to the weapon entity. Next, when player tries to drop check if the item that's being dropped contains the pev_iuser2 flag and if that's true apply the flag to the new weaponbox. |
Re: Hide custom entity, Game not loading functions first time, Entity ID problems
Quote:
I didn't quite understand this part: Quote:
PHP Code:
|
Re: Hide custom entity, Game not loading functions first time, Entity ID problems
Use pev_iuser3 or 4 then if 2 is reserved for rarity.
|
Re: Hide custom entity, Game not loading functions first time, Entity ID problems
Quote:
|
Re: Hide custom entity, Game not loading functions first time, Entity ID problems
Quote:
|
All times are GMT -4. The time now is 01:59. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.