
class GravRotTracesFX extends Effects;

#EXEC TEXTURE IMPORT NAME=GravTrace 	FILE=EFFECTS\GravTrace.BMP 	GROUP=Coronas 	FLAGS=2

//Mesh 01
#EXEC MESH IMPORT 	MESH=GravRotTracesFX01 ANIVFILE=MODELS\GravRotTracesFX_a.3d DATAFILE=MODELS\GravRotTracesFX_d.3d X=0 Y=0 Z=0
#exec MESH LODPARAMS MESH=GravRotTracesFX01 STRENGTH=0.5
#EXEC MESH ORIGIN 	MESH=GravRotTracesFX01 X=0 Y=0 Z=0

#EXEC MESH SEQUENCE MESH=GravRotTracesFX01 SEQ=All 		STARTFRAME=0 NUMFRAMES=40
#EXEC MESH SEQUENCE MESH=GravRotTracesFX01 SEQ=Still 		STARTFRAME=0 NUMFRAMES=1
#EXEC MESH SEQUENCE MESH=GravRotTracesFX01 SEQ=RotPlay 	STARTFRAME=0 NUMFRAMES=40 RATE=39.0
#EXEC MESH SEQUENCE MESH=GravRotTracesFX01 SEQ=RotLoop 	STARTFRAME=0 NUMFRAMES=39 RATE=38.0

#EXEC MESHMAP NEW 	MESHMAP=GravRotTracesFX01 MESH=GravRotTracesFX01
#EXEC MESHMAP SCALE 	MESHMAP=GravRotTracesFX01 X=0.075 Y=0.075 Z=0.15

#exec MESHMAP SETTEXTURE MESHMAP=GravRotTracesFX01 NUM=1 TEXTURE=GravTrace

//Mesh 02
#EXEC MESH IMPORT 	MESH=GravRotTracesFX02 ANIVFILE=MODELS\GravRotTracesFX_a.3d DATAFILE=MODELS\GravRotTracesFX_d.3d X=0 Y=0 Z=0
#exec MESH LODPARAMS MESH=GravRotTracesFX02 STRENGTH=0.5
#EXEC MESH ORIGIN 	MESH=GravRotTracesFX02 X=0 Y=0 Z=0 YAW=32 PITCH=32 ROLL=32

#EXEC MESH SEQUENCE MESH=GravRotTracesFX02 SEQ=All 		STARTFRAME=0 NUMFRAMES=40
#EXEC MESH SEQUENCE MESH=GravRotTracesFX02 SEQ=Still 		STARTFRAME=0 NUMFRAMES=1
#EXEC MESH SEQUENCE MESH=GravRotTracesFX02 SEQ=RotPlay 	STARTFRAME=0 NUMFRAMES=40 RATE=39.0
#EXEC MESH SEQUENCE MESH=GravRotTracesFX02 SEQ=RotLoop 	STARTFRAME=0 NUMFRAMES=39 RATE=38.0

#EXEC MESHMAP NEW 	MESHMAP=GravRotTracesFX02 MESH=GravRotTracesFX02
#EXEC MESHMAP SCALE 	MESHMAP=GravRotTracesFX02 X=0.075 Y=0.075 Z=0.15

#exec MESHMAP SETTEXTURE MESHMAP=GravRotTracesFX02 NUM=1 TEXTURE=GravTrace

//Mesh 03
#EXEC MESH IMPORT 	MESH=GravRotTracesFX03 ANIVFILE=MODELS\GravRotTracesFX_a.3d DATAFILE=MODELS\GravRotTracesFX_d.3d X=0 Y=0 Z=0
#exec MESH LODPARAMS MESH=GravRotTracesFX03 STRENGTH=0.5
#EXEC MESH ORIGIN 	MESH=GravRotTracesFX03 X=0 Y=0 Z=0 YAW=-32 PITCH=-32 ROLL=-32

#EXEC MESH SEQUENCE MESH=GravRotTracesFX03 SEQ=All 		STARTFRAME=0 NUMFRAMES=40
#EXEC MESH SEQUENCE MESH=GravRotTracesFX03 SEQ=Still 		STARTFRAME=0 NUMFRAMES=1
#EXEC MESH SEQUENCE MESH=GravRotTracesFX03 SEQ=RotPlay 	STARTFRAME=0 NUMFRAMES=40 RATE=39.0
#EXEC MESH SEQUENCE MESH=GravRotTracesFX03 SEQ=RotLoop 	STARTFRAME=0 NUMFRAMES=39 RATE=38.0

#EXEC MESHMAP NEW 	MESHMAP=GravRotTracesFX03 MESH=GravRotTracesFX03
#EXEC MESHMAP SCALE 	MESHMAP=GravRotTracesFX03 X=0.075 Y=0.075 Z=0.15

#exec MESHMAP SETTEXTURE MESHMAP=GravRotTracesFX03 NUM=1 TEXTURE=GravTrace


var() Mesh TraceMesh[3];

simulated function InitializePlay(byte n, float PlayRate, optional bool bLoop)
{
	if (n < ArrayCount(TraceMesh))
		Mesh = TraceMesh[n];
	
	if (PlayRate <= 0)
		PlayRate = 1.0;
	
	if (bLoop)
		LoopAnim('RotLoop', PlayRate);
	else
		PlayAnim('RotPlay', PlayRate, 0.0);
}

defaultproperties
{
   bNetTemporary=False
   bTrailerSameRotation=True
   Physics=PHYS_Trailer
   RemoteRole=ROLE_SimulatedProxy
   Mass=0.00
   TraceMesh(0)=LodMesh'GravRotTracesFX01'
   TraceMesh(1)=LodMesh'GravRotTracesFX02'
   TraceMesh(2)=LodMesh'GravRotTracesFX03'
   DrawType=DT_Mesh
   Style=STY_Translucent
   Mesh=LodMesh'GravRotTracesFX01'
   ScaleGlow=1.65
   bUnlit=True
}