Advertisement
TC24k

Random_Spellcast_Lots_of_Good_Code

Jul 27th, 2011
159
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
XML 23.36 KB | None | 0 0
  1. <spellcast xmlns:xi="http://www.w3.org/2001/XInclude">
  2.     <config
  3.             RequireVersion="2.16"
  4.            Debug="true"
  5.            HideErrors="false"
  6.            ShowGearSwaps="false"
  7.            />
  8.     <variables>
  9.         <!--Variable for locking TP-->
  10.         <var nooverwrite="true" Name="LockTP">15</var>
  11.         <!--Have Vars-->
  12.         <var name="HaveArtemis Medal">1</var>
  13.         <var name="BLMAF2Pants">1</var>
  14.         <var name="HaveSorcRing">0</var>
  15.         <var name="HaveDarkObi">0</var>
  16.         <var name="HaveLightObi">0</var>
  17.         <var name="HaveEarthObi">0</var>
  18.         <var name="HaveWaterObi">0</var>
  19.         <var name="HaveWindObi">1</var>
  20.         <var name="HaveFireObi">0</var>
  21.         <var name="HaveIceObi">1</var>
  22.         <var name="HaveThunderObi">1</var>
  23.         <var name="HaveNovio">0</var>
  24.         <var name="HaveWaterRing">0</var>
  25.         <var name="HaveIceRing">0</var>
  26.         <var name="TwilightCape">0</var>
  27.         <!-- Ugg Pendant settings for various gearsets. -->
  28.         <var name="RDMUggPendantMP">402</var>
  29.         <var name="WHMUggPendantMP">351</var>
  30.         <var name="SCHUggPendantMP">346</var>
  31.         <var name="NINUggPendantMP">311</var>
  32.         <var name="RDMHighResistMP">353</var>
  33.         <var name="WHMHighResistMP">363</var>
  34.         <var name="SCHHighResistMP">358</var>
  35.         <var name="NINHighResistMP">323</var>
  36.         <!-- Set HP Variables for what the maximum amount of HP you can have to trigger sorc ring is for each subjob -->
  37.         <var name="RDMRingHP">793</var>
  38.         <var name="WHMRingHP">706</var>
  39.         <var name="NINRingHP">720</var>
  40.         <var name="SCHRingHP">706</var>
  41.         <!--Renaming Vars-->
  42.         <var name="UggPendant">1</var>
  43.         <var Name="LightStaff">Apollo's Staff</var>
  44.         <var Name="DarkStaff">Pluto's Staff</var>
  45.         <var Name="FireStaff">Vulcan's Staff</var>
  46.         <var Name="IceStaff">Aquilo's Staff</var>
  47.         <var Name="WindStaff">Auster's Staff</var>
  48.         <var Name="EarthStaff">Terra's Staff</var>
  49.         <var Name="ThunderStaff">Indra's Staff</var>
  50.         <var Name="WaterStaff">Neptune's Staff</var>
  51.         <var name="DarkObi">Anrin Obi</var>
  52.         <var name="LightObi">Korin Obi</var>
  53.         <var name="WindObi">Furin Obi</var>
  54.         <var name="IceObi">Hyorin Obi</var>
  55.         <var name="FireObi">Karin Obi</var>
  56.         <var name="WaterObi">Suirin Obi</var>
  57.         <var name="ThunderObi">Rairin Obi</var>
  58.         <var name="EarthObi">Dorin Obi</var>
  59.         <!--Do Not Change These Vars-->
  60.         <var name="sublimation-counter">0</var>
  61.         <var name="sublimation-complete">0</var>
  62.     </variables>
  63.     <sets>
  64.         <group name="Main" default="yes">
  65.             <!--Standard Sets-->
  66.             <set name="Standard">
  67.                 <main>$IceStaff</main>
  68.                 <sub>Elementa Grip</sub>
  69.                 <ammo>Witchstone</ammo>
  70.                 <head>Teal Chapeau</head>
  71.                 <neck>Feud Pendant</neck>
  72.                 <lear>Moldavite Earring</lear>
  73.                 <rear>Graiai Earring</rear>
  74.                 <body>Teal Saio</body>
  75.                 <hands>Zenith Mitts</hands>
  76.                 <lring>Snow Ring</lring>
  77.                 <rring>Snow Ring</rring>
  78.                 <back>Ixion Cape</back>
  79.                 <waist>Witch Sash</waist>
  80.                 <legs>Teal Slops</legs>
  81.                 <feet>Cobra Crackows</feet>
  82.             </set>
  83.             <set name="MP" BaseSet="Standard">
  84.                 <head>Sorcerer's Petas.</head>
  85.                 <neck>Aesir Torque</neck>
  86.                 <rear>Antivenom Earring</rear>
  87.                 <body>Goliard Saio</body>
  88.                 <back>Rainbow Cape</back>
  89.                 <waist>Hierarch Belt</waist>
  90.                 <legs>Yigit Seraweels</legs>
  91.             </set>
  92.             <set name="Resting">
  93.                 <body>Errant Hpl.</body>
  94.                 <sub>Ariesian Grip</sub>
  95.                 <main>$DarkStaff</main>
  96.                 <ammo>Clarus Stone</ammo>
  97.                 <head>Selenian Cap</head>
  98.                 <waist>Qiqirn Sash +1</waist>
  99.                 <feet>Goliard Clogs</feet>
  100.                 <neck>Beak Necklace +1</neck>
  101.                 <lear>Boroka Earring</lear>
  102.                 <rear>Antivenom Earring</rear>
  103.                 <legs>Baron's Slops</legs>
  104.                 <back>Invigorating Cape</back>
  105.             </set>
  106.             <set name="FastCast">
  107.                 <neck>Rostrum Pumps</neck>
  108.             </set>
  109.             <set name="Haste|Ninjutsu" BaseSet="FastCast">
  110.                 <body>Goliard Saio</body>
  111.             </set>
  112.             <set name="ConserveMP" BaseSet="Haste">
  113.             </set>
  114.             <set name="Aftercast|Idle" BaseSet="Standard">
  115.                 <main>$EarthStaff</main>
  116.                 <lring>Jelly Ring</lring>
  117.                 <rring>Dark Ring</rring>
  118.                 <legs>Tatsumaki Sitagoromo</legs>
  119.             </set>
  120.             <set name="Sleep" BaseSet="Aftercast">
  121.                 <main>Hardwood Katana</main>
  122.             </set>
  123.             <!--Magic Sets-->
  124.             <set name="EnfeeblingMagic" BaseSet="FullDamage">
  125.                 <body>Wizard's Coat</body>
  126.                 <sub>Macero Grip</sub>
  127.                 <head>Igqira Tiara</head>
  128.                 <neck>Spider Torque</neck>
  129.                 <legs>Igqira Lappa</legs>
  130.             </set>
  131.             <set name="HealingMagic">
  132.                 <main>$LightStaff</main>
  133.                 <legs>Mahatma Slops</legs>
  134.                 <feet>Teal Pigaches</feet>
  135.                 <lring>Solemn Ring</lring>
  136.             </set>
  137.             <set name="DarkMagic" BaseSet="Haste">
  138.                 <legs>Wizard's Tonban</legs>
  139.                 <main>$DarkStaff</main>
  140.                 <sub>Caecus Grip</sub>
  141.                 <neck>Dark Torque</neck>
  142.                 <body>Nashira Manteel</body>
  143.                 <feet>Igqira Huaraches</feet>
  144.                 <hands>Sorcerer's Gloves</hands>
  145.             </set>
  146.             <set name="EnhancingMagic" BaseSet="HealingMagic">
  147.                 <main lock="yes">$WaterStaff</main>
  148.                 <feet>Teal Pigaches</feet>
  149.                 <legs>Mahatma Slops</legs>
  150.                 <body>Errant Houppelande</body>
  151.             </set>
  152.             <!--Nuking Sets-->
  153.             <set name="MinusHP" BaseSet="FastCast">
  154.             </set>
  155.             <set name="FullDamage" BaseSet="Standard">
  156.             </set>
  157.             <set name="LightResist" BaseSet="FullDamage">
  158.                 <head>Sorcerer's Petas.</head>
  159.             </set>
  160.             <set name="MidResist" BaseSet="LightResist">
  161.                 <head>Sorcerer's Petas.</head>
  162.                 <hands>Wizard's Gloves</hands>
  163.             </set>
  164.             <set name="HighResist|ElementalMagic" BaseSet="MidResist">
  165.                 <head>Sorcerer's Petas.</head>
  166.                 <hands>Wizard's Gloves</hands>
  167.                 <neck>Elemental Torque</neck>
  168.                 <legs>Druid's Slops</legs>
  169.             </set>
  170.             <!--Individual Spell-->
  171.             <set name="Stoneskin" BaseSet="Standard">
  172.                 <main>$WaterStaff</main>
  173.                 <lring>Solemn Ring</lring>
  174.                 <neck>Stone Gorget</neck>
  175.                 <body>Errant Hpl.</body>
  176.                 <legs>Mahatma Slops</legs>
  177.                 <feet>Teal Pigaches</feet>
  178.             </set>
  179.         </group>
  180.     </sets>
  181.     <rules>/
  182.         <!--Automatic Rules-->
  183.         <if spell="Meteor">
  184.             <if status="resting" NotBuffActive="Weakness" advanced='%MP&lt;$%SubJobMaxMP'>
  185.                 <equip when="resting" set="MP" />
  186.             </if>
  187.             <cancelspell/>
  188.             <return/>
  189.         </if>
  190.         <elseif spell="Poison V">
  191.             <if BuffActive="*sleep*">
  192.                 <equip when="precast" Set="Sleep" />
  193.             </if>
  194.             <cancelspell/>
  195.             <return/>
  196.         </elseif>
  197.         <!--Rules to stop parsing if you can't perform an action-->
  198.         <if BuffActive="Sleep|Petrification|Stun|Terror|Charm">
  199.             <return/>
  200.         </if>
  201.         <elseif Type="*Magic|BardSong|Ninjutsu" BuffActive="Silence">
  202.             <return/>
  203.         </elseif>
  204.         <elseif Type="Weaponskill|JobAbility|PetCommand" BuffActive="Amnesia">
  205.             <cancelspell/>
  206.             <return/>
  207.         </elseif>
  208.         <elseif type="Weaponskill">
  209.             <if mode="OR" TPLT="100" advanced='%SpellTargetDistance&gt;4' notstatus="engaged">
  210.                 <cancelspell/>
  211.                 <return/>
  212.             </if>
  213.         </elseif>
  214.         <!--Automatic targetting of yourself when casting a spell that can target you, but you have no target selected-->
  215.         <if ValidTarget="Self|Self, Party|Self, Party, Ally, NPC|Self, Party, Ally, NPC, Enemy" SpellTargetType="None">
  216.             <defaulttarget Target="%Playername" />
  217.         </if>
  218.         <elseif ValidTarget="Self|Self, Party|Self, Party, Ally, NPC" SpellTargetType="None|Monster">
  219.             <defaulttarget Target="%Playername" />
  220.         </elseif>
  221.         <elseif ValidTarget="Self|Self, Party" SpellTargetType="None|Monster|NPC">
  222.             <defaulttarget Target="%Playername" />
  223.         </elseif>
  224.         <!--Added sleep timers and warnings to the chatlog-->
  225.         <if spell="Sleep|Sleepga">
  226.             <command when="aftercast">spellcast var inc sleepid;wait 30;input /echo [$sleepid:%spell] &lt;%SpellTargetName&gt; Wearing off in 30s</command>
  227.             <command when="aftercast">wait 45;input /echo [$sleepid:%spell] &lt;%SpellTargetName&gt;Wearing off in 15s</command>
  228.             <command when="aftercast">wait 55;input /echo [$sleepid:%spell] &lt;%SpellTargetName&gt;Wearing off in 5s;spellcast var dec sleepid;</command>
  229.         </if>
  230.         <elseif spell="Sleep II|Sleepga II">
  231.                     <command when="aftercast">spellcast var inc sleepid;wait 45;input /echo [$sleepid:%spell] &lt;%SpellTargetName&gt; Wearing off in 45s</command>
  232.                     <command when="aftercast">wait 75;input /echo [$sleepid:%spell] &lt;%SpellTargetName&gt;Wearing off in 15s</command>
  233.                     <command when="aftercast">wait 85;input /echo [$sleepid:%spell] &lt;%SpellTargetName&gt;Wearing off in 5s;spellcast var dec sleepid;</command>
  234.         </elseif>
  235.         <!--Cancel Buff Rules-->
  236.         <if spell="Sneak" SpellTarget="%Playername">
  237.                     <midcastdelay delay="1.5" />
  238.                     <command when="midcast">cancel 71</command>
  239.                     </if>
  240.                     <elseif Spell="Monomi*">
  241.                         <midcastdelay delay="2.5" />
  242.                         <command when="midcast">cancel 71</command>
  243.                     </elseif>
  244.                     <elseif spell="Utsusemi: Ichi">
  245.                         <midcastdelay delay="2" />
  246.                         <command when="midcast">cancel 66</command>
  247.                     </elseif>
  248.                     <elseif Spell="Stoneskin">
  249.                         <midcastdelay delay="2.8" />
  250.                         <command when="midcast">cancel 37</command>
  251.                     </elseif>
  252.                     <elseif spell="Reraise*">
  253.                         <if BuffActive="Reraise">
  254.                                 <midcastdelay delay="5" />
  255.                                 <command when="midcast">cancel 113</command>
  256.                     </if>
  257.         </elseif>
  258.         <!--Job Ability Rules-->
  259.         <if spell="Penury|Parsimony">
  260.             <if BuffActive="Light Arts|Addendum: White">
  261.                 <Changespell Spell="Penury" />
  262.             </if>
  263.             <elseif BuffActive="Dark Arts|Addendum: Black">
  264.                 <Changespell Spell="Parsimony" />
  265.             </elseif>
  266.             <return/>
  267.         </if>
  268.         <elseif spell="Celerity|Alacrity">
  269.             <if BuffActive="Light Arts|Addendum: White">
  270.                 <Changespell Spell="Celerity" />
  271.             </if>
  272.             <elseif BuffActive="Dark Arts|Addendum: Black">
  273.                 <Changespell Spell="Alacrity" />
  274.             </elseif>
  275.             <return/>
  276.         </elseif>
  277.         <elseif spell="Addendum*">
  278.             <if BuffActive="Light Arts">
  279.                 <Changespell Spell="Addendum: White" />
  280.             </if>
  281.             <elseif BuffActive="Dark Arts">
  282.                 <Changespell Spell="Addendum: Black" />
  283.             </elseif>
  284.             <return/>
  285.         </elseif>
  286.         <!--Gearlocks Start Here-->
  287.         <if EquipHead="Reraise Hairpin" notbuffactive="Reraise">
  288.             <equip when="precast|midcast|aftercast|engaged|idle|resting">
  289.                 <head lock="t" />
  290.             </equip>
  291.             <addtochat Color="369" when="precast">. . . . . . . . . . . . . . - - Reraise Earring Locked - - . . . . . . . . . . . . . .</addtochat>
  292.         </if>
  293.         <elseif EquipREar="Reraise Earring" Notbuffactive="Reraise">
  294.             <equip when="precast|midcast|aftercast|engaged|idle|resting">
  295.                 <rear lock="t" />
  296.             </equip>
  297.             <addtochat Color="369" when="precast">. . . . . . . . . . . . . . - - Reraise Earring Locked - - . . . . . . . . . . . . . .</addtochat>
  298.         </elseif>
  299.         <elseif EquipLEar="Reraise Earring" Notbuffactive="Reraise">
  300.             <equip when="precast|midcast|aftercast|engaged|idle|resting">
  301.                 <lear lock="t" />
  302.             </equip>
  303.             <addtochat Color="369" when="precast">. . . . . . . . . . . . . . - - Reraise Earring Locked - - . . . . . . . . . . . . . .</addtochat>
  304.         </elseif>
  305.         <if EquipRRing="Emperor Band|Empress Band|Anniversary Ring|Kupofried's Ring" notbuffactive="Dedication">
  306.             <equip when="precast|midcast|aftercast|engaged|idle|resting">
  307.                 <rring lock="t" />
  308.             </equip>
  309.             <addtochat Color="369" when="precast">. . . . . . . . . . . . . . - - EXP Ring Locked - - . . . . . . . . . . . . . .</addtochat>
  310.         </if>
  311.         <elseif EquipLRing="Emperor Band|Empress Band|Anniversary Ring|Kupofried's Ring" notbuffactive="Dedication">
  312.             <equip when="precast|midcast|aftercast|engaged|idle|resting">
  313.                 <lring lock="t" />
  314.             </equip>
  315.             <addtochat Color="369" when="precast">. . . . . . . . . . . . . . - - EXP Ring Locked - - . . . . . . . . . . . . . .</addtochat>
  316.         </elseif>
  317.         <if Mode="OR" Status="Engaged" TPGT="$LockTP">
  318.             <equip when="precast|midcast|aftercast|engaged|idle|resting">
  319.                 <main lock="t" /><sub lock="t" /><range lock="t" /><ammo lock="t" />
  320.             </equip>
  321.         </if>
  322.         <!--autoset rules-->
  323.         <if spell="autoset">
  324.             <equip when="resting|idle" set="%Status" />
  325.             <return/>
  326.         </if>
  327.         <!--Changespells For sneak/invis when subbing NIN-->
  328.         <if Subjob="NIN">
  329.             <if Spell="Invisible">
  330.                 <if SubJobLvlLT="34">
  331.                     <Changespell Spell="Tonko: Ichi" />
  332.                 </if>
  333.                 <else>
  334.                     <Changespell Spell="Tonko: Ni" />
  335.                 </else>
  336.             </if>
  337.             <elseif Spell="Sneak">
  338.                 <Changespell Spell="Monomi: Ichi" />
  339.             </elseif>
  340.         </if>
  341.         <!--Change Cure Spells based on MP-->
  342.         <if Spell="Cure III">
  343.             <if BuffActive="Light Arts|Addendum: White" MPLT="42">
  344.                 <Changespell Spell="Cure II" />
  345.             </if>
  346.             <elseif Buffactive="Dark Arts|Addendum: Black" MPLT="56">
  347.                 <Changespell Spell="Cure II" />
  348.             </elseif>
  349.             <elseif notbuffactive="*Arts|Addend*" MPLT="46">
  350.                 <Changespell Spell="Cure II" />
  351.             </elseif>
  352.         </if>
  353.         <elseif Spell="Cure II">
  354.             <if BuffActive="Light Arts|Addendum: White" MPLT="22">
  355.                 <Changespell Spell="Cure" />
  356.             </if>
  357.             <elseif Buffactive="Dark Arts|Addendum: Black" MPLT="29">
  358.                 <Changespell Spell="Cure" />
  359.             </elseif>
  360.             <elseif notbuffactive="*Arts|Addend*" MPLT="24">
  361.                 <Changespell Spell="Cure" />
  362.             </elseif>
  363.         </elseif>
  364.         <elseif Spell="Curaga II">
  365.             <if BuffActive="Light Arts|Addendum: White" MPLT="108">
  366.                 <Changespell Spell="Curaga" />
  367.             </if>
  368.             <elseif Buffactive="Dark Arts|Addendum: Black" MPLT="144">
  369.                 <Changespell Spell="Curaga" />
  370.             </elseif>
  371.             <elseif notbuffactive="*Arts|Addend*" MPLT="120">
  372.                 <Changespell Spell="Curaga" />
  373.             </elseif>
  374.         </elseif>
  375.         <elseif Spell="Thunder IV">
  376.             <if MLvlLT="46">
  377.                 <Changespell Spell="Thunder" />
  378.             </if>
  379.             <elseif MLvlLT="66">
  380.                 <Changespell Spell="Thunder II" />
  381.             </elseif>
  382.             <elseif MLvlLT="75">
  383.                 <Changespell Spell="Thunder III" />
  384.             </elseif>
  385.         </elseif>
  386.         <elseif Spell="Blizzard IV">
  387.             <if MLvlLT="42">
  388.                 <Changespell Spell="Blizzard" />
  389.             </if>
  390.             <elseif MLvlLT="64">
  391.                 <Changespell Spell="Blizzard II" />
  392.             </elseif>
  393.             <elseif MLvlLT="74">
  394.                 <Changespell Spell="Blizzard III" />
  395.             </elseif>
  396.         </elseif>
  397.         <elseif Spell="Fire IV">
  398.             <if MLvlLT="38">
  399.                 <Changespell Spell="Fire" />
  400.             </if>
  401.             <elseif MLvlLT="62">
  402.                 <Changespell Spell="Fire II" />
  403.             </elseif>
  404.             <elseif MLvlLT="73">
  405.                 <Changespell Spell="Fire III" />
  406.             </elseif>
  407.         </elseif>
  408.         <elseif Spell="Aero IV">
  409.             <if MLvlLT="34">
  410.                 <Changespell Spell="Aero" />
  411.             </if>
  412.             <elseif MLvlLT="59">
  413.                 <Changespell Spell="Aero II" />
  414.             </elseif>
  415.             <elseif MLvlLT="72">
  416.                 <Changespell Spell="Aero III" />
  417.             </elseif>
  418.         </elseif>
  419.         <elseif Spell="Water IV">
  420.             <if MLvlLT="30">
  421.                 <Changespell Spell="Water" />
  422.             </if>
  423.             <elseif MLvlLT="55">
  424.                 <Changespell Spell="Water II" />
  425.             </elseif>
  426.             <elseif MLvlLT="70">
  427.                 <Changespell Spell="Water III" />
  428.             </elseif>
  429.         </elseif>
  430.         <elseif Spell="Stone IV">
  431.             <if MLvlLT="26">
  432.                 <Changespell Spell="Stone" />
  433.             </if>
  434.             <elseif MLvlLT="51">
  435.                 <Changespell Spell="Stone II" />
  436.             </elseif>
  437.             <elseif MLvlLT="68">
  438.                 <Changespell Spell="Stone III" />
  439.             </elseif>
  440.         </elseif>
  441.         <elseif spell="Thundaga III">
  442.             <if MLvlLT="61">
  443.                 <Changespell spell="Thundaga" />
  444.             </if>
  445.             <elseif MLvlLT="73">
  446.                 <Changespell Spell="Thundaga II" />
  447.             </elseif>
  448.         </elseif>
  449.         <elseif spell="Blizzaga III">
  450.             <if MLvlLT="57">
  451.                 <Changespell spell="Blizzaga" />
  452.             </if>
  453.             <elseif MLvlLT="71">
  454.                 <Changespell Spell="Blizzaga II" />
  455.             </elseif>
  456.         </elseif>
  457.         <elseif spell="Firaga III">
  458.             <if MLvlLT="53">
  459.                 <Changespell spell="Firaga" />
  460.             </if>
  461.             <elseif MLvlLT="69">
  462.                 <Changespell Spell="Firaga II" />
  463.             </elseif>
  464.         </elseif>
  465.         <elseif spell="Aeroga III">
  466.             <if MLvlLT="48">
  467.                 <Changespell spell="Aeroga" />
  468.             </if>
  469.             <elseif MLvlLT="67">
  470.                 <Changespell Spell="Aeroga II" />
  471.             </elseif>
  472.         </elseif>
  473.         <elseif spell="Waterga III">
  474.             <if MLvlLT="44">
  475.                 <Changespell spell="Waterga" />
  476.             </if>
  477.             <elseif MLvlLT="65">
  478.                 <Changespell Spell="Waterga II" />
  479.             </elseif>
  480.         </elseif>
  481.         <elseif spell="Stonega III">
  482.             <if MLvlLT="40">
  483.                 <Changespell spell="Stonega" />
  484.             </if>
  485.             <elseif MLvlLT="63">
  486.                 <Changespell Spell="Stonega II" />
  487.             </elseif>
  488.         </elseif>
  489.         <elseif spell="Bio II">
  490.             <if MLvlLT="35">
  491.                 <Changespell Spell="Bio" />
  492.             </if>
  493.         </elseif>
  494.         <elseif spell="Poison II">
  495.             <if MLvlLT="43">
  496.                 <Changespell Spell="Poison" />
  497.             </if>
  498.         </elseif>
  499.         <!--Equip staves, Fast Cast, and Aftercast gear-->
  500.         <if Type="*Magic|BardSong|Ninjutsu">
  501.             <if notType="Ninjutsu">
  502.                 <equip when="midcast"><main>$%SpellElementStaff</main></equip>
  503.             </if>
  504.             <equip when="aftercast" set="Aftercast" />
  505.         </if>
  506.         <!--Situational Gear-->
  507.         <if MPPLT="86" day="Watersday" CommandPrefix="/magic" MLvlGT="64" NotSkill="ElementalMagic" advanced='"$HaveWaterRing"="1"'>
  508.             <equip when="midcast"><rring lock="t">Water Ring</rring></equip>
  509.             <addtochat Color="369" when="midcast">. . . . . . . . . . . . . . - - Equipped Water Ring - - . . . . . . . . . . . . . .</addtochat>
  510.         </if>
  511.         <elseif MPPLT="86" day="Iceday" Skill="ElementalMagic"  MLvlGT="64" advanced='"$HaveWaterRing"="1"'>
  512.             <if Mode="OR" Spell="Rasp|Drown|Choke|Burn|Frost|Shock" SpellTargetName="Genbu|Suzaku|Seiryu|Byakko|Kirin|Cerberus|Khimaira|Tyger|Jailer of Love|Sarameya">
  513.                 <equip when="midcast"><rring lock="t">Ice Ring</rring></equip>
  514.                 <addtochat Color="369" when="midcast">. . . . . . . . . . . . . . - - Equipped Ice Ring - - . . . . . . . . . . . . . .</addtochat>
  515.             </if>
  516.         </elseif>
  517.         <if CommandPrefix="/magic" MLvlGT="70" NotSpell="Dia*|*na|Erase|*Raise*" NotSkill="SummoningMagic|EnhancingMagic" Advanced='("%SpellElement"="%WeatherElement" OR "%SpellElement"="%DayElement") AND "$Have%SpellElementObi"="1"'>
  518.             <equip when="midcast">
  519.                 <waist lock="t">$%SpellElementObi</waist>
  520.             </equip>
  521.             <addtochat Color="369" when="midcast">. . . . . . . . . . . . . . - - Equipped $%SpellElementObi - - . . . . . . . . . . . . . .</addtochat>
  522.         </if>
  523.         <!--Specific Spells-->
  524.         <if spell="Aquaveil*|Blink|Deodorize|Dia*|Erase|Escape|Invisible|*na|Pro*|Raise*|Re*|Shell*|Sneak|Tele*|Tractor|Warp*">
  525.             <equip when="midcast" set="ConserveMP" />
  526.             <return/>
  527.         </if>
  528.         <if spell="Stoneskin">
  529.             <equip when="midcast" set="%Spell" />
  530.             <return/>
  531.         </if>
  532.         <!--Elemental Magic Rules-->
  533.         <if Skill="ElementalMagic">
  534.             <!--Elemental Debuffs, not affected by Magic Attack Bonus, subbed in INT gear-->
  535.             <if Spell="Frost|Drown|Rasp|Burn|Shock|Choke">
  536.                 <equip when="midcast" Set="HighResist" />
  537.                 <equip when="midcast"><head>Goetia Petasos +2</head><body>Errant Hpl.</body></equip>
  538.             </if>
  539.             <!--All Nukes-->
  540.             <else>
  541.                 <midcastdelay Delay="2" />
  542.                 <!--High resist mobs when NOT using Elemental Seal-->
  543.                 <if SpellTargetName="Genbu|Suzaku|Seiryu|Byakko|Kirin|Cerberus|Khimaira|Tyger|Jailer of Love|Sarameya|Andhrimnir|Ariri Samariri" NotBuffActive="Elemental Seal">
  544.                     <equip when="midcast" Set="HighResist" />
  545.                     <addtochat Color="369" when="midcast">. . . . . . . . . . . . . . - - HighResist Equipped - - . . . . . . . . . . . . . .</addtochat>
  546.                 </if>
  547.                 <else>
  548.                     <!--Mid resist mobs NOT using Elemental Seal-->
  549.                     <if SpellTargetName="Proto*|Fafnir|Tinnin|Jailer*|Odin|Freke|Gorgimera|Vampyr Jarl|Balrahn" NotBuffActive="Elemental Seal">
  550.                         <equip when="midcast" Set="MidResist" />
  551.                         <addtochat Color="369" when="midcast">. . . . . . . . . . . . . . - - MidResist Equipped - - . . . . . . . . . . . . . .</addtochat>
  552.                     </if>
  553.                     <else>
  554.                         <!--Light Resisting Mobs or Dynamis/Einherjar/Salvage-->
  555.                         <if mode="or" Area="Dynamis *|Hazhalm*|*Remnants*" SpellTargetName="Dea|Lambton Worm|Sandworm|Guivre|King Arthro|Serket">
  556.                             <if NotBuffActive="Elemental Seal">
  557.                                 <equip when="midcast" Set="LightResist" />
  558.                                 <addtochat Color="369" when="midcast">. . . . . . . . . . . . . . - - LightResist Equipped - - . . . . . . . . . . . . . .</addtochat>
  559.                             </if>
  560.                             <else>
  561.                                 <equip when="midcast" Set="FullDamage" />
  562.                             </else>
  563.                         </if>
  564.                         <!--All other Mobs or using Elemental Seal-->
  565.                         <else>
  566.                             <equip when="midcast" Set="FullDamage" />
  567.                         </else>
  568.                     </else>
  569.                 </else>
  570.                 <!--Uggalepih Pendant rules based on exact MP numbers to activate with given gear and mobs-->
  571.                 <if MLvlGT="69">
  572.                     <!--When not using Elemental Seal-->
  573.                     <if NotBuffactive="Elemental Seal" SpellTargetName="Genbu|Suzaku|Seiryu|Byakko|Kirin|Cerberus|Khimaira|Tyger|Jailer of Love|Sarameya|Andhrimnir|Ariri Samariri" MPAftercastLT="$%SubjobHighResistMP">
  574.                         <equip when="midcast"><neck lock="t">Uggalepih Pendant</neck></equip>
  575.                         <addtochat Color="369" when="midcast">. . . . . . . . . . . . . . - - Uggalepih Pendant Equipped - - . . . . . . . . . . . . . .</addtochat>
  576.                     </if>
  577.                     <!--Using Elemental Seal-->
  578.                     <elseif MPAftercastLT="$%SubjobUggPendantMP">
  579.                         <equip when="midcast"><neck lock="t">Uggalepih Pendant</neck></equip>
  580.                         <addtochat Color="369" when="midcast">. . . . . . . . . . . . . . - - Uggalepih Pendant Equipped - - . . . . . . . . . . . . . .</addtochat>
  581.                     </elseif>
  582.                 </if>
  583.                 <!--Rules for when borrowing Novio Earring-->
  584.                 <if advanced='$HaveNovio == 1'>
  585.                     <equip when="midcast"><rear>Novio Earring</rear></equip>
  586.                 </if>
  587.                 <!--Sorc Ring rules using exact HP amounts to trigger-->
  588.                 <if MLvlGT="49" advanced='$HaveSorcRing == 1'>
  589.                     <if HPLT="$%SubJobRingHP">
  590.                         <equip when="midcast">
  591.                         <lring lock="t">Sorcerer's Ring</lring>
  592.                         </equip>
  593.                         <command when="precast">cancel 42</command>
  594.                         <addtochat Color="369" when="midcast">. . . . . . . . . . . . . . - - Sorcerer's Ring Equipped - - . . . . . . . . . . . . . .</addtochat>
  595.                     </if>
  596.                 </if>
  597.                 <!--Sorcerer's Tonban Rules. Equips af2 when spell element matches day element, but only if not already at 35% cap from obi for matching day and double weather-->
  598.                 <if Advanced='(!((bool)strmatch("* x2","%Weather") AND "%WeatherElement" = "%SpellElement" AND "$%SpellElementObi" = "1") OR !("%WeatherElement" = "%SpellElement")) AND ("%SpellElement" = "%DayElement" AND "$BLMAF2Pants" = "1") AND ("%skill"="ElementalMagic")'>
  599.                     <equip when="midcast">
  600.                         <legs lock="t">Sorcerer's Tonban</legs>
  601.                     </equip>
  602.                     <addtochat Color="369" when="midcast">. . . . . . . . . . . . . . - - Sorcerer's Tonban Equipped - - . . . . . . . . . . . . . .</addtochat>
  603.                     <if advanced='"$TwilightCape" == "1"'>
  604.                         <equip when="midcast"><back lock="yes">Twilight Cape</back>
  605.                     </equip>
  606.                     <addtochat Color="369" when="midcast">. . . . . . . . . . . . . . - - Twilight Cape Equipped - - . . . . . . . . . . . . . .</addtochat>
  607.                     </if>
  608.                 </if>
  609.                     <if advanced="%MoonPCT &gt;35">
  610.                         <equip when="midcast">
  611.                                 <neck lock="yes">Artemis' Medal</neck>
  612.                         </equip>
  613.                 </if>
  614.                 <if MPPAfterCastLT="50">
  615.                     <if advanced="%MoonPCT &gt;80">
  616.                             <equip when="midcast">
  617.                                     <neck lock="yes">Artemis' Medal</neck>
  618.                             </equip>
  619.                     </if>
  620.                     <elseif advanced="$UggPendant==1">
  621.                             <equip when="midcast">
  622.                                     <neck lock="yes">Uggalepih Pendant</neck>
  623.                             </equip>
  624.                     </elseif>                                                              
  625.                 </if>
  626.             </else>
  627.             <return/>
  628.         </if>
  629.         <!--All other magic spells-->
  630.         <if Skill="*Magic|Ninjutsu|Singing">
  631.             <equip when="midcast" set="%Skill" />
  632.             <return/>
  633.         </if>
  634.     </rules>
  635. </spellcast>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement