trigger enemies to start attacking
Post Reply
Quote
Re: trigger enemies to start attacking
Posted by fizscy46 on Mon Aug 16th at 4:25am 2004


How can I make some grunts not start attacking until a trigger is activated (That being, a mulimanager tagets them or a trigger relay)? [addsig]



Quote
Re: trigger enemies to start attacking
Posted by JFry on Mon Aug 16th at 7:30am 2004


hmm that is pretty tricky. What you could do is have a set grunts with the 'friendly' flag checked and a set without and when the time is right teleport the friendlies out and the enemies in. It would be hard but you MIGHT be able to make it look seamless. Then again somebody might have a much easier answer for you.



Quote
Re: trigger enemies to start attacking
Posted by fizscy46 on Mon Aug 16th at 5:21pm 2004


There's a friendly flag? I don't have that... And I'm sure I have the up-to-date FGD (HL3x) [addsig]



Quote
Re: trigger enemies to start attacking
Posted by Gwil on Mon Aug 16th at 6:18pm 2004


might be "prisoner" or "pre disaster" flag or something like that on your smartedit screen, fizscy
[addsig]




Quote
Re: trigger enemies to start attacking
Posted by fizscy46 on Mon Aug 16th at 6:30pm 2004


Oh, prisoner and gag in flags work.

Well, I gave it a shot, the problem is that you can't choose the grunts face like you can with scientists, and some have masks. So the effect may occationally randomly work.

Is it possible to change flags using a trigger_changetarget maybe (Since the flags run on a value as well that defines which boxes are checked) [addsig]




Quote
Re: trigger enemies to start attacking
Posted by omegaslayer on Mon Aug 16th at 8:00pm 2004


No change target is for paths....what you could do is make your grunts on a scripted_sequence with an action like idle# and then I think there is an option in scripted_sequence that turns the AI back on, which will make them start attacking again. [addsig]



Quote
Re: trigger enemies to start attacking
Posted by fizscy46 on Mon Aug 16th at 8:45pm 2004


Change target can change any value in the keys tab (Using its killtarget value as the key you want to change)...

I've never seen that, unless if the enemy AI is set to ambush by the scripted sequence makes them not attack until its changed back to default AI [addsig]




Quote
Re: trigger enemies to start attacking
Posted by beer hunter on Mon Aug 16th at 10:58pm 2004


Haven't tried the scripted thing but it sounds interesting.

The simplest way is prolly to put a func_wall_toggle around each grunt, set Render mode to texture and FX to 0. This creates an invisible wall which monsters won't shoot thru. Target the wall with a trigger_once to make it disappear and allow grunts to shoot. The downside is that shooting at the wall will create sparks, players might also be able to kill monsters thru the walls but i haven't tested this.

Jfrys suggestion also sounded like he was on the right track - use an env_sprite with Sprite field set to the grunt model and a monster_maker to create a grunt that shoots. Target both entities with a trigger so that the sprite is turned off and the grunt spawned. Would also need a func_wall_toggle to cover the Sprite grunt to stop players walking thru it.

Theres maybe smarter ways of doing it but nothing comes to mind...




Quote
Re: trigger enemies to start attacking
Posted by fizscy46 on Mon Aug 16th at 11:54pm 2004


Sprite = 2-d.

As for the func_wall_toggle, wouldn't the grunts try shooting the player through it? If not, I'm ok (Player has no bullet guns until after they start attacking) [addsig]




Quote
Re: trigger enemies to start attacking
Posted by ReNo on Tue Aug 17th at 12:15am 2004


A sprite is 2D, but you can set an env_sprite entity to display a model, and it will therefore be a 3D model that is put in game. Not sure if that is still supported by the newest FGD and hammer version though, I thought it was prone to cause crashes though perhaps that can be rectified through some FGD tinkering. [addsig]



Quote
Re: trigger enemies to start attacking
Posted by fizscy46 on Tue Aug 17th at 2:44am 2004


Would one of the cycler entities work instead? I'd blow up Half-Life if I fiddled with the the FGD (I know they aren't connected, but it'd happen anyways!). [addsig]



Quote
Re: trigger enemies to start attacking
Posted by beer hunter on Tue Aug 17th at 5:34pm 2004


? quote:
Sprite = 2-d.


Like Reno said - can be used for models, not sure if it crashes HL tho' ? Its maybe better to only use the func_wall_toggle as its got less chance of messing up.

? quote:
As for the func_wall_toggle, wouldn't the grunts try shooting the player through it? If not, I'm ok (Player has no bullet guns until after they start attacking)


i just played around with a little test map and func_wall_toggle works fine - blocks player visibility so grunts don't shoot. Also tried a func_breakable but they see thru that

cycler_sprite instead of env_sprite should also work ok.




Quote
Re: trigger enemies to start attacking
Posted by Captain P on Thu Aug 19th at 2:36pm 2004


A few posts up you said you couldn't set the face of the grunt, right?

Well, that is possible... Go into SmartEdit mode, add a key named 'body' and apply a value to it. The value corresponds with a combination of the grunts submodels. Just play around with that a bit.
[addsig]




Quote
Re: trigger enemies to start attacking
Posted by fizscy46 on Thu Aug 19th at 6:32pm 2004


Beer Hunter's answer seems to work the nicest [addsig]




Post Reply