旧版 tactics



<!--	强制生产单位(无视人口限制,无视训练时间,受建造上限限制,建议使用<singleuse>1</singleuse>语句,使其只能生产一次。)	-->
	<action>
		<name stringid="69158">SpawnTest2</name>
		<type>Spawn</type>
		<rate type="Protoname">X.0</rate>
		<active>1</active>
		<singleuse>1</singleuse>
		<animationrate>1</animationrate>
		<persistent>1</persistent>
	</action>

<!--	自动生产单位1	-->
	<action>
		<name stringid="StringID">ActionName1</name>
		<type>Maintain</type>
		<rate type="Protoname">X.0</rate>
		<persistent>1</persistent>
		<active>1</active>
		<singleuse>0</singleuse>
	</action>
	<tactic>
		<action>ActionName1</action>
	</tactic>

<!--	自动生产单位2	-->
	<action>
		<name stringid="68982">SpawnUnit</name>
		<type>DanceBonus</type>
		<active>1</active>
		<persistent>1</persistent>
		<dancebonustype>UnitSpawn</dancebonustype>
		<modifyprotoid>Protoname</modifyprotoid>
		<modifymultiplier>0.065</modifymultiplier>
		<modifyexponent>1.03</modifyexponent>
		<modifybase>0.0</modifybase>
	</action>
	<tactic>
		<action>SpawnUnit</action>d>
	</tactic>

<!--	自动生产单位2	带按钮-->
	<action>
		<name stringid="68982">SpawnUnit</name>
		<type>DanceBonus</type>
		<active>1</active>
		<persistent>1</persistent>
		<dancebonustype>UnitSpawn</dancebonustype>
		<modifyprotoid>Protoname</modifyprotoid>
		<modifymultiplier>0.065</modifymultiplier>
		<modifyexponent>1.03</modifyexponent>
		<modifybase>0.0</modifybase>
	</action>
	<tactic>
		SpawnUnit
		<action>SpawnUnit</action>
		<protounitcommand>protoPowerName(按钮)</protounitcommand>
		<agerequirement>1</agerequirement>
		<active>1</active>
		<transition>
			<tactic>Food</tactic>
			<length>2</length>
			<exit>1</exit>
		</transition>
		<transition>
			<tactic>protoPowerName(按钮)</tactic>
			<length>2</length>
			<exit>1</exit>
		</transition>
	</tactic>






<!-- 作用于己方的光环模型 -->
		<modelattachment>effects\ypack_auras\daimyopower.xml</modelattachment>

<!-- 作用于敌方的光环模型 -->
		<modelattachment>effects\ypack_auras\frightpower.xml</modelattachment>

<!--	光环——生命值	-->
	<action>
		<name stringid="StringID">ActionName2</name>
		<type>AutoRangedModify</type>
		<modifyprotoid>Protoname</modifyprotoid>
		<active>1</active>
		<maxrange>24</maxrange>
		<persistent>1</persistent>
		<modifytype>MaxHP</modifytype>
		<modifymultiplier>1.1</modifymultiplier>
		<modelattachment>effects\ypack_auras\daimyopower.xml</modelattachment>
		<modelattachmentbone>bonethatdoesntexist</modelattachmentbone>
		<targetenemy>0</targetenemy>
	</action>
	<tactic>
		<action>ActionName2</action>
	</tactic>


<!--	光环——攻击力	-->
	<action>
		<name stringid="StringID">ActionName3</name>
		<type>AutoRangedModify</type>
		<modifyprotoid>Protoname</modifyprotoid>
		<active>1</active>
		<maxrange>24</maxrange>
		<persistent>1</persistent>
		<modifytype>Damage</modifytype>
		<modifymultiplier>1.1</modifymultiplier>
		<modelattachment>effects\ypack_auras\daimyopower.xml</modelattachment>
		<modelattachmentbone>bonethatdoesntexist</modelattachmentbone>
		<targetenemy>0</targetenemy>
	</action>
	<tactic>
		<action>ActionName3</action>
	</tactic>


