-----------------------------------------------------------------------------
--  File     : /mods/4DC_V0.8/projectiles/UAL0216_ArtCannon01/UAL0216_ArtCannon01_script.lua
--
--  Author(s): Eddy, EbolaSoup, Resin Smoker, Optimus Prime, Vissroid 
--
--  Summary  : Aeon 'LongHammer' Artillery Projectile
--
--  Copyright © 2011 4DC_V0.8  All rights reserved.
-----------------------------------------------------------------------------

local RandomFloat = import('/lua/utilities.lua').GetRandomFloat
local TDArtCannonShell = import('/mods/4DC_V0.8/lua/4d_projectiles.lua').TArtCannon

TDArtCannon01 = Class(TDArtCannonShell) {
    OnImpact = function(self, targetType, targetEntity)
        TDArtCannonShell.OnImpact(self, targetType, targetEntity)
        local army = self:GetArmy()
        CreateLightParticle( self, -1, army, 6, 8, 'glow_03', 'ramp_blue_16' )
        CreateLightParticle( self, -1, army, 3, 12, 'glow_03', 'ramp_antimatter_02' )
        if targetType == 'Terrain' or targetType == 'Prop' then
            CreateDecal( self:GetPosition(), RandomFloat(0.0,6.28), 'scorch_011_albedo', '', 'Albedo', 2, 2, 350, 60, army )  
        end
        self:ShakeCamera(2, 1, 0.5, 0.5)      
    end,
}
TypeClass = TDArtCannon01