YaTraceMoverComponent¶
YaTraceMoverComponent
determines how an entity traces a target entity. YaTraceMoverComponent
can only function when the Trace Mover module (https://developer.yahaha.com/manual/yahaha-studio-manual/scripting/module/module-reference/TraceMover/) is added to the same object.Functions¶
void StartTrace(YaEntity targetEntity, number speed, TraceMode traceMode, [float3 offset], [number maxTraceTime])¶
SERVER ONLY
Starts the trace.
targetEntity
Target entity to be tracedspeed
Trace speedtraceMode
Trace Modeoffset
Position offset of the targetmaxTraceTime
Maximum trace time in seconds
void EndTrace()¶
SERVER ONLY
Stops the trace.
Events¶
TracerReachTargetEvent<void>¶
SERVER ONLY
Fired when the target is hit by the trace
Code sample¶
1 2 3 4 5 6 7 8 9 10 |
|