OFPEC Forum

Editors Depot - Mission Editing and Scripting => ArmA - Editing/Scripting General => Topic started by: ckclaw on 12 Aug 2007, 13:59:55

Title: Dynamic trigger/waypoints?
Post by: ckclaw on 12 Aug 2007, 13:59:55
Hi guys,
Hope this gonna make sense,did search but dont think id know the answer if i spotted it? :D

Basically it's a BHD style mission,the bh starts over Parasio on a placement radius of 200(smoking and tail rotor gone)!
How can i link enemy waypoints etc to the crash site,as obviously it will be different everytime due to the placement radius?

Many Thanks

ck
Title: Re: Dynamic trigger/waypoints?
Post by: Mandoble on 12 Aug 2007, 14:16:14
For each enemy group:
setWaypointPosition (http://www.ofpec.com/COMREF/index.php?action=list&game=All&letter=s#setWaypointPosition)

First waypoint is 1.
Title: Re: Dynamic trigger/waypoints?
Post by: ckclaw on 12 Aug 2007, 14:21:01
Thanks Mandoble,but could you elaborate a bit more?
Did check the comref but a bit confusing to me
Title: Re: Dynamic trigger/waypoints?
Post by: Mandoble on 12 Aug 2007, 14:39:39
You want to move the waypoints of your units to a new location, use that command to do it. I assume you gave waypoints to the enemies from the editor, right?
Title: Re: Dynamic trigger/waypoints?
Post by: ckclaw on 12 Aug 2007, 14:49:00
As of yet i have not setup the enemies/waypoints,its just the way i do my missions. ;)
Make sure everything else works first etc.
Sorry im not explaining myself very well-lack of cider! :blink:

Edit:-

the waypoints are not set yet cause where i would place them would not nessecarly be the place the chopper crashes!
Title: Re: Dynamic trigger/waypoints?
Post by: Cheetah on 12 Aug 2007, 15:13:13
Place the waypoints for the enemy groups. Give groupnames by adding the following code in the leader's init:
Code: [Select]
groupAlpha = group this;
Name the heli "blackhawk".
Next, have a script or trigger activate a few seconds after the mission starts (trigger: timeout 5-5-5, condition: true)

On activation:
Code: [Select]
[groupAlpha, 1] setWaypointPosition [getPos blackhawk, 0]
Title: Re: Dynamic trigger/waypoints?
Post by: ckclaw on 12 Aug 2007, 15:55:46
Gez sorry guys cant get that to work either!

Going on the cider now,must be missing something simple? :)



EDIT:-

YAY damn cider kicking in now!  :clap:

Got it,had typo in timeout! lol

Thanks All!  :good: