
//~~~~~~~~~~~~~~~~~~~~//~~~~~~~~~~~~~~~~~~~~//~~~~~~~~~~~~~~~~~~~~//
//
// Dynamite Explosion
//
//~~~~~~~~~~~~~~~~~~~~//~~~~~~~~~~~~~~~~~~~~//~~~~~~~~~~~~~~~~~~~~//

datablock ParticleData(Explosion_P)
{  
   canSaveDynamicFields = "1";
   dragCoefficient = "0";
   windCoefficient = "0";
   gravityCoefficient = "0";
   inheritedVelFactor = "0";
   constantAcceleration = "0";
   lifetimeMS = "220";
   lifetimeVarianceMS = "0";
   spinSpeed = "0.1";
   spinRandomMin = "-96";
   spinRandomMax = "50";
   useInvAlpha = "0";
   animateTexture = "0";
   framesPerSec = "1";
   textureName = "assets/data/effects/effecttextures/glowexplosion.png";
   animTexName[0] = "assets/data/effects/effecttextures/glowexplosion.png";
   colors[0] = "1 1 1 1";
   colors[1] = "1 1 1 0.692913";
   colors[2] = "1 1 1 1";
   colors[3] = "1 1 1 0";
   sizes[0] = "3.45";
   sizes[1] = "7.6";
   sizes[2] = "8.9";
   sizes[3] = "6.7";
   times[0] = "0";
   times[1] = "0.5";
   times[2] = "0.8";
   times[3] = "1";
   allowLighting = "0";
   constrainPos = "0";
};

datablock ParticleEmitterData(explosionParticleEmitterData)
{
   canSaveDynamicFields = "1";
   className = "ParticleEmitterData";
   receiveLMLighting = "1";
   ejectionPeriodMS = "80";
   periodVarianceMS = "0";
   ejectionVelocity = "0.6";
   velocityVariance = "0.25";
   ejectionOffset = "0";
   thetaMin = "0";
   thetaMax = "0";
   phiReferenceVel = "1";
   phiVariance = "61";
   overrideAdvance = "0";
   orientParticles = "0";
   orientOnVelocity = "0";
   particles = "Explosion_P";
   lifetimeMS = "90";
   lifetimeVarianceMS = "0";
   useEmitterSizes = "0";
   useEmitterColors = "0";
   emitterType = "vector";
   ejectionInvert = "0";
   fadeColor = "0";
   fadeSize = "0";
   fadeVelocity = "0";
   fadeOffset = "0";
   vector = "0 0 0";
   spreadMin = "0";
   spreadMax = "0";
   pathOrigin = "origin";
   radiusMin = "0";
   radiusMax = "1";

};

datablock ParticleData(Blast_P)
{  
   canSaveDynamicFields = "1";
   dragCoefficient = "0";
   windCoefficient = "0";
   gravityCoefficient = "0";
   inheritedVelFactor = "0";
   constantAcceleration = "0";
   lifetimeMS = "410";
   lifetimeVarianceMS = "50";
   spinSpeed = "0.1";
   spinRandomMin = "-100";
   spinRandomMax = "100";
   useInvAlpha = "1";
   animateTexture = "0";
   framesPerSec = "1";
   textureName = "assets/data/effects/effecttextures/blastdamage.png";
   colors[0] = "1 1 1 1";
   colors[1] = "1 1 1 1";
   colors[2] = "1 1 1 .8";
   colors[3] = "1 1 1 0.1";
   sizes[0] = "5.45";
   sizes[1] = "10.6";
   sizes[2] = "11.9";
   sizes[3] = "9.5";
   times[0] = "0";
   times[1] = "0.3";
   times[2] = "0.8";
   times[3] = "1";
   allowLighting = "0";
   constrainPos = "0";
};
datablock ParticleEmitterData(blastParticleEmitterData)
{
   canSaveDynamicFields = "1";
   className = "ParticleEmitterData";
   receiveLMLighting = "0";
   ejectionPeriodMS = "100";
   periodVarianceMS = "0";
   ejectionVelocity = "0";
   velocityVariance = "0";
   ejectionOffset = "0";
   thetaMin = "0";
   thetaMax = "0";
   phiReferenceVel = "1";
   phiVariance = "61";
   overrideAdvance = "0";
   orientParticles = "0";
   orientOnVelocity = "0";
   particles = "blast_P";
   lifetimeMS = "120";
   lifetimeVarianceMS = "0";
   useEmitterSizes = "0";
   useEmitterColors = "0";
   emitterType = "vector";
   ejectionInvert = "0";
   fadeColor = "0";
   fadeSize = "0";
   fadeVelocity = "1";
   fadeOffset = "0";
   vector = "0 0 0";
   spreadMin = "0";
   spreadMax = "0";
   pathOrigin = "origin";
   radiusMin = "0";
   radiusMax = "1";

};

