<?xml version="1.0" standalone="no" ?>
<unit>
	<!-- *** parameters *** -->
	<parameters>
		<size value="2" />
		<height value="5" />
		<max-hp value="10000" regeneration="0"/>
		<max-ep value="0" />
		<armor value="0" />
		<armor-type value="stone"/>				
		<sight value="15" />
		<time value="10" />
		<multi-selection value="false" />
		<cellmap value="true">
			<row value="11"/>
			<row value="11"/>
		</cellmap>
		<levels/>
		<fields>
			<field value="land" />
		</fields>
		<properties>
			<property value="burnable"/>
		</properties>
		<light enabled="true" red="0.8" green="0.8" blue="0.5"/>
		<unit-requirements/>
		<upgrade-requirements />
		<resource-requirements>
			<resource name="pieces" amount="1" />
			<resource name="stone" amount="140" />
		</resource-requirements>
		<resources-stored>			
			<resource name= "stone" amount="200"/>				
			<resource name= "pieces" amount="10"/>	
		</resources-stored>
		<image path="images/rook.bmp" />
		<image-cancel path="../rook/images/cancel.bmp"/>
		<meeting-point value="true" image-path="../rook/images/meeting_point.bmp"/>
		<selection-sounds enabled="true">
			<sound path="../rook/sounds/click.wav" />
		</selection-sounds>
		<command-sounds enabled="true">
			<sound path="../rook/sounds/click.wav" />
		</command-sounds>
	</parameters>
	
	<!-- *** skills *** -->
	<skills>

		<skill>
			<type value="stop" />
			<name value="stop_skill"/>		
			<ep-cost value="0" />
			<speed value="300" />
			<anim-speed value="100" />
			<animation path="models/castle.g3d" />
			<sound enabled="false" />
		</skill>
		
		<!--skill>
			<type value="be_built" />
			<name value="be_built_skill"/>		
			<ep-cost value="0" />
			<speed value="300" />
			<anim-speed value="300" />
			<animation path="models/castle.g3d" />
			<sound enabled="false" />
		</skill-->	
		
		<skill>
			<type value="produce" />
			<name value="produce_skill"/>		
			<ep-cost value="0" />
			<speed value="300" />
			<anim-speed value="100" />
			<animation path="models/castle.g3d" />
			<sound enabled="false" />
		</skill>

		<skill>
			<type value="attack"/>
			<name value="attack_skill"/>		
			<ep-cost value="0"/>
			<speed value="80"/>
			<anim-speed value="90"/>
			<animation path="models/castle.g3d"/>
			<sound enabled="false"/>
			<attack-strenght value="120"/>
			<attack-var value="50"/>
			<attack-range value="12"/>
			<attack-type value="piercing"/>
			<attack-start-time value="0.3"/>
			<attack-fields>
				<field value="land"/>
				<field value="air"/>
			</attack-fields>
			<projectile value="true">
				<particle value="true" path="particle_proj.xml"/>
				<sound enabled="false"/>
			</projectile>
			<splash value="false"/>
		</skill>	
		
		<skill>
			<type value="die" />
			<name value="die_skill"/>		
			<ep-cost value="0" />
			<speed value="300" />
			<anim-speed value="300" />
			<animation path="models/castle.g3d" />
			<sound enabled="false"/>			
			<fade value="true"/>
		</skill>

		<skill>
			<type value="morph"/>
			<name value="rook"/>		
			<ep-cost value="0"/>
			<speed value="500"/>
			<anim-speed value="33"/>
			<animation path="models/rook_shrink.g3d"/>
			<sound enabled="false"/>
		</skill>
		
		<skill>
			<type value="upgrade" />
			<name value="upgrade_skill"/>		
			<ep-cost value="0" />
			<speed value="300" />
			<anim-speed value="150" />
			<animation path="models/castle.g3d" />
			<sound enabled="false" start-time="0.3">
				<!--sound-file path="sounds/anvil1.wav"/-->
			</sound>
		</skill>

	</skills>
	
	<!-- *** commands *** -->
	<commands>

		<command>
			<type value="stop"/>
			<name value="attack_off"/>
			<image path="images/defense_tower_attack_off.bmp"/>
			<unit-requirements/>
			<upgrade-requirements/>
			<stop-skill value="stop_skill"/>
		</command>

		<command>
			<type value="attack_stopped"/>
			<name value="attack_on"/>
			<image path="images/defense_tower_attack_on.bmp"/>
			<unit-requirements/>
		        <upgrade-requirements>
		        	<upgrade name="castle_attack"/>
		        </upgrade-requirements>
			<attack-skill value="attack_skill"/>
                        <stop-skill value="stop_skill"/>
		</command>
		
		<command>
			<type value="upgrade"/>
			<name value="upgrade_castle_attack" />
			<image path="../../upgrades/castle_attack/images/stables.bmp" />
			<unit-requirements />
			<upgrade-requirements />
			<upgrade-skill value="upgrade_skill"/>
			<produced-upgrade name="castle_attack"/>
		</command>
		
		<command>
			<type value="upgrade"/>
			<name value="upgrade_chess" />
			<image path="../../upgrades/chess/images/blade.bmp" />
			<unit-requirements />
			<upgrade-requirements />
			<upgrade-skill value="upgrade_skill"/>
			<produced-upgrade name="chess"/>
		</command>

		<command>
			<type value="upgrade"/>
			<name value="upgrade_queens" />
			<image path="../../upgrades/queens/images/emp.bmp" />
			<unit-requirements />
			<upgrade-requirements />
			<upgrade-skill value="upgrade_skill"/>
			<produced-upgrade name="queens"/>
		</command>

		<command>
			<type value="upgrade"/>
			<name value="upgrade_stone_pieces" />
			<image path="../../upgrades/stone_pieces/images/shield1.bmp" />
			<unit-requirements />
			<upgrade-requirements />
			<upgrade-skill value="upgrade_skill"/>
			<produced-upgrade name="stone_pieces"/>
		</command>
	
		<command>
			<type value="produce"/>
			<name value="produce_pawn" />
			<image path="../pawn/images/pawn.bmp" />
			<unit-requirements />
			<upgrade-requirements />
			<produce-skill value="produce_skill"/>
			<produced-unit name="pawn"/>
		</command>	

		<command>
			<type value="morph"/>
			<name value="un_castle"/>
			<image path="../rook/images/rook.bmp"/>
			<unit-requirements/>
		        <upgrade-requirements>
		        	<upgrade name="castle_attack"/>
		        </upgrade-requirements>
			<morph-skill value="rook"/>
			<morph-unit name= "rook"/>
			<discount value="100"/>
		</command>

	</commands>
</unit>