<!--	光环——速度	-->
	<action>
		<name stringid="StringID">ActionName4</name>
		<type>AutoRangedModify</type>
		<modifyprotoid>Protoname</modifyprotoid>
		<active>1</active>
		<maxrange>24</maxrange>
		<persistent>1</persistent>
		<modifytype>Speed</modifytype>
		<modifymultiplier>1.1</modifymultiplier>
		<modelattachment>effects\ypack_auras\daimyopower.xml</modelattachment>
		<modelattachmentbone>bonethatdoesntexist</modelattachmentbone>
		<targetenemy>0</targetenemy>
	</action>
	<tactic>
		<action>ActionName4</action>
	</tactic>


<!--	光环——视野	-->
	<action>
		<name stringid="StringID">ActionName5</name>
		<type>AutoRangedModify</type>
		<modifyprotoid>Protoname</modifyprotoid>
		<active>1</active>
		<maxrange>24</maxrange>
		<persistent>1</persistent>
		<modifytype>los</modifytype>
		<modifymultiplier>1.1</modifymultiplier>
		<modelattachment>effects\ypack_auras\daimyopower.xml</modelattachment>
		<modelattachmentbone>bonethatdoesntexist</modelattachmentbone>
		<targetenemy>0</targetenemy>
	</action>
	<tactic>
		<action>ActionName5</action>
	</tactic>


<!--	光环——击杀敌人经验值	-->
	<action>
		<name stringid="StringID">ActionName6</name>
		<type>AutoRangedModify</type>
		<modifyprotoid>Protoname</modifyprotoid>
		<active>1</active>
		<maxrange>24</maxrange>
		<persistent>1</persistent>
		<modifytype>Bounty</modifytype>
		<modifymultiplier>1.1</modifymultiplier>
		<modelattachment>effects\ypack_auras\daimyopower.xml</modelattachment>
		<modelattachmentbone>bonethatdoesntexist</modelattachmentbone>
		<targetenemy>0</targetenemy>
	</action>
	<tactic>
		<action>ActionName6</action>
	</tactic>


<!--	光环——采集资源效率	-->
	<action>
		<name stringid="StringID">ActionName7</name>
		<type>AutoRangedModify</type>
		<modifyprotoid>Protoname</modifyprotoid>
		<active>1</active>
		<maxrange>24</maxrange>
		<persistent>1</persistent>
		<modifytype>GatherRate</modifytype>
		<modifymultiplier>1.1</modifymultiplier>
		<modelattachment>effects\ypack_auras\daimyopower.xml</modelattachment>
		<modelattachmentbone>bonethatdoesntexist</modelattachmentbone>
		<targetenemy>0</targetenemy>
	</action>
	<tactic>
		<action>ActionName7</action>
	</tactic>


<!--	光环——自动采集资源效率	-->
	<action>
		<name stringid="StringID">ActionName8</name>
		<type>AutoRangedModify</type>
		<modifyprotoid>Protoname</modifyprotoid>
		<active>1</active>
		<maxrange>24</maxrange>
		<persistent>1</persistent>
		<modifytype>AutoGatherRate</modifytype>
		<modifymultiplier>1.1</modifymultiplier>
		<modelattachment>effects\ypack_auras\daimyopower.xml</modelattachment>
		<modelattachmentbone>bonethatdoesntexist</modelattachmentbone>
		<targetenemy>0</targetenemy>
	</action>
	<tactic>
		<action>ActionName8</action>
	</tactic>







<!--	畜牧、王者山丘自动转换	-->
	<action>
		<name stringid="69161">AutoConvert</name>
		<type>AutoConvert</type>
		<maxrange>12.0</maxrange>
		<active>1</active>
		<persistent>1</persistent>
	</action>
	<tactic>
		<action>AutoConvert</action>
	</tactic>


<!--	自动采集资源	-->
	<action>
		<name stringid="43019">AutoGather</name>
		<type>AutoGather</type>
		<active>1</active>
		<persistent>1</persistent>
		<Rate type="ResourceName">0.250000</Rate>
	</action>
	<tactic>
		<action>AutoGather</action>
	</tactic>