datablock afxEffectWrapperData(explosionEffectWrapperData)
{
  effect = explosionParticleEmitterData;
  orientConstraint = "testEffect";

  delay       = 0;
  fadeInTime  = 0;
  fadeOutTime = 0;
};

datablock afxEffectWrapperData(blastEffectWrapperData)
{
  effect = blastParticleEmitterData;
  orientConstraint = "testEffect";

  delay       = 0.05;
  fadeInTime  = 0;
  fadeOutTime = 0;
};

// Blast Smoke Cloud
datablock ParticleData(cloud_P)
{
   canSaveDynamicFields = "1";
   dragCoefficient = "0.21";
   windCoefficient = "0";
   gravityCoefficient = "-0.06";
   inheritedVelFactor = "0";
   constantAcceleration = "0";
   lifetimeMS = "750";
   lifetimeVarianceMS = "100";
   spinSpeed = "0.1";
   spinRandomMin = "-60";
   spinRandomMax = "145";
   useInvAlpha = "1";
   animateTexture = "0";
   framesPerSec = "1";
   textureName = "assets/data/effects/effecttextures/LMF_smokeA.png";
   colors[0] = "0 0 0 0.4";
   colors[1] = "0.3 0.3 0.3 1";
   colors[2] = "0.5 0.5 0.5 0.3";
   colors[3] = "1 1 1 1";
   sizes[0] = "4.58";
   sizes[1] = "12";
   sizes[2] = "11";
   sizes[3] = "1";
   times[0] = "0";
   times[1] = "0.7";
   times[2] = "1";
   times[3] = "1";
   allowLighting = "0";
   constrainPos = "0";
};
datablock ParticleEmitterData(cloudParticleEmitterData) 
{
   canSaveDynamicFields = "1";
   className = "ParticleEmitterData";
   receiveLMLighting = "1";
   ejectionPeriodMS = "50";
   periodVarianceMS = "0";
   ejectionVelocity = "0.4";
   velocityVariance = "0";
   ejectionOffset = "0";
   ejectionDistance = "0.34";
   thetaMin = "0";
   thetaMax = "180";
   phiReferenceVel = "0";
   phiVariance = "360";
   overrideAdvance = "0";
   orientParticles = "0";
   orientOnVelocity = "1";
   particles = "cloud_P";
   lifetimeMS = "240";
   lifetimeVarianceMS = "0";
   useEmitterSizes = "0";
   useEmitterColors = "0";
   emitterType = "vector";
   ejectionInvert = "0";
   fadeColor = "0";
   fadeSize = "0";
   fadeVelocity = "0";
   fadeOffset = "0";
   vector = "0 0 0";
   spreadMin = "0";
   spreadMax = "0";
   pathOrigin = "origin";
   radiusMin = "0";
   radiusMax = "1";
};

datablock afxEffectWrapperData(cloudEffectWrapperData)
{
  effect = cloudParticleEmitterData;
  orientConstraint = "testEffect";

  delay       = 0.1;
  fadeInTime  = 0;
  fadeOutTime = 0;
};

// Blast decal
datablock afxZodiacData(BlastZodiac)
{
   texture = "~/data/effects/effecttextures/blastdamage.png";
   radius = 6;
   startAngle = 0;
   growInTime = 0;
   shrinkOutTime = 0;
   growthRate = 0;
   color = "1 1 1 .9";
   blend = normal; // normal, additive, or subtractive
   showOnTerrain = true;
};
datablock afxEffectWrapperData(BlastEffect)
{
   effect = BlastZodiac;
   posConstraint = construction;
   fadeInTime = ".05";
   fadeOutTime = 3;
};

