home *** CD-ROM | disk | FTP | other *** search
/ GameStar 2006 April / Gamestar_83_2006-04_dvd.iso / Dema / lotrbfme2_demo.exe / INI.big / data_ini_object_goodfaction_structures_dwarven_dwarfcastlewalls.ini < prev    next >
Text File  |  2006-01-31  |  88KB  |  2,903 lines

  1.  
  2.  
  3.  
  4. ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
  5. ;;                                                            ;;
  6. ;;    CASTLE WALL PIECES FOR THE NEW WALL BUILD SYSTEM        ;;
  7. ;;                                                            ;;
  8. ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
  9.  
  10. Object DwarvenCastleWallSegment
  11.   
  12.   ; *** ART Parameters ***
  13.   
  14.       SelectPortrait  =  BPDWall
  15.   
  16.     Draw = W3DScriptedModelDraw ModuleTag_Draw
  17.         OkToChangeModelColor  = Yes
  18.         UseStandardModelNames = Yes
  19.         DefaultModelConditionState
  20.             Model = DBWallRamp2
  21.         End
  22.         
  23.  
  24.         IdleAnimationState
  25.             Flags = ADJUST_HEIGHT_BY_CONSTRUCTION_PERCENT
  26.             Animation                =    ReallyDamagedanimation
  27.                 AnimationName        =     DBWallRamp2.DBWallRamp2
  28.                 AnimationMode        =    LOOP
  29.                End
  30.                StateName = STATE_None
  31.         End
  32.     End
  33.    
  34.   ; ***DESIGN parameters ***
  35.   DisplayName         = OBJECT:DwarvenCastleWallSegment
  36.   Side                = Dwarves
  37.   EditorSorting       = STRUCTURE
  38.   ThreatLevel = 1.0
  39.     ThreatBreakdown ModuleTag_DetailedThreat
  40.         AIKindOf = WALL
  41.     End
  42.  
  43.   BuildCost           = DWARVEN_WALLSEGMENT_SMALL_BUILDCOST
  44.   BuildTime           = DWARVEN_WALLSEGMENT_SMALL_BUILDTIME           ; in seconds
  45.   VisionRange         = DWARVEN_WALLSEGMENT_SMALL_VISION_RANGE         ; Shroud clearing distance
  46.   ShroudClearingRange = DWARVEN_WALLSEGMENT_SMALL_SHROUD_CLEAR
  47.   CommandSet            = DwarvenWallUpgradeNodeCommandSet
  48.   
  49.   ArmorSet
  50.         Conditions        = None
  51.         Armor             = DwarvenWallArmor
  52.         DamageFX          = None
  53.     End
  54.   
  55.   ; *** AUDIO Parameters ***
  56.  
  57.     #include "..\..\..\Includes\StandardBuildingEvaEvents.inc"
  58.  
  59.     SoundOnDamaged                = BuildingLightDamageStone
  60.     SoundOnReallyDamaged        = BuildingHeavyDamageStone
  61.  
  62.     UnitSpecificSounds
  63.         UnderConstruction        = WallConstructionLoop      ;Built first time
  64.         ; UnderRepairFromDamage    = NoSound                    ; Repaired No animation on the building, so don't bother playing sound
  65.         UnderRepairFromRubble    = WallConstructionLoop        ;Repaired from completely destroyed (not used???)
  66.     End
  67.  
  68.     ;Behavior                        = GettingBuiltBehavior ModuleTag_04
  69.     ;    RebuildTimeSeconds            = 30
  70.     ;    SelfBuildingLoop            = WallConstructionLoop        ;Only played if we DON'T spawn a worker
  71.     ;    SelfRepairFromDamageLoop    = NoSound                    ;This doesn't cause an animation, so don't bother playing a sound
  72.     ;    SelfRepairFromRubbleLoop    = WallConstructionLoop
  73.     ;End
  74.  
  75.     CampnessValue = CAMPNESS_WALL
  76.  
  77.   ; *** ENGINEERING Parameters ***
  78.   RadarPriority       = STRUCTURE
  79.   KindOf              = PRELOAD STRUCTURE SELECTABLE IMMOBILE SCORE WALL_SEGMENT SCALEABLE_WALL MADE_OF_STONE
  80.  
  81.   Behavior            = GettingBuiltBehavior ModuleTag_04
  82.       UseSpawnTimerWithoutWorker         = Yes
  83.       SpawnTimer    = DEFAULT_STRUCTURE_HEALDELAY
  84.         SelfBuildingLoop = BuildingConstructionLoop ; Only played if we DON'T spawn a worker
  85.     SelfRepairFromDamageLoop  = NoSound         ; This doesn't cause an animation, so don't bother playing a sound
  86.     SelfRepairFromRubbleLoop  = BuildingConstructionLoop
  87.   End
  88.  
  89.   Body                = StructureBody ModuleTag_05
  90.     MaxHealth         = DWARVEN_WALLSEGMENT_SMALL_HEALTH
  91.   End
  92.  
  93.  
  94.     // These should always appear together on wall segments
  95.     Behavior = KeepObjectDie ModuleTag_IWantRubble 
  96.         DeathTypes            = ALL -SUICIDED
  97.     End
  98.     Behavior            = SlowDeathBehavior ModuleTag_SlowDeath
  99.         DeathTypes            = NONE +SUICIDED
  100.         DestructionDelay = 5000
  101.     End                                                
  102.     // These should always appear together on wall segments
  103.  
  104.  
  105.     Behavior = ReplaceSelfUpgrade ModuleTag_Replace_With_Hub
  106.         ReplaceWith = DwarvenCastleWallHub
  107.         TriggeredBy = Upgrade_DwarvenWallHub
  108.         ConflictsWith = Upgrade_DwarvenWallRegularGate Upgrade_DwarvenWallPosternGate Upgrade_DwarvenWallTower Upgrade_DwarvenWallCatapult
  109.     End
  110.         
  111.     Behavior = ReplaceSelfUpgrade ModuleTag_Replace_With_Gate
  112.         ReplaceWith = DwarvenCastleWallGate
  113.         TriggeredBy = Upgrade_DwarvenWallRegularGate
  114.         ConflictsWith = Upgrade_DwarvenWallHub Upgrade_DwarvenWallPosternGate Upgrade_DwarvenWallTower Upgrade_DwarvenWallCatapult
  115.     End
  116.  
  117.     Behavior = ReplaceSelfUpgrade ModuleTag_Replace_With_PosternGate
  118.         ReplaceWith = DwarvenWallPosternGate
  119.         TriggeredBy = Upgrade_DwarvenWallPosternGate
  120.         ConflictsWith = Upgrade_DwarvenWallHub Upgrade_DwarvenWallRegularGate Upgrade_DwarvenWallTower Upgrade_DwarvenWallCatapult
  121.     End
  122.  
  123.     Behavior = ReplaceSelfUpgrade ModuleTag_Replace_With_Tower
  124.         ReplaceWith = DwarvenCastleWallTower
  125.         TriggeredBy = Upgrade_DwarvenWallTower
  126.         ConflictsWith = Upgrade_DwarvenWallHub Upgrade_DwarvenWallRegularGate Upgrade_DwarvenWallPosternGate Upgrade_DwarvenWallCatapult
  127.     End
  128.  
  129.     Behavior = ReplaceSelfUpgrade ModuleTag_Replace_With_Catapult
  130.         ReplaceWith = DwarvenCastleWallCatapult
  131.         TriggeredBy = Upgrade_DwarvenWallCatapult
  132.         ConflictsWith = Upgrade_DwarvenWallHub Upgrade_DwarvenWallRegularGate Upgrade_DwarvenWallPosternGate Upgrade_DwarvenWallTower
  133.     End
  134.  
  135.     Behavior = ProductionUpdate ModuleTag_RequiredForUpgradeProduction
  136.     End
  137.  
  138.   Geometry              = BOX
  139.   GeometryMajorRadius   = 25.0
  140.   GeometryMinorRadius   = 20.0
  141.   GeometryHeight        = 50
  142.   GeometryIsSmall       = No
  143.   Shadow                = SHADOW_VOLUME
  144.   BuildCompletion     = PLACED_BY_PLAYER
  145. End
  146.  
  147. ;---------------------------------------------
  148. Object DwarvenCastleWallHub
  149.  
  150.     SelectPortrait = BPDWall_Hub
  151.   
  152.   ; *** ART Parameters ***
  153.     Draw = W3DScriptedModelDraw ModuleTag_Draw
  154.         OkToChangeModelColor  = Yes
  155.         UseStandardModelNames = Yes
  156.         DefaultModelConditionState
  157.             Model = DBWallRmprt
  158.         End
  159.         
  160.         IdleAnimationState
  161.             Flags = ADJUST_HEIGHT_BY_CONSTRUCTION_PERCENT
  162.             Animation                =    ReallyDamagedanimation
  163.                 AnimationName        =     DBWallRmprt.DBWallRmprt
  164.                 AnimationMode        =    LOOP
  165.                End
  166.                StateName = STATE_None
  167.         End
  168.     End
  169.  
  170.   ; ***DESIGN parameters ***
  171.   DisplayName         = OBJECT:DwarvenCastleWallHub
  172.   Side                = Dwarves
  173.   EditorSorting       = STRUCTURE
  174.   ThreatLevel = 1.0
  175.     ThreatBreakdown ModuleTag_DetailedThreat
  176.         AIKindOf = WALL
  177.     End
  178.  
  179.   BuildCost           = DWARVEN_WALLHUB_SMALL_BUILDCOST
  180.   BuildTime           = DWARVEN_WALLHUB_SMALL_BUILDTIME           ; in seconds
  181.   VisionRange         = DWARVEN_WALLHUB_SMALL_VISION_RANGE          ; Shroud clearing distance
  182.   ShroudClearingRange = DWARVEN_WALLHUB_SMALL_SHROUD_CLEAR
  183.  
  184.  
  185.  
  186.     CommandSet = DwarvenCastleWallHubCommandSet
  187.     
  188.     ArmorSet
  189.         Conditions        = None
  190.         Armor             = DwarvenWallArmor
  191.         DamageFX          = None
  192.     End
  193.  
  194.   ; *** AUDIO Parameters ***
  195.  
  196.     #include "..\..\..\Includes\StandardBuildingEvaEvents.inc"
  197.  
  198.     VoiceSelect                = NeutralWallHubSelect
  199.  
  200.     SoundOnDamaged            = BuildingLightDamageStone
  201.     SoundOnReallyDamaged    = BuildingHeavyDamageStone
  202.  
  203.     CampnessValue = CAMPNESS_WALL
  204.  
  205.   ; *** ENGINEERING Parameters ***
  206.   RadarPriority       = STRUCTURE
  207.   KindOf              = PRELOAD STRUCTURE SELECTABLE IMMOBILE SCORE WALL_HUB MADE_OF_STONE
  208.  
  209.   Behavior            = GettingBuiltBehavior ModuleTag_04
  210.       UseSpawnTimerWithoutWorker         = Yes
  211.       SpawnTimer    = DEFAULT_STRUCTURE_HEALDELAY
  212.         SelfBuildingLoop = BuildingConstructionLoop ; Only played if we DON'T spawn a worker
  213.     SelfRepairFromDamageLoop  = NoSound         ; This doesn't cause an animation, so don't bother playing a sound
  214.     SelfRepairFromRubbleLoop  = BuildingConstructionLoop
  215.   End
  216.  
  217.   Body                = StructureBody ModuleTag_05
  218.     MaxHealth         = DWARVEN_WALLHUB_SMALL_HEALTH
  219.   End
  220.  
  221.   Behavior            = DestroyDie ModuleTag_07
  222.     ;nothing
  223.   End
  224.  
  225.     Behavior = WallHubBehavior ModuleTag_WALL_HUB
  226.  
  227.         Options = OPTION_ONE
  228.         
  229.         MaxBuildoutDistance = MEN_FORTRESS_WALL_EFFECTIVE_RADIUS
  230.         
  231.         StaggeredBuildFactor = STANDARD_WALL_STAGGERED_BUILD_FACTOR
  232.         
  233.  
  234.         ;;This defines the pattern built on flat terrain
  235.         SegmentTemplateName = DwarvenCastleWallSegment
  236.         SegmentTemplateName = DwarvenCastleWallSegment
  237.         SegmentTemplateName = DwarvenCastleWallSegment
  238.         SegmentTemplateName = DwarvenCastleWallSegment
  239.         SegmentTemplateName = DwarvenCastleWallSegment
  240.         SegmentTemplateName = DwarvenCastleWallSegment
  241.         SegmentTemplateName = DwarvenCastleWallSegment
  242.         SegmentTemplateName = DwarvenCastleWallSegment
  243.         SegmentTemplateName = DwarvenCastleWallHub
  244.  
  245.         HubCapTemplateName = DwarvenCastleWallHub
  246.         DefaultSegmentTemplateName = DwarvenCastleWallSegment
  247.  
  248.         ;CliffCapTemplateName = [NAME]        
  249.         ;ShoreCapTemplateName = [NAME]        
  250.         ;BorderCapTemplateName = [NAME]        
  251.         ;ElevatedSegmentTemplateName = [NAME]
  252.  
  253.     End
  254.  
  255.  
  256.     Behavior = WallHubBehavior ModuleTag_Build_A_Ramp
  257.     
  258.         Options = OPTION_TWO
  259.         MaxBuildoutDistance = MEN_FORTRESS_WALL_EFFECTIVE_RADIUS
  260.         
  261.         StaggeredBuildFactor = STANDARD_WALL_STAGGERED_BUILD_FACTOR
  262.     
  263.         ;;This defines the pattern built on flat terrain
  264.         SegmentTemplateName = DwarvenCastleWallSegment
  265.         
  266.         HubCapTemplateName = DwarvenWallRamp
  267.         DefaultSegmentTemplateName = DwarvenCastleWallSegment
  268.         
  269.     End
  270.  
  271.  
  272.     Behavior = WallHubBehavior ModuleTag_Build_A_NARROW_WALL
  273.     
  274.         Options = OPTION_THREE 
  275.         MaxBuildoutDistance = MEN_FORTRESS_WALL_EFFECTIVE_RADIUS
  276.         
  277.         StaggeredBuildFactor = STANDARD_WALL_STAGGERED_BUILD_FACTOR
  278.     
  279.         SegmentTemplateName = DwarvenWallSegmentSmall
  280.         SegmentTemplateName = DwarvenWallSegmentSmall
  281.         SegmentTemplateName = DwarvenWallSegmentSmall
  282.         SegmentTemplateName = DwarvenWallSegmentSmall
  283.         SegmentTemplateName = DwarvenWallSegmentSmall
  284.         SegmentTemplateName = DwarvenWallSegmentSmall
  285.         SegmentTemplateName = DwarvenWallSegmentSmall
  286.         SegmentTemplateName = DwarvenWallSegmentSmall
  287.         SegmentTemplateName = DwarvenWallHubSmall
  288.         
  289.         HubCapTemplateName = DwarvenWallHubSmall
  290.         DefaultSegmentTemplateName = DwarvenWallSegmentSmall
  291.         
  292.         ;CliffCapTemplateName = [NAME]        
  293.         ;ShoreCapTemplateName = [NAME]        
  294.         ;BorderCapTemplateName = [NAME]        
  295.         ;ElevatedSegmentTemplateName = [NAME]
  296.          
  297.     End
  298.  
  299.   Geometry              = CYLINDER
  300.   GeometryMajorRadius   = 50.0
  301.   GeometryMinorRadius   = 50.0
  302.   GeometryHeight        = 50.0
  303.   GeometryIsSmall       = No
  304.   Shadow                = SHADOW_VOLUME
  305.   BuildCompletion     = PLACED_BY_PLAYER
  306.   
  307.       GeometryContactPoint     = X:35        Y:35    Z:0            Repair
  308.     GeometryContactPoint     = X:35        Y:0        Z:0            Repair
  309.     GeometryContactPoint     = X:22.954        Y:15.951    Z:0
  310.     GeometryContactPoint     = X:5.435        Y:-23.279    Z:0
  311.     GeometryContactPoint    = X:-0.459        Y:-0.275    Z:116.828    Swoop
  312. End
  313.  
  314.  
  315. ;---------------------------------------------------------
  316. Object DwarvenCastleWallGate
  317.    
  318.    ; *** ART Parameters ***
  319.      Draw = W3DScriptedModelDraw ModuleTag_Draw
  320.          OkToChangeModelColor  = Yes
  321.          UseStandardModelNames = Yes
  322.          DefaultModelConditionState
  323.              Model = DBWallGate
  324.          End
  325.          
  326.         RampMesh1 = R1
  327.         RampMesh2 = R2
  328.         
  329.         IdleAnimationState
  330.             Flags = ADJUST_HEIGHT_BY_CONSTRUCTION_PERCENT
  331.             Animation                =    ReallyDamagedanimation
  332.                 AnimationName        =     DBWallGate.DBWallGate
  333.                 AnimationMode        =    LOOP
  334.                End
  335.                StateName = STATE_None
  336.         End
  337.      End
  338.       
  339.    ; ***DESIGN parameters ***
  340.    DisplayName         = OBJECT:DwarvenCastleWallGate
  341.    Side                = Dwarves
  342.    EditorSorting       = STRUCTURE
  343.    ThreatLevel = 1.0
  344.     ThreatBreakdown ModuleTag_DetailedThreat
  345.         AIKindOf = WALL
  346.     End
  347.   
  348.    BuildCost           = DWARVEN_WALLGATE_SMALL_BUILDCOST
  349.    BuildTime           = DWARVEN_WALLGATE_SMALL_BUILDTIME          ; in seconds
  350.    VisionRange         = DWARVEN_WALLGATE_SMALL_VISION_RANGE         ; Shroud clearing distance
  351.    ShroudClearingRange = DWARVEN_WALLGATE_SMALL_SHROUD_CLEAR
  352.    
  353.    CommandSet            = CastleGateCommandSet
  354.  
  355.    ArmorSet
  356.         Conditions        = None
  357.         Armor             = DwarvenWallArmor
  358.         DamageFX          = None
  359.     End
  360.     
  361.    ; *** AUDIO Parameters ***
  362.     #include "..\..\..\Includes\StandardBuildingEvaEvents.inc"
  363.      SoundOnDamaged        = BuildingLightDamageStone
  364.      SoundOnReallyDamaged    = BuildingHeavyDamageStone
  365.     CampnessValue = CAMPNESS_WALL
  366.  
  367.    ; *** ENGINEERING Parameters ***
  368.    RadarPriority       = STRUCTURE
  369.    KindOf              = PRELOAD STRUCTURE SELECTABLE IMMOBILE SCORE MADE_OF_STONE BLOCKING_GATE WALL_GATE WALL_UPGRADE
  370.   
  371.    Behavior            = GettingBuiltBehavior ModuleTag_04
  372.        UseSpawnTimerWithoutWorker         = Yes
  373.        SpawnTimer    = DEFAULT_STRUCTURE_HEALDELAY
  374.          SelfBuildingLoop = BuildingConstructionLoop ; Only played if we DON'T spawn a worker
  375.      SelfRepairFromDamageLoop  = NoSound         ; This doesn't cause an animation, so don't bother playing a sound
  376.      SelfRepairFromRubbleLoop  = BuildingConstructionLoop
  377.    End
  378.  
  379.    Body                = StructureBody ModuleTag_05
  380.      MaxHealth         = DWARVEN_WALLGATE_SMALL_HEALTH
  381.    End
  382.   
  383.       // These should always appear together on wall segments
  384.     Behavior = KeepObjectDie ModuleTag_IWantRubble 
  385.         DeathTypes            = ALL -SUICIDED
  386.     End
  387.     Behavior            = SlowDeathBehavior ModuleTag_SlowDeath
  388.         DeathTypes            = NONE +SUICIDED
  389.         DestructionDelay    = 5000
  390.     End                                                
  391.     // These should always appear together on wall segments
  392.     
  393.     Behavior = GateOpenAndCloseBehavior ModuleTag_GATE
  394.         ResetTimeInMilliseconds            = 3000                ;important! this must be longer than the gates animation, ir it will twitch
  395.         OpenByDefault                    = No
  396.         PercentOpenForPathing            = 50
  397.         SoundOpeningGateLoop            = GateOpenStart
  398.         SoundClosingGateLoop            = GateCloseStart
  399.         SoundFinishedOpeningGate        = GateOpenEnd
  400.         SoundFinishedClosingGate        = GateCloseEnd
  401.         TimeBeforePlayingOpenSound        = 9500
  402.         TimeBeforePlayingClosedSound    = 9500
  403.     End
  404.  
  405.     Behavior = InheritUpgradeCreate ModuleTag_InheritNumenorStonework
  406.         Radius = DWARVEN_FORTRESS_WALL_EFFECTIVE_RADIUS
  407.         Upgrade = Upgrade_DwarvenFortressDwarvenStonework
  408.         ObjectFilter = ANY +DwarvenFortressCitadel
  409.     End
  410.   
  411.     Behavior = AttributeModifierUpgrade ModuleTag_Reinforced
  412.         TriggeredBy                = Upgrade_DwarvenFortressDwarvenStonework
  413.         AttributeModifier        = DwarvenStoneworkExpansion_Bonus
  414.         CustomAnimAndDuration    = AnimState:UPGRADE_NUMENOR_STONEWORK AnimTime:0
  415.     End
  416.     
  417.     Behavior = FakePathfindPortalBehaviour ModuleTag_FAKEPATHFIND
  418.         AllowEnemies            = No
  419.         AllowNonSkirmishAIUnits    = No
  420.     End
  421.     
  422.     Behavior = AIGateUpdate ModuleTage_AIGateUpdate
  423.         TriggerWidthX = 200.0
  424.         TriggerWidthY = 100.0
  425.     End
  426.  
  427.     GeometryIsSmall          = No
  428.  
  429. ;    Example from MenWallGate
  430.     ; Main
  431.     AdditionalGeometry    = BOX
  432.     GeometryName          = "Closed"
  433.     GeometryMajorRadius   = 25.0  
  434.     GeometryMinorRadius   = 95.0  
  435.     GeometryHeight        = 50
  436.     
  437.     ; Left open
  438.     AdditionalGeometry    = BOX
  439.     GeometryName          = "OpenLeft"
  440.     GeometryMajorRadius   = 25.0  
  441.     GeometryMinorRadius   = 24.0  
  442.     GeometryHeight        = 50
  443.     GeometryOffset        = X:0 Y:-70 Z:0
  444.     
  445.     ; Right open
  446.     AdditionalGeometry    = BOX
  447.     GeometryName          = "OpenRight"
  448.     GeometryMajorRadius   = 25.0  
  449.     GeometryMinorRadius   = 24.0  
  450.     GeometryHeight        = 50
  451.     GeometryOffset        = X:0 Y:70 Z:0   
  452.    
  453.    Shadow                = SHADOW_VOLUME
  454.    BuildCompletion     = PLACED_BY_PLAYER
  455. End
  456.    
  457.  
  458.  
  459. ;---------------------------------------------------------
  460. Object DwarvenWallPosternGate
  461.  
  462.   ; *** ART Parameters ***
  463.     Draw = W3DScriptedModelDraw ModuleTag_Draw
  464.         OkToChangeModelColor  = Yes
  465.         UseStandardModelNames = Yes
  466.         
  467.         ExtraPublicBone = Post01
  468.         ExtraPublicBone = Post02
  469.         ExtraPublicBone = Post03
  470.         ExtraPublicBone = Post04
  471.         
  472.         DefaultModelConditionState
  473.             ;Model = DBWallPG
  474.             Model = GBWallPG        ;//        Replace this when the dwarven version is ready
  475.         End
  476.         
  477.         WallBoundsMesh = P1
  478.         
  479.         IdleAnimationState
  480.             Flags = ADJUST_HEIGHT_BY_CONSTRUCTION_PERCENT
  481.             Animation                =    ReallyDamagedanimation
  482.                 ;AnimationName        =     DBWallrampart.DBWallrampart
  483.                 AnimationName        =     GBWallrampart.GBWallrampart        ;//    Replace this when the dwarven version is ready
  484.                 AnimationMode        =    LOOP
  485.                End
  486.                StateName = STATE_None
  487.         End    
  488.         
  489.     End
  490.  
  491.     ; ***DESIGN parameters ***
  492.     DisplayName         = OBJECT:DwarvenWallPosternGate
  493.     Side                = Dwarves
  494.     EditorSorting       = STRUCTURE
  495.     ThreatLevel = 1.0
  496.     ThreatBreakdown ModuleTag_DetailedThreat
  497.         AIKindOf = WALL
  498.     End
  499.      
  500.     BuildCost           = DWARVEN_POSTERNGATE_SMALL_BUILDCOST
  501.     BuildTime           = DWARVEN_POSTERNGATE_SMALL_BUILDTIME         ; in seconds
  502.     VisionRange         = DWARVEN_POSTERNGATE_SMALL_VISION_RANGE         ; Shroud clearing distance
  503.     ShroudClearingRange = DWARVEN_POSTERNGATE_SMALL_SHROUD_CLEAR
  504.  
  505.  
  506.  
  507.         
  508.  
  509.     ; *** AUDIO Parameters ***
  510.         #include "..\..\..\Includes\StandardBuildingEvaEvents.inc"
  511.         SoundOnDamaged        = BuildingLightDamageStone
  512.         SoundOnReallyDamaged    = BuildingHeavyDamageStone
  513.         CampnessValue = CAMPNESS_WALL
  514.  
  515.     ; *** ENGINEERING Parameters ***
  516.     RadarPriority       = STRUCTURE
  517.     KindOf              = PRELOAD STRUCTURE SELECTABLE IMMOBILE SCORE WALL_UPGRADE MADE_OF_STONE IGNORE_FOR_VICTORY
  518.  
  519.     Behavior            = GettingBuiltBehavior ModuleTag_04
  520.         UseSpawnTimerWithoutWorker         = Yes
  521.         SpawnTimer    = DEFAULT_STRUCTURE_HEALDELAY
  522.         RebuildTimeSeconds = 30
  523.         SelfBuildingLoop = BuildingConstructionLoop ; Only played if we DON'T spawn a worker
  524.         SelfRepairFromDamageLoop  = NoSound         ; This doesn't cause an animation, so don't bother playing a sound
  525.         SelfRepairFromRubbleLoop  = BuildingConstructionLoop
  526.     End
  527.  
  528.     Body                = StructureBody ModuleTag_05
  529.         MaxHealth         = DWARVEN_POSTERNGATE_SMALL_HEALTH
  530.     End
  531.      
  532.     // These should always appear together on wall segments
  533.     Behavior = KeepObjectDie ModuleTag_IWantRubble 
  534.         DeathTypes            = ALL -SUICIDED
  535.     End
  536.     Behavior            = SlowDeathBehavior ModuleTag_SlowDeath
  537.         DeathTypes            = NONE +SUICIDED
  538.         DestructionDelay    = 5000
  539.     End                                                
  540.     // These should always appear together on wall segments
  541.     
  542.     
  543.     Behavior = DynamicPortalBehaviour PosternGatePortal
  544.         ActivationDelaySeconds    = 0.0
  545.         GenerateNow                = Yes
  546.         
  547.         ObjectFilter    = POSTERNGATE_ALLOWABLE_OBJECTFILTER
  548.         BonePrefix        = Post
  549.         NumberOfBones    = 4
  550.         WayPoint        = Index:0    Type:Walk    ; 0
  551.         WayPoint        = Index:1    Type:Walk    ; 1
  552.         WayPoint        = Index:2    Type:Walk    ; 2
  553.         WayPoint        = Index:3    Type:Walk    ; 3
  554.         WayPoint        = Index:2    Type:Walk    ; 4
  555.         WayPoint        = Index:1    Type:Walk    ; 5
  556.         Link            = From:0 Via:4 Via:5 To:3
  557.         Link            = From:3 Via:1 Via:2 To:0
  558.     End
  559.  
  560.     GeometryIsSmall            = No
  561.     
  562.     Geometry              = BOX
  563.     GeometryMajorRadius   = 25.0  
  564.     GeometryMinorRadius   = 98.0 ; must be a multiple of 20
  565.     GeometryHeight        = 50
  566.  
  567.     AdditionalGeometry    = CYLINDER
  568.     GeometryMajorRadius   = 40.0 
  569.     GeometryMinorRadius   = 40.0 
  570.     GeometryHeight        = 50.0
  571.     
  572.     Shadow                = SHADOW_VOLUME
  573.     BuildCompletion     = PLACED_BY_PLAYER
  574. End
  575.  
  576.  
  577.  
  578. ;---------------------------------------------
  579. Object DwarvenCastleWallTower
  580.   ; *** ART Parameters ***
  581.     Draw = W3DScriptedModelDraw ModuleTag_Draw
  582.         OkToChangeModelColor  = Yes
  583.         UseStandardModelNames = Yes
  584.         DefaultModelConditionState
  585.             ;Model = DBWallTwr
  586.             Model = GBWallTwr        ;//    Replace this when the dwarven version is ready
  587.         End
  588.         
  589.         WallBoundsMesh = P1
  590. ;        RampMesh1 = R1
  591. ;        RampMesh2 = R2
  592.         
  593.         IdleAnimationState
  594.             Flags = ADJUST_HEIGHT_BY_CONSTRUCTION_PERCENT
  595.             Animation                =    ReallyDamagedanimation
  596.                 AnimationName        =     GBWallrampart.GBWallrampart
  597.                 AnimationMode        =    LOOP
  598.                End
  599.                StateName = STATE_None
  600.         End    
  601.         
  602.     End
  603.  
  604.     ; ***DESIGN parameters ***
  605.     DisplayName         = OBJECT:DwarvenCastleWallSegment
  606.     Side                = Dwarves
  607.     EditorSorting       = STRUCTURE
  608.     ThreatLevel            = 1.0
  609.     ThreatBreakdown ModuleTag_DetailedThreat
  610.         AIKindOf = WALL
  611.     End
  612.      
  613.     BuildCost           = DWARVEN_WALLTOWER_SMALL_BUILDCOST
  614.     BuildTime           = DWARVEN_WALLTOWER_SMALL_BUILDTIME           ; in seconds
  615.     VisionRange         = DWARVEN_WALLTOWER_SMALL_VISION_RANGE          ; Shroud clearing distance
  616.     ShroudClearingRange = DWARVEN_WALLTOWER_SMALL_SHROUD_CLEAR
  617.  
  618.  
  619.  
  620.         
  621.  
  622.     ; *** AUDIO Parameters ***
  623.         #include "..\..\..\Includes\StandardBuildingEvaEvents.inc"
  624.         SoundOnDamaged        = BuildingLightDamageStone
  625.         SoundOnReallyDamaged    = BuildingHeavyDamageStone
  626.         CampnessValue = CAMPNESS_WALL
  627.  
  628.     ; *** ENGINEERING Parameters ***
  629.     RadarPriority       = STRUCTURE
  630.     KindOf              = PRELOAD STRUCTURE SELECTABLE IMMOBILE SCORE MADE_OF_STONE CAN_ATTACK WALL_UPGRADE
  631.  
  632.      WeaponSet
  633.         Conditions            = None
  634.         Weapon                = PRIMARY StructureAxeWeapon
  635.         AutoChooseSources    = PRIMARY FROM_PLAYER FROM_SCRIPT FROM_AI
  636.     End
  637.     
  638.     Behavior = AIUpdateInterface ModuleTag_SoWeCanUseWeapon
  639.          AutoAcquireEnemiesWhenIdle    = Yes
  640.          MoodAttackCheckRate            = 250
  641.      End
  642.  
  643.     Behavior            = GettingBuiltBehavior ModuleTag_04
  644.         UseSpawnTimerWithoutWorker         = Yes
  645.         SpawnTimer    = DEFAULT_STRUCTURE_HEALDELAY
  646.         RebuildTimeSeconds = 30
  647.         SelfBuildingLoop = BuildingConstructionLoop ; Only played if we DON'T spawn a worker
  648.         SelfRepairFromDamageLoop  = NoSound         ; This doesn't cause an animation, so don't bother playing a sound
  649.         SelfRepairFromRubbleLoop  = BuildingConstructionLoop
  650.     End
  651.  
  652.     Body                = StructureBody ModuleTag_05
  653.         MaxHealth         = 1500.0
  654.     End
  655.      
  656.     // These should always appear together on wall segments
  657.     Behavior = KeepObjectDie ModuleTag_IWantRubble 
  658.         DeathTypes            = ALL -SUICIDED
  659.     End
  660.     Behavior            = SlowDeathBehavior ModuleTag_SlowDeath
  661.         DeathTypes            = NONE +SUICIDED
  662.         DestructionDelay    = 5000
  663.     End                                                
  664.     // These should always appear together on wall segments    
  665.     GeometryIsSmall       = No
  666.  
  667.     Geometry              = BOX
  668.     GeometryMajorRadius   = 25.0  
  669.     GeometryMinorRadius   = 98.0 ; must be a multiple of 20
  670.     GeometryHeight        = 50
  671.  
  672.     AdditionalGeometry    = CYLINDER
  673.     GeometryMajorRadius   = 40.0 
  674.     GeometryMinorRadius   = 40.0 
  675.     GeometryHeight        = 50.0
  676.     
  677.     Shadow                = SHADOW_VOLUME
  678.     BuildCompletion     = PLACED_BY_PLAYER
  679. End
  680.  
  681. ;---------------------------------------------
  682. Object DwarvenCastleWallCatapult
  683.  
  684.   ; *** ART Parameters ***
  685.     Draw = W3DScriptedModelDraw ModuleTag_Draw
  686.         
  687.         OkToChangeModelColor  = Yes
  688.         UseStandardModelNames = Yes
  689.         
  690.         DefaultModelConditionState
  691.             ;Model = DBWallTreb
  692.             Model = GBWallTreb        ;//    Replace this with the dwarven version when ready
  693.         End
  694.  
  695.         WallBoundsMesh = P1
  696. ;        RampMesh1 = R1
  697. ;        RampMesh2 = R2
  698.         
  699. ;        IdleAnimationState
  700. ;            Flags = ADJUST_HEIGHT_BY_CONSTRUCTION_PERCENT
  701. ;            Animation                =    ReallyDamagedanimation
  702. ;                AnimationName        =     GBWallrampart.GBWallrampart
  703. ;                AnimationMode        =    LOOP
  704. ;              End
  705. ;              StateName = STATE_None
  706. ;        End    
  707.         
  708.     End
  709.  
  710.     ; ***DESIGN parameters ***
  711.     DisplayName         = OBJECT:DwarvenCastleWallCatapult
  712.     Side                = Dwarves
  713.     EditorSorting       = STRUCTURE
  714.     ThreatLevel            = 1.0
  715.  
  716.     BuildCost           = DWARVEN_WALLCATAPULT_SMALL_BUILDCOST
  717.     BuildTime           = DWARVEN_WALLCATAPULT_SMALL_BUILDTIME          ; in seconds
  718.     VisionRange         = DWARVEN_WALLCATAPULT_SMALL_VISION_RANGE        ; Shroud clearing distance
  719.     ShroudClearingRange = DWARVEN_WALLCATAPULT_SMALL_SHROUD_CLEAR
  720.  
  721.  
  722.  
  723.         
  724.  
  725.     ; *** AUDIO Parameters ***
  726.     #include "..\..\..\Includes\StandardBuildingEvaEvents.inc"
  727.     SoundOnDamaged        = BuildingLightDamageStone
  728.     SoundOnReallyDamaged    = BuildingHeavyDamageStone
  729.     CampnessValue = CAMPNESS_WALL
  730.  
  731.     ; *** ENGINEERING Parameters ***
  732.     RadarPriority       = STRUCTURE
  733.     KindOf              = PRELOAD STRUCTURE SELECTABLE IMMOBILE SCORE MADE_OF_STONE WALL_UPGRADE
  734.  
  735.     Behavior            = GettingBuiltBehavior ModuleTag_04
  736.     UseSpawnTimerWithoutWorker         = Yes
  737.         SpawnTimer    = DEFAULT_STRUCTURE_HEALDELAY
  738.         RebuildTimeSeconds = 30
  739.         SelfBuildingLoop = BuildingConstructionLoop ; Only played if we DON'T spawn a worker
  740.         SelfRepairFromDamageLoop  = NoSound         ; This doesn't cause an animation, so don't bother playing a sound
  741.         SelfRepairFromRubbleLoop  = BuildingConstructionLoop
  742.     End
  743.     
  744.     Behavior = OCLUpdate MakeTheCatapult
  745.         OCL            = OCL_DwarvenCatapultUpgrade
  746.         MinDelay    = 1500
  747.         MaxDelay    = 1500
  748.         Amount        = 1
  749.     End
  750.  
  751.     Body                = StructureBody ModuleTag_05
  752.         MaxHealth         = DWARVEN_WALLCATAPULT_SMALL_HEALTH
  753.     End
  754.      
  755.     // These should always appear together on wall segments
  756.     Behavior = KeepObjectDie ModuleTag_IWantRubble 
  757.         DeathTypes            = ALL -SUICIDED
  758.     End
  759.     Behavior            = SlowDeathBehavior ModuleTag_SlowDeath
  760.         DeathTypes            = NONE +SUICIDED
  761.         DestructionDelay    = 5000
  762.     End                                                
  763.     // These should always appear together on wall segments
  764.     GeometryIsSmall            = No
  765.  
  766.     Geometry              = BOX
  767.     GeometryMajorRadius   = 25.0  
  768.     GeometryMinorRadius   = 98.0 ; must be a multiple of 20
  769.     GeometryHeight        = 50
  770.  
  771.     AdditionalGeometry    = CYLINDER
  772.     GeometryMajorRadius   = 40.0 
  773.     GeometryMinorRadius   = 40.0 
  774.     GeometryHeight        = 50.0
  775.     
  776.     Shadow                = SHADOW_VOLUME
  777.     BuildCompletion     = PLACED_BY_PLAYER
  778. End
  779.  
  780.  
  781.  
  782. //----------------------------Small Walls----------------------------------
  783.  
  784.  
  785. Object DwarvenWallSegmentSmall
  786.   
  787.     // *** ART Parameters ***
  788.   
  789.       SelectPortrait  =  BPDWall
  790.   
  791.     Draw = W3DScriptedModelDraw ModuleTag_Draw
  792.         OkToChangeModelColor  = Yes
  793.         UseStandardModelNames = Yes
  794.         DefaultModelConditionState
  795.             Model = DBWallN
  796.         End
  797.  
  798.         ModelConditionState = SNOW BUILD_PLACEMENT_CURSOR
  799.             Model = DBWallN_CUR
  800.             Texture    = DBFortress1.tga DBFortress1_snow.tga
  801.         End
  802.         
  803.         ModelConditionState = BUILD_PLACEMENT_CURSOR
  804.             Model = DBWallN_CUR
  805.         End
  806.                     
  807.         IdleAnimationState
  808. ;            Flags = ADJUST_HEIGHT_BY_CONSTRUCTION_PERCENT
  809. ;            Animation                =    ReallyDamagedanimation
  810. ;                AnimationName        =     GBWallrampart.GBWallrampart
  811. ;                AnimationMode        =    LOOP
  812. ;             End
  813.             StateName = STATE_None
  814.         End    
  815.         
  816.  
  817.         ;------------ New Build Up States coming soon. 
  818.         
  819.         ModelConditionState = SNOW AWAITING_CONSTRUCTION
  820.             Model = DBWallN_A
  821.             Texture    = DBFortress1.tga DBFortress1_snow.tga
  822.         End
  823.                 
  824.         ModelConditionState   = AWAITING_CONSTRUCTION 
  825.             Model               = DBWallN_A
  826.         End
  827.         AnimationState        = AWAITING_CONSTRUCTION
  828.             Animation           =  DBWallN_A
  829.                 AnimationName     =  DBWallN_A.DBWallN_A
  830.                 AnimationMode     = MANUAL
  831.                 AnimationBlendTime = 0
  832.             End
  833.             Flags                  = START_FRAME_FIRST
  834.         End
  835.  
  836.         ModelConditionState   = PARTIALLY_CONSTRUCTED 
  837.             Model               = DBWallN_A
  838.         End
  839.         AnimationState        = PARTIALLY_CONSTRUCTED
  840.             Animation           =  DBWallN_A
  841.                 AnimationName     =  DBWallN_A.DBWallN_A
  842.                 AnimationMode     = MANUAL
  843.                 AnimationBlendTime = 0
  844.             End
  845.             Flags                  = START_FRAME_FIRST
  846.         End
  847.  
  848.  
  849.         ModelConditionState = UPGRADE_NUMENOR_STONEWORK ACTIVELY_BEING_CONSTRUCTED PARTIALLY_CONSTRUCTED
  850.             Model    = DBWallN_A
  851.             Texture    = DBFortress1.tga DBFortress_U.tga
  852.         End
  853.  
  854.         ModelConditionState = SNOW ACTIVELY_BEING_CONSTRUCTED PARTIALLY_CONSTRUCTED
  855.             Model = DBWallN_A
  856.             Texture    = DBFortress1.tga DBFortress1_snow.tga
  857.         End
  858.         
  859.         ModelConditionState   = ACTIVELY_BEING_CONSTRUCTED PARTIALLY_CONSTRUCTED
  860.             Model               = DBWallN_A
  861.         End
  862.         
  863.         AnimationState        = ACTIVELY_BEING_CONSTRUCTED PARTIALLY_CONSTRUCTED
  864.             Animation           = DBWallN_A
  865.                 AnimationName     = DBWallN_A.DBWallN_A
  866.                 AnimationMode     = MANUAL
  867.                 AnimationBlendTime = 0
  868.             End
  869.             Flags                  = START_FRAME_FIRST
  870.             StateName              = BeingConstructed
  871.             ParticleSysBone   = NONE WallConstructDust FollowBone:Yes
  872.         End
  873.  
  874.  
  875.         ;--damaged building
  876.       
  877.         ModelConditionState  = DAMAGED
  878.             Model         = DBWallN_D1
  879.         End
  880.         
  881.         AnimationState = DAMAGED
  882.             EnteringStateFX    = FX_WallDamaged
  883.         End        
  884.         
  885.         ModelConditionState  = REALLYDAMAGED
  886.             Model         = DBWallN_D2
  887.         End
  888.         
  889.         AnimationState = REALLYDAMAGED
  890.               Animation                =    RubbleAnimation
  891.                 AnimationName        =     DBWallN_D2.DBWallN_D2
  892.                 AnimationMode        =    ONCE
  893.               End
  894.             EnteringStateFX    = FX_WallDamaged
  895.         End
  896.  
  897.         ModelConditionState  = COLLAPSING
  898.             Model         = DBWallN_D3
  899.         End
  900.         
  901.         AnimationState = COLLAPSING
  902.               Animation                =    RubbleAnimation
  903.                 AnimationName        =     DBWallN_D3.DBWallN_D3
  904.                 AnimationMode        =    ONCE
  905.               End
  906.               ParticleSysBone NONE WallDestructionDust
  907.             EnteringStateFX            = FX_StructureMediumCollapse
  908.         End
  909.  
  910.         ModelConditionState  = RUBBLE
  911.             Model         = None    ;GBWall_Rubble  
  912.         End  
  913.         
  914.         AnimationState = RUBBLE
  915.         End
  916.         
  917.         ModelConditionState  = POST_RUBBLE
  918.             Model         = None    ;GBWall_Rubble
  919.         End
  920.         
  921.         AnimationState = POST_RUBBLE
  922.         End
  923.  
  924.         ModelConditionState  = POST_COLLAPSE
  925.             Model         = None
  926.         End
  927.         
  928.         AnimationState = POST_COLLAPSE
  929.         End 
  930.  
  931.         ModelConditionState = UPGRADE_NUMENOR_STONEWORK
  932.             Model    = DBWallN
  933.             Texture    = DBFortress1.tga DBFortress_U.tga
  934.         End
  935.  
  936.         ModelConditionState = SNOW  
  937.             Model = DBWallN
  938.             Texture    = DBFortress1.tga DBFortress1_snow.tga
  939.         End        
  940.  
  941.     End
  942.  
  943.     Draw = W3DScriptedModelDraw ModuleTag_Draw_Rubble
  944.         OkToChangeModelColor  = Yes
  945.         UseStandardModelNames = Yes
  946.         DefaultModelConditionState
  947.             Model = None
  948.         End
  949.     
  950.         ModelConditionState  = COLLAPSING
  951.             Model         = GBWall_Rubble
  952.         End
  953.         
  954.         ModelConditionState  = RUBBLE
  955.             Model         = GBWall_Rubble
  956.         End
  957.         
  958.         ModelConditionState  = POST_RUBBLE
  959.             Model         = GBWall_Rubble
  960.         End
  961.  
  962.         ModelConditionState  = POST_COLLAPSE
  963.             Model         = None
  964.         End
  965.     End
  966.    
  967.     Draw = W3DFloorDraw ModuleTag_DrawFloor    
  968.           StaticModelLODMode        =    yes ; Will append M or L to the skin name depending on GameLOD
  969.           ModelName                =    GBWallN_Bib
  970.           WeatherTexture            =    SNOWY GBWall_Bib_Snow.tga
  971.           HideIfModelConditions    =    AWAITING_CONSTRUCTION
  972.           HideIfModelConditions    =    PARTIALLY_CONSTRUCTED
  973.           HideIfModelConditions    =    COLLAPSING
  974.           HideIfModelConditions    =    RUBBLE
  975.     End
  976.   
  977.   ; ***DESIGN parameters ***
  978.   DisplayName         = OBJECT:DwarvenCastleWallSegment
  979.   Side                = Dwarves
  980.   EditorSorting       = STRUCTURE
  981.   ThreatLevel = 1.0
  982.   ThreatBreakdown ModuleTag_DetailedThreat
  983.         AIKindOf = WALL
  984.     End
  985.  
  986.  
  987.     CommandSet = DwarvenWallSegmentCommandSet
  988.   ArmorSet
  989.         Conditions        = None
  990.         Armor             = DwarvenWallArmor
  991.         DamageFX          = None
  992.     End
  993.  
  994.   BuildCost           = DWARVEN_WALLSEGMENT_SMALL_BUILDCOST
  995.   BuildTime           = DWARVEN_WALLSEGMENT_SMALL_BUILDTIME
  996.   VisionRange         = DWARVEN_WALLSEGMENT_SMALL_VISION_RANGE
  997.   ShroudClearingRange = DWARVEN_WALLSEGMENT_SMALL_SHROUD_CLEAR
  998.  
  999.   ; *** AUDIO Parameters ***
  1000.  
  1001.     #include "..\..\..\Includes\StandardBuildingEvaEvents.inc"
  1002.  
  1003.     VoiceSelect                        = Gui_PlotSelect2
  1004.     VoiceSelectUnderConstruction    = BuildingGoodVoiceSelectUnderConstruction
  1005.  
  1006.     SoundOnDamaged                    = BuildingLightDamageStone
  1007.     SoundOnReallyDamaged            = BuildingHeavyDamageStone
  1008.  
  1009.     UnitSpecificSounds
  1010.         UnderConstruction        = WallConstructionLoop      ;Built first time
  1011.         ; UnderRepairFromDamage    = NoSound                    ; Repaired No animation on the building, so don't bother playing sound
  1012.         UnderRepairFromRubble    = WallConstructionLoop        ;Repaired from completely destroyed (not used???)
  1013.     End
  1014.  
  1015.     CampnessValue = CAMPNESS_WALL
  1016.  
  1017.   ; *** ENGINEERING Parameters ***
  1018.   RadarPriority       = STRUCTURE
  1019.   KindOf              = PRELOAD STRUCTURE SELECTABLE IMMOBILE WALL_SEGMENT SCALEABLE_WALL DEFENSIVE_WALL MADE_OF_STONE HAS_HEALTH_BAR
  1020.  
  1021.     Behavior                        = GettingBuiltBehavior ModuleTag_04
  1022.         SelfBuildingLoop            = WallConstructionLoop            // Only played if we DON'T spawn a worker
  1023.         SelfRepairFromDamageLoop    = NoSound                        // This doesn't cause an animation, so don't bother playing a sound
  1024.         SelfRepairFromRubbleLoop    = WallConstructionLoop
  1025.         UseSpawnTimerWithoutWorker         = Yes
  1026.         SpawnTimer    = DEFAULT_STRUCTURE_HEALDELAY
  1027.         RebuildTimeSeconds            = DWARVEN_WALLSEGMENT_SMALL_BUILDTIME
  1028.     End
  1029.  
  1030.    ;This is important to let the user select the rubble to begin self repair
  1031.   KeepSelectableWhenDead    = Yes
  1032.  
  1033.   Body                = StructureBody ModuleTag_05
  1034.         MaxHealth                = DWARVEN_WALLSEGMENT_SMALL_HEALTH
  1035.         MaxHealthDamaged        = DWARVEN_WALLSEGMENT_SMALL_HEALTH_DAMAGED
  1036.         MaxHealthReallyDamaged    = DWARVEN_WALLSEGMENT_SMALL_HEALTH_REALLY_DAMAGED
  1037.   End
  1038.  
  1039.     // These should always appear together on wall segments
  1040.     Behavior = KeepObjectDie ModuleTag_IWantRubble 
  1041.         DeathTypes            = ALL -SUICIDED
  1042.     End
  1043.     Behavior            = SlowDeathBehavior ModuleTag_SlowDeath
  1044.         DeathTypes            = NONE +SUICIDED
  1045.         DestructionDelay = 5000
  1046.     End                                                
  1047.     // These should always appear together on wall segments
  1048.  
  1049. //    Behavior                  = StructureCollapseUpdate ModuleTag_StructureCollapseUpdate 
  1050. //        MinCollapseDelay        = 000
  1051. //        MaxCollapseDelay        = 000
  1052. //        CollapseDamping         = .5
  1053. //        MaxShudder              = 0.6
  1054. //        MinBurstDelay           = 250
  1055. //        MaxBurstDelay           = 800
  1056. //        BigBurstFrequency       = 4
  1057. //        FXList                  = INITIAL   FX_StructureMediumCollapse
  1058. //        FXList                  = ALMOST_FINAL  FX_StructureAlmostCollapse
  1059. //        DestroyObjectWhenDone    = Yes
  1060. //        CollapseHeight            = 0
  1061. //    End
  1062.          
  1063.  
  1064.  
  1065.     Behavior = ReplaceSelfUpgrade ModuleTag_Replace_With_Hub
  1066.         ReplaceWith = DwarvenWallHubSmall
  1067.         TriggeredBy = Upgrade_DwarvenWallHub
  1068.         ConflictsWith = Upgrade_DwarvenWallRegularGate Upgrade_DwarvenWallPosternGate Upgrade_DwarvenWallTower Upgrade_DwarvenWallCatapult
  1069.     End
  1070.         
  1071.     Behavior = ReplaceSelfUpgrade ModuleTag_Replace_With_Gate
  1072.         ReplaceWith = DwarvenWallGateSmall
  1073.         TriggeredBy = Upgrade_DwarvenWallRegularGate
  1074.         ConflictsWith = Upgrade_DwarvenWallHub Upgrade_DwarvenWallPosternGate Upgrade_DwarvenWallTower Upgrade_DwarvenWallCatapult
  1075.     End
  1076.  
  1077.     Behavior = ReplaceSelfUpgrade ModuleTag_Replace_With_PosternGate
  1078.         ReplaceWith = DwarvenWallPosternGateSmall
  1079.         TriggeredBy = Upgrade_DwarvenWallPosternGate
  1080.         ConflictsWith = Upgrade_DwarvenWallHub Upgrade_DwarvenWallRegularGate Upgrade_DwarvenWallTower Upgrade_DwarvenWallCatapult
  1081.     End
  1082.  
  1083.     Behavior = ReplaceSelfUpgrade ModuleTag_Replace_With_Tower
  1084.         ReplaceWith = DwarvenWallTowerSmall
  1085.         TriggeredBy = Upgrade_DwarvenWallTower
  1086.         ConflictsWith = Upgrade_DwarvenWallHub Upgrade_DwarvenWallRegularGate Upgrade_DwarvenWallPosternGate Upgrade_DwarvenWallCatapult
  1087.     End
  1088.  
  1089.     Behavior = ReplaceSelfUpgrade ModuleTag_Replace_With_Catapult
  1090.         ReplaceWith = DwarvenWallCatapultSmall
  1091.         TriggeredBy = Upgrade_DwarvenWallCatapult
  1092.         ConflictsWith = Upgrade_DwarvenWallHub Upgrade_DwarvenWallRegularGate Upgrade_DwarvenWallPosternGate Upgrade_DwarvenWallTower
  1093.     End
  1094.  
  1095.     Behavior = ProductionUpdate ModuleTag_RequiredForUpgradeProduction
  1096.     End
  1097.  
  1098.     Behavior = InheritUpgradeCreate ModuleTag_InheritStonework
  1099.         Radius = DWARVEN_FORTRESS_WALL_EFFECTIVE_RADIUS
  1100.         Upgrade = Upgrade_DwarvenFortressDwarvenStonework
  1101.         ObjectFilter = ANY +DwarvenFortressCitadel
  1102.     End
  1103.  
  1104.     Behavior = AttributeModifierUpgrade ModuleTag_Reinforced
  1105.         TriggeredBy                = Upgrade_DwarvenFortressDwarvenStonework
  1106.         AttributeModifier        = DwarvenStoneworkExpansion_Bonus
  1107.         CustomAnimAndDuration    = AnimState:UPGRADE_NUMENOR_STONEWORK AnimTime:0
  1108.     End
  1109.  
  1110.     Behavior = ModelConditionUpgrade ModuleTag_ShowTheStones
  1111.         TriggeredBy            = Upgrade_DwarvenFortressDwarvenStonework        
  1112.         AddConditionFlags    = UPGRADE_NUMENOR_STONEWORK
  1113.         Permanent            = Yes
  1114.     End
  1115.  
  1116.     Geometry              = BOX
  1117.     GeometryMajorRadius   = 8.0        ; 10.0 
  1118.     GeometryMinorRadius   = 20.0    ; 
  1119.     GeometryHeight        = 40.0    ; 53.0
  1120.     GeometryIsSmall       = No
  1121.       
  1122.       
  1123.     Shadow                = SHADOW_VOLUME
  1124.     BuildCompletion     = PLACED_BY_PLAYER
  1125. End
  1126.  
  1127.  
  1128. ;---------------------------------------------
  1129. Object DwarvenWallGateSmall
  1130.   ; *** ART Parameters ***
  1131.   
  1132.       SelectPortrait = BPDWall_Gate
  1133.   
  1134.     Draw = W3DScriptedModelDraw ModuleTag_Draw
  1135.         OkToChangeModelColor  = Yes
  1136.         UseStandardModelNames = Yes
  1137.         DefaultModelConditionState
  1138.             Model = DBWallGateN_SKN
  1139.         End
  1140.         
  1141. ;        IdleAnimationState
  1142. ;            Flags = ADJUST_HEIGHT_BY_CONSTRUCTION_PERCENT
  1143. ;            Animation                =    ReallyDamagedanimation
  1144. ;                AnimationName        =     GBWallrampart.GBWallrampart
  1145. ;                AnimationMode        =    LOOP
  1146. ;              End
  1147. ;             StateName = STATE_None
  1148. ;        End    
  1149.  
  1150.  
  1151.  
  1152.         ;------------ New Build Up States coming soon. 
  1153.         ModelConditionState   = AWAITING_CONSTRUCTION 
  1154.             Model               = DBWallGateN_A
  1155.         End
  1156.         AnimationState        = AWAITING_CONSTRUCTION
  1157.             Animation           =  DBWallGateN_A
  1158.                 AnimationName     =  DBWallGateN_A.DBWallGateN_A
  1159.                 AnimationMode     = MANUAL
  1160.                 AnimationBlendTime = 0
  1161.             End
  1162.             Flags                  = START_FRAME_FIRST
  1163. ;            BeginScript
  1164. ;                CurDrawablePlaySound("GondorBarracksBeginConstruction")
  1165. ;            EndScript
  1166.         End
  1167.  
  1168.         ModelConditionState    = UPGRADE_NUMENOR_STONEWORK ACTIVELY_BEING_CONSTRUCTED PARTIALLY_CONSTRUCTED
  1169.             Model        = DBWallGateN_A
  1170.             Texture        = DBFortress1.tga DBFortress_U.tga
  1171.         End
  1172.  
  1173.         ModelConditionState   = ACTIVELY_BEING_CONSTRUCTED PARTIALLY_CONSTRUCTED
  1174.             Model               = DBWallGateN_A
  1175.         End
  1176.         
  1177.         AnimationState        = ACTIVELY_BEING_CONSTRUCTED PARTIALLY_CONSTRUCTED
  1178.             Animation           = DBWallGateN_A
  1179.                 AnimationName     = DBWallGateN_A.DBWallGateN_A
  1180.                 AnimationMode     = MANUAL
  1181.                 AnimationBlendTime = 0
  1182.             End
  1183.             Flags                  = START_FRAME_FIRST
  1184. ;            StateName              = BeingConstructed
  1185. ;            BeginScript
  1186. ;                CurDrawablePlaySound("GondorBarracksBeginConstruction")
  1187. ;            EndScript
  1188.         ParticleSysBone   = NONE WallConstructDust FollowBone:Yes
  1189.         End
  1190.  
  1191. ;--------- damage states for the gate
  1192.  
  1193.         ModelConditionState   = DAMAGED
  1194.             Model               = DBWallGateN_D1
  1195.         End
  1196.         
  1197.         ModelConditionState   = REALLYDAMAGED
  1198.             Model               = DBWallGateN_D2
  1199.         End
  1200.  
  1201.         ModelConditionState  = COLLAPSING DOOR_1_OPENING
  1202.             Model         = DBWallGateN_D4
  1203.         End
  1204.         AnimationState = COLLAPSING DOOR_1_OPENING
  1205.               Animation                =    RubbleAnimation
  1206.                 AnimationName        =     DBWallGateN_D4.DBWallGateN_D4
  1207.                 AnimationMode        =    ONCE
  1208.               End
  1209.         End
  1210.         
  1211.         ModelConditionState  = COLLAPSING
  1212.             Model         = DBWallGateN_D3
  1213.         End
  1214.         AnimationState = COLLAPSING
  1215.               Animation                =    RubbleAnimation
  1216.                 AnimationName        =     DBWallGateN_D3.DBWallGateN_D3
  1217.                 AnimationMode        =    ONCE
  1218.               End
  1219.             EnteringStateFX            = FX_StructureMediumCollapse
  1220.         End
  1221.  
  1222.         ModelConditionState  = RUBBLE
  1223.             Model         = None  
  1224.         End  
  1225.         
  1226.         ModelConditionState  = POST_RUBBLE
  1227.             Model         = NONE
  1228.             ParticleSysBone NONE SmokeBuildingMediumRubble
  1229.         End
  1230.         AnimationState = POST_RUBBLE
  1231.         End
  1232.  
  1233.         ModelConditionState  = POST_COLLAPSE
  1234.         Model         = None
  1235.             ParticleSysBone NONE SmokeBuildingMediumRubble
  1236.         End
  1237.         AnimationState = POST_COLLAPSE
  1238.         End 
  1239.  
  1240.                 
  1241. ;------ Door Animations
  1242.  
  1243.         AnimationState = DOOR_1_OPENING 
  1244.             Flags = START_FRAME_LAST
  1245.             StateName = Door_Open
  1246.             Animation                =    Death
  1247.                 AnimationName        =    DBWallGateN_SKL.DBWallGateN_OP
  1248.                 AnimationMode        =    ONCE
  1249.             End
  1250.             BeginScript
  1251.                 Prev = CurDrawablePrevAnimationState()
  1252.                 if Prev == "Door_Close" then CurDrawableSetTransitionAnimState("TRANS_Closed_To_Open") end
  1253.             EndScript
  1254.         End
  1255.         TransitionState = TRANS_Closed_To_Open
  1256.             Animation = Open 
  1257.                 AnimationName    =    DBWallGateN_SKL.DBWallGateN_OPN
  1258.                 AnimationMode    =    ONCE 
  1259.             End
  1260.         End
  1261.     
  1262.         AnimationState = DOOR_1_CLOSING 
  1263.             Flags = START_FRAME_LAST
  1264.             StateName = Door_Close
  1265.             Animation                =    Death
  1266.                 AnimationName        =    DBWallGateN_SKL.DBWallGateN_CL
  1267.                 AnimationMode        =    ONCE
  1268.             End
  1269.             BeginScript
  1270.                 Prev = CurDrawablePrevAnimationState()
  1271.                 if Prev == "Door_Open" then CurDrawableSetTransitionAnimState("TRANS_Open_To_Closed") end
  1272.             EndScript
  1273.         End
  1274.         TransitionState = TRANS_Open_To_Closed
  1275.             Animation = Open 
  1276.                 AnimationName    =    DBWallGateN_SKL.DBWallGateN_CLS
  1277.                 AnimationMode    =    ONCE 
  1278.             End
  1279.         End
  1280.  
  1281.         ModelConditionState = UPGRADE_NUMENOR_STONEWORK
  1282.             Model = DBWallGateN_SKN
  1283.             Texture = DBFortress1.tga DBFortress_U.tga
  1284.         End
  1285.             
  1286.         ModelConditionState = SNOW  
  1287.             Model = DBWallGateN_SKN
  1288.             Texture    = DBFortress1.tga DBFortress1_snow.tga
  1289.         End      
  1290.                             
  1291.     End
  1292.  
  1293.      Draw = W3DFloorDraw ModuleTag_DrawFloor    
  1294.            StaticModelLODMode = yes ; Will append M or L to the skin name depending on GameLOD
  1295.           ModelName = DBWallGateN_Bib
  1296.           WeatherTexture        = SNOWY DBWall_Bib_Snow.tga 
  1297.     End
  1298.      
  1299.     ; ***DESIGN parameters ***
  1300.     DisplayName         = OBJECT:DwarvenCastleWallGateSmall
  1301.     Side                = Dwarves
  1302.     EditorSorting       = STRUCTURE
  1303.     ThreatLevel = 1.0
  1304.     ThreatBreakdown ModuleTag_DetailedThreat
  1305.         AIKindOf = WALL
  1306.     End
  1307.      
  1308.     BuildCost           = DWARVEN_WALLGATE_SMALL_BUILDCOST
  1309.     BuildTime           = DWARVEN_WALLGATE_SMALL_BUILDTIME
  1310.     VisionRange         = DWARVEN_WALLGATE_SMALL_VISION_RANGE
  1311.     ShroudClearingRange = DWARVEN_WALLGATE_SMALL_SHROUD_CLEAR
  1312.  
  1313.  
  1314.     ; *** AUDIO Parameters ***
  1315.  
  1316.     #include "..\..\..\Includes\StandardBuildingEvaEvents.inc"
  1317.  
  1318.     VoiceSelect                        = GateSelect
  1319.     VoiceSelectUnderConstruction    = BuildingGoodVoiceSelectUnderConstruction
  1320.  
  1321.     SoundOnDamaged                    = BuildingLightDamageStone
  1322.     SoundOnReallyDamaged            = BuildingHeavyDamageStone
  1323.  
  1324.     UnitSpecificSounds
  1325.         UnderConstruction        = WallConstructionLoop      ;Built first time
  1326.         ; UnderRepairFromDamage    = NoSound                    ; Repaired No animation on the building, so don't bother playing sound
  1327.         UnderRepairFromRubble    = WallConstructionLoop        ;Repaired from completely destroyed (not used???)
  1328.     End
  1329.  
  1330.     CampnessValue = CAMPNESS_WALL
  1331.  
  1332.     ; *** ENGINEERING Parameters ***
  1333.     RadarPriority       = STRUCTURE
  1334.     KindOf              = PRELOAD STRUCTURE SELECTABLE IMMOBILE SCORE WALL_UPGRADE MADE_OF_STONE BLOCKING_GATE WALL_GATE
  1335.     CommandSet            = CastleGateCommandSet
  1336.  
  1337.         ArmorSet
  1338.         Conditions        = None
  1339.         Armor             = DwarvenWallArmor
  1340.         DamageFX          = None
  1341.     End
  1342.  
  1343.     Behavior                        = GettingBuiltBehavior ModuleTag_04
  1344.         SelfBuildingLoop            = WallConstructionLoop            // Only played if we DON'T spawn a worker
  1345.         SelfRepairFromDamageLoop    = NoSound                        // This doesn't cause an animation, so don't bother playing a sound
  1346.         SelfRepairFromRubbleLoop    = WallConstructionLoop
  1347.         SpawnTimer                    = -1.0                            // Negative means no 'autoheal'
  1348.         RebuildTimeSeconds            = DWARVEN_WALLGATE_SMALL_BUILDTIME
  1349.     End
  1350.  
  1351.     Body                = StructureBody ModuleTag_05
  1352.         MaxHealth         = DWARVEN_WALLGATE_SMALL_HEALTH
  1353.     End
  1354.      
  1355.     // These should always appear together on wall segments
  1356.     Behavior = KeepObjectDie ModuleTag_IWantRubble 
  1357.         DeathTypes            = ALL -SUICIDED
  1358.     End
  1359.     Behavior            = SlowDeathBehavior ModuleTag_SlowDeath
  1360.         DeathTypes            = NONE +SUICIDED
  1361.         DestructionDelay    = 5000
  1362.         ;Sound                = INITIAL BuildingSink
  1363.     End                                                
  1364.     // These should always appear together on wall segments
  1365.  
  1366.     Behavior = GateOpenAndCloseBehavior ModuleTag_GATE
  1367.         ResetTimeInMilliseconds            = 3000                ;important! this must be longer than the gates animation, ir it will twitch
  1368.         OpenByDefault                    = No
  1369.         PercentOpenForPathing            = 50
  1370.         SoundOpeningGateLoop            = GateOpenStart
  1371.         SoundClosingGateLoop            = GateCloseStart
  1372.         SoundFinishedOpeningGate        = GateOpenEnd
  1373.         SoundFinishedClosingGate        = GateCloseEnd
  1374.         TimeBeforePlayingOpenSound        = 9500
  1375.         TimeBeforePlayingClosedSound    = 9500
  1376.     End
  1377.     
  1378.     Behavior = FakePathfindPortalBehaviour ModuleTag_FAKEPATHFIND
  1379.         AllowEnemies            = No
  1380.         AllowNonSkirmishAIUnits    = No
  1381.     End
  1382.     
  1383.     Behavior = AIGateUpdate ModuleTage_AIGateUpdate
  1384.         TriggerWidthX = 200.0
  1385.         TriggerWidthY = 100.0
  1386.     End
  1387.  
  1388.     Behavior = InheritUpgradeCreate ModuleTag_InheritStonework
  1389.         Radius = DWARVEN_FORTRESS_WALL_EFFECTIVE_RADIUS
  1390.         Upgrade = Upgrade_DwarvenFortressDwarvenStonework
  1391.         ObjectFilter = ANY +DwarvenFortressCitadel
  1392.     End
  1393.  
  1394.     Behavior = AttributeModifierUpgrade ModuleTag_Reinforced
  1395.         TriggeredBy                = Upgrade_DwarvenFortressDwarvenStonework
  1396.         AttributeModifier        = DwarvenStoneworkExpansion_Bonus
  1397.         CustomAnimAndDuration    = AnimState:UPGRADE_NUMENOR_STONEWORK AnimTime:0
  1398.     End
  1399.  
  1400.     Behavior = ModelConditionUpgrade ModuleTag_ShowTheStones
  1401.         TriggeredBy            = Upgrade_DwarvenFortressDwarvenStonework        
  1402.         AddConditionFlags    = UPGRADE_NUMENOR_STONEWORK
  1403.         Permanent            = Yes
  1404.     End
  1405.  
  1406.     GeometryIsSmall          = No
  1407.  
  1408.     ; right pillar
  1409.     Geometry              = BOX
  1410.     GeometryMajorRadius   = 10.0  
  1411.     GeometryMinorRadius   = 10.0  
  1412.     GeometryHeight        = 75
  1413.     GeometryOffset        = X:0 Y:50 Z:0
  1414.     
  1415.     ; left pillar
  1416.     AdditionalGeometry    = BOX
  1417.     GeometryMajorRadius   = 10.0  
  1418.     GeometryMinorRadius   = 10.0  
  1419.     GeometryHeight        = 75
  1420.     GeometryOffset        = X:0 Y:-50 Z:0
  1421.  
  1422.     ; Main
  1423.     AdditionalGeometry    = BOX
  1424.     GeometryName          = "Closed"
  1425.     GeometryMajorRadius   = 9.0  
  1426.     GeometryMinorRadius   = 50.0  
  1427.     GeometryHeight        = 50
  1428.     
  1429.     ; Left open
  1430.     AdditionalGeometry    = BOX
  1431.     GeometryName          = "OpenLeft"
  1432.     GeometryMajorRadius   = 9.0  
  1433.     GeometryMinorRadius   = 10.0  
  1434.     GeometryHeight        = 40
  1435.     GeometryOffset        = X:0 Y:-30 Z:0
  1436.     
  1437.     ; Right open
  1438.     AdditionalGeometry    = BOX
  1439.     GeometryName          = "OpenRight"
  1440.     GeometryMajorRadius   = 9.0  
  1441.     GeometryMinorRadius   = 10.0  
  1442.     GeometryHeight        = 40
  1443.     GeometryOffset        = X:0 Y:30 Z:0
  1444.  
  1445.     // need some geometry points to tell enemy weapons where to hit.
  1446.     GeometryContactPoint = X:0    Y:50 Z:75
  1447.     GeometryContactPoint = X:0    Y:50 Z:10
  1448.     GeometryContactPoint = X:0    Y:-50 Z:10
  1449.     GeometryContactPoint = X:0    Y:-50 Z:75
  1450.     
  1451.     Shadow                = SHADOW_VOLUME
  1452.     BuildCompletion     = PLACED_BY_PLAYER
  1453. End
  1454.  
  1455. ;---------------------------------------------
  1456. Object DwarvenWallPosternGateSmall
  1457.   
  1458.   ; *** ART Parameters ***
  1459.   
  1460.       SelectPortrait = BPDWall_PosternGate
  1461.       
  1462.     Draw = W3DScriptedModelDraw ModuleTag_Draw
  1463.         OkToChangeModelColor  = Yes
  1464.         UseStandardModelNames = Yes
  1465.         
  1466.         ExtraPublicBone = Post01
  1467.         ExtraPublicBone = Post02
  1468.         ExtraPublicBone = Post03
  1469.         ExtraPublicBone = Post04
  1470.     
  1471.         DefaultModelConditionState
  1472.             Model = DBWallPGN
  1473.         End
  1474.         IdleAnimationState
  1475. ;            Flags = ADJUST_HEIGHT_BY_CONSTRUCTION_PERCENT
  1476. ;            Animation                =    ReallyDamagedanimation
  1477. ;                AnimationName        =     GBWallrampart.GBWallrampart
  1478. ;                AnimationMode        =    LOOP
  1479. ;              End
  1480. ;              StateName = STATE_None
  1481.         End    
  1482.  
  1483.  
  1484.         ;------------ New Build Up States coming soon. 
  1485.         ModelConditionState   = AWAITING_CONSTRUCTION UPGRADE_NUMENOR_STONEWORK
  1486.             Model               = DBWallPGN_A
  1487.             Texture    = DBFortress1.tga DBFortress_U.tga
  1488.         End
  1489.         ModelConditionState   = AWAITING_CONSTRUCTION SNOW
  1490.             Model               = DBWallPGN_A
  1491.             Texture    = DBFortress1.tga DBFortress1_snow.tga
  1492.         End
  1493.         ModelConditionState   = AWAITING_CONSTRUCTION 
  1494.             Model               = DBWallPGN_A
  1495.         End
  1496.         AnimationState        = AWAITING_CONSTRUCTION
  1497.             Animation           =  DBWallPGN_A
  1498.                 AnimationName     =  DBWallPGN_A.DBWallPGN_A
  1499.                 AnimationMode     = MANUAL
  1500.                 AnimationBlendTime = 0
  1501.             End
  1502.             Flags                  = START_FRAME_FIRST
  1503. ;            BeginScript
  1504. ;                CurDrawablePlaySound("GondorBarracksBeginConstruction")
  1505. ;            EndScript
  1506.         End
  1507.  
  1508.         ModelConditionState        = UPGRADE_NUMENOR_STONEWORK ACTIVELY_BEING_CONSTRUCTED PARTIALLY_CONSTRUCTED
  1509.             Model        = DBWallPGN_A
  1510.             Texture        = DBFortress1.tga DBFortress_U.tga
  1511.         End
  1512.         ModelConditionState        = SNOW ACTIVELY_BEING_CONSTRUCTED PARTIALLY_CONSTRUCTED
  1513.             Model        = DBWallPGN_A
  1514.             Texture    = DBFortress1.tga DBFortress1_snow.tga
  1515.         End
  1516.         ModelConditionState   = ACTIVELY_BEING_CONSTRUCTED PARTIALLY_CONSTRUCTED
  1517.             Model               = DBWallPGN_A
  1518.             ParticleSysBone   = NONE WallConstructDust FollowBone:Yes
  1519.         End
  1520.         
  1521.         AnimationState        = ACTIVELY_BEING_CONSTRUCTED PARTIALLY_CONSTRUCTED
  1522.             Animation           = DBWallPGN_A
  1523.                 AnimationName     = DBWallPGN_A.DBWallPGN_A
  1524.                 AnimationMode     = MANUAL
  1525.                 AnimationBlendTime = 0
  1526.             End
  1527.             Flags                  = START_FRAME_FIRST
  1528. ;            StateName              = BeingConstructed
  1529. ;            BeginScript
  1530. ;                CurDrawablePlaySound("GondorBarracksBeginConstruction")
  1531. ;            EndScript
  1532.         End
  1533.  
  1534.  
  1535.         ;--damaged building
  1536.       
  1537.         ModelConditionState  = DAMAGED
  1538.             Model         = DBWallPGN_D1 
  1539.         End
  1540.         AnimationState = DAMAGED
  1541.         End        
  1542.         
  1543.         ModelConditionState  = REALLYDAMAGED
  1544.             Model         = DBWallPGN_D2
  1545.         End
  1546.         
  1547.         AnimationState = REALLYDAMAGED
  1548.               Animation                =    RubbleAnimation
  1549.                 AnimationName        =     DBWallPGN_D2.DBWallPGN_D2
  1550.                 AnimationMode        =    ONCE
  1551.               End
  1552.             EnteringStateFX    = FX_BuildingReallyDamaged
  1553.         End
  1554.  
  1555.         ModelConditionState  = COLLAPSING
  1556.             Model         = DBWallPGN_D3
  1557.         End
  1558.         
  1559.         AnimationState = COLLAPSING
  1560.               Animation                =    RubbleAnimation
  1561.                 AnimationName        =     DBWallPGN_D3.DBWallN_D3
  1562.                 AnimationMode        =    ONCE
  1563.               End
  1564.             EnteringStateFX            = FX_StructureMediumCollapse
  1565.         End
  1566.         AnimationState = DYING
  1567.              EnteringStateFX            = FX_StructureMediumCollapse
  1568.         End
  1569.  
  1570.         ModelConditionState  = DYING
  1571.             Model         = None
  1572.         End
  1573.  
  1574.         ModelConditionState  = RUBBLE
  1575.             Model         = None  
  1576.         End  
  1577.         
  1578.         ModelConditionState  = POST_RUBBLE
  1579.             Model         = NONE
  1580.             ParticleSysBone NONE SmokeBuildingMediumRubble
  1581.         End
  1582.         
  1583.         AnimationState = POST_RUBBLE
  1584.         End
  1585.  
  1586.         ModelConditionState  = POST_COLLAPSE
  1587.         Model         = None
  1588.             ParticleSysBone NONE SmokeBuildingMediumRubble
  1589.         End
  1590.         
  1591.         AnimationState = POST_COLLAPSE
  1592.         End 
  1593.  
  1594.         ModelConditionState = UPGRADE_NUMENOR_STONEWORK
  1595.             Model    = DBWallPGN
  1596.             Texture    = DBFortress1.tga DBFortress_U.tga
  1597.         End
  1598.  
  1599.         ModelConditionState = SNOW  
  1600.             Model = DBWallPGN
  1601.             Texture    = DBFortress1.tga DBFortress1_snow.tga
  1602.         End     
  1603.         
  1604.     End
  1605.  
  1606.     Draw = W3DScriptedModelDraw ModuleTag_DrawWall
  1607.         AffectedByStealth        = No
  1608.         OkToChangeModelColor  = Yes
  1609.         UseStandardModelNames = Yes
  1610.         DefaultModelConditionState
  1611.             Model = DBWallN
  1612.         End
  1613.  
  1614.         ModelConditionState = SNOW BUILD_PLACEMENT_CURSOR
  1615.             Model = DBWallN_CUR
  1616.             Texture    = DBFortress1.tga DBFortress1_snow.tga
  1617.         End
  1618.         
  1619.         ModelConditionState = BUILD_PLACEMENT_CURSOR
  1620.             Model = DBWallN_CUR
  1621.         End
  1622.                     
  1623.         IdleAnimationState
  1624. ;            Flags = ADJUST_HEIGHT_BY_CONSTRUCTION_PERCENT
  1625. ;            Animation                =    ReallyDamagedanimation
  1626. ;                AnimationName        =     GBWallrampart.GBWallrampart
  1627. ;                AnimationMode        =    LOOP
  1628. ;             End
  1629.             StateName = STATE_None
  1630.         End    
  1631.         
  1632.  
  1633.         ;------------ New Build Up States coming soon. 
  1634.         
  1635.         ModelConditionState = SNOW AWAITING_CONSTRUCTION
  1636.             Model = DBWallN_A
  1637.             Texture    = DBFortress1.tga DBFortress1_snow.tga
  1638.         End
  1639.                 
  1640.         ModelConditionState   = AWAITING_CONSTRUCTION 
  1641.             Model               = DBWallN_A
  1642.         End
  1643.         AnimationState        = AWAITING_CONSTRUCTION
  1644.             Animation           =  DBWallN_A
  1645.                 AnimationName     =  DBWallN_A.DBWallN_A
  1646.                 AnimationMode     = MANUAL
  1647.                 AnimationBlendTime = 0
  1648.             End
  1649.             Flags                  = START_FRAME_FIRST
  1650. ;            BeginScript
  1651. ;                CurDrawablePlaySound("GondorBarracksBeginConstruction")
  1652. ;            EndScript
  1653.         End
  1654.  
  1655.         ModelConditionState = UPGRADE_NUMENOR_STONEWORK ACTIVELY_BEING_CONSTRUCTED PARTIALLY_CONSTRUCTED
  1656.             Model    = DBWallN_A
  1657.             Texture    = DBFortress1.tga DBFortress_U.tga
  1658.         End
  1659.  
  1660.         ModelConditionState = SNOW ACTIVELY_BEING_CONSTRUCTED PARTIALLY_CONSTRUCTED
  1661.             Model = DBWallN_A
  1662.             Texture    = DBFortress1.tga DBFortress1_snow.tga
  1663.         End
  1664.         
  1665.         ModelConditionState   = ACTIVELY_BEING_CONSTRUCTED PARTIALLY_CONSTRUCTED
  1666.             Model               = DBWallN_A
  1667.         End
  1668.         
  1669.         AnimationState        = ACTIVELY_BEING_CONSTRUCTED PARTIALLY_CONSTRUCTED
  1670.             Animation           = DBWallN_A
  1671.                 AnimationName     = DBWallN_A.DBWallN_A
  1672.                 AnimationMode     = MANUAL
  1673.                 AnimationBlendTime = 0
  1674.             End
  1675.             Flags                  = START_FRAME_FIRST
  1676.             StateName              = BeingConstructed
  1677. ;            BeginScript
  1678. ;                CurDrawablePlaySound("GondorBarracksBeginConstruction")
  1679. ;            EndScript
  1680.             ParticleSysBone   = NONE WallConstructDust FollowBone:Yes
  1681.         End
  1682.  
  1683.  
  1684.         ;--damaged building
  1685.       
  1686.         ModelConditionState  = DAMAGED
  1687.             Model         = DBWallN ;DBWallN_D1  
  1688.         End
  1689.         AnimationState = DAMAGED
  1690.         End        
  1691.         
  1692.         ModelConditionState  = REALLYDAMAGED
  1693.             Model         = DBWallN_D2
  1694.         End
  1695.         
  1696.         AnimationState = REALLYDAMAGED
  1697.               Animation                =    RubbleAnimation
  1698.                 AnimationName        =     DBWallN_D2.DBWallN_D2
  1699.                 AnimationMode        =    ONCE
  1700.               End
  1701.             EnteringStateFX    = FX_BuildingReallyDamaged
  1702.         End
  1703.  
  1704.         ModelConditionState  = COLLAPSING
  1705.             Model         = DBWallN_D3
  1706.         End
  1707.         
  1708.         AnimationState = COLLAPSING
  1709.               Animation                =    RubbleAnimation
  1710.                 AnimationName        =     DBWallN_D3.DBWallN_D3
  1711.                 AnimationMode        =    ONCE
  1712.               End
  1713.         End
  1714.  
  1715.         ModelConditionState  = DYING
  1716.             Model         = DBWallN_D3
  1717.         End
  1718.         
  1719.         AnimationState = DYING
  1720.               Animation                =    RubbleAnimation
  1721.                 AnimationName        =     DBWallN_D3.DBWallN_D3
  1722.                 AnimationMode        =    ONCE
  1723.               End
  1724.         End
  1725.  
  1726.  
  1727.         ModelConditionState  = RUBBLE
  1728.             Model         = None  
  1729.         End  
  1730.         
  1731.         ModelConditionState  = POST_RUBBLE
  1732.             Model         = NONE
  1733.             ParticleSysBone NONE SmokeBuildingMediumRubble
  1734.         End
  1735.         
  1736.         AnimationState = POST_RUBBLE
  1737.         End
  1738.  
  1739.         ModelConditionState  = POST_COLLAPSE
  1740.         Model         = None
  1741.             ParticleSysBone NONE SmokeBuildingMediumRubble
  1742.         End
  1743.         
  1744.         AnimationState = POST_COLLAPSE
  1745.         End 
  1746.  
  1747.         ModelConditionState    = UPGRADE_NUMENOR_STONEWORK
  1748.             Model    = DBWallN
  1749.             Texture    = DBFortress1.tga DBFortress_U.tga
  1750.         End
  1751.  
  1752.         ModelConditionState = SNOW  
  1753.             Model = DBWallN
  1754.             Texture    = DBFortress1.tga DBFortress1_snow.tga
  1755.         End        
  1756.  
  1757.     End
  1758.  
  1759.      Draw = W3DFloorDraw ModuleTag_DrawFloor    
  1760.            StaticModelLODMode = yes ; Will append M or L to the skin name depending on GameLOD
  1761.           ModelName = DBWallPGN_Bib
  1762.           WeatherTexture        = SNOWY DBWall_Bib_Snow.tga 
  1763.     End
  1764.      
  1765.     ; ***DESIGN parameters ***
  1766.     DisplayName         = OBJECT:DwarvenCastleWallPosternGateSmall
  1767.     DisplayNameInvisibleForEnemy         = OBJECT:DwarvenCastleWallSegment
  1768.     Side                = Dwarves
  1769.     EditorSorting       = STRUCTURE
  1770.     ThreatLevel = 1.0
  1771.     ThreatBreakdown ModuleTag_DetailedThreat
  1772.         AIKindOf = WALL
  1773.     End
  1774.      
  1775.     BuildCost           = DWARVEN_POSTERNGATE_SMALL_BUILDCOST
  1776.     BuildTime           = DWARVEN_POSTERNGATE_SMALL_BUILDTIME           ; in seconds
  1777.     VisionRange         = DWARVEN_POSTERNGATE_SMALL_VISION_RANGE         ; Shroud clearing distance
  1778.     ShroudClearingRange = DWARVEN_POSTERNGATE_SMALL_SHROUD_CLEAR
  1779.  
  1780.     CommandSet    = SellableCommandSet
  1781.  
  1782.     ; *** AUDIO Parameters ***
  1783.  
  1784.     #include "..\..\..\Includes\StandardBuildingEvaEvents.inc"
  1785.  
  1786.     VoiceSelect                        = GondorPosternGateSelect
  1787.     VoiceSelectUnderConstruction    = BuildingGoodVoiceSelectUnderConstruction
  1788.  
  1789.     SoundOnDamaged                    = BuildingLightDamageStone
  1790.     SoundOnReallyDamaged            = BuildingHeavyDamageStone
  1791.  
  1792.     UnitSpecificSounds
  1793.         UnderConstruction        = WallConstructionLoop      ;Built first time
  1794.         ; UnderRepairFromDamage    = NoSound                    ; Repaired No animation on the building, so don't bother playing sound
  1795.         UnderRepairFromRubble    = WallConstructionLoop        ;Repaired from completely destroyed (not used???)
  1796.     End
  1797.  
  1798.     CampnessValue = CAMPNESS_WALL
  1799.  
  1800.     ; *** ENGINEERING Parameters ***
  1801.     RadarPriority       = STRUCTURE
  1802.     KindOf              = PRELOAD STRUCTURE SELECTABLE IMMOBILE SCORE MADE_OF_STONE IGNORE_FOR_VICTORY WALL_UPGRADE
  1803.  
  1804.     Behavior                        = GettingBuiltBehavior ModuleTag_04
  1805.         UseSpawnTimerWithoutWorker         = Yes
  1806.         SpawnTimer    = DEFAULT_STRUCTURE_HEALDELAY
  1807.         RebuildTimeSeconds            = 30
  1808.         SelfBuildingLoop            = WallConstructionLoop            ;Only played if we DON'T spawn a worker
  1809.         SelfRepairFromDamageLoop     = WallConstructionLoop
  1810.         SelfRepairFromRubbleLoop    = WallConstructionLoop
  1811.     End
  1812.  
  1813.     Body                = StructureBody ModuleTag_05
  1814.         MaxHealth         = DWARVEN_POSTERNGATE_SMALL_HEALTH
  1815.     End
  1816.      
  1817.     Behavior            = SlowDeathBehavior ModuleTag_SlowDeath
  1818.         DeathTypes            = ALL
  1819.         DestructionDelay    = 5000
  1820.     End                                                
  1821.     
  1822.     Behavior = DynamicPortalBehaviour PosternGatePortal
  1823.         ActivationDelaySeconds    = 0.0
  1824.         GenerateNow                = Yes
  1825.         
  1826.         ObjectFilter    = POSTERNGATE_ALLOWABLE_OBJECTFILTER
  1827.         BonePrefix        = Post
  1828.         NumberOfBones    = 4
  1829.         WayPoint        = Index:0    Type:Walk    ; 0
  1830.         WayPoint        = Index:1    Type:Walk    ; 1
  1831.         WayPoint        = Index:2    Type:Walk    ; 2
  1832.         WayPoint        = Index:3    Type:Walk    ; 3
  1833.         WayPoint        = Index:2    Type:Walk    ; 4
  1834.         WayPoint        = Index:1    Type:Walk    ; 5
  1835.         Link            = From:0 Via:4 Via:5 To:3
  1836.         Link            = From:3 Via:1 Via:2 To:0
  1837.     End
  1838.     
  1839.     #include "..\..\..\includes\DefaultPosternGateInvisibilityUpdate.inc"
  1840.     
  1841.     Behavior = InheritUpgradeCreate ModuleTag_InheritStonework
  1842.         Radius = DWARVEN_FORTRESS_WALL_EFFECTIVE_RADIUS
  1843.         Upgrade = Upgrade_DwarvenFortressDwarvenStonework
  1844.         ObjectFilter = ANY +DwarvenFortressCitadel
  1845.     End
  1846.  
  1847.     Behavior = AttributeModifierUpgrade ModuleTag_Reinforced
  1848.         TriggeredBy                = Upgrade_DwarvenFortressDwarvenStonework
  1849.         AttributeModifier        = DwarvenStoneworkExpansion_Bonus
  1850.         CustomAnimAndDuration    = AnimState:UPGRADE_NUMENOR_STONEWORK AnimTime:0
  1851.     End
  1852.  
  1853.     Behavior = ModelConditionUpgrade ModuleTag_ShowTheStones
  1854.         TriggeredBy            = Upgrade_DwarvenFortressDwarvenStonework        
  1855.         AddConditionFlags    = UPGRADE_NUMENOR_STONEWORK
  1856.         Permanent            = Yes
  1857.     End
  1858.  
  1859.     Geometry              = BOX
  1860.     GeometryMajorRadius   = 8.0        ; 10.0 
  1861.     GeometryMinorRadius   = 20.0    ; 
  1862.     GeometryHeight        = 40.0    ; 53.0
  1863.     GeometryIsSmall       = No
  1864.  
  1865.         
  1866.     Shadow                = SHADOW_VOLUME
  1867.     BuildCompletion     = PLACED_BY_PLAYER
  1868. End
  1869.  
  1870. ;---------------------------------------------
  1871. Object DwarvenWallTowerSmall
  1872.   ; *** ART Parameters ***
  1873.   
  1874.       SelectPortrait = BPDWall_AxeTower
  1875.   
  1876.   
  1877.     Draw = W3DScriptedModelDraw ModuleTag_Draw
  1878.         OkToChangeModelColor  = Yes
  1879.         UseStandardModelNames = Yes
  1880.     
  1881.         ExtraPublicBone = Arrow_01
  1882.         ExtraPublicBone = Arrow_02
  1883.         ExtraPublicBone = Arrow_03
  1884.         ExtraPublicBone = Arrow_04
  1885.         ExtraPublicBone = Arrow_05
  1886.         ExtraPublicBone = Arrow_06
  1887.         ExtraPublicBone = Arrow_07
  1888.         ExtraPublicBone = Arrow_08
  1889.     
  1890.         DefaultModelConditionState
  1891.             Model                = DBWallTwrN
  1892.             WeaponLaunchBone    = PRIMARY ARROW_
  1893.         End
  1894.         IdleAnimationState
  1895. ;            Flags = ADJUST_HEIGHT_BY_CONSTRUCTION_PERCENT
  1896. ;            Animation                =    ReallyDamagedanimation
  1897. ;                AnimationName        =     GBWallrampart.GBWallrampart
  1898. ;                AnimationMode        =    LOOP
  1899. ;              End
  1900. ;              StateName = STATE_None
  1901.         End    
  1902.  
  1903.  
  1904.         ;------------ New Build Up States coming soon. 
  1905.         ModelConditionState   = AWAITING_CONSTRUCTION 
  1906.             Model               = DBWallTwrN_A
  1907.         End
  1908.         AnimationState        = AWAITING_CONSTRUCTION
  1909.             Animation           =  DBWallTwrN_A
  1910.                 AnimationName     =  DBWallTwrN_A.DBWallTwrN_A
  1911.                 AnimationMode     = MANUAL
  1912.                 AnimationBlendTime = 0
  1913.             End
  1914.             Flags                  = START_FRAME_FIRST
  1915. ;            BeginScript
  1916. ;                CurDrawablePlaySound("GondorBarracksBeginConstruction")
  1917. ;            EndScript
  1918.         End
  1919.  
  1920.         ModelConditionState    = UPGRADE_NUMENOR_STONEWORK ACTIVELY_BEING_CONSTRUCTED
  1921.             Model        = DBWallTwrN_A
  1922.             Texture        = DBFortress1.tga DBFortress_U.tga
  1923.         End
  1924.  
  1925.         ModelConditionState   = ACTIVELY_BEING_CONSTRUCTED PARTIALLY_CONSTRUCTED
  1926.             Model               = DBWallTwrN_A
  1927.             ParticleSysBone   = NONE WallConstructDust FollowBone:Yes
  1928.         End
  1929.         
  1930.         AnimationState        = ACTIVELY_BEING_CONSTRUCTED PARTIALLY_CONSTRUCTED
  1931.             Animation           = DBWallTwrN_A
  1932.                 AnimationName     = DBWallTwrN_A.DBWallTwrN_A
  1933.                 AnimationMode     = MANUAL
  1934.                 AnimationBlendTime = 0
  1935.             End
  1936.             Flags                  = START_FRAME_FIRST
  1937. ;            StateName              = BeingConstructed
  1938. ;            BeginScript
  1939. ;                CurDrawablePlaySound("GondorBarracksBeginConstruction")
  1940. ;            EndScript
  1941.         End        
  1942.  
  1943.  
  1944.         ;--damaged building
  1945.       
  1946.         ModelConditionState  = DAMAGED
  1947.             Model         = DBWallTwrN_D1  
  1948.         End
  1949.         AnimationState = DAMAGED
  1950.         End        
  1951.         
  1952.         ModelConditionState  = REALLYDAMAGED
  1953.             Model         = DBWallTwrN_D2
  1954.         End
  1955.         
  1956.         AnimationState = REALLYDAMAGED
  1957.               Animation                =    RubbleAnimation
  1958.                 AnimationName        =     DBWallTwrN_D2.DBWallTwrN_D2
  1959.                 AnimationMode        =    ONCE
  1960.               End
  1961.             EnteringStateFX    = FX_BuildingReallyDamaged
  1962.         End
  1963.  
  1964.         ModelConditionState  = COLLAPSING
  1965.             Model         = DBWallTwrN_D3
  1966.         End
  1967.         AnimationState = COLLAPSING
  1968.               Animation                =    RubbleAnimation
  1969.                 AnimationName        =     DBWallTwrN_D3.DBWallTwrN_D3
  1970.                 AnimationMode        =    ONCE
  1971.               End
  1972.             EnteringStateFX            = FX_StructureMediumCollapse
  1973.         End
  1974.         
  1975.         ModelConditionState  = DYING
  1976.             Model         = DBWallTwrN_D3
  1977.         End
  1978.         AnimationState = DYING
  1979.               Animation                =    RubbleAnimation
  1980.                 AnimationName        =     DBWallTwrN_D3.DBWallTwrN_D3
  1981.                 AnimationMode        =    ONCE
  1982.               End
  1983.             EnteringStateFX            = FX_StructureMediumCollapse
  1984.         End
  1985.  
  1986.         ModelConditionState  = RUBBLE
  1987.             Model         = None  
  1988.         End  
  1989.         
  1990.         ModelConditionState  = POST_RUBBLE
  1991.             Model         = NONE
  1992.             ParticleSysBone NONE SmokeBuildingMediumRubble
  1993.         End
  1994.         AnimationState = POST_RUBBLE
  1995.         End
  1996.  
  1997.         ModelConditionState  = POST_COLLAPSE
  1998.         Model         = None
  1999.             ParticleSysBone NONE SmokeBuildingMediumRubble
  2000.         End
  2001.         AnimationState = POST_COLLAPSE
  2002.         End 
  2003.  
  2004.         ModelConditionState    = UPGRADE_NUMENOR_STONEWORK
  2005.             Model    = DBWallTwrn
  2006.             Texture    = DBFortress1.tga DBFortress_U.tga
  2007.         End
  2008.         
  2009.         ModelConditionState = SNOW  
  2010.             Model = DBWallTwrN
  2011.             Texture    = DBFortress1.tga DBFortress1_snow.tga
  2012.         End     
  2013.  
  2014.         
  2015.     End
  2016.  
  2017.      Draw = W3DFloorDraw ModuleTag_DrawFloor    
  2018.            StaticModelLODMode = yes ; Will append M or L to the skin name depending on GameLOD
  2019.           ModelName = DBWallTwrN_Bib
  2020.           WeatherTexture        = SNOWY DBWall_Bib_Snow.tga 
  2021.     End
  2022.  
  2023.     ; ***DESIGN parameters ***
  2024.     DisplayName         = OBJECT:DwarvenCastleWallTowerSmall
  2025.     Side                = Dwarves
  2026.     EditorSorting       = STRUCTURE
  2027.     ThreatLevel            = 1.0
  2028.     ThreatBreakdown ModuleTag_DetailedThreat
  2029.         AIKindOf = WALL
  2030.     End
  2031.      
  2032.     BuildCost           = DWARVEN_WALLTOWER_SMALL_BUILDCOST
  2033.     BuildTime           = DWARVEN_WALLTOWER_SMALL_BUILDTIME           ; in seconds
  2034.     VisionRange         = DWARVEN_WALLTOWER_SMALL_VISION_RANGE        ; Shroud clearing distance
  2035.     ShroudClearingRange = DWARVEN_WALLTOWER_SMALL_SHROUD_CLEAR
  2036.  
  2037.     CommandSet    = SellableCommandSet
  2038.  
  2039.     ; *** AUDIO Parameters ***
  2040.  
  2041.     #include "..\..\..\Includes\StandardBuildingEvaEvents.inc"
  2042.  
  2043.     VoiceSelect                        = DwarfTowerWallSelect
  2044.     VoiceSelectUnderConstruction    = BuildingGoodVoiceSelectUnderConstruction
  2045.  
  2046.     SoundOnDamaged                    = BuildingLightDamageStone
  2047.     SoundOnReallyDamaged            = BuildingHeavyDamageStone
  2048.  
  2049.     UnitSpecificSounds
  2050.         UnderConstruction        = WallConstructionLoop      ;Built first time
  2051.         ; UnderRepairFromDamage    = NoSound                    ; Repaired No animation on the building, so don't bother playing sound
  2052.         UnderRepairFromRubble    = WallConstructionLoop        ;Repaired from completely destroyed (not used???)
  2053.     End
  2054.  
  2055.     CampnessValue = CAMPNESS_WALL
  2056.  
  2057.     ; *** ENGINEERING Parameters ***
  2058.     RadarPriority       = STRUCTURE
  2059.     KindOf              = PRELOAD STRUCTURE SELECTABLE IMMOBILE SCORE MADE_OF_STONE CAN_ATTACK IGNORE_FOR_VICTORY WALL_UPGRADE
  2060.  
  2061.     Behavior                        = GettingBuiltBehavior ModuleTag_04
  2062.         UseSpawnTimerWithoutWorker         = Yes
  2063.         SpawnTimer    = DEFAULT_STRUCTURE_HEALDELAY
  2064.         RebuildTimeSeconds            = 30
  2065.         SelfBuildingLoop            = WallConstructionLoop            ;Only played if we DON'T spawn a worker
  2066.         SelfRepairFromDamageLoop     = WallConstructionLoop
  2067.         SelfRepairFromRubbleLoop    = WallConstructionLoop
  2068.     End
  2069.  
  2070.     WeaponSet
  2071.         Conditions            = None
  2072.         Weapon                = PRIMARY StructureAxeWeapon
  2073.         AutoChooseSources    = PRIMARY FROM_PLAYER FROM_SCRIPT FROM_AI
  2074.     End
  2075.  
  2076.     Behavior = AIUpdateInterface ModuleTag_SoWeCanUseWeapon
  2077.          AutoAcquireEnemiesWhenIdle    = Yes
  2078.          MoodAttackCheckRate            = 250
  2079.      End
  2080.  
  2081.     Body = StructureBody ModuleTag_05
  2082.         MaxHealth = DWARVEN_WALLTOWER_SMALL_HEALTH
  2083.     End
  2084.  
  2085.     Behavior = InheritUpgradeCreate ModuleTag_InheritStonework
  2086.         Radius = DWARVEN_FORTRESS_WALL_EFFECTIVE_RADIUS
  2087.         Upgrade = Upgrade_DwarvenFortressDwarvenStonework
  2088.         ObjectFilter = ANY +DwarvenFortressCitadel
  2089.     End
  2090.  
  2091.     Behavior = AttributeModifierUpgrade ModuleTag_Reinforced
  2092.         TriggeredBy                = Upgrade_DwarvenFortressDwarvenStonework
  2093.         AttributeModifier        = DwarvenStoneworkExpansion_Bonus
  2094.         CustomAnimAndDuration    = AnimState:UPGRADE_NUMENOR_STONEWORK AnimTime:0
  2095.     End
  2096.  
  2097.     Behavior = ModelConditionUpgrade ModuleTag_ShowTheStones
  2098.         TriggeredBy            = Upgrade_DwarvenFortressDwarvenStonework        
  2099.         AddConditionFlags    = UPGRADE_NUMENOR_STONEWORK
  2100.         Permanent            = Yes
  2101.     End
  2102.      
  2103.     Behavior            = SlowDeathBehavior ModuleTag_SlowDeath
  2104.         DeathTypes            = ALL
  2105.         DestructionDelay    = 5000
  2106.     End                                                
  2107.  
  2108.     GeometryIsSmall       = No
  2109.     
  2110.     Geometry              = BOX
  2111.     GeometryMajorRadius   = 15.0 
  2112.     GeometryMinorRadius   = 15.0 
  2113.     GeometryHeight        = 40.0
  2114.     
  2115.     AdditionalGeometry    = BOX
  2116.     GeometryMajorRadius   = 10.0 
  2117.     GeometryMinorRadius   = 10.0 
  2118.     GeometryHeight        = 50.0
  2119.     GeometryOffset          = X:0 Y:0 Z:40
  2120.     
  2121.     AdditionalGeometry    = BOX
  2122.     GeometryMajorRadius   = 8.0        ; 10.0 
  2123.     GeometryMinorRadius   = 20.0    ; 
  2124.     GeometryHeight        = 40.0    ; 53.0
  2125.     GeometryIsSmall       = No
  2126.  
  2127.  
  2128.     
  2129.     Shadow                = SHADOW_VOLUME
  2130.     BuildCompletion     = PLACED_BY_PLAYER
  2131. End
  2132.  
  2133. ;---------------------------------------------
  2134. Object DwarvenWallCatapultSmall
  2135.  
  2136.   ; *** ART Parameters ***
  2137.   
  2138.   SelectPortrait  =  UPDwarven_IronHillsCatapult
  2139.   
  2140.     Draw = W3DScriptedModelDraw ModuleTag_Draw
  2141.         OkToChangeModelColor  = Yes
  2142.         UseStandardModelNames = Yes
  2143.         DefaultModelConditionState
  2144.             Model = DBWallTrebN
  2145.         End
  2146.         
  2147.                 
  2148.         IdleAnimationState
  2149.         End    
  2150.  
  2151.         //------------ New Build Up States coming soon. 
  2152.         ModelConditionState   = AWAITING_CONSTRUCTION 
  2153.             Model               = DBWallTrebN_A
  2154.         End
  2155.         AnimationState        = AWAITING_CONSTRUCTION
  2156.             Animation           =  DBWallTrebN_A
  2157.                 AnimationName     =  DBWallTrebN_A.DBWallTrebN_A
  2158.                 AnimationMode     = MANUAL
  2159.                 AnimationBlendTime = 0
  2160.             End
  2161.             Flags                  = START_FRAME_FIRST
  2162.         End
  2163.  
  2164.         ModelConditionState      = UPGRADE_NUMENOR_STONEWORK ACTIVELY_BEING_CONSTRUCTED PARTIALLY_CONSTRUCTED
  2165.             Model            = DBWallTrebN_A
  2166.             Texture            = DBFortress1.tga DBFortress_U.tga
  2167.         End
  2168.  
  2169.         ModelConditionState   = ACTIVELY_BEING_CONSTRUCTED PARTIALLY_CONSTRUCTED
  2170.             Model               = DBWallTrebN_A
  2171.             ParticleSysBone   = NONE WallConstructDust FollowBone:Yes
  2172.         End
  2173.         
  2174.         AnimationState        = ACTIVELY_BEING_CONSTRUCTED PARTIALLY_CONSTRUCTED
  2175.             Animation           = DBWallTrebN_A
  2176.                 AnimationName     = DBWallTrebN_A.DBWallTrebN_A
  2177.                 AnimationMode     = MANUAL
  2178.                 AnimationBlendTime = 0
  2179.             End
  2180.             Flags                  = START_FRAME_FIRST
  2181.         End
  2182.  
  2183.  
  2184.         //--damaged building
  2185.       
  2186.         ModelConditionState  = DAMAGED
  2187.             Model         = DBWallTrebN_D1  
  2188.         End
  2189.         AnimationState = DAMAGED
  2190.         End        
  2191.         
  2192.         ModelConditionState  = REALLYDAMAGED
  2193.             Model         = DBWallTrebN_D2
  2194.         End
  2195.         
  2196.         AnimationState = REALLYDAMAGED
  2197.               Animation                =    RubbleAnimation
  2198.                 AnimationName        =     DBWallTrebN_D2.DBWallTrebN_D2
  2199.                 AnimationMode        =    ONCE
  2200.               End
  2201.             EnteringStateFX    = FX_BuildingReallyDamaged
  2202.         End
  2203.  
  2204.         ModelConditionState  = RUBBLE
  2205.             Model         = DBWallTrebN_D3
  2206.         End
  2207.         AnimationState = RUBBLE
  2208.               Animation                =    RubbleAnimation
  2209.                 AnimationName        =     DBWallTrebN_D3.DBWallTrebN_D3
  2210.                 AnimationMode        =    ONCE
  2211.               End
  2212.             EnteringStateFX            = FX_StructureMediumCollapse
  2213.         End
  2214.         
  2215.         ModelConditionState  = DYING
  2216.             Model         = DBWallTrebN_D3
  2217.         End
  2218.           
  2219.         AnimationState = DYING
  2220.               Animation                =    RubbleAnimation
  2221.                 AnimationName        =     DBWallTrebN_D3.DBWallTrebN_D3
  2222.                 AnimationMode        =    ONCE
  2223.               End
  2224.             EnteringStateFX            = FX_StructureMediumCollapse
  2225.         End
  2226.         
  2227.         
  2228.         
  2229.         ModelConditionState  = POST_RUBBLE
  2230.             Model         = NONE
  2231.             ParticleSysBone NONE SmokeBuildingMediumRubble
  2232.         End
  2233.         AnimationState = POST_RUBBLE
  2234.         End
  2235.  
  2236.         ModelConditionState  = POST_COLLAPSE
  2237.         Model         = None
  2238.             ParticleSysBone NONE SmokeBuildingMediumRubble
  2239.         End
  2240.         AnimationState = POST_COLLAPSE
  2241.         End 
  2242.  
  2243.         ModelConditionState = UPGRADE_NUMENOR_STONEWORK
  2244.             Model    = DBWallTrebN
  2245.             Texture    = DBFortress1.tga DBFortress_U.tga
  2246.         End
  2247.  
  2248.         ModelConditionState = SNOW  
  2249.             Model = DBWallTrebN
  2250.             Texture    = DBFortress1.tga DBFortress1_snow.tga
  2251.         End    
  2252.         
  2253.     End
  2254.  
  2255.       Draw = W3DFloorDraw ModuleTag_DrawFloor    
  2256.            StaticModelLODMode        = yes // Will append M or L to the skin name depending on GameLOD
  2257.           ModelName                = DBWallTrebN_Bib
  2258.           WeatherTexture            = SNOWY DBWall_Bib_Snow.tga 
  2259.     End
  2260.  
  2261.  
  2262.     // ***DESIGN parameters ***
  2263.     DisplayName         = OBJECT:DwarvenCastleWallCatapultSmall
  2264.     Side                = Dwarves
  2265.     EditorSorting       = STRUCTURE
  2266.     ThreatLevel = 1.0
  2267.      
  2268.     BuildCost           = DWARVEN_WALLCATAPULT_SMALL_BUILDCOST
  2269.     BuildTime           = DWARVEN_WALLCATAPULT_SMALL_BUILDTIME           ; in seconds
  2270.     VisionRange         = DWARVEN_WALLCATAPULT_SMALL_VISION_RANGE          ; Shroud clearing distance
  2271.     ShroudClearingRange = DWARVEN_WALLCATAPULT_SMALL_SHROUD_CLEAR
  2272.         
  2273.  
  2274.     // *** AUDIO Parameters ***
  2275.  
  2276.     #include "..\..\..\Includes\StandardBuildingEvaEvents.inc"
  2277.  
  2278.     VoiceSelect                        = DwarvenCatapultExpansionSelect
  2279.     VoiceSelectUnderConstruction    = BuildingGoodVoiceSelectUnderConstruction
  2280.  
  2281.     SoundOnDamaged                    = BuildingLightDamageStone
  2282.     SoundOnReallyDamaged            = BuildingHeavyDamageStone
  2283.  
  2284.     UnitSpecificSounds
  2285.         UnderConstruction        = WallConstructionLoop      ;Built first time
  2286.         ; UnderRepairFromDamage    = NoSound                    ; Repaired No animation on the building, so don't bother playing sound
  2287.         UnderRepairFromRubble    = WallConstructionLoop        ;Repaired from completely destroyed (not used???)
  2288.     End
  2289.  
  2290.     CampnessValue = CAMPNESS_WALL
  2291.  
  2292.     // *** ENGINEERING Parameters ***
  2293.     RadarPriority       = STRUCTURE
  2294.     KindOf              = PRELOAD STRUCTURE SELECTABLE IMMOBILE SCORE MADE_OF_STONE IGNORE_FOR_VICTORY WALL_UPGRADE // WALL_HUB
  2295.  
  2296.     Behavior                        = GettingBuiltBehavior ModuleTag_04
  2297.         UseSpawnTimerWithoutWorker         = Yes
  2298.         SpawnTimer    = DEFAULT_STRUCTURE_HEALDELAY
  2299.         RebuildTimeSeconds            = 30
  2300.         SelfBuildingLoop            = WallConstructionLoop            ;Only played if we DON'T spawn a worker
  2301.         SelfRepairFromDamageLoop     = NoSound                        ;This doesn't cause an animation, so don't bother playing a sound
  2302.         SelfRepairFromRubbleLoop    = WallConstructionLoop
  2303.     End
  2304.  
  2305.     Body                = StructureBody ModuleTag_05
  2306.         MaxHealth                = DWARVEN_WALLCATAPULT_SMALL_HEALTH
  2307.         MaxHealthDamaged        = DWARVEN_WALLCATAPULT_SMALL_HEALTH_DAMAGED
  2308.         MaxHealthReallyDamaged    = DWARVEN_WALLCATAPULT_SMALL_HEALTH_REALLY_DAMAGED
  2309.     End
  2310.  
  2311.     Behavior = InheritUpgradeCreate ModuleTag_InheritStonework
  2312.         Radius            = DWARVEN_FORTRESS_WALL_EFFECTIVE_RADIUS
  2313.         Upgrade            = Upgrade_DwarvenFortressDwarvenStonework
  2314.         ObjectFilter    = ANY +DwarvenFortressCitadel
  2315.     End
  2316.  
  2317.     Behavior = AttributeModifierUpgrade ModuleTag_Reinforced
  2318.         TriggeredBy                = Upgrade_DwarvenFortressDwarvenStonework
  2319.         AttributeModifier        = DwarvenStoneworkExpansion_Bonus
  2320.         CustomAnimAndDuration    = AnimState:UPGRADE_NUMENOR_STONEWORK AnimTime:0
  2321.     End
  2322.  
  2323.     Behavior = ModelConditionUpgrade ModuleTag_ShowTheStones
  2324.         TriggeredBy            = Upgrade_DwarvenFortressDwarvenStonework        
  2325.         AddConditionFlags    = UPGRADE_NUMENOR_STONEWORK
  2326.         Permanent            = Yes
  2327.     End
  2328.  
  2329.     //Catapult Behaviors
  2330.     Behavior = ProductionUpdate ProductionUpdateModuleTag
  2331.     End
  2332.     Behavior = GrantUpgradeCreate ModuleTag_ActLikeAnOldUpgrade
  2333.         UpgradeToGrant = Upgrade_TrebuchetTurret
  2334.         GiveOnBuildComplete = Yes // The ExemptStatus UnderConstruction hack doesn't work on foundation buildings.
  2335.     End
  2336.     Behavior = CommandSetUpgrade ModueTag_TrebCommandSet
  2337.         TriggeredBy            = Upgrade_TrebuchetTurret
  2338.         ConflictsWith        = Upgrade_HasWallTrebuchet 
  2339.         CommandSet            = DwarvenUpgradeCommandSetBuyNewCatapult
  2340.     End
  2341.     Behavior = CommandSetUpgrade ModueTag_TrebCommandSet3
  2342.         TriggeredBy            = Upgrade_HasWallTrebuchet Upgrade_TrebuchetTurret
  2343.         CommandSet            = SellableCommandSet
  2344.         RequiresAllTriggers    = Yes
  2345.     End
  2346.     Behavior = ObjectCreationUpgrade MakeTheFreeTreb
  2347.         TriggeredBy        = Upgrade_TrebuchetTurret
  2348.         Delay            = 0.0
  2349.         
  2350.         RemoveUpgrade    = Upgrade_WallTrebuchetButtonEnable
  2351.         GrantUpgrade    = Upgrade_HasWallTrebuchet
  2352.         DestroyWhenSold = Yes
  2353.         DeathAnimAndDuration = AnimState:DEATH_2 AnimTime:999999
  2354.         Offset            = X:0.0 Y:0.0 Z:51.0
  2355.     End
  2356.     Behavior = ObjectCreationUpgrade MakeTheFreeTreb2
  2357.         TriggeredBy        = Upgrade_HasWallTrebuchet
  2358.         ConflictsWith    = Upgrade_OpenGarrison Upgrade_PosternGate
  2359.         Delay            = 0.0
  2360.         
  2361.         RemoveUpgrade    = Upgrade_WallTrebuchetButtonEnable
  2362.         ThingToSpawn    = DwarvenWallCatapult
  2363.         Offset            = X:0.0 Y:0.0 Z:51.0
  2364.         FadeInTime        = 600
  2365.     End
  2366.     Behavior = SlaveWatcherBehavior WatchTheTreb
  2367.         RemoveUpgrade        = Upgrade_HasWallTrebuchet            //when our slave dies, remove this upgrade, so we can get the upgrade again.
  2368.         GrantUpgrade        = Upgrade_WallTrebuchetButtonEnable    //when our slave dies, enable the button that allows us to buy a new one
  2369.         ShareUpgrades        = Yes                                //So He'll get our Flaming Munitions
  2370.     End
  2371.  
  2372.     Behavior                = SlowDeathBehavior ModuleTag_SlowDeath
  2373.         DeathTypes            = ALL
  2374.         DestructionDelay    = 5000
  2375.     End
  2376.  
  2377.          
  2378.     GeometryIsSmall            = No
  2379.  
  2380.     Geometry              = BOX
  2381.     GeometryMajorRadius   = 8.0        ; 10.0 
  2382.     GeometryMinorRadius   = 20.0    ; 
  2383.     GeometryHeight        = 40.0    ; 53.0
  2384.     GeometryIsSmall       = No
  2385.     
  2386.     AdditionalGeometry        = CYLINDER
  2387.     GeometryMajorRadius       = 25.0 
  2388. //    GeometryMinorRadius       = 25.0 
  2389.     GeometryHeight            = 50.0
  2390.     
  2391.     Shadow                    = SHADOW_VOLUME
  2392.     BuildCompletion            = PLACED_BY_PLAYER
  2393. End
  2394.  
  2395.  
  2396. ;---------------------------------------------
  2397. Object DwarvenWallHubSmall
  2398.   
  2399.   ; *** ART Parameters ***
  2400.   
  2401.       SelectPortrait = BPDWall_WallHub
  2402.   
  2403.     Draw = W3DScriptedModelDraw ModuleTag_Draw
  2404.         OkToChangeModelColor  = Yes
  2405.         UseStandardModelNames = Yes
  2406.         DefaultModelConditionState
  2407.             Model = DBWallRmprtN
  2408.         End
  2409.  
  2410.         ModelConditionState    = UPGRADE_NUMENOR_STONEWORK ACTIVELY_BEING_CONSTRUCTED
  2411.             Model    = DBWallRmprtN_A
  2412.             Texture    = DBFortress1.tga DBFortress_U.tga
  2413.         End
  2414.  
  2415.         ModelConditionState = SNOW ACTIVELY_BEING_CONSTRUCTED
  2416.             Model    = DBWallRmprtN_A        
  2417.             Texture = DBFortress1.tga DBFortress1_Snow.tga
  2418.         End 
  2419.         
  2420.         ModelConditionState = ACTIVELY_BEING_CONSTRUCTED
  2421.             Model            = DBWallRmprtN_A
  2422.             ParticleSysBone = NONE BuildingContructDust
  2423.         End
  2424.  
  2425.         AnimationState = ACTIVELY_BEING_CONSTRUCTED
  2426.             Animation                    = UpAndStill
  2427.                 AnimationName            = DBWallRmprtN_A.DBWallRmprtN_A
  2428.                 AnimationMode            = MANUAL
  2429.             End
  2430.             BeginScript
  2431.                 CurDrawablePlaySound("GondorBarracksBeginConstruction")
  2432.             EndScript
  2433.         End
  2434.         
  2435.         ;--damaged building
  2436.       
  2437.         ModelConditionState  = DAMAGED
  2438.             Model         = DBWallRmprtN_D1 
  2439.         End
  2440.         AnimationState = DAMAGED
  2441.             EnteringStateFX    = FX_BuildingDamaged ;FX_HubDamaged
  2442.         End        
  2443.         
  2444.         ModelConditionState  = REALLYDAMAGED
  2445.             Model         = DBWallRmprtN_D2
  2446.         End
  2447.         
  2448.         AnimationState = REALLYDAMAGED
  2449.               Animation                =    RubbleAnimation
  2450.                 AnimationName        =     DBWallRmprtN_D2.DBWallRmprtN_D2
  2451.                 AnimationMode        =    ONCE
  2452.               End
  2453.             EnteringStateFX    = FX_BuildingReallyDamaged ;FX_HubDamaged
  2454.         End
  2455.  
  2456.         ModelConditionState  = COLLAPSING
  2457.             Model         = DBWallRmprtN_D3
  2458.         End
  2459.         
  2460.         AnimationState = COLLAPSING
  2461.               Animation                =    RubbleAnimation
  2462.                 AnimationName        =     DBWallRmprtN_D3.DBWallRmprtN_D3
  2463.                 AnimationMode        =    ONCE
  2464.               End
  2465.               EnteringStateFX    = FX_StructureMediumCollapse
  2466.               ParticleSysBone NONE HubDestructionDust
  2467.         End
  2468.  
  2469.  
  2470.         ModelConditionState  = DYING
  2471.             Model         = DBWallRmprtN_D3
  2472.         End
  2473.         
  2474.         AnimationState = DYING
  2475.               Animation                =    RubbleAnimation
  2476.                 AnimationName        =     DBWallRmprtN_D3.DBWallRmprtN_D3
  2477.                 AnimationMode        =    ONCE
  2478.               End
  2479.               EnteringStateFX    = FX_StructureMediumCollapse
  2480.               ParticleSysBone NONE HubDestructionDust
  2481.         End
  2482.  
  2483.  
  2484.         ModelConditionState  = RUBBLE
  2485.             Model         = None  
  2486.         End  
  2487.         
  2488.         ModelConditionState  = POST_RUBBLE
  2489.             Model         = NONE
  2490.         End
  2491.         
  2492.         AnimationState = POST_RUBBLE
  2493.         End
  2494.  
  2495.         ModelConditionState  = POST_COLLAPSE
  2496.             Model         = None
  2497.         End
  2498.         
  2499.         AnimationState = POST_COLLAPSE
  2500.         End 
  2501.  
  2502.         ModelConditionState    = UPGRADE_NUMENOR_STONEWORK
  2503.             Model    = DBWallRmprtN
  2504.             Texture    = DBFortress1.tga DBFortress_U.tga
  2505.         End
  2506.         
  2507.         ModelConditionState = SNOW
  2508.             Model    = DBWallRmprtN        
  2509.             Texture = DBFortress1.tga DBFortress1_Snow.tga
  2510.         End 
  2511.         
  2512.     End
  2513.  
  2514.     Draw = W3DFloorDraw ModuleTag_DrawFloor    
  2515.            StaticModelLODMode = yes ; Will append M or L to the skin name depending on GameLOD
  2516.           ModelName = DBWallRmprtNBib
  2517.           WeatherTexture        = SNOWY GBWall_Bib_Snow.tga 
  2518.           HideIfModelConditions    =    AWAITING_CONSTRUCTION
  2519.           HideIfModelConditions    =    PARTIALLY_CONSTRUCTED
  2520.     End
  2521.          
  2522.     ; ***DESIGN parameters ***
  2523.     DisplayName         = OBJECT:DwarvenWallHub
  2524.     Side                = Dwarves
  2525.     EditorSorting       = STRUCTURE
  2526.     ThreatLevel = 1.0
  2527.     ThreatBreakdown ModuleTag_DetailedThreat
  2528.         AIKindOf = WALL
  2529.     End
  2530.      
  2531.     BuildCost           = DWARVEN_WALLHUB_SMALL_BUILDCOST
  2532.     BuildTime           = DWARVEN_WALLHUB_SMALL_BUILDTIME           ; in seconds
  2533.     VisionRange         = DWARVEN_WALLHUB_SMALL_VISION_RANGE          ; Shroud clearing distance
  2534.     ShroudClearingRange = DWARVEN_WALLHUB_SMALL_SHROUD_CLEAR
  2535.  
  2536.     CommandSet = DwarvenCastleWallHubSmallCommandSet
  2537.         
  2538.         ArmorSet
  2539.         Conditions        = None
  2540.         Armor             = DwarvenWallArmor
  2541.         DamageFX          = None
  2542.     End
  2543.         
  2544.   ; *** AUDIO Parameters ***
  2545.  
  2546.     #include "..\..\..\Includes\StandardBuildingEvaEvents.inc"
  2547.  
  2548.     VoiceSelect                        = NeutralWallHubSelect
  2549.     VoiceSelectUnderConstruction    = BuildingGoodVoiceSelectUnderConstruction
  2550.  
  2551.     SoundOnDamaged                    = BuildingLightDamageStone
  2552.     SoundOnReallyDamaged            = BuildingHeavyDamageStone
  2553.  
  2554.     UnitSpecificSounds
  2555.         UnderConstruction        = BuildingConstructionLoop      ;Built first time
  2556.         ; UnderRepairFromDamage    = NoSound                        ; Repaired No animation on the building, so don't bother playing sound
  2557.         UnderRepairFromRubble    = BuildingConstructionLoop        ;Repaired from completely destroyed (not used???)
  2558.     End
  2559.  
  2560.     CampnessValue = CAMPNESS_WALL
  2561.  
  2562.     ; *** ENGINEERING Parameters ***
  2563.     RadarPriority       = STRUCTURE
  2564.     KindOf              = PRELOAD STRUCTURE SELECTABLE IMMOBILE SCORE WALL_HUB WALL_UPGRADE MADE_OF_STONE    
  2565.     
  2566. //    Behavior            = GettingBuiltBehavior GetBuiltBehaviorTag
  2567. //        WorkerName          = DwarvenWorkerNoSelect
  2568. //    End
  2569.      
  2570.     Behavior                        = GettingBuiltBehavior ModuleTag_04
  2571.         UseSpawnTimerWithoutWorker         = Yes
  2572.         SpawnTimer    = DEFAULT_STRUCTURE_HEALDELAY
  2573.         RebuildTimeSeconds            = 30
  2574.         SelfBuildingLoop            = WallConstructionLoop            ;Only played if we DON'T spawn a worker
  2575.         SelfRepairFromDamageLoop     = WallConstructionLoop
  2576.         SelfRepairFromRubbleLoop    = WallConstructionLoop
  2577.     End
  2578.  
  2579.     Body                = StructureBody ModuleTag_05
  2580.         MaxHealth         = DWARVEN_WALLHUB_SMALL_HEALTH
  2581.     End
  2582.      
  2583.     Behavior                = SlowDeathBehavior ModuleTag_SlowDeath
  2584.         DeathTypes            = ALL
  2585.         DestructionDelay    = 5000
  2586.     End
  2587.                         
  2588.  
  2589.     Behavior = WallHubBehavior ModuleTag_Build_A_Span
  2590.     
  2591.         Options = OPTION_ONE
  2592.         MaxBuildoutDistance = MEN_FORTRESS_WALL_EFFECTIVE_RADIUS
  2593.         
  2594.         StaggeredBuildFactor = STANDARD_WALL_STAGGERED_BUILD_FACTOR
  2595.         
  2596.         MaxBuildoutDistance = 1500.0
  2597.     
  2598.         ;;This defines the pattern built on flat terrain
  2599.         SegmentTemplateName = DwarvenWallSegmentSmall
  2600.         SegmentTemplateName = DwarvenWallSegmentSmall
  2601.         SegmentTemplateName = DwarvenWallSegmentSmall
  2602.         SegmentTemplateName = DwarvenWallSegmentSmall
  2603.         SegmentTemplateName = DwarvenWallSegmentSmall
  2604.         SegmentTemplateName = DwarvenWallSegmentSmall
  2605.         SegmentTemplateName = DwarvenWallSegmentSmall
  2606.         SegmentTemplateName = DwarvenWallSegmentSmall
  2607.         SegmentTemplateName = DwarvenWallHubSmall
  2608.         
  2609.         BuilderRadius = 20
  2610.  
  2611.         HubCapTemplateName = DwarvenWallHubSmall
  2612.         DefaultSegmentTemplateName = DwarvenWallSegmentSmall
  2613.         
  2614.         CliffCapTemplateName = DwarvenWallCliffCap        
  2615.         ;ShoreCapTemplateName = [NAME]        
  2616.         ;BorderCapTemplateName = [NAME]        
  2617.         ;ElevatedSegmentTemplateName = [NAME]
  2618.         
  2619.     End
  2620.  
  2621.     Behavior = TerrainResourceBehavior ModuleTag_NewMoneyDeadSpot
  2622.         Radius            = 60        ;// How far we try to claim ground
  2623.         MaxIncome        = 0            ;// If we were to get all we wanted, how much we would earn.  Linear slope to 0 at 0% claim
  2624.         IncomeInterval    = 999999    ;// How often (in msec) we give that much money
  2625.         HighPriority    = Yes        ;// A high priority claim gets to pretend it was there first.
  2626.         Visible = No         ;// Don't show decal when a resource building is selected.
  2627.     End
  2628.  
  2629.         Behavior = InheritUpgradeCreate ModuleTag_InheritStonework
  2630.         Radius = DWARVEN_FORTRESS_WALL_EFFECTIVE_RADIUS
  2631.         Upgrade = Upgrade_DwarvenFortressDwarvenStonework
  2632.         ObjectFilter = ANY +DwarvenFortressCitadel
  2633.     End
  2634.  
  2635.     Behavior = AttributeModifierUpgrade ModuleTag_Reinforced
  2636.         TriggeredBy                = Upgrade_DwarvenFortressDwarvenStonework
  2637.         AttributeModifier        = DwarvenStoneworkExpansion_Bonus
  2638.         CustomAnimAndDuration    = AnimState:UPGRADE_NUMENOR_STONEWORK AnimTime:0
  2639.     End
  2640.  
  2641.     Behavior = ModelConditionUpgrade ModuleTag_ShowTheStones
  2642.         TriggeredBy            = Upgrade_DwarvenFortressDwarvenStonework        
  2643.         AddConditionFlags    = UPGRADE_NUMENOR_STONEWORK
  2644.         Permanent            = Yes
  2645.     End
  2646.  
  2647.  
  2648.     Geometry                  = CYLINDER
  2649.     GeometryMajorRadius       = 20.0 ; 
  2650.     GeometryMinorRadius       = 20.0 ; 
  2651.     GeometryHeight            = 70.0
  2652.     GeometryIsSmall           = No
  2653.  
  2654.     ; additional geometry, exactly same as the wall piece - if this isn't here we might get holes!    
  2655.     AdditionalGeometry      = BOX
  2656.     GeometryMajorRadius   = 8.0        ; 10.0 
  2657.     GeometryMinorRadius   = 20.0    ; 
  2658.     GeometryHeight        = 40.0    ; 53.0
  2659.     GeometryIsSmall       = No
  2660.         
  2661.     GeometryContactPoint     = X:35        Y:35    Z:0            Repair
  2662.     GeometryContactPoint     = X:35        Y:0        Z:0            Repair
  2663.     GeometryContactPoint     = X:22.954        Y:15.951    Z:0
  2664.     GeometryContactPoint     = X:5.435        Y:-23.279    Z:0
  2665.     GeometryContactPoint    = X:-0.459        Y:-0.275    Z:116.828    Swoop
  2666.     
  2667.     Shadow                    = SHADOW_VOLUME
  2668.     BuildCompletion            = PLACED_BY_PLAYER
  2669.     
  2670. End
  2671.  
  2672. ;--------------------------------------------------------
  2673.  
  2674. Object DwarvenWallCliffCap
  2675.  
  2676.     SelectPortrait  =  BPDWall
  2677.   
  2678.   ; *** ART Parameters ***
  2679.     Draw = W3DScriptedModelDraw ModuleTag_Draw
  2680.         OkToChangeModelColor  = Yes
  2681.         UseStandardModelNames = Yes
  2682.         DefaultModelConditionState
  2683.             Model = DBWallNE
  2684.         End
  2685.                 
  2686.  
  2687.         //------------ New Build Up States coming soon.     
  2688.         ModelConditionState = UPGRADE_NUMENOR_STONEWORK SNOW AWAITING_CONSTRUCTION
  2689.             Model = DBWallNE_A
  2690.             Texture    = DBFortress1.tga DBFortress_U.tga
  2691.         End            
  2692.         ModelConditionState = SNOW AWAITING_CONSTRUCTION
  2693.             Model = DBWallNE_A
  2694.             Texture    = DBFortress1.tga DBFortress_Snow.tga
  2695.         End
  2696.         ModelConditionState   = AWAITING_CONSTRUCTION 
  2697.             Model               = DBWallNE_A
  2698.         End
  2699.         AnimationState        = AWAITING_CONSTRUCTION
  2700.             Animation           =  DBWallNE_A
  2701.                 AnimationName     =  DBWallNE_A.DBWallNE_A
  2702.                 AnimationMode     = MANUAL
  2703.                 AnimationBlendTime = 0
  2704.             End
  2705.             Flags                  = START_FRAME_FIRST
  2706.         End
  2707.  
  2708.         ModelConditionState    = UPGRADE_NUMENOR_STONEWORK ACTIVELY_BEING_CONSTRUCTED PARTIALLY_CONSTRUCTED
  2709.             Model    = DBWallNE_A
  2710.             Texture    = DBFortress1.tga DBFortress_U.tga
  2711.         End
  2712.         ModelConditionState = SNOW ACTIVELY_BEING_CONSTRUCTED PARTIALLY_CONSTRUCTED
  2713.             Model = DBWallNE_A
  2714.             Texture    = DBFortress1.tga DBFortress1_Snow.tga
  2715.         End
  2716.         ModelConditionState   = ACTIVELY_BEING_CONSTRUCTED PARTIALLY_CONSTRUCTED
  2717.             Model               = DBWallNE_A
  2718.         End
  2719.         AnimationState        = ACTIVELY_BEING_CONSTRUCTED PARTIALLY_CONSTRUCTED
  2720.             Animation           = DBWallNE_A
  2721.                 AnimationName     = DBWallNE_A.DBWallNE_A
  2722.                 AnimationMode     = MANUAL
  2723.                 AnimationBlendTime = 0
  2724.             End
  2725.             Flags                  = START_FRAME_FIRST
  2726.             StateName              = BeingConstructed
  2727.             ParticleSysBone   = NONE WallConstructDust FollowBone:Yes
  2728.         End
  2729.         
  2730.  
  2731.         ;--damaged building
  2732.       
  2733.         ModelConditionState  = DAMAGED
  2734.             Model         = DBWallNE_D1
  2735.         End
  2736.         
  2737.         AnimationState = DAMAGED
  2738.             EnteringStateFX    = FX_WallDamaged
  2739.         End        
  2740.         
  2741.         ModelConditionState  = REALLYDAMAGED
  2742.             Model         = DBWallNE_D2
  2743.         End
  2744.         
  2745.         AnimationState = REALLYDAMAGED
  2746.               Animation                =    RubbleAnimation
  2747.                 AnimationName        =     DBWallNE_D2.DBWallNE_D2
  2748.                 AnimationMode        =    ONCE
  2749.               End
  2750.             EnteringStateFX    = FX_WallDamaged
  2751.         End
  2752.  
  2753.         ModelConditionState  = COLLAPSING
  2754.             Model         = DBWallNE_D3
  2755.         End
  2756.         
  2757.         AnimationState = COLLAPSING
  2758.               Animation                =    RubbleAnimation
  2759.                 AnimationName        =     DBWallNE_D3.DBWallNE_D3
  2760.                 AnimationMode        =    ONCE
  2761.               End
  2762.               ParticleSysBone NONE WallDestructionDust
  2763.             EnteringStateFX            = FX_StructureMediumCollapse
  2764.         End
  2765.  
  2766.         ModelConditionState  = RUBBLE
  2767.             Model         = None    ;GBWall_Rubble  
  2768.         End  
  2769.         AnimationState = RUBBLE
  2770.         End
  2771.         
  2772.         ModelConditionState  = POST_RUBBLE
  2773.             Model         = None    ;GBWall_Rubble
  2774.         End
  2775.         AnimationState = POST_RUBBLE
  2776.         End
  2777.  
  2778.         ModelConditionState  = POST_COLLAPSE
  2779.             Model         = None
  2780.         End
  2781.         AnimationState = POST_COLLAPSE
  2782.         End 
  2783.         
  2784.         ModelConditionState    = UPGRADE_NUMENOR_STONEWORK
  2785.             Model    = DBWallNE
  2786.             Texture    = DBFortress1.tga DBFortress_U.tga
  2787.         End
  2788.         ModelConditionState = SNOW  
  2789.             Model = DBWallNE
  2790.             Texture    = DBFortress1.tga DBFortress1_snow.tga
  2791.         End            
  2792.     End
  2793.    
  2794. ;    Draw = W3DFloorDraw ModuleTag_DrawFloor    
  2795. ;            StaticModelLODMode = yes ; Will append M or L to the skin name depending on GameLOD
  2796. ;          ModelName = GBWallN_Bib
  2797. ;    End
  2798.   
  2799.   ; ***DESIGN parameters ***
  2800.   DisplayName         = OBJECT:GondorCastleWallSegment
  2801.   Side                = Men
  2802.   EditorSorting       = STRUCTURE
  2803.   ThreatLevel = 1.0
  2804.   ThreatBreakdown ModuleTag_DetailedThreat
  2805.     AIKindOf = WALL
  2806.   End
  2807.  
  2808.  
  2809.     CommandSet            = DwarvenWallCliffCapCommandSet
  2810.   
  2811.   ArmorSet
  2812.         Conditions        = None
  2813.         Armor             = DwarvenWallArmor
  2814.         DamageFX          = None
  2815.     End
  2816.  
  2817.     BuildCost           = MEN_WALLSEGMENT_SMALL_BUILDCOST
  2818.     BuildTime           = MEN_WALLSEGMENT_SMALL_BUILDTIME
  2819.     VisionRange         = MEN_WALLSEGMENT_SMALL_VISION_RANGE
  2820.     ShroudClearingRange = MEN_WALLSEGMENT_SMALL_SHROUD_CLEAR
  2821.  
  2822.     ; *** AUDIO Parameters ***
  2823.  
  2824.     #include "..\..\..\Includes\StandardBuildingEvaEvents.inc"
  2825.  
  2826.     VoiceSelectUnderConstruction    = BuildingGoodVoiceSelectUnderConstruction
  2827.  
  2828.     SoundOnDamaged                    = BuildingLightDamageStone
  2829.     SoundOnReallyDamaged            = BuildingHeavyDamageStone
  2830.  
  2831.     UnitSpecificSounds
  2832.         UnderConstruction        = WallConstructionLoop      ;Built first time
  2833.         ; UnderRepairFromDamage    = NoSound                    ; Repaired No animation on the building, so don't bother playing sound
  2834.         UnderRepairFromRubble    = WallConstructionLoop        ;Repaired from completely destroyed (not used???)
  2835.     End
  2836.  
  2837.     CampnessValue = CAMPNESS_WALL
  2838.  
  2839.     ; *** ENGINEERING Parameters ***
  2840.     RadarPriority       = STRUCTURE
  2841.     KindOf              = PRELOAD STRUCTURE SELECTABLE IMMOBILE SCORE DEFENSIVE_WALL MADE_OF_STONE CAN_CAST_REFLECTIONS
  2842.  
  2843.     Behavior                        = GettingBuiltBehavior ModuleTag_04
  2844.         UseSpawnTimerWithoutWorker         = Yes
  2845.         SpawnTimer    = DEFAULT_STRUCTURE_HEALDELAY
  2846.         RebuildTimeSeconds            = 30
  2847.         SelfBuildingLoop            = WallConstructionLoop            ;Only played if we DON'T spawn a worker
  2848.         SelfRepairFromDamageLoop     = NoSound
  2849.         SelfRepairFromRubbleLoop    = WallConstructionLoop
  2850.     End
  2851.  
  2852.     Body                = StructureBody ModuleTag_05
  2853.         MaxHealth         = MEN_WALLSEGMENT_SMALL_HEALTH
  2854.     End
  2855.  
  2856.     // These should always appear together on wall segments
  2857.     Behavior = KeepObjectDie ModuleTag_IWantRubble 
  2858.         DeathTypes            = ALL -SUICIDED
  2859.     End
  2860.     Behavior            = SlowDeathBehavior ModuleTag_SlowDeath
  2861.         DeathTypes            = NONE +SUICIDED
  2862.         DestructionDelay    = 5000
  2863.     End                                                
  2864.     // These should always appear together on wall segments
  2865.          
  2866. ;    Behavior            = DestroyDie ModuleTag_07
  2867. ;        ;nothing
  2868. ;    End
  2869.  
  2870.     Behavior = InheritUpgradeCreate ModuleTag_InheritStonework
  2871.         Radius = DWARVEN_FORTRESS_WALL_EFFECTIVE_RADIUS
  2872.         Upgrade = Upgrade_DwarvenFortressDwarvenStonework
  2873.         ObjectFilter = ANY +DwarvenFortressCitadel
  2874.     End
  2875.  
  2876.     Behavior = AttributeModifierUpgrade ModuleTag_Reinforced
  2877.         TriggeredBy                = Upgrade_DwarvenFortressDwarvenStonework
  2878.         AttributeModifier        = DwarvenStoneworkExpansion_Bonus
  2879.         CustomAnimAndDuration    = AnimState:UPGRADE_NUMENOR_STONEWORK AnimTime:0
  2880.     End
  2881.  
  2882.     Behavior = ModelConditionUpgrade ModuleTag_ShowTheStones
  2883.         TriggeredBy            = Upgrade_DwarvenFortressDwarvenStonework        
  2884.         AddConditionFlags    = UPGRADE_NUMENOR_STONEWORK
  2885.         Permanent            = Yes
  2886.     End
  2887.  
  2888.  
  2889.     Geometry                  = BOX
  2890.     GeometryMajorRadius       = 10.0 
  2891.     GeometryMinorRadius       = 40.0   
  2892.     GeometryHeight            = 80
  2893.     GeometryIsSmall            = No
  2894.     GeometryOffset            = X:0 Y:-20 Z:-40
  2895.   
  2896.   
  2897.   Shadow                = SHADOW_VOLUME
  2898.   BuildCompletion     = PLACED_BY_PLAYER
  2899. End
  2900.  
  2901.  
  2902.  
  2903.