#
# Sub-Based Torpedo Script
#
local CTorpedoSubProjectile = import('/lua/cybranprojectiles.lua').CTorpedoSubProjectile
local RandomFloat = import('/lua/utilities.lua').GetRandomFloat
local EffectTemplate = import('/lua/EffectTemplates.lua')

CANTorpedoNanite01 = Class(CTorpedoSubProjectile) {

    FxImpactUnit = EffectTemplate.CProtonArtilleryHit01,
    FxImpactProp = EffectTemplate.CProtonArtilleryHit01,
    FxImpactLand = EffectTemplate.CProtonArtilleryHit01,
    FxImpactWater = EffectTemplate.CProtonArtilleryHit01,
    FxImpactUnderWater = EffectTemplate.CProtonArtilleryHit01,
    FxImpactNone = EffectTemplate.CProtonArtilleryHit01,
		FxLandHitScale = 1,
		FxUnitHitScale = 1,
		FxWaterHitScale = 1,
		
		    OnImpact = function(self, targetType, targetEntity)
        local army = self:GetArmy()
        CreateLightParticle( self, -1, army, 3, 7, 'glow_03', 'ramp_fire_11' ) 
        CTorpedoSubProjectile.OnImpact(self, targetType, targetEntity)
    end,       
}

TypeClass = CANTorpedoNanite01