Jump to content
Sign in to follow this  
Cataclysm2000

Triggers, rearming and UAVs

Recommended Posts

Hey, I am making a mission that requires you to take out enemy AA before your armor can advance. How do I set this up? I have a trigger set to the AA unit with the script "alive Shilka1 false". This is about as far as I got..

I'd also like to know how to add the option to control the UAV little bird to an Apache and if the AI is smart enough to rearm on its own or if I need to script it somehow.

Thanks guys!

Share this post


Link to post
Share on other sites

in Condition write: !(alive Shilka1)

The trigger will "fire" when the shilka is dead.

Share this post


Link to post
Share on other sites

Thanks Speeder, that worked perfect. I decided to switch teams however and the Linebacker is much tougher than the Shilka. Is there a way to fire the trigger when the unit is disabled or the crew gets out?

I also want to add a voiceover for when the trigger fires, something along the lines of "Anit-air is down, requesting CAS, over" How do I go about adding this?

Share this post


Link to post
Share on other sites

Take your pick.

getDammage shilka1 >0.5

!canMove shilka1

!canfire shilka1

!(driver shilka1 in shilka1)

Share this post


Link to post
Share on other sites

How does this look?

_soldierOne sidechat "Enemy AA is down, over!"
Col. Omar=[east,"HQ"]; Col. Omar sidechat "Roger, CAS in en route"

!alive shilka1 OR !canfire Shilka1 OR count crew shilka1==0

Edited by Cataclysm2000

Share this post


Link to post
Share on other sites

Thanks guys, it worked great. Now I have a couple more questions :p

I have this:

_soldierOne sidechat "Enemy AA is down, over!"; sleep 1;
Azziz=[east,"HQ"]; Azziz sidechat "Roger, CAS in en route"

The idea is to make it wait a second before Azziz radios back so it feels more real, but it doesnt work. I tried sleep 1000 thinking it might be in miliseconds but to no avail. Also, Azziz doesn't show up as Azziz. Do I have to set up another trigger with a countdown of 1s for the relpy?

EDIT: oops sorry, I thought I was editing. Didn't mean to double post

Share this post


Link to post
Share on other sites

It works fine for me.

Azziz will show up as something else though.

Setting Azziz = [east,"HQ"] is just assigning an array to that variable.

[east,"HQ"] sidechat "Roger, CAS in en route" will give the same result.

Where are you using the code, if it's in a trigger it won't work as is.

this would work in a trigger.

soldierone sidechat "Enemy AA is down, over!"; call { [] spawn {  sleep 5;azziz = [east,"HQ"];azziz sidechat "Roger, CAS in en route"}};

Edited by F2k Sel

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×