Page 1 of 1

moving object

Posted: Fri Sep 09, 2005 4:12 am
by RJH
i need some help makeing an entity e.g. static corona move from waypoint to waypoint then disapear and wait to be triggered again?

I already have one set up with a trigger leading to a corona with a targetname of flare1 and a target of flare1wp

then a splinepath with a targetname of flare1wp and target of flare1wp2 and so on for about 3 more splinepaths. i need a script to make it move, or im just doing all wrong?

Posted: Fri Sep 09, 2005 8:59 am
by bdbodger
The corona may need to be a script_model , you can use one of these commands

flypath( Entity array, Float speed, Float acceleration, Float look_ahead )

Makes the script slave fly the specified path with speed and acceleration until reached_distance close to position

followpath( Entity path, [ String arg1 ], [ String arg2 ], [ String arg3 ], [ String arg4 ], [ String arg5 ], [ String arg6 ] )

Makes the script slave follow the specified path. The allowable arguments are ignoreangles,
ignorevelocity, normalangles, loop, and a number specifying the start time


eg:

local.startpoint = $mything.origin
$mything followpath $flare1wp // or $mything flypath $flarewp1 1500 200 256
$mything waitmove
$mything hide
$mything.origin = local.startpoint

With followpath the speed defaults to about 200 units per second but you can change that with

$mything.speed = ??? // set a value

before you move it and you can use show to show it before you move it I assume you will hide it at the top of the script but you might spawn it the first time or each time it is up to you .