OFPEC Forum

Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting Multiplayer => Topic started by: zinco on 24 Mar 2003, 02:15:17

Title: alternative to cycle waypoints??
Post by: zinco on 24 Mar 2003, 02:15:17
It seems, for me anyway, using cycle to get a vehicle to go back and forth for instance does not work very consistently.  Some times it works just fine other time not at all.

I would like to do the same thing using gamelogics and a script.  Not sure what commands to use though.
If i use a trigger to trigger the script and gamelogic to mark the positions how do i get the jeep with ai or tank with ai to move to the position i want.

I'm sure it is pretty easy i just do not know the commands that well.

Thanks, Zinco
Title: Re:alternative to cycle waypoints??
Post by: Knut Erik on 24 Mar 2003, 09:24:12
I have an idea. Create a script and write this..



Quote
#loop
NameOfCar domove getpos FirstGameLogic
@ Unitready NameOfCar
NameOfCar domove getpos NextGameLogic
@ Unitready NameOfCar
goto "loop"

Then put this in the init field of the car:

this exec "NameOfScript.sqs"
Title: Re:alternative to cycle waypoints??
Post by: zinco on 24 Mar 2003, 23:22:02
COOL thanks.  i'll try it and let u know.
Title: Re:alternative to cycle waypoints??
Post by: zinco on 25 Mar 2003, 05:03:55
works like a champ so far.  thank a bunch
Title: Re:alternative to cycle waypoints??
Post by: Knut Erik on 25 Mar 2003, 09:49:58
I'm glad it worked (It was only an idea that popped into my head.)

Now you only need to :
 8) 8) 8) 8) 8) 8) 8)
Solve the Topic
 8) 8) 8) 8) 8) 8) 8)
Title: Re:alternative to cycle waypoints??
Post by: zinco on 27 Mar 2003, 02:57:22
1st ideas are usually the best.  i do not think it will solve the problem that i have heard some people complain about............the fact that they sometime weave back and forth and do funny things.  but it works for my purposes.  i will press solve, ty.