<!--	采集资源	-->
	<action>
		<name stringid="42178">Gather</name>
		<type>Gather</type>
		<maxrange>0.5</maxrange>
		<rate type="Plantation">1.0</rate>
		<rate type="AbstractMine">1.0</rate>
		<rate type="SPCSpanishShipRuins">1.0</rate>
		<rate type="Farm">1.0</rate>
		<rate type="Mill">1.0</rate>
		<rate type="FirePit">1.0</rate>
		<rate type="BerryBush">1.0</rate>
		<rate type="Tree">1.0</rate>
		<rate type="Herdable">1.0</rate>
		<rate type="Huntable">1.0</rate>
		<rate type="ypBerryBuilding">1.0</rate>
		<rate type="ypGroveBuilding">1.0</rate>
	</action>
	<tactic>
		<action>Gather</action>
	</tactic>

<!--	畜牧在建筑物加快增长食物	-->
	<action>
		<name stringid="42178">Gather</name>
		<type>Gather</type>
		<maxrange>0.5</maxrange>
		<rate type="LivestockPen">1.0</rate>
		<rate type="Farm">1.0</rate>
		<rate type="ypVillage">1.0</rate>
		<addresourcestoinventory>1</addresourcestoinventory>
	</action>
	<tactic>
		<action>Gather</action>
	</tactic>

<!--	畜牧自动自动增长食物	-->
	<action>
		<name stringid="43295">AutoGatherFood</name>
		<type>AutoGather</type>
		<persistent>1</persistent>
		<addresourcestoinventory>1</addresourcestoinventory>
	</action>
	<tactic>
		<action>AutoGatherFood</action>
	</tactic>


<!--	自动采集茶叶	-->
	<action>
		<name stringid="69149">AutoGatherTrade</name>
		<type>AutoGather</type>
		<donotautogatherunlessgathering>1</donotautogatherunlessgathering>
		<active>0</active>
		<persistent>1</persistent>
	</action>
	<tactic>
		<action>AutoGatherTrade</action>
	</tactic>

<!--	砍树	-->
	<action>
		<name stringid="69151">Hunting</name>
		<type>Hunting</type>
		<maxrange>10</maxrange>
		<rate type="Herdable">1.0</rate>
		<rate type="Huntable">1.0</rate>
		<rate type="Tree">1.0</rate>
		<typedmaxrange type="Herdable">0</typedmaxrange>
		<typedmaxrange type="Huntable">10</typedmaxrange>
		<typedmaxrange type="Tree">0</typedmaxrange>
	</action>
	<tactic>
		<action>Hunting</action>
	</tactic>

<!--	NoWork	-->
	<action>
		<name stringid="69183">NoWork</name>
		<type>NoWork</type>
		<maxrange>10</maxrange>
		<rate type="Herdable">1.0</rate>
		<rate type="Huntable">1.0</rate>
		<typedmaxrange type="Herdable">0</typedmaxrange>
		<typedmaxrange type="AbstractNuggetWater">0</typedmaxrange>
		<typedmaxrange type="Huntable">10</typedmaxrange>
	</action>
	<tactic>
		<action>NoWork</action>
	</tactic>

<!--	治疗单位	-->
	<action>
		<name stringid="69155">Heal</name>
		<type>Heal</type>
		<active>0</active>
		<maxrange>12</maxrange>
		<rate type="LogicalTypeHealed">50.0 </rate>
		<anim>Heal</anim>
	</action>
	<tactic>
		<action>Heal</action>
	</tactic>

<!--	捡宝藏	-->
	<action>
		<name stringid="69148">Discover</name>
		<type>Discover</type>
		<anim>Pickup</anim>
		<maxrange>0.2</maxrange>
		<rate type="AbstractNuggetLand">1.0</rate>
	</action>
	<tactic>
		<action>Discover</action>
	</tactic>

<!--	建造建筑	-->
	<action>
		<name stringid="69147">Build</name>
		<type>Build</type>
		<anim>Build</anim>
		<maxrange>0.2</maxrange>
		<rate type="Building">1.0</rate>
	</action>
	<tactic>
		<action>Build</action>
	</tactic>


