-----------------------------------------------------------------------------
--
--  File     :  /4DC_v0.8/hook/units/XSB2108/XSB2108_unit.bp
--
--  Author(s):  Resin_Smoker
--
--  Special Thanks: Mithy, Bulletmagnet
--
--  Summary  : Seraphim Tactical Missile Launcher Blueprint 
--             Modded for Re-Targeting,
--             smoother turning missiles &
--             child projectile creation
--
--  Copyright © 2011 4DC_V0.8  All rights reserved.
-----------------------------------------------------------------------------

UnitBlueprint {
    AI = {
        InitialAutoMode = true,
    },
    Audio = {
        Close = Sound {
            Bank = 'XSB',
            Cue = 'XSB2108_Doors_Close',
            LodCutoff = 'UnitMove_LodCutoff',
        },
        Destroyed = Sound {
            Bank = 'XSL_Destroy',
            Cue = 'XSB_Destroy_Huge',
            LodCutoff = 'UnitMove_LodCutoff',
        },
        DoneBeingBuilt = Sound {
            Bank = 'XSB',
            Cue = 'XSB2108_Activate',
            LodCutoff = 'UnitMove_LodCutoff',
        },
        Killed = Sound {
            Bank = 'XSL_Destroy',
            Cue = 'XSB_Destroy_Lrg_PreDestroy',
            LodCutoff = 'UnitMove_LodCutoff',
        },
        Open = Sound {
            Bank = 'XSB',
            Cue = 'XSB2108_Doors_Open',
            LodCutoff = 'UnitMove_LodCutoff',
        },
        UISelection = Sound {
            Bank = 'SeraphimSelect',
            Cue = 'Seraphim_Select_gun',
            LodCutoff = 'UnitMove_LodCutoff',
        },
    },
    Buffs = {
        Regen = {
            Level1 = 2,
            Level2 = 4,
            Level3 = 6,
            Level4 = 8,
            Level5 = 10,
        },
    },
    BuildIconSortPriority = 150,
    Categories = {
        'ANTINAVY',
        'PRODUCTFA',
        'SELECTABLE',
        'BUILTBYTIER2ENGINEER',
        'BUILTBYTIER3ENGINEER',
        'BUILTBYTIER2COMMANDER',
        'BUILTBYTIER3COMMANDER',
        'SERAPHIM',
        'STRUCTURE',
        'STRATEGIC',
        'TECH2',
        'INDIRECTFIRE',
        'TACTICALMISSILEPLATFORM',
        'DRAGBUILD',
        'SILO',
        'SIZE4',
        'VISIBLETORECON',
        'RECLAIMABLE',
        'OVERLAYINDIRECTFIRE',
        'SORTSTRATEGIC',
    },
    CollisionOffsetY = 0,
    Defense = {
        AirThreatLevel = 0,
        ArmorType = 'Structure',
        EconomyThreatLevel = 9,
        Health = 1500,
        MaxHealth = 1500,
        RegenRate = 0,
        SubThreatLevel = 0,
        SurfaceThreatLevel = 0,
    },
    Description = '<LOC xsb2108_desc>Tactical Missile Launcher',
    Display = {
        Abilities = {
            'Retargeting',
            '<LOC ability_manuallaunch>Manual Launch',
        },
        AnimationDeath = {
            {
                Animation = '/units/xsb2108/xsb2108_ADeath.sca',
                AnimationRateMax = 1,
                AnimationRateMin = 1,
                Weight = 100,
            },
        },
        DamageEffects = {
            {
                Bone = 0,
                OffsetX = 0.1,
                OffsetY = 0,
                OffsetZ = 0.5,
            },
            {
                Bone = 0,
                OffsetX = -0.1,
                OffsetY = 0,
                OffsetZ = 0.5,
            },
            {
                Bone = 0,
                OffsetX = -0.1,
                OffsetY = 0,
                OffsetZ = -0.5,
            },
            {
                Bone = 0,
                OffsetX = 0.1,
                OffsetY = 0,
                OffsetZ = -0.5,
            },
        },        
        Mesh = {
            IconFadeInZoom = 130,
            LODs = {
                {
                    AlbedoName = '/units/xsb2108/xsb2108_albedo.dds',
                    LODCutoff = 100,                    
                    LookupName = '/textures/environment/Falloff_seraphim_lookup.dds',                     
                    MeshName = '/units/xsb2108/xsb2108_lod0.scm',
                    NormalsName = '/units/xsb2108/xsb2108_normalsTS.dds',
                    Scrolling = true,
                    SpecularName = '/units/xsb2108/xsb2108_specteam.dds',                                 
                    ShaderName = 'Seraphim',         
                },
                {
                    AlbedoName = '/units/xsb2108/xsb2108_lod1_albedo.dds',
                    LODCutoff = 215,
                    LookupName = '/textures/environment/Falloff_seraphim_lookup.dds',                    
                    MeshName = '/units/xsb2108/xsb2108_lod1.scm',            
                    NormalsName = '/units/xsb2108/xsb2108_lod1_normalsTS.dds',                
                    ShaderName = 'Seraphim', 
                    SpecularName = '/units/xsb2108/xsb2108_lod1_specteam.dds',                                                                       
                }, 
            },
        },        
        PlaceholderMeshName = 'UXB0026',
        SpawnRandomRotation = true,
        Tarmacs = {
            {
                Albedo = 'Tarmacs/Tar6x_seraphim_01_albedo',
                DeathLifetime = 300,
                FadeOut = 150,
                Length = 6.4,
                Normal = 'Tarmacs/Tar6x_seraphim_01_normals',
                Orientations = {
                    0,
                    90,
                    180,
                    270,
                },
                RemoveWhenDead = false,
                Width = 6.4,
            },
        },
        UniformScale = 0.05,
    },
    Economy = {
        BuildCostEnergy = 4500,
        BuildCostMass = 825,
        BuildRate = 80,
        BuildTime = 700,
        RebuildBonusIds = {
            'xsb2108',
        },
    },
    Footprint = {
        SizeX = 1,
        SizeZ = 1,
    },
    General = {
        Category = 'Strategic',
        Classification = 'RULEUC_Weapon',
        CommandCaps = {
            RULEUCC_Attack = false,
            RULEUCC_CallTransport = false,
            RULEUCC_Capture = false,
            RULEUCC_Guard = false,
            RULEUCC_Move = false,
            RULEUCC_Nuke = false,
            RULEUCC_Patrol = false,
            RULEUCC_Pause = true,
            RULEUCC_Reclaim = false,
            RULEUCC_Repair = false,
            RULEUCC_RetaliateToggle = false,
            RULEUCC_SiloBuildTactical = true,
            RULEUCC_Stop = true,
            RULEUCC_Tactical = true,
            RULEUCC_Transport = false,
        },
        FactionName = 'Seraphim',
        Icon = 'land',
        SelectionPriority = 5,
        TechLevel = 'RULEUTL_Advanced',
        UnitName = '<LOC xsb2108_name>Ythis',
        UnitWeight = 1,
    },
    Intel = {
        VisionRadius = 24,
    },
    Interface = {
        HelpText = '<LOC xsb2108_help>Tactical Missile Launcher',
    },
    LifeBarHeight = 0.075,
    LifeBarOffset = 0.5,
    LifeBarSize = 1,
    Physics = {
        BankingSlope = 0,
        BuildOnLayerCaps = {
            LAYER_Air = false,
            LAYER_Land = true,
            LAYER_Orbit = false,
            LAYER_Seabed = false,
            LAYER_Sub = false,
            LAYER_Water = false,
        },
        DragCoefficient = 0.2,
        FlattenSkirt = true,
        MaxSteerForce = 0,
        MeshExtentsX = 0.75,
        MeshExtentsY = 0.35,
        MeshExtentsZ = 1.5,
        MinSpeedPercent = 0,
        MotionType = 'RULEUMT_None',
        SkirtOffsetX = -0.5,
        SkirtOffsetZ = -0.5,
        SkirtSizeX = 2,
        SkirtSizeZ = 2,
        TurnRate = 0,
    },
    SelectionSizeX = 0.45,
    SelectionSizeZ = 0.65,
    SelectionThickness = 0.6,
    SizeX = 0.65,
    SizeY = 0.8,
    SizeZ = 1,
    StrategicIconName = 'icon_structure2_missile',
    ModIconName = '4dc',
    StrategicIconSortPriority = 180,
    Veteran = {
        Level1 = 9,
        Level2 = 18,
        Level3 = 27,
        Level4 = 36,
        Level5 = 45,
    },
    Weapon = {
        {
            AboveWaterTargetsOnly = false,
            Audio = {
                Fire = Sound {
                    Bank = 'XSB_Weapon',
                    Cue = 'XSB2108_Laanse_Missile',
                    LodCutoff = 'Weapon_LodCutoff',
                },
            },
            BallisticArc = 'RULEUBA_None',
            CollideFriendly = false,
            CountedProjectile = true,
            Damage = 6000,
            DamageRadius = 2,
            DamageType = 'Normal',
            DisplayName = 'Laanse Tactical Missile Launcher',
            dontOKCheck = true,  --	don't do OKC check for this weapon.
            FireTargetLayerCapsTable = {
                Land = 'Land|Water',
            },
            FiringTolerance = 999,
            ForceSingleFire = true,
            InitialProjectileStorage = 0,
            Label = 'CruiseMissile',
            ManualFire = true,
            MaxProjectileStorage = 20,
            MaxRadius = 256,
            MinRadius = 15,
            MuzzleChargeDelay = 1.5,
            MuzzleSalvoDelay = 0,
            MuzzleSalvoSize = 1,
            MuzzleVelocity = 10,
            ProjectileId = '/projectiles/SIFLaanseTacticalMissile04/SIFLaanseTacticalMissile04_proj.bp',
            ProjectileLifetime = 60,
            RackBones = {
                {
                    MuzzleBones = {
                        'Projectile',
                    },
                    RackBone = 'Projectile',
                },
            },
            RackFireTogether = false,
            RackRecoilDistance = 0,
            RackReloadTimeout = 10,
            RackSalvoChargeTime = 0,
            RackSalvoReloadTime = 0,
            RackSalvoSize = 1,
            RackSlavedToTurret = false,
            RangeCategory = 'UWRC_IndirectFire',
            RateOfFire = 3,
            TargetCheckInterval = 1,
            TargetPriorities = {
                'SPECIALHIGHPRI',
                'STRUCTURE DEFENSE',
                'NAVAL',
                'SPECIALLOWPRI',
                'ALLUNITS',
            },
            TargetRestrictDisallow = 'UNTARGETABLE',
            TurretDualManipulators = false,
            TurretPitch = 0,
            TurretPitchRange = 0,
            TurretPitchSpeed = 0,
            TurretYaw = 0,
            TurretYawRange = 0,
            TurretYawSpeed = 0,
            Turreted = false,
            WeaponCategory = 'Missile',
            WeaponRepackTimeout = 3,
            WeaponUnpackAnimation = '/units/xsb2108/xsb2108_aopen.sca',
            WeaponUnpackAnimationRate = 1,
            WeaponUnpacks = true,
        },
    },
    Wreckage = {
        Blueprint = '/props/DefaultWreckage/DefaultWreckage_prop.bp',
        EnergyMult = 0,
        HealthMult = 0.9,
        MassMult = 0.9,
        ReclaimTimeMultiplier = 1,
        WreckageLayers = {
            Air = false,
            Land = true,
            Seabed = false,
            Sub = false,
            Water = false,
        },
    },
}