datablock ParticleData(whitepuff_P)
{
   canSaveDynamicFields = "1";
   dragCoefficient = "0";
   windCoefficient = "0";
   gravityCoefficient = "-0.28";
   inheritedVelFactor = "0";
   constantAcceleration = "0";
   lifetimeMS = "2200";
   lifetimeVarianceMS = "100";
   spinSpeed = "0.1";
   spinRandomMin = "-100";
   spinRandomMax = "100";
   useInvAlpha = "1";
   animateTexture = "0";
   framesPerSec = "1";
   textureName = "assets/data/effects/effecttextures/smoke.png";
   colors[0] = ".5 .5 .5 1";
   colors[1] = ".8 .8 .8 0.7";
   colors[2] = "1 1 1 0.5";
   colors[3] = "1 1 1 0";
   sizes[0] = "1";
   sizes[1] = "2";
   sizes[2] = "3";
   sizes[3] = "2.5";
   times[0] = "0";
   times[1] = "0.35";
   times[2] = "0.70";
   times[3] = "1";
   allowLighting = "0";
   constrainPos = "0";
};
datablock ParticleEmitterData(whitepuffParticleEmitterData) 
{
   canSaveDynamicFields = "1";
   className = "ParticleEmitterData";
   receiveLMLighting = "0";
   ejectionPeriodMS = "200";
   periodVarianceMS = "0";
   ejectionVelocity = "0";
   velocityVariance = "0";
   ejectionOffset = "0";
   ejectionDistance = "0";
   thetaMin = "0";
   thetaMax = "0";
   phiReferenceVel = "0";
   phiVariance = "0";
   overrideAdvance = "0";
   orientParticles = "0";
   orientOnVelocity = "1";
   particles = "whitepuff_P";
   lifetimeMS = "580";
   lifetimeVarianceMS = "0";
   useEmitterSizes = "0";
   useEmitterColors = "0";
   emitterType = "vector";
   ejectionInvert = "0";
   fadeColor = "0";
   fadeSize = "0";
   fadeVelocity = "1";
   fadeOffset = "0";
   vector = "0 0 1";
   spreadMin = "0";
   spreadMax = "0";
   pathOrigin = "origin";
   radiusMin = "0";
   radiusMax = "1";
};
datablock afxEffectWrapperData(whitepuffEffectWrapperData)
{
  effect = whitepuffParticleEmitterData;
  orientConstraint = "testEffect";

  delay       = "0.5";
  fadeInTime  = 0;
  fadeOutTime = 0;
};
datablock afxEffectronData(whitepuffEffectronData)
{
  duration = $AFX::INFINITE_TIME;
  addEffect = whitepuffEffectWrapperData;
};

// MAIN TNT Explosion
datablock afxEffectronData(explosionEffectronData)
{
  duration = $AFX::INFINITE_TIME;
  addEffect = explosionEffectWrapperData;
  addEffect = blastEffectWrapperData;
  addEffect = cloudEffectWrapperData;
  addEffect = BlastEffect;
};

 //~~~~~~~~~~~~~~~~~~~~//~~~~~~~~~~~~~~~~~~~~//~~~~~~~~~~~~~~~~~~~~//
//
// Desert Rock Explosion
//
//~~~~~~~~~~~~~~~~~~~~//~~~~~~~~~~~~~~~~~~~~//~~~~~~~~~~~~~~~~~~~~//

// Blast Smoke Cloud
datablock ParticleData(desertcloud_P)
{
   canSaveDynamicFields = "1";
   dragCoefficient = "0.21";
   windCoefficient = "0";
   gravityCoefficient = "-0.06";
   inheritedVelFactor = "0";
   constantAcceleration = "0";
   lifetimeMS = "700";
   lifetimeVarianceMS = "100";
   spinSpeed = "0.1";
   spinRandomMin = "-60";
   spinRandomMax = "145";
   useInvAlpha = "1";
   animateTexture = "0";
   framesPerSec = "1";
   textureName = "assets/data/effects/effecttextures/LMF_smokeA.png";
   colors[0] = "0 0 0 0.5";
   colors[1] = "0.65 0.4 0.1 0.9";
   colors[2] = "0.6 0.5 0.1 0.5";
   colors[3] = "1 1 1 1";
   sizes[0] = "4";
   sizes[1] = "9";
   sizes[2] = "8.5";
   sizes[3] = "1";
   times[0] = "0";
   times[1] = "0.7";
   times[2] = "1";
   times[3] = "1";
   allowLighting = "0";
   constrainPos = "0";
};
datablock ParticleEmitterData(desertcloudParticleEmitterData)
{
   canSaveDynamicFields = "1";
   className = "ParticleEmitterData";
   receiveLMLighting = "1";
   ejectionPeriodMS = "60";
   periodVarianceMS = "0";
   ejectionVelocity = "0.4";
   velocityVariance = "0";
   ejectionOffset = "0";
   ejectionDistance = "0.34";
   thetaMin = "0";
   thetaMax = "180";
   phiReferenceVel = "0";
   phiVariance = "360";
   overrideAdvance = "0";
   orientParticles = "0";
   orientOnVelocity = "1";
   particles = "desertcloud_P";
   lifetimeMS = "250";
   lifetimeVarianceMS = "0";
   useEmitterSizes = "0";
   useEmitterColors = "0";
   emitterType = "vector";
   ejectionInvert = "0";
   fadeColor = "0";
   fadeSize = "0";
   fadeVelocity = "0";
   fadeOffset = "0";
   vector = "0 0 0";
   spreadMin = "0";
   spreadMax = "0";
   pathOrigin = "origin";
   radiusMin = "0";
   radiusMax = "1";
};

datablock afxEffectWrapperData(desertcloudEffectWrapperData)
{
  effect = desertcloudParticleEmitterData;
  orientConstraint = "testEffect";

  delay       = 0;
  fadeInTime  = 0;
  fadeOutTime = 0;
};