<!--	间谍隐身(如果添加,还需要在单位xml添加动作)	-->
	<action>
		<name stringid="46491">Stealth</name>
		<type>Stealth</type>
		<maxrange>20.0</maxrange>
		<active>1</active>
		<persistent>1</persistent>
	</action>
	<tactic>
		Stealth
		<action>Stealth</action>
		<checkifcanstealth range="20.0">1</checkifcanstealth>
		<speedmodifier>0.5</speedmodifier>
		<attacktype>LogicalTypeHandUnitsAttack</attacktype>
		<transition>
			<tactic>Melee</tactic>
			<length>0.8</length>
			<anim>Cover_Out</anim>
			<exit>1</exit>
			<automatic>1</automatic>
			<commandautomatic>1</commandautomatic>
		</transition>
		<transition>
			<tactic>Defend</tactic>
			<length>0.8</length>
			<anim>Cover_Out</anim>
			<exit>1</exit>
			<automatic>1</automatic>
			<commandautomatic>1</commandautomatic>
		</transition>
		<transition>
			<tactic>Cover</tactic>
			<length>0.8</length>
			<anim>Cover_Out</anim>
			<exit>1</exit>
			<automatic>1</automatic>
			<commandautomatic>1</commandautomatic>
		</transition>
		<!--	其他战术的transition	-->
		<transition>
			<tactic>Stealth</tactic>
			<length>2</length>
			<exit>1</exit>
		</transition>
		<!--	其他战术的transition	-->
		<autoretarget>0</autoretarget>
		<idleanim>Charge_idle</idleanim>
		<boredanim>Charge_bored</boredanim>
		<deathanim>Death_by_melee</deathanim>
		<walkanim>Charge_walk</walkanim>
		<joganim>Charge_jog</joganim>
		<runanim>Charge_run</runanim>
	</tactic>

<!--	近战攻击(如果添加,还需要在单位xml添加动作)	-->
	<action>
		<name stringid="38135">MeleeHandAttack</name>
		<type>Attack</type>
		<maxrange>1.75</maxrange>
		<rate type="Unit">1.0 </rate>
		<attackaction>1</attackaction>
		<handlogic>1</handlogic>
		<anim>HandAttack</anim>
		<idleanim>CombatIdle</idleanim>
		<impacteffect>effects\impacts\melee</impacteffect>
		<speedboost>1</speedboost>
		<targetspeedboost>1</targetspeedboost>
		<basedamagecap>1</basedamagecap>
	</action>
	<!--	..........................	-->
	<tactic>
		<action priority="25">HandAttack</action>
	</tactic>

<!--	齐射攻击(如果添加,还需要在单位xml添加动作)	-->
	<action>
		<name stringid="38127">VolleyRangedAttack</name>
		<type>Attack</type>
		<attackaction>1</attackaction>
		<rangedlogic>1</rangedlogic>
		<anim>Volley_standing_attack</anim>
		<reloadanim>Volley_standing_reload</reloadanim>
		<idleanim>Volley_standing_idle</idleanim>
		<accuracy>10</accuracy>
		<accuracyreductionfactor>0.0</accuracyreductionfactor>
		<aimbonus>0</aimbonus>
		<maxspread>5</maxspread>
		<spreadfactor>0.25</spreadfactor>
		<trackrating>12</trackrating>
		<unintentionaldamagemultiplier>0.7</unintentionaldamagemultiplier>
		<projectile>Arrow</projectile>
		<minrange>2</minrange>
		<rate type="Unit">1.0 </rate>
	</action>
	<!--	................,看不下去,你还是找一个单位的tactics复制吧。	-->
	<!--(只想复制关键语句,但是又怕新人以为只有这几个语句,而且动作也不一样,所以还是自己找tactics复制吧)	-->
	<tactic>
		Volley
		<action priority="100">VolleyRangedAttack</action>
		<attacktype>LogicalTypeRangedUnitsAttack</attacktype>
		<autoattacktype>LogicalTypeRangedUnitsAutoAttack</autoattacktype>
		<attackresponsetype>LogicalTypeRangedUnitsAttack</attackresponsetype>
	</tactic>






<!--		-->
	<tactic>

	</tactic>