Raised This Month: $ Target: $400
 0% 

[HELP] Check monster_turret


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
DarthMan
Veteran Member
Join Date: Aug 2011
Old 04-05-2017 , 16:02   [HELP] Check monster_turret
Reply With Quote #1

Hello there. How can I check if a monster_turret is active?
I want to display a HUD message if the turret is active.
I've never seen a server to have this thing, so it would be cool to introduce it on my BM HL server, since I plan working on a map with turrets in the near future. Any help will be appreciated. Thanks!
DarthMan is offline
gabuch2
AlliedModders Donor
Join Date: Mar 2011
Location: Chile
Old 04-07-2017 , 08:25   Re: [HELP] Check monster_turret
Reply With Quote #2

If the turrets activate automatically if the players are nearby you can use pev_enemy
__________________

Last edited by gabuch2; 04-07-2017 at 08:26.
gabuch2 is offline
DarthMan
Veteran Member
Join Date: Aug 2011
Old 04-07-2017 , 11:16   Re: [HELP] Check monster_turret
Reply With Quote #3

Quote:
Originally Posted by Shattered Heart Lynx View Post
If the turrets activate automatically if the players are nearby you can use pev_enemy
Nope, basically I want to display a hud message no matter where the player is.
They will activate once the player will get closer to them.
I've been also thinking about making sentry gun and dispensers just like on TFC, but I don't rly know how good this is gonna fit with HL, also since they are colored and HL1 has no teams, only CS, DOD and TFC.
DarthMan is offline
gabuch2
AlliedModders Donor
Join Date: Mar 2011
Location: Chile
Old 04-07-2017 , 11:28   Re: [HELP] Check monster_turret
Reply With Quote #4

You can extract the player's topcolor and bottomcolor values and put them into the sentry's pev_colormap value (so the Sentry Guns will take their owner's color palette) .

There should be a Ham function that gets called when when monster_turret (and mini, etc). You can try hooking Ham_CheckEnemy() and get an enemy player walk near the turret while it is deactivated.
__________________

Last edited by gabuch2; 04-07-2017 at 11:38.
gabuch2 is offline
DarthMan
Veteran Member
Join Date: Aug 2011
Old 04-07-2017 , 12:18   Re: [HELP] Check monster_turret
Reply With Quote #5

Quote:
Originally Posted by Shattered Heart Lynx View Post
You can extract the player's topcolor and bottomcolor values and put them into the sentry's pev_colormap value (so the Sentry Guns will take their owner's color palette) .

There should be a Ham function that gets called when when monster_turret (and mini, etc). You can try hooking Ham_CheckEnemy() and get an enemy player walk near the turret while it is deactivated.
I see, thanks
DarthMan 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 18:01.


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