// Blast decal
datablock afxZodiacData(rockBlastZodiac)
{
   texture = "~/data/effects/construction_small.png";
   radius = 5;
   startAngle = 0;
   growInTime = 0;
   shrinkOutTime = 0;
   growthRate = 0;
   color = "1 1 1 .8";
   blend = normal; // normal, additive, or subtractive
   showOnTerrain = true;
};
datablock afxEffectWrapperData(rockDecalEffectWrapper)
{
   effect = rockBlastZodiac;
   posConstraint = construction;
   delay       = 0;
   fadeInTime = "0.05";
   fadeOutTime = "3";
};

datablock ParticleData(blastrock1_P)
{
   canSaveDynamicFields = "1";
   dragCoefficient = "0.51";
   windCoefficient = "0.28";
   gravityCoefficient = "0.22";
   inheritedVelFactor = "0.045";
   constantAcceleration = "-0.6";
   lifetimeMS = "1327";
   lifetimeVarianceMS = "96";
   spinSpeed = "0";
   spinRandomMin = "-70";
   spinRandomMax = "375";
   useInvAlpha = "1";
   animateTexture = "0";
   framesPerSec = "1";
   textureName = "assets/data/effects/effecttextures/rock1.png";
   animTexName[0] = "assets/data/effects/effecttextures/rock1.png";
   colors[0] = "1 1 1 1";
   colors[1] = "1 1 1 1";
   colors[2] = "1 1 1 1";
   colors[3] = "1 1 1 0.5";
   sizes[0] = "0.4";
   sizes[1] = "0.4";
   sizes[2] = "0.4";
   sizes[3] = "0.3";
   times[0] = "0";
   times[1] = "0.3";
   times[2] = "0.6";
   times[3] = "1";
   useInvAlpha = true;
  	allowLighting = false;
   constrainPos = "0";
};
datablock ParticleData(blastrock2_P)
{
   canSaveDynamicFields = "1";
   dragCoefficient = "0.51";
   windCoefficient = "0.28";
   gravityCoefficient = "0.22";
   inheritedVelFactor = "0.045";
   constantAcceleration = "-0.6";
   lifetimeMS = "2000";
   lifetimeVarianceMS = "96";
   spinSpeed = "0";
   spinRandomMin = "-70";
   spinRandomMax = "375";
   useInvAlpha = "1";
   animateTexture = "0";
   framesPerSec = "1";
   textureName = "assets/data/effects/effecttextures/rock2.png";
   animTexName[0] = "assets/data/effects/effecttextures/rock2.png";
   colors[0] = "1 1 1 1";
   colors[1] = "1 1 1 1";
   colors[2] = "1 1 1 1";
   colors[3] = "1 1 1 0.5";
   sizes[0] = "0.4";
   sizes[1] = "0.4";
   sizes[2] = "0.4";
   sizes[3] = "0.3";
   times[0] = "0";
   times[1] = "0.3";
   times[2] = "0.6";
   times[3] = "1";
   useInvAlpha = true;
  	allowLighting = false;
   constrainPos = "0";
};

datablock ParticleEmitterData(blastrockParticleEmitterData)
{	 
  	canSaveDynamicFields = "1";
   className = "ParticleEmitterData";
   receiveLMLighting = "1";
   ejectionPeriodMS = "20";
   periodVarianceMS = "0";
   ejectionVelocity = "2.2";
   velocityVariance = "0.5";
   ejectionOffset = "0";
   ejectionDistance = "0";
   thetaMin = "0";
   thetaMax = "180";
   phiReferenceVel = "0.96";
   phiVariance = "360";
   overrideAdvance = "0";
   orientParticles = "0";
   orientOnVelocity = "1";
   particles = "blastrock2_P";
   lifetimeMS = "100";
   lifetimeVarianceMS = "0";
   useEmitterSizes = "0";
   useEmitterColors = "0";
   emitterType = "disc";
   ejectionInvert = "0";
   fadeColor = "0";
   fadeSize = "0";
   fadeVelocity = "0";
   fadeOffset = "0";
   vector = "0 0 0";
   spreadMin = "1";
   spreadMax = "3";
   pathOrigin = "origin";
   radiusMin = "0";
   radiusMax = "3";
};

datablock afxEffectWrapperData(rockblastEffectWrapperData)
{
  effect = blastrockParticleEmitterData;
  orientConstraint = "testEffect";

  delay       = 0.2;
  fadeInTime  = 0;
  fadeOutTime = 0;
};

// MAIN Rock Explosion
datablock afxEffectronData(rockexplosionEffectronData)
{
  duration = $AFX::INFINITE_TIME;
  addEffect = rockblastEffectWrapperData;
  addEffect = desertcloudEffectWrapperData;
  addEffect = rockDecalEffectWrapper;
};