<?xml version="1.0" encoding="utf-8"?>
<AssetDeclaration xmlns="uri:ea.com:eala:asset" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xi="http://www.w3.org/2001/XInclude">
	<Tags></Tags>
	<Includes>
		<Include
			type="all"
			source="ART:ABLifRec.w3x" />
		<Include
			type="all"
			source="ART:ABLifRec_D2.w3x" />
		<Include
			type="all"
			source="ART:ABLifRecD2_AN.w3x" />
		<Include
			type="all"
			source="ART:ABLifRec_D3.w3x" />
		<Include
			type="all"
			source="ART:ABLifRecD3_AN.w3x" />
		<Include
			type="all"
			source="ART:ABLFRecycling.xml" />
		<Include
			type="all"
			source="ART:ABLFRecycling_D.xml" />
			
		<!-- Base Object -->
		<Include
			type="instance"
			source="DATA:BaseObjects/BaseStructure.xml" />
	</Includes>
	<!-- PowerPlant -->
	<GameObject
		id="MG_Alien_LifeFormPlant"
		inheritFrom="BaseStructure"
		SelectPortrait="Portrait_LifeformRecyclingPlant"
		ButtonImage="Portrait_LifeformRecyclingPlant"
		Side="ALIEN"
		EditorSorting="STRUCTURE"
		Browser="REGION METAGAME ALIEN"
		BuildCost="100"
		BuildTime="1"
		PlacementViewAngle="315d"
		CommandSet="EmptyCommandSet"
		KindOf="STRUCTURE SELECTABLE IMMOBILE CAN_CAST_REFLECTIONS UNIQUE_UNIT AUTO_ACQUIRABLE_BY_AI NOT_AUTOACQUIRABLE COVER IGNORE_CAN_NOT_BUILD"
		RadarPriority="STRUCTURE"
		ProductionQueueType="MAIN_STRUCTURE"
		BuildPlacementTypeFlag="MAIN_STRUCTURE"
		EditorName="MG_Alien_LifeFormPlant"
		Description="Desc:MG_Alien_LifeFormPlant"
		TypeDescription="Type:MetaNODTemplePrime">
		<DisplayName
			xai:joinAction="Replace" xmlns:xai="uri:ea.com:eala:asset:instance">NAME:MG_Alien_LifeFormPlant</DisplayName>
		<ArmorSet
			Armor="AlienPowerProjectorArmor"
			DamageFX="FactionStructureDamageFX" />
		<SkirmishAIInformation
			BaseBuildingLocation="HOMEBASE" />
		<Draws>
			<ScriptedModelDraw
				id="ModuleTag_Draw"
				OkToChangeModelColor="true">
				<ModelConditionState
					ParseCondStateType="PARSE_DEFAULT">
					<Model
						Name="ABLifRec" />
					<ParticleSysBone
						BoneName="FXBone01"
						FXParticleSystemTemplate="AlienPowerPlant"
						FollowBone="true" />
					<ParticleSysBone
						BoneName="FXBone01"
						FXParticleSystemTemplate="AlienPowerPlantGlow"
						FollowBone="true" />
				</ModelConditionState>
				<ModelConditionState
					ParseCondStateType="PARSE_NORMAL"
					ConditionsYes="STRUCTURE_UNPACKING">
					<Model
						Name="ABLifRec" />
				</ModelConditionState>
				<ModelConditionState
					ParseCondStateType="PARSE_NORMAL"
					ConditionsYes="RUBBLE">
					<Model
						Name="ABLifRec_D3" />
				</ModelConditionState>
				<ModelConditionState
					ParseCondStateType="PARSE_NORMAL"
					ConditionsYes="REALLYDAMAGED">
					<Model
						Name="ABLifRec_D2" />
					<ParticleSysBone
						BoneName="FXBone01"
						FXParticleSystemTemplate="AlienPowerPlant"
						FollowBone="true" />
					<ParticleSysBone
						BoneName="FXBone01"
						FXParticleSystemTemplate="AlienPowerPlantGlow"
						FollowBone="true" />
					<ParticleSysBone
						BoneName="FXBone02"
						FXParticleSystemTemplate="AlienDamageFire01"
						FollowBone="true" />
					<ParticleSysBone
						BoneName="FXBone02"
						FXParticleSystemTemplate="AlienDamageFireGlow01"
						FollowBone="true" />
					<ParticleSysBone
						BoneName="FXBone02"
						FXParticleSystemTemplate="AlienDamageFireGlow02"
						FollowBone="true" />
				</ModelConditionState>
				<ModelConditionState
					ParseCondStateType="PARSE_NORMAL"
					ConditionsYes="DAMAGED">
					<Model
						Name="ABLFRecycling" />
					<Texture
						Original="ABLFRecycling"
						New="ABLFRecycling_D" />
					<ParticleSysBone
						BoneName="FXBone01"
						FXParticleSystemTemplate="AlienPowerPlant"
						FollowBone="true" />
					<ParticleSysBone
						BoneName="FXBone01"
						FXParticleSystemTemplate="AlienPowerPlantGlow"
						FollowBone="true" />
					<ParticleSysBone
						BoneName="FXBone02"
						FXParticleSystemTemplate="AlienDamageFire01"
						FollowBone="true" />
				</ModelConditionState>
				<AnimationState
					ParseCondStateType="PARSE_DEFAULT"
					StateName="STATE_bored">
				</AnimationState>
				<AnimationState
					ParseCondStateType="PARSE_NORMAL"
					ConditionsYes="STRUCTURE_UNPACKING">
				</AnimationState>
				<AnimationState
					ParseCondStateType="PARSE_NORMAL"
					ConditionsYes="RUBBLE"
					StateName="STATE_Rubble"
					Flags="START_FRAME_LAST">
					<Animation
						AnimationName="ABLifRec_D3"
						AnimationMode="MANUAL" />
					<Script>
						Prev = CurDrawablePrevAnimationState();
						if Prev ~= "STATE_Rubble" and Prev ~= "TRANS_IntoRubble" then
						CurDrawableSetTransitionAnimState("TRANS_IntoRubble")
						end
					</Script>
				</AnimationState>
				<AnimationState
					ParseCondStateType="PARSE_NORMAL"
					ConditionsYes="REALLYDAMAGED"
					StateName="STATE_ReallyDamaged"
					Flags="START_FRAME_LAST">
					<Animation
						AnimationName="ABLifRec_D2"
						AnimationMode="MANUAL" />
					<Script>
						Prev = CurDrawablePrevAnimationState();
						if Prev ~= "STATE_ReallyDamaged" and Prev ~= "TRANS_IntoReallyDamaged" then
						CurDrawableSetTransitionAnimState("TRANS_IntoReallyDamaged")
						end
					</Script>
				</AnimationState>

				<AnimationState
					ParseCondStateType="PARSE_TRANSITION"
					StateName="TRANS_IntoReallyDamaged">
					<Animation
						AnimationName="ABLifRec_D2"
						AnimationMode="ONCE"
						AnimationBlendTime="0" />
				</AnimationState>
				<AnimationState
					ParseCondStateType="PARSE_TRANSITION"
					StateName="TRANS_IntoRubble">
					<Animation
						AnimationName="ABLifRec_D3"
						AnimationMode="ONCE"
						AnimationBlendTime="0" />
				</AnimationState>
			</ScriptedModelDraw>

		</Draws>

		<Behaviors>
			<FXListBehavior
				id="ModuleTag_FXList">
				<DieMuxData
					DeathTypes="ALL" />
				<Event
					Index="onTransitionToDamaged"
					FX="FX_AlienBuildingDamagedM" />
				<Event
					Index="onTransitionToReallyDamaged"
					FX="FX_AlienBuildingDamagedM" />
				<Event
					Index="onTransitionToRubble"
					FX="FX_AlienBuildingRubbleM" />
			</FXListBehavior>
			<SlowDeath
				id="ModuleTag_Death"
				SinkDelay="3.0s"
				SinkRate="4.0"
				DestructionDelay="8.0s">
				<Sound Type="INITIAL" List="ALI_Building_Die" />
				<DieMuxData
					DeathTypes="ALL" />
			</SlowDeath>
			<StructureUnpackUpdate
				id="StructureUnpackUpdate"
				UnpackTime="2.0s" />
      <xi:include
				href="../../Includes/GenericBuildingRepair.xml" />
      <xi:include
				href="../../Includes/GenericEngineerContain.xml" />
      <xi:include
				href="../../Includes/AdvancedAlienBuildingDestruction.xml" />
      <xi:include
				href="../../Includes/AdvancedAlienBuildingSuicide.xml" />
      <!-- This needs to be in every Stategic Buildings XML
		            DO NOT CHANGE THE id. it must be the same in all files-->

		<MetaGameStratButtonInfo
				        id="ModuleTag_MetaGameStratButtonInfo"
				        MetaGameDescription="Desc:MG_Alien_LifeFormPlant"
				        MetaGameTypeDescription="Type:MetaAlienRiftGenerator"
				        >
				        <!-- you can list as many powers as you want here -->
				
						
					<Powers
						Image="Button_PlayerPowerAlienPlague"
						Title="NAME:PlayerPowerAlienPlague"
						TypeDescription="TYPE:PlayerPowerAlienPlague"
						Description="DESC:PlayerPowerAlienPlague" 
						MetaGameOp="SCRIN_POWER_ALIEN_PLAGUE"/>		

					<Powers
						Image="Button_PlayerPowerEradicate"
						Title="NAME:PlayerPowerEradicate"
						TypeDescription="TYPE:PlayerPowerEradicate"
						Description="DESC:PlayerPowerEradicate" 
						MetaGameOp="SCRIN_POWER_ERADICATE"/>		
		
						
      </MetaGameStratButtonInfo>	
		</Behaviors>
    <AI>
      <AIUpdate
				id="ModuleTag_AI" />
    </AI>
		<Body>
			<ActiveBody
				id="ModuleTag_Body"
				MaxHealth="4000.0" />
		</Body>
		<Geometry
			IsSmall="false">
			<Shape
				Type="CYLINDER"
				MajorRadius="41.5067"
				MinorRadius="41.5067"
				Height="9.5105">
				<Offset
					x="7.73712"
					y="-1.90735e-006"
					z="0.0" />
			</Shape>
			<Shape
				Type="CYLINDER"
				MajorRadius="19.0931"
				MinorRadius="19.0931"
				Height="38.605"
				ContactPointGeneration="INFANTRY">
				<Offset
					x="5.75443"
					y="-9.53674e-007"
					z="0.0" />
			</Shape>
		</Geometry>
		<AudioArrayVoice>
			<AudioEntry
				Sound="ALI_Reactor_Select"
				AudioType="voiceSelect" />
		</AudioArrayVoice>
		<AudioArraySound>
			<AudioEntry Sound="ALI_Building_LightDamage" AudioType="soundOnDamaged" />
			<AudioEntry Sound="ALI_Building_HeavyDamage" AudioType="soundOnReallyDamaged" />
			<AudioEntry Sound="ALI_Building_Placed" AudioType="soundUnderConstruction" />
		</AudioArraySound>
		<ShadowInfo
			Type="VOLUME" />
		<VisionInfo
			VisionRange="100"
			ShroudClearingRange="100" />
		<ProjectedBuildabilityInfo
			Radius="175"
			BuildPlacementTypes="MAIN_STRUCTURE OTHER_STRUCTURE" />
	</GameObject>
</AssetDeclaration>
