这个教程是给普通单位添加探险家采集宝藏的动作,使其能捡宝藏。与以往教程不同,这次不只是让你直接复制语句了,而是告诉你怎样复制游戏原有的内容。
例如我要给火枪手添加采集宝藏,那么有有哪些已有的单位能采集宝藏?探险家、村民都可以。那我就提取探险家的动画xml与tactics,然后复制里面语句到火枪手里面。
1. 先把火枪手的tactics文件以及动画xml提取出来。(探险家的就随意吧,我就不提取了,我直接在AOE3ED里面复制。)
2.在tactics寻找探险家采集宝藏的定义,很明显第一个就是了,然后将语句复制进火枪手的tactics。我是怎么知道是第一个?作为大佬就是这么6的,从看英文来看是"发现",但是我就是觉得这个是捡宝藏。另外,Discover旁边不是有个69148,你自己去stringtabley.xml搜索一下。
(为了不影响其他单位,所以我在protoy.xml将火枪手的tactics修改成Musketeer.tactics了。)
Musketeer.tactics - 记事本 | ____ | □ | X | ||
文件(F) 编辑(E) 格式(O) 查看(V) 帮助(H) | |||||
<!-- converted from XMB to XML --> <tactics> <action> <name stringid="69148">Discover</name> <type>Discover</type> <anim>Pickup</anim> <maxrange>0.2</maxrange> <rate type="AbstractNuggetLand">1.0</rate> </action> <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> <maxheight>0</maxheight> <accuracy>1.0</accuracy> <accuracyreductionfactor>1.5</accuracyreductionfactor> <aimbonus>0</aimbonus> <maxspread>5</maxspread> <spreadfactor>0.25</spreadfactor> <trackrating>12</trackrating> <unintentionaldamagemultiplier>0.7</unintentionaldamagemultiplier> <projectile>InvisibleProjectile</projectile> <impacteffect>effects\impacts\gun</impacteffect> <minrange>2</minrange> <rate type="Unit">1.0 </rate> <throw>1</throw> <damage>13.000000</damage> <maxrange>12.000000</maxrange> <rof>2.000000</rof> <instantballistics>1</instantballistics> </action> <action> <name stringid="38130">VolleyHandAttack</name> <type>Attack</type> <maxrange>1.75</maxrange> <rate type="Unit">1.0 </rate> <attackaction>1</attackaction> <handlogic>1</handlogic> <speedboost>1</speedboost> <anim>charge_attack</anim> <idleanim>charge_idle</idleanim> <impacteffect>effects\impacts\melee</impacteffect> <targetspeedboost>1</targetspeedboost> </action> <action> <name stringid="38136">DefendRangedAttack</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> <maxheight>0</maxheight> <accuracy>1.0</accuracy> <accuracyreductionfactor>1.5</accuracyreductionfactor> <aimbonus>0</aimbonus> <maxspread>5</maxspread> <spreadfactor>0.25</spreadfactor> <trackrating>12</trackrating> <unintentionaldamagemultiplier>0.7</unintentionaldamagemultiplier> <projectile>InvisibleProjectile</projectile> <impacteffect>effects\impacts\gun</impacteffect> <minrange>2</minrange> <rate type="Unit">1.0 </rate> <throw>1</throw> <damage>13.000000</damage> <maxrange>12.000000</maxrange> <rof>2.000000</rof> <instantballistics>1</instantballistics> </action> <action> <name stringid="38137">DefendHandAttack</name> <type>Attack</type> <maxrange>1.75</maxrange> <rate type="Unit">1.0 </rate> <attackaction>1</attackaction> <handlogic>1</handlogic> <speedboost>1</speedboost> <anim>charge_attack</anim> <idleanim>charge_idle</idleanim> <impacteffect>effects\impacts\melee</impacteffect> <damage>6.5</damage> <rof>1.0</rof> <targetspeedboost>1</targetspeedboost> </action> <action> <name stringid="38129">StaggerRangedAttack</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> <maxheight>0</maxheight> <accuracy>1.0</accuracy> <accuracyreductionfactor>1.5</accuracyreductionfactor> <aimbonus>0</aimbonus> <maxspread>5</maxspread> <spreadfactor>0.25</spreadfactor> <trackrating>12</trackrating> <unintentionaldamagemultiplier>0.7</unintentionaldamagemultiplier> <projectile>InvisibleProjectile</projectile> <impacteffect>effects\impacts\gun</impacteffect> <minrange>2</minrange> <rate type="Unit">1.0 </rate> <throw>1</throw> <damage>13.000000</damage> <maxrange>12.000000</maxrange> <rof>2.000000</rof> <instantballistics>1</instantballistics> </action> <action> <name stringid="38132">StaggerHandAttack</name> <type>Attack</type> <maxrange>1.75</maxrange> <rate type="Unit">1.0 </rate> <attackaction>1</attackaction> <handlogic>1</handlogic> <speedboost>1</speedboost> <anim>charge_attack</anim> <idleanim>charge_idle</idleanim> <impacteffect>effects\impacts\melee</impacteffect> <damage>6.5</damage> <rof>1.0</rof> <targetspeedboost>1</targetspeedboost> </action> <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> <speedboost>1</speedboost> <anim>Charge_attack</anim> <idleanim>Charge_idle</idleanim> <impacteffect>effects\impacts\melee</impacteffect> <damage>6.5</damage> <rof>1.0</rof> <targetspeedboost>1</targetspeedboost> </action> <action> <name stringid="38118">BuildingAttack</name> <type>Attack</type> <rangedlogic>1</rangedlogic> <maxrange>6</maxrange> <rate type="LogicalTypeShipsAndBuildings">1.0 </rate> <attackaction>1</attackaction> <speedboost>1</speedboost> <anim>Raze_attack</anim> <idleanim>Raze_idle</idleanim> <impacteffect>effects\impacts\torch</impacteffect> <projectile>TorchProjectile</projectile> </action> <action> <name stringid="69147">Build</name> <type>Build</type> <anim>Build</anim> <active>0</active> <maxrange>0.2</maxrange> <rate type="Barracks">2.0</rate> <rate type="Stable">2.0</rate> <rate type="ArtilleryDepot">2.0</rate> <rate type="Warhut">2.0</rate> <rate type="Corral">2.0</rate> <rate type="FortFrontier">2.0</rate> <rate type="ypBarracksIndian">2.0</rate> <rate type="ypCaravanserai">2.0</rate> <rate type="ypCastle">2.0</rate> </action> <tactic> Volley <action priority="100">VolleyRangedAttack</action> <action priority="75">BuildingAttack</action> <action priority="25">VolleyHandAttack</action> <action>Build</action> <action>Discover</action> <attacktype>LogicalTypeRangedUnitsAttack</attacktype> <autoattacktype>LogicalTypeRangedUnitsAutoAttack</autoattacktype> <attackresponsetype>LogicalTypeRangedUnitsAttack</attackresponsetype> <runaway>1</runaway> <autoretarget>1</autoretarget> <idleanim>Volley_standing_idle</idleanim> <boredanim>Volley_standing_bored</boredanim> <deathanim>Death_by_melee</deathanim> <walkanim>Volley_walk</walkanim> <joganim>Volley_jog</joganim> <runanim>Volley_run</runanim> </tactic> <tactic> Defend <action priority="100">DefendRangedAttack</action> <action priority="75">BuildingAttack</action> <action priority="25">DefendHandAttack</action> <action>Build</action> <action>Discover</action> <attacktype>LogicalTypeRangedUnitsAttack</attacktype> <autoattacktype>LogicalTypeRangedUnitsAutoAttack</autoattacktype> <attackresponsetype>LogicalTypeRangedUnitsAttack</attackresponsetype> <runaway>0</runaway> <autoretarget>1</autoretarget> <idleanim>Defend_idle</idleanim> <boredanim>Defend_bored</boredanim> <deathanim>Death_by_melee</deathanim> <walkanim>Cover_walk</walkanim> <joganim>Cover_jog</joganim> <runanim>Cover_run</runanim> </tactic> <tactic> Stagger <action priority="100">StaggerRangedAttack</action> <action priority="75">BuildingAttack</action> <action priority="25">StaggerHandAttack</action> <action>Build</action> <action>Discover</action> <attacktype>LogicalTypeRangedUnitsAttack</attacktype> <autoattacktype>LogicalTypeRangedUnitsAutoAttack</autoattacktype> <attackresponsetype>LogicalTypeRangedUnitsAttack</attackresponsetype> <runaway>0</runaway> <autoretarget>1</autoretarget> <idleanim>Cover_ranged_idle</idleanim> <boredanim>Cover_bored</boredanim> <deathanim>Death_by_melee</deathanim> <walkanim>Cover_walk</walkanim> <joganim>Cover_jog</joganim> <runanim>Cover_run</runanim> </tactic> <tactic> Melee <action priority="100">BuildingAttack</action> <action priority="75">MeleeHandAttack</action> <action>Build</action> <action>Discover</action> <attacktype>LogicalTypeRangedUnitsAttack</attacktype> <autoattacktype>LogicalTypeRangedUnitsAutoAttack</autoattacktype> <attackresponsetype>LogicalTypeRangedUnitsAttack</attackresponsetype> <runaway>0</runaway> <autoretarget>1</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> </tactics> |
|||||