WARNING: Some of this code may be outdated, last update in August 2009.
If you wish to read a more in depth breakdown behind the thinking, structure and code in this SpellCast/AutoExec example, I made a post on my LiveJournal post
I set this up to have 1-hit keys for each avatar. Personally, I rarely use F9 through F12 and I rarely use [ or ]. Therefore, my example has keys bound as:
| Key | Bound |
| F9 | Assault |
| F10 | Physical BP Rage |
| F11 | Magical BP Rage or Astral Flow BP |
| F12 | Best BP Ward |
| [ | Retreat |
| ] | Release |
I am only binding 3 BPs per avatar, so it is assumed in this xml that in-game macro sets are setup to coincide with the xml, to provide the rest of the Blood Pacts which are not bound to keys. This might be unpopular, but given the low frequency of use, it's okay. After all, this is just an example, you can change it.
For this example, when releasing, the macro set returns to set one, when summoning, the macro set switches to the proper set. The sets for this xml are:
| Macro Set | Avatar |
| Set #1 | No Avatar |
| Set #2 | Carbuncle |
| Set #3 | Diabolos |
| Set #4 | Fenrir |
| Set #5 | Garuda |
| Set #6 | Ifrit |
| Set #7 | Leviathan |
| Set #8 | Ramuh |
| Set #9 | Titan |
| Set #10 | Shiva |
Features
Locking in sets to maintain maximum MP as long as possible.
Locking in Balrahn's Ring while in Assault/Nyzul/Salvage.
Automatically choosing the correct Elemental Spirit for Siphon.
As previously mentioned, using aliases to bind keys F10-F12 to the avatars best blood pacts.
As previously mentioned, automatically binding the Astral Flow Blood Pact to F11 when used or Astral Flow is active.
Providing the possibility of Fenrir's current Blood Pacts displaying when Summoned and when the Blood Pacts are performed. (currently seems to be an issue with %moonpct variable so this isn't completely accurate right now)
Equipping the correct AFv2 depending on day and weather with unique sets for avatars.
Gearing swapping maximize Blood Pact potency while reducing Blood Pact timers.
Conjurer's ring support.
Blink casting support.
Instant wake up when slept with avatar out.
Spell cancelling sneak.
Changespell setups to switch Cure 3 to Cure 2 to Regen if you don't have enough MP to cast the spell specified.
Changespell setups to switch Regen 2 to Regen if you don't have enough MP to cast the Regen spell specified.
Many of the basic concepts came from ddaydj's smn xml and Whitewing's smn xml.
I don't think this will make sense without posting everything, so I am going to post the load script, AutoExec XML and SpellCast XML.
Script loading up Summoner
sc load smn.xml
autoexec load smn1.xml
keyboard_bind F9 assault
keyboard_bind F10 bp1
keyboard_bind F11 bp2
keyboard_bind F12 bp3
keyboard_bind [ retreat
keyboard_bind ] release
keyboard_bind ^` sublimation
keyboard_bind ^h input /item "Wizard Cookie" <me>;wait 1.5;input /heal
keyboard_bind !h input /item "Wizard Cookie" <me>;wait 1.5;input /heal
1st AutoExec XML
<autoexec>
<!--This calls to switch your ring to Belrahn's for assault/salvage areas, it also changes this autoexec file with on that doesn't include the ring changing at the bottom-->
<register event="zone_Leujaoam_Sanctum|zone_Mamool_Ja_Training_Grounds|zone_Lebros_Cavern|zone_Periqia|zone_Ilrusi_Atoll|zone_Nyzul_Isle|zone_*Remnants">sc var set Ring "Balrahn's Ring";autoexec load smn2.xml;</register>
<!--This will wake you up instantly if you have an avatar out, if you don't have an avatar, it at least removes stoneskin to help-->
<register event="gainbuff_sleep">cancel 37;input /equip neck "Sacrifice Torque"</register>
<!--To replace the Sac Torque so you don't continue to lose life-->
<register event="losebuff_sleep">input /equip neck "Orochi Nodowa"</register>
<!--If you hit 100% MP, this puts your maximum MP gear on, SpellCast commands are not used because it happens regardless of set, Hierarch Belt is added in case you are still healing-->
<register event="mpp_100">sc var set MPNeck "Beak Necklace +1";sc var set MPBack "Intensifying Cape";input /equip neck "Beak Necklace +1";input /equip back "Intensifying Cape";input /equip waist "Hierarch Belt"</register>
<!--These variables are for switching rings when you go below 75% hp, the problem is it will switch them even w/o an avatar out, but it is more dynamic than placing this in spellcast, since HP can fluctuate at any time-->
<register event="hppgt75">sc var set Ring "$TRing";input /equip ring2 "Trooper's Ring"</register>
<register event="hpplt76">sc var set Ring "$CRing";input /equip ring2 "Conjurer's Ring"</register>
</autoexec>
2nd AutoExec XML - loaded when entering nyzul/assault/salvage reverts upon exit
<autoexec>
<register event="zone_*">sc var set Ring "Serket Ring";autoexec load smn1.xml;</register>
<register event="gainbuff_sleep">cancel 37;input /equip neck "Sacrifice Torque"</register>
<register event="losebuff_sleep">input /equip neck "Orochi Nodowa"</register>
<register event="mpp_100">sc var set MPNeck "Beak Necklace +1";sc var set MPBack "Intensifying Cape";input /equip neck "Beak Necklace +1";input /equip back "Intensifying Cape";</register>
</autoexec>
SpellCast XML
<spellcast>
<config
RequireVersion="2.30"
ShowGearSwaps="false"
Debug="false"
HideErrors="false"
ShowSpellInfo="false"
/>
<variables crear="true">
<!--This determines if Fenrir's Blood Pact stats are displayed in /echo. 1 for on, 0 for off.-->
<var name="FenrirStats">1</var>
<!--Current standing set, Current standing staff and current avatar variables-->
<var name="CurrentSet">Idle</var>
<var name="CurrentStaff">Terra's Staff</var>
<var name="CurrentAvatar">None</var>
<!--Variables for elemental staves making them ElementStaff-->
<var name="IceStaff">Aquilo's Staff</var>
<var name="WindStaff">Auster's Staff</var>
<var name="EarthStaff">Terra's Staff</var>
<var name="ThunderStaff">Jupiter's Staff</var>
<var name="WaterStaff">Water Staff</var>
<var name="FireStaff">Fire Staff</var>
<var name="DarkStaff">Pluto's Staff</var>
<var name="LightStaff">Light Staff</var>
<!--Variables creating the elemental logic needed to choose the correct elemental for siphon -->
<var name="NoneStrength">-1</var>
<var name="LightStrength">-1</var>
<var name="DarkStrength">-1</var>
<var name="FireStrength">6</var>
<var name="IceStrength">5</var>
<var name="WindStrength">4</var>
<var name="EarthStrength">3</var>
<var name="ThunderStrength">2</var>
<var name="WaterStrength">1</var>
<!--Variables for Elemental Spirit Names used for changespells for Elemental Siphon-->
<var name="LightSpirit">Light Spirit</var>
<var name="DarkSpirit">Dark Spirit</var>
<var name="FireSpirit">Fire Spirit</var>
<var name="EarthSpirit">Earth Spirit</var>
<var name="WindSpirit">Air Spirit</var>
<var name="WaterSpirit">Water Spirit</var>
<var name="IceSpirit">Ice Spirit</var>
<var name="ThunderSpirit">Thunder Spirit</var>
<!--Variables for the possible right rings-->
<var name="Ring">Serket Ring</var>
<!--Variables to equip the correct head piece-->
<var name="PerpHead">Summoner's Horn</var>
<var name="DmgHead">Evk. Horn +1</var>
<!--Gear with apostrophes that needs to be set in variables-->
<var name="SHorn">Summoner's Horn</var>
<var name="TRing">Trooper's Ring</var>
<var name="CRing">Conjurer's Ring</var>
<!--Gear that determines main gear for max MP-->
<var name="MPNeck">Beak Necklace +1</var>
<var name="MPBack">Intensifying Cape</var>
<!--MP max for each subjob, needed for MP Locks, add any other subs if needed-->
<var name="SCHmax">1160</var>
<var name="WHMmax">1179</var>
<var name="NINmax">1101</var>
<var name="THFmax">1101</var>
</variables>
<sets>
<group name="Default" default="Yes">
<!-- The Idle set is the basis of all sets -->
<set name="Idle">
<main>$CurrentStaff</main>
<sub>Staff Strap</sub>
<ammo>Hedgehog Bomb</ammo>
<head>Summoner's Horn</head>
<neck>$MPNeck</neck>
<lear>Loquac. Earring</lear>
<rear>Magnetic Earring</rear>
<body>Yinyang Robe</body>
<hands>Nashira Gages</hands>
<lring>Evoker's Ring</lring>
<rring>$Ring</rring>
<back>$MPBack</back>
<waist>Hierarch Belt</waist>
<legs>Summoner's Spats</legs>
<feet>Evk. Pigaches +1</feet>
</set>
<!-- This set is for gear you wear with your avatar out that isn't normall equipped -->
<set name="Pet" baseset="Idle">
<head>$PerpHead</head>
<legs>Evk. Spats +1</legs>
</set>
<!-- Day/Weather/Full adds in AFv2 gear if day or weather match avatar-->
<set name="Day" baseset="Pet">
<body>Summoner's Dblt.</body>
</set>
<set name="Weather" baseset="Pet">
<head>Summoner's Horn</head>
</set>
<set name="Full" baseset="Pet">
<head>Summoner's Horn</head>
<body>Summoner's Dblt.</body>
</set>
<!--Carbuncle specific gear, only Refresh top, Carby Mitts and Light Staff required for 1 mp tick.-->
<set name="Carbuncle" baseset="Pet">
<hands>Carbuncle Mitts</hands>
<feet>Summoner's Pgch.</feet>
</set>
<!--Astral Flow gear, perpetuation gear and MP is not needed-->
<set name="AstralFlow" baseset="Pet">
<neck>Orochi Nodowa</neck>
<rear>Magnetic Earring</rear>
<body>Yinyang Robe</body>
<hands>Summoner's Brcr.</hands>
<lring>Evoker's Ring</lring>
<rring>$Ring</rring>
<back>Cheviot Cape</back>
<feet>Summoner's Pgch.</feet>
</set>
<!--BloodPact Based Gear-->
<!--Gear to reduce Bloodpact delay-->
<set name="BPTime" baseset="$CurrentSet">
<head>Summoner's Horn</head>
<body>Yinyang Robe</body>
<hands>Summoner's Brcr.</hands>
<legs>Summoners's Spats</legs>
<feet>Summoner's Pgch.</feet>
</set>
<!--Gear to increase Smn Skill-->
<set name="BPSkill1" baseset="$CurrentSet">
<head>Evk. Horn +1</head>
<rear>Smn. Earring</rear>
<neck>Smn. Torque</neck>
<hands>Summoner's Brcr.</hands>
<legs>Austere Slops</legs>
<feet>Austere Sabots</feet>
</set>
<!--Gear for Smn Skill to minimize MP loss when MP hasn't been depleted-->
<set name="BPSkill2" baseset="$CurrentSet">
<head>Evk. Horn +1</head>
<rear>Smn. Earring</rear>
<neck>Smn. Torque</neck>
<body>Evk. Doublet +1</body>
<hands>Summoner's Brcr.</hands>
<legs>Austere Slops</legs>
<feet>Austere Sabots</feet>
</set>
<!--Gear to increase bp damage -->
<set name="BPDmg" baseset="$CurrentSet">
<head>$DmgHead</head>
<rear>Smn. Earring</rear>
<neck>Sacrifice Torque</neck>
<body>Summoner's Doublet</body>
<hands>Summoner's Brcr.</hands>
<legs>Evk. Spats +1</legs>
<feet>Summoner's Pgch.</feet>
</set>
<!--Resting sets, second set is swapped shortly before first healing MP tick-->
<set name="Resting1" baseset="Idle">
<main>Pluto's Staff</main>
<head>Cobra Hat</head>
<neck>Beak Necklace +1</neck>
<rear>Magnetic Earring</rear>
<body>Yinyang Robe</body>
<hands>Genie Gages</hands>
<back>Intensifying Cape</back>
<waist>Qiqirn Sash +1</waist>
<legs>Baron's Slops</legs>
</set>
<!--I didn't put in a baseset, because to avoid the error spam if you happen to look at the expanded log while resting-->
<set name="Resting2">
<body>Evk. Doublet +1</body>
</set>
<!--Fast Cast which doesn't provide much speed, this is also the back up blink cast set for when you spam abilities-->
<set name="FastCast">
<head>Walahra Turban</head>
<lear>Loquac. Earring</lear>
<waist>Swift Belt</waist>
<feet>Rostrum Pumps</feet>
</set>
<!--This set is designed to make you blink momentarily, I prefer -enmity pieces.-->
<set name="BlinkCast">
<!--Penitent's Rope does not cause a conflict b/c it's locked if MP is too high-->
<waist>Penitent's Rope</waist>
<legs>Jet Seraweels</legs>
</set>
<!--The basic set for all non-Summoner spells, except Ninjutsu-->
<set name="BaseMagic" baseset="Idle">
<main>$%SpellElementStaff</main>
<head>Evk. Horn +1</head>
<main>Errant Hpl.</main>
<rring>Balrahn's Ring</rring>
<back>Prism Cape</back>
<waist>Penitent's Rope</waist>
<legs>Jet Seraweels</legs>
<feet>Rostrum Pumps</feet>
</set>
<set name="DarkMagic" baseset="FastCast">
<main>$%SpellElementStaff</main>
<rring>Balrahn's Ring</rring>
<neck>Dark Torque</neck>
<rear>Dark Earring</rear>
</set>
<set name="DivineMagic" baseset="BaseMagic"/>
<!--This should have your max Elemental Magic gear if you carry it, for those with Genie Gages you can put them in for fun lol XD-->
<set name="ElementalMagic" baseset="BaseMagic">
<hands>Genie Gages</hands>
</set>
<!--This should have your max Enfeebling Magic gear if you carry it-->
<set name="EnfeeblingMagic" baseset="BaseMagic"/>
<!--This should have your max Enhancing Magic gear if you carry it-->
<set name="EnhancingMagic" baseset="Idle" />
<!--Probably best to keep -enmity gear in here since MND and enhancing gear make little difference-->
<set name="HealingMagic" baseset="BaseMagic">
<rring>Trooper's Ring</rring>
</set>
<!--Max mind setup-->
<set name="MindSetup" baseset="BaseMagic">
<main>Kirin's Pole</main>
</set>
<!--If you use a Skulker's cape put it here-->
<set name="Skulker" />
<set name="LightObi" baseset="%Skill">
<waist>Korin Obi</waist>
</set>
<set name="DarkObi" baseset="%Skill">
<waist>Anrin Obi</waist>
</set>
</group>
</sets>
<rules>
<!--These rules lock your gear so that you don't reduce your MP with unnecessary slot changes and switch to more defensive gear as your MP becomes lower, ignored if Astral Flow is on-->
<if mode="or" notbuffactive="Astral Flow" notspell="Sleep">
<!--These particular rules are for Assault and Nyzul, since you'll probably use a Balrahn's Ring, you will not be using a MP ring.-->
<if area="Leujaoam Sanctum|Mamool Ja Training Grounds|Lebros Cavern|Periqia|Ilrusi Atoll|Nyzul Isle">
<if advanced='%MP<($%SubJobmax-170)'>
<var cmd='set MPNeck "Orochi Nodowa"'/>
<var cmd='set MPBack "Cheviot Cape"'/>
</if>
<elseif advanced='%MP<($%SubJobmax-122)'>
<changelock when="precast|midcast|aftercast" slot="waist" lock="yes"/>
<var cmd='set MPNeck "Orochi Nodowa"'/>
<var cmd='set MPBack "Cheviot Cape"'/>
</elseif>
<elseif mode="and" advanced='%MP<($%SubJobmax-92)'>
<changelock when="precast|midcast|aftercast" slot="back|waist" lock="yes"/>
<var cmd='set MPNeck "Orochi Nodowa"'/>
<var cmd='set MPBack "Intensifying Cape"'/>
</elseif>
<elseif mode="and" nottype="BloodPact*" advanced='%MP<($%SubJobmax-72)'>
<changelock when="precast|midcast|aftercast" slot="rear|back|rring|waist" lock="yes"/>
<var cmd='set MPNeck "Orochi Nodowa"'/>
<var cmd='set MPBack "Intensifying Cape"'/>
</elseif>
<elseif nottype="BloodPact*">
<changelock when="precast|midcast|aftercast" slot="neck|rear|rring|back|waist" lock="yes"/>
<var cmd='set MPNeck "Beak Necklace +1"'/>
<var cmd='set MPBack "Intensifying Cape"'/>
</elseif>
<!--If MP is above the last tier and it is a blood pact, we will not lock the ear & neck to maximize the BP-->
<else>
<changelock when="precast|midcast|aftercast" slot="rring|back|waist" lock="yes"/>
<var cmd='set MPNeck "Beak Necklace +1"'/>
<var cmd='set MPBack "Intensifying Cape"'/>
</else>
</if>
<!--These rules are for Salvage, the rules won't work well in here. Regardless, it's normally best to max out MP in there anyway-->
<elseif area="*Remnants">
<var cmd='set MPNeck "Beak Necklace +1"'/>
<var cmd='set MPBack "Intensifying Cape"'/>
</elseif>
<!--These are /whm and /sch up, since the two are fairly close anyway, I've left them both set to the /sch numbers-->
<elseif subjob="SCH|WHM|NIN|THF">
<if advanced='%MP<($%SubJobmax-170)'>
<var cmd='set MPNeck "Orochi Nodowa"'/>
<var cmd='set MPBack "Cheviot Cape"'/>
<if advanced='"$Ring"!="$CRing"'>
<var cmd='set Ring "$TRing"'/>
</if>
</if>
<elseif advanced='%MP<($%SubJobmax-140)'>
<changelock when="precast|midcast|aftercast" slot="back" lock="yes"/>
<var cmd='set MPNeck "Orochi Nodowa"'/>
<var cmd='set MPBack "Intensifying Cape"'/>
<if advanced='"$Ring"!="$CRing"'>
<var cmd='set Ring "$TRing"'/>
</if>
</elseif>
<elseif advanced='%MP<($%SubJobmax-90)'>
<changelock when="precast|midcast|aftercast" slot="back|rring" lock="yes"/>
<var cmd='set MPNeck "Orochi Nodowa"'/>
<var cmd='set MPBack "Intensifying Cape"'/>
<if advanced='"$Ring"!="$CRing"'>
<var cmd='set Ring "Serket Ring"'/>
</if>
</elseif>
<elseif mode="AND" nottype="BloodPact*" advanced='%MP<($%SubJobmax-42)'>
<changelock when="precast|midcast|aftercast" slot="back|rring|waist" lock="yes"/>
<var cmd='set MPNeck "Orochi Nodowa"'/>
<var cmd='set MPBack "Intensifying Cape"'/>
<if advanced='"$Ring"!="$CRing"'>
<var cmd='set Ring "Serket Ring"'/>
</if>
</elseif>
<elseif mode="AND" nottype="BloodPact*" advanced='%MP<($%SubJobmax-22)'>
<changelock when="precast|midcast|aftercast" slot="rear|back|rring|waist" lock="yes"/>
<var cmd='set MPNeck "Orochi Nodowa"'/>
<var cmd='set MPBack "Intensifying Cape"'/>
<if advanced='"$Ring"!="$CRing"'>
<var cmd='set Ring "Serket Ring"'/>
</if>
</elseif>
<elseif nottype="BloodPact*">
<changelock when="precast|midcast|aftercast" slot="neck|rear|rring|back|waist" lock="yes"/>
<var cmd='set MPNeck "Beak Necklace +1"'/>
<var cmd='set MPBack "Intensifying Cape"'/>
<if advanced='"$Ring"!="$CRing"'>
<var cmd='set Ring "Serket Ring"'/>
</if>
</elseif>
<else>
<changelock when="precast|midcast|aftercast" slot="rring|back|waist" lock="yes"/>
<var cmd='set MPNeck "Beak Necklace +1"'/>
<var cmd='set MPBack "Intensifying Cape"'/>
<if advanced='"$Ring"!="$CRing"'>
<var cmd='set Ring "Serket Ring"'/>
</if>
</else>
</elseif>
<!--For any unforeseen circumstances-->
<else>
<var cmd='set MPNeck "Orochi Nodowa"'/>
<var cmd='set MPBack "Cheviot Cape"'/>
<if advanced='"$Ring"!="$CRing"'>
<var cmd='set Ring "Serket Ring"'/>
</if>
</else>
</if>
<!--This will be caught by autoset events-->
<if spell="autoset">
<if status="resting">
<!--Set standard gear picks to max MP, including Serket if not in a refresh zone-->
<var cmd='set MPNeck "Beak Necklace +1"'/>
<var cmd='set MPBack "Intensifying Cape"'/>
<if notarea="Leujaoam Sanctum|Mamool Ja Training Grounds|Lebros Cavern|Periqia|Ilrusi Atoll|Nyzul Isle">
<var cmd='set Ring "Serket Ring"'/>
</if>
<equip when="resting" set="Resting1"/>
<command when="resting">wait 18.3;sc set Resting2</command>
</if>
<elseif status="idle">
<equip when="idle" set="$CurrentSet"/>
</elseif>
<elseif status="dead|zoning">
<changelock when="*" slot="main|sub|range|ammo|head|neck|rear|lear|body|hands|lring|rring|back|waist|legs|feet" lock="yes"/>
</elseif>
</if>
<!--Rules for spirits and avatars-->
<if type="SummonerPact">
<var cmd='set CurrentStaff "$%SpellElementStaff"'/>
<equip when="precast" set="FastCast"/>
<!--These keyboard binds are used regardless of it being an avatar or a elemental spirit-->
<command when="precast">keyboard_bind F9 Assault;keyboard_bind [ Retreat</command>
<!--The following statements all effect non-gear; sets keyboard binds and chooses correct spell for siphon-->
<if spell="*Spirit">
<if area="Dynamis*|*Apollyon*">
<changespell spell="$DarkSpirit"/>
</if>
<elseif area="*Temenos*">
<changespell spell="$LightSpirit"/>
</elseif>
<!--Checks if Weather Element is stronger than Day Element-->
<elseif Advanced='"%WeatherElement"!="None" AND ("%Weather"="%WeatherElement x2" OR $%WeatherElementStrength!=$%DayElementStrength-1 OR "%WeatherElement"="Fire" AND "%DayElement"!="Water")'>
<changespell spell="$%WeatherElementSpirit"/>
</elseif>
<else>
<changespell spell="$%DayElementSpirit"/>
</else>
</if>
<!--Else is reserved for setting binds and variables when summoning-->
<else>
<!--Dark avatars are embedded together-->
<if element="Dark">
<!--Diabolos's aliases do not follow the usual PhyRage, MagRage, Ward structure:
bp1 Nether Blast
bp2 Dream Shroud
bp3 Noctoshield-->
<if spell="Diabolos">
<var cmd="set CurrentAvatar Diabolos"/>
<if buffactive="Astral Flow">
<command when="midcast">input /macro set 3;alias bp1 NetherBlast;alias bp2 RuinousOmen;alias bp3 Noctoshieldalias</command>
</if>
<else>
<command when="midcast">input /macro set 3;alias bp1 NetherBlast;alias bp2 DreamShroud;alias bp3 Noctoshield</command>
</else>
</if>
<!--Fenrir's aliases do not follow the usual PhyRage, MagRage, Ward structure:
bp1 Eclipse Bite
bp2 Ecliptic Growl
bp3 Ecliptic Howl-->
<elseif spell="Fenrir">
<var cmd="set CurrentAvatar Fenrir"/>
<if buffactive="Astral Flow">
<command when="midcast">input /macro set 4;alias bp1 EclipseBite;alias bp2 HowlingMoon;alias bp3 EclipticHowl</command>
</if>
<else>
<command when="midcast">input /macro set 4;alias bp1 EclipseBite;alias bp2 EclipticGrowl;alias bp3 EclipticHowl</command>
</else>
<if advanced='"$FenrirStats"="1"'>
<if advanced='"%MoonPCT">"89"'>
<command when="precast">input /echo FENRIR MOON BASED BLOOD PACT STATS @ MOON %MOONPCT%;input /echo [Ecliptic Howl] Accuracy 25 - Evasion 1;input /echo [Ecliptic Growl] STR/DEX/VIT 7 - INT/MND/CHR/AGI 1;input /echo [Lunar Cry] Enemy Acc Down 31 - Enemy Eva Down 1</command>
</if>
<elseif advanced='"%MoonPCT">"74"'>
<command when="precast">input /echo FENRIR MOON BASED BLOOD PACT STATS @ MOON %MOONPCT%;input /echo [Ecliptic Howl] Accuracy 21 - Evasion 5;input /echo [Ecliptic Growl] STR/DEX/VIT 6 - INT/MND/CHR/AGI 2;input /echo [Lunar Cry] Enemy Acc Down 26 - Enemy Eva Down 6</command>
</elseif>
<elseif advanced='"%MoonPCT">"59"'>
<command when="precast">input /echo FENRIR MOON BASED BLOOD PACT STATS @ MOON %MOONPCT%;input /echo [Ecliptic Howl] Accuracy 17 - Evasion 9;input /echo [Ecliptic Growl] STR/DEX/VIT 5 - INT/MND/CHR/AGI 3;input /echo [Lunar Cry] Enemy Acc Down 21 - Enemy Eva Down 11</command>
</elseif>
<elseif advanced='"%MoonPCT">"39"'>
<command when="precast">input /echo FENRIR MOON BASED BLOOD PACT STATS @ MOON %MOONPCT%;input /echo [Ecliptic Howl] Accuracy 13 - Evasion 13;input /echo [Ecliptic Growl] STR/DEX/VIT 4 - INT/MND/CHR/AGI 4;input /echo [Lunar Cry] Enemy Acc Down 16 - Enemy Eva Down 16</command>
</elseif>
<elseif advanced='"%MoonPCT">"24"'>
<command when="precast">input /echo FENRIR MOON BASED BLOOD PACT STATS @ MOON %MOONPCT%;input /echo [Ecliptic Howl] Accuracy 9 - Evasion 17;input /echo [Ecliptic Growl] STR/DEX/VIT 3 - INT/MND/CHR/AGI 5;input /echo [Lunar Cry] Enemy Acc Down 11 - Enemy Eva Down 21</command>
</elseif>
<elseif advanced='"%MoonPCT">"9"'>
<command when="precast">input /echo FENRIR MOON BASED BLOOD PACT STATS @ MOON %MOONPCT%;input /echo [Ecliptic Howl] Accuracy 5 - Evasion 21;input /echo [Ecliptic Growl] STR/DEX/VIT 2 - INT/MND/CHR/AGI 6;input /echo [Lunar Cry] Enemy Acc Down 6 - Enemy Eva Down 26</command>
</elseif>
<else>
<command when="precast">input /echo FENRIR MOON BASED BLOOD PACT STATS @ MOON %MOONPCT%;input /echo [Ecliptic Howl] Accuracy 1 - Evasion 25;input /echo [Ecliptic Growl] STR/DEX/VIT 1 - INT/MND/CHR/AGI 7;input /echo [Lunar Cry] Enemy Acc Down 1 - Enemy Eva Down 31</command>
</else>
</if>
</elseif>
</if>
<!--Carbuncle's aliases do not follow the usual PhyRage, MagRage, Ward structure,:
bp1 Meteorite
bp3 Shining Ruby (Pro/Shell) / Searing Light
bp2 Healing Ruby 2-->
<elseif spell="Carbuncle">
<var cmd="set CurrentAvatar Carbuncle"/>
<if buffactive="Astral Flow">
<command when="midcast">input /macro set 2;alias bp1 Meteorite;alias bp1 SearingLight;alias bp3 HealingRubyII</command>
</if>
<else>
<command when="midcast">input /macro set 2;alias bp1 Meteorite;alias bp2 ShiningRuby;alias bp3 HealingRubyII</command>
</else>
</elseif>
<!--Garuda's aliases are as follows:
bp1 Predator Claws
bp2 Wind Blade / Aerial Blast
bp3 Hastega-->
<elseif spell="Garuda">
<var cmd="set CurrentAvatar Garuda"/>
<var cmd='set PerpHead "Karura Hachigane"'/>
<var cmd='set DmgHead "Karura Hachigane"'/>
<if buffactive="Astral Flow">
<command when="midcast">input /macro set 5;alias bp1 PredatorClaws;alias bp2 AerialBlast;alias bp3 Hastega</command>
</if>
<else>
<command when="midcast">input /macro set 5;alias bp1 PredatorClaws;alias bp2 WindBlade;alias bp3 Hastega</command>
</else>
</elseif>
<!--Titan's aliases are as follows:
bp1 Mountain Buster
bp2 Geocrush
bp3 Earthen Ward-->
<elseif spell="Titan">
<var cmd="set CurrentAvatar Titan"/>
<if buffactive="Astral Flow">
<command when="midcast">input /macro set 9;alias bp1 MountainBuster;alias bp2 EarthenFury;alias bp3 EarthenWard</command>
</if>
<else>
<command when="midcast">input /macro set 9;alias bp1 MountainBuster;alias bp2 Geocrush;alias bp3 EarthenWard</command>
</else>
</elseif>
<!--Leviathan's aliases are as follows:
bp1 Spinning Dive
bp2 Water IV
bp3 Spring Water-->
<elseif spell="Leviathan">
<var cmd="set CurrentAvatar Leviathan"/>
<if buffactive="Astral Flow">
<command when="midcast">input /macro set 7;alias bp1 SpinningDive;alias bp2 TidalWave;alias bp3 SpringWater</command>
</if>
<else>
<command when="midcast">input /macro set 7;alias bp1 SpinningDive;alias bp2 Water4;alias bp3 SpringWater</command>
</else>
</elseif>
<!--Ramuh's aliases are as follows:
bp1 Chaotic Strike
bp2 Thunder IV
bp3 Lightning Armor-->
<elseif spell="Ramuh">
<var cmd="set CurrentAvatar Ramuh"/>
<if buffactive="Astral Flow">
<command when="midcast">input /macro set 8;alias bp1 ChaoticStrike;alias bp2 JudgmentBolt;alias bp3 LightningArmor</command>
</if>
<else>
<command when="midcast">input /macro set 8;alias bp1 ChaoticStrike;alias bp2 Thunder4;alias bp3 LightningArmor</command>
</else>
</elseif>
<!--Shiva's aliases are as follows:
bp1 Rush
bp2 Heavenly Strike
bp3 Sleepga-->
<elseif spell="Shiva">
<var cmd="set CurrentAvatar Shiva"/>
<if buffactive="Astral Flow">
<command when="midcast">input /macro set 10;alias bp1 Rush;alias bp2 DiamondDust;alias bp3 Sleepga</command>
</if>
<else>
<command when="midcast">input /macro set 10;alias bp1 Rush;alias bp2 HeavenlyStrike;alias bp3 Sleepga</command>
</else>
</elseif>
<!--Ifrit's aliases are as follows:
bp1 Flaming Crush
bp2 Fire IV
bp3 Crimson Howl-->
<elseif Spell="Ifrit">
<var cmd="set CurrentAvatar Ifrit"/>
<if buffactive="Astral Flow">
<command when="midcast">input /macro set 6;alias bp1 FlamingCrush;alias bp2 Inferno;alias bp3 CrimsonHowl</command>
</if>
<else>
<command when="midcast">input /macro set 6;alias bp1 FlamingCrush;alias bp2 Fire4;alias bp3 CrimsonHowl</command>
</else>
</elseif>
</else>
<!-- This set of statements determine the gear based on weather, day, et cetera -->
<if buffactive="Astral Flow">
<var cmd="set CurrentSet AstralFlow"/>
<equip When="midcast" set="AstralFlow"/>
</if>
<elseif spell="Carbuncle">
<!--Carbuncle does not need afv2 so his gear is specified differently -->
<var cmd="set CurrentSet Carbuncle"/>
<equip When="midcast" set="Carbuncle"/>
</elseif>
<!--Checks for both Day and Weather to see if it is the same as avatar/spirit and Equips both Afv2 Body and Head-->
<elseif advanced='"%spellElement"="%WeatherElement" and "%spellElement"="%DayElement"'>
<var cmd="set CurrentSet Full"/>
<equip when="midcast" set="Full"/>
</elseif>
<!--Checks to see if DayElement is same as avatar/spirit and equips Afv2 body-->
<elseif advanced='"%spellElement"="%DayElement"'>
<!--Sets gear to the elemant and afv2 body-->
<var cmd="set CurrentSet Day"/>
<equip when="midcast" set="Day"/>
</elseif>
<!--Checks to see if WeatherElement is same as avatar/spirit and equips Afv2 Head-->
<elseif advanced='"%spellElement"="%WeatherElement"'>
<var cmd="set CurrentSet Weather"/>
<equip when="midcast" set="Weather"/>
</elseif>
<!--If the situation doesn't warrant any day/weather gear else sets it to the normal gear -->
<else>
<var cmd="set CurrentSet Pet"/>
<equip when="midcast" set="Pet"/>
</else>
<equip when="aftercast" set="$CurrentSet"/>
</if>
<!--Checks if your doing a BloodPact and swaps gear for each calculation (Time SMN Skill+/Dmg + > Back to Original Gear before BP) -->
<elseif type="BloodPact*">
<if type="BloodPactWard">
<!--The following rules display the stats of the blood pact based on moon %, if people are trustworthy enough to not GM call for Windower, switch to /p. Personally, I trust no one... Eventhough I'm posting this on Windower.net-->
<if mode="AND" spell="Lunar Cry|Ecliptic*" advanced='"$FenrirStats"="1"'>
<if spell="Lunar Cry">
<if advanced='"%MoonPCT">"89"'>
<command when="precast">input /echo [Lunar Cry] %Target's Accuracry Down 31 - %Target's Eva Down 1</command>
</if>
<elseif advanced='"%MoonPCT">"74"'>
<command when="precast">input /echo [Lunar Cry] %Target's Accuracry Down 26 - %Target's Eva Down 6</command>
</elseif>
<elseif advanced='"%MoonPCT">"59"'>
<command when="precast">input /echo [Lunar Cry] %Target's Accuracry Down 21 - %Target's Eva Down 11</command>
</elseif>
<elseif advanced='"%MoonPCT">"39"'>
<command when="precast">input /echo [Lunar Cry] %Target's Accuracry Down 16 - %Target's Eva Down 16</command>
</elseif>
<elseif advanced='"%MoonPCT">"24"'>
<command when="precast">input /echo [Lunar Cry] %Target's Accuracry Down 11 - %Target's Eva Down 21</command>
</elseif>
<elseif advanced='"%MoonPCT">"9"'>
<command when="precast">input /echo [Lunar Cry] %Target's Accuracry Down 6 - %Target's Eva Down 26</command>
</elseif>
<else>
<command when="precast">input /echo [Lunar Cry] %Target's Accuracry Down 1 - %Target's Eva Down 21</command>
</else>
</if>
<elseif spell="Ecliptic Growl">
<if advanced='"%MoonPCT">"89"'>
<command when="precast">input /echo [Ecliptic Growl] STR/DEX/VIT 7 - INT/MND/CHR/AGI 1</command>
</if>
<elseif advanced='"%MoonPCT">"74"'>
<command when="precast">input /echo [Ecliptic Growl] STR/DEX/VIT 6 - INT/MND/CHR/AGI 2</command>
</elseif>
<elseif advanced='"%MoonPCT">"59"'>
<command when="precast">input /echo [Ecliptic Growl] STR/DEX/VIT 5 - INT/MND/CHR/AGI 3</command>
</elseif>
<elseif advanced='"%MoonPCT">"39"'>
<command when="precast">input /echo [Ecliptic Growl] STR/DEX/VIT 4 - INT/MND/CHR/AGI 4</command>
</elseif>
<elseif advanced='"%MoonPCT">"24"'>
<command when="precast">input /echo [Ecliptic Growl] STR/DEX/VIT 3 - INT/MND/CHR/AGI 5</command>
</elseif>
<elseif advanced='"%MoonPCT">"9"'>
<command when="precast">input /echo [Ecliptic Growl] STR/DEX/VIT 2 - INT/MND/CHR/AGI 6</command>
</elseif>
<else>
<command when="precast">input /echo [Ecliptic Growl] STR/DEX/VIT 1 - INT/MND/CHR/AGI 7</command>
</else>
</elseif>
<elseif spell="Ecliptic Howl">
<if advanced='"%MoonPCT">"89"'>
<command when="precast">input /echo [Ecliptic Howl] Accuracy 25 - Evasion 1</command>
</if>
<elseif advanced='"%MoonPCT">"74"'>
<command when="precast">input /echo [Ecliptic Howl] Accuracy 21 - Evasion 5</command>
</elseif>
<elseif advanced='"%MoonPCT">"59"'>
<command when="precast">input /echo [Ecliptic Howl] Accuracy 17 - Evasion 9</command>
</elseif>
<elseif advanced='"%MoonPCT">"39"'>
<command when="precast">input /echo [Ecliptic Howl] Accuracy 13 - Evasion 13</command>
</elseif>
<elseif advanced='"%MoonPCT">"24"'>
<command when="precast">input /echo [Ecliptic Howl] Accuracy 9 - Evasion 17</command>
</elseif>
<elseif advanced='"%MoonPCT">"9"'>
<command when="precast">input /echo [Ecliptic Howl] Accuracy 5 - Evasion 21</command>
</elseif>
<else>
<command when="precast">input /echo [Ecliptic Howl] Accuracy 1 - Evasion 25</command>
</else>
</elseif>
</if>
<equip when="precast" set="BPTime"/>
<!--This if statement determines if your current MP will be reduced by a Smn Skill gear with a perp body, if it will it replaces it with max MP body-->
<if advanced='%MP>($%SubJobmax-62)'>
<equip when="midcast" set="BPSkill2"/>
</if>
<else>
<equip when="midcast" set="BPSkill1"/>
</else>
<aftercastdelay delay="3.5"/>
<equip when="aftercast" set="$CurrentSet"/>
</if>
<elseif type="BloodPactRage">
<if spell="Fire*|Stone*|Water*|Aero*|Blizz*|Thund*|Meteor*|Heavenly*|Wind*|Geocrush*|Grand*">
<equip when="precast" set="BPTime"/>
<!--This if statement determines if your current MP will be reduced by a Smn Skill gear with a perp body, if it will it replaces it with max MP body-->
<if advanced='%MP>($%SubJobmax-62)'>
<equip when="midcast" set="BPSkill2"/>
</if>
<else>
<equip when="midcast" set="BPSkill1"/>
</else>
<aftercastdelay delay="3.5"/>
<equip when="aftercast" set="$CurrentSet"/>
</if>
<elseif spell="Searing*|Howling*|Inferno*|Earthen*|Tidal*|Aerial*|Diamond*|Judgment*|Ruinous*">
<!--Cancel Astral Flow Blood Pact if you don't have enough MP-->
<if advanced='(%MainJobLVL*2)>%MP'>
<cancelspell />
</if>
<else>
<equip when="precast" set="BPTime"/>
<equip when="midcast" set="BPSkill1"/>
<aftercastdelay delay="3.0"/>
<equip when="aftercast" set="$CurrentSet"/>
</else>
</elseif>
<else>
<equip when="precast" set="BPTime"/>
<equip when="midcast" set="BPDmg"/>
<aftercastdelay delay="3.0"/>
<equip when="aftercast" set="$CurrentSet"/>
</else>
</elseif>
</elseif>
<elseif type="PetCommand">
<!--this line provides nothing, except it makes you blink cast allowing to continue moving-->
<if EquipLegs="Jet Seraweels">
<equip when="precast" set="FastCast"/>
</if>
<else>
<equip when="precast" set="BlinkCast"/>
</else>
<if spell="Release">
<var cmd='set PerpHead "$SHorn"'/>
<var cmd='set DmgHead "Evk. Horn +1"'/>
<var cmd="set CurrentAvatar None"/>
<var cmd='set CurrentStaff "$EarthStaff"'/>
<var cmd="set CurrentSet Idle"/>
<defaulttarget target="<me>"/>
<command when="precast">input /macro set 1</command>
<equip when="aftercast" set="Idle"/>
</if>
<!--reset gear if you hit retreat-->
<else>
<equip when="aftercast" set="$CurrentSet"/>
</else>
</elseif>
<elseif type="JobAbility">
<if EquipLegs="Jet Seraweels">
<equip when="precast" set="FastCast"/>
</if>
<else>
<equip when="precast" set="BlinkCast"/>
</else>
<!--Equips Smn Skill gear to maximise mp gained -->
<if spell="Elemental Siphon">
<if advanced='%MP>($%SubJobmax-365)'>
<equip when="Precast|Midcast" set="BPskill2"/>
</if>
<else>
<equip when="Precast|Midcast" set="BPskill1"/>
</else>
<equip when="aftercast" set="$CurrentSet"/>
</if>
<if subjob="SCH">
<equip when="aftercast" set="$CurrentSet"/>
<!--When Light or Dark Arts are used, keys are bound for Alt+3 as MP reduction strategem Alt+4 as cast/recast strategem
Personally I like Alt+1 as Light Arts and Alt+2 as Dark Arts, this simplifies it for me, obviously you are free to change this to however you like-->
<if spell="Light Arts">
<!--If Light Arts is already active and Light Arts is used, it will trigger Addendum White, eliminating the need for a second macro/bind-->
<if buffactive="Light Arts">
<changespell spell="Addendum: White"/>
</if>
<command when="precast">keyboard_bind !3 Penury</command>
<command when="precast">keyboard_bind !4 Celerity</command>
</if>
<elseif spell="Dark Arts">
<!--If Dark Arts is already active and Dark Arts is used, it will trigger Addendum Black, eliminating the need for a second macro/bind-->
<if buffactive="Dark Arts">
<changespell spell="Addendum: Black"/>
</if>
<command when="precast">keyboard_bind !3 Parsimony</command>
<command when="precast">keyboard_bind !4 Alacrity</command>
</elseif>
</if>
<if spell="Astral Flow">
<var cmd="set CurrentSet AstralFlow"/>
<equip When="aftercast" set="AstralFlow"/>
<!--This overwrites what is usually magical bp-rage alias with the astral flow bp-->
<if advanced='"$CurrentAvatar"="Diabolos"'>
<command when="midcast">alias bp2 RuinousOmen</command>
</if>
<elseif advanced='"$CurrentAvatar"="Fenrir"'>
<command when="midcast">alias bp2 HowlingMoon</command>
</elseif>
<elseif advanced='"$CurrentAvatar"="Carbuncle"'>
<command when="midcast">alias bp2 SearingLight</command>
</elseif>
<elseif advanced='"$CurrentAvatar"="Garuda"'>
<command when="midcast">alias bp2 AerialBlast</command>
</elseif>
<elseif advanced='"$CurrentAvatar"="Titan"'>
<command when="midcast">alias bp2 EarthenFury</command>
</elseif>
<elseif advanced='"$CurrentAvatar"="Leviathan"'>
<command when="midcast">alias bp2 TidalWave</command>
</elseif>
<elseif advanced='"$CurrentAvatar"="Ramuh"'>
<command when="midcast">alias bp2 JudgmentBolt</command>
</elseif>
<elseif advanced='"$CurrentAvatar"="Shiva"'>
<command when="midcast">alias bp2 DiamondDust</command>
</elseif>
<elseif advanced='"$CurrentAvatar"="Ifrit"'>
<command when="midcast">alias bp2 Inferno</command>
</elseif>
</if>
</elseif>
<elseif type="WhiteMagic|BlackMagic">
<equip when="aftercast" set="$CurrentSet"/>
<if spell="Cur*" notspell="Cursna">
<!--Cure cancellation rules for when you subjob is SCH-->
<if subjob="SCH">
<if BuffActive="Light Arts">
<!-- Light Arts is Active -10% MP Cost -->
<if NotBuffActive="Penury">
<if Spell="Cure III" MPLT="42">
<changespell Spell="Cure II" />
</if>
<elseif Spell="Cure II" MPLT="22">
<changespell Spell="Regen" />
</elseif>
</if>
<else>
<!-- Penury is Active -50% MP Cost -->
<if Spell="Cure III" MPLT="23">
<changespell Spell="Cure II" />
</if>
<elseif Spell="Cure II" MPLT="12">
<changespell Spell="Regen" />
</elseif>
</else>
</if>
<!--Eek! Curing in Dark Arts-->
<elseif buffactive="Dark Arts">
<if Spell="Cure III" MPLT="54">
<changespell Spell="Cure II" />
</if>
<elseif Spell="Cure II" MPLT="28">
<changespell Spell="Regen" />
</elseif>
</elseif>
<!--No Arts-->
<else>
<if Spell="Cure III" MPLT="46">
<changespell Spell="Cure II" />
</if>
<elseif Spell="Cure II" MPLT="24">
<changespell Spell="Regen" />
</elseif>
</else>
</if>
<!--Cure cancellation rules for when you subjob isn't SCH-->
<else>
<if Spell="Cure III" MPLT="46">
<changespell Spell="Cure II" />
</if>
<elseif Spell="Cure II" MPLT="24">
<changespell Spell="Regen" />
</elseif>
</else>
<!--Gear changes for Cures-->
<equip when="precast" set="FastCast"/>
<if mode="OR" weather="Light" day="Lightsday">
<equip when="midcast" set="LightObi"/>
</if>
<else>
<equip when="midcast" set="%Skill"/>
</else>
</if>
<!--Due to Summoner's lack of powerful Cure spells I often use Regens, so I've applied similar rules-->
<elseif spell="Regen*">
<!--Regen cancellation rules for when you subjob is SCH-->
<if subjob="SCH">
<if BuffActive="Light Arts">
<!-- Light Arts is Active -10% MP Cost -->
<if NotBuffActive="Penury">
<if Spell="Regen II" MPLT="33">
<changespell Spell="Regen" />
</if>
<elseif Spell="Regen" MPLT="14">
<cancelspell />
</elseif>
</if>
<else>
<!-- Penury is Active -50% MP Cost -->
<if Spell="Regen II" MPLT="18">
<changespell Spell="Regen" />
</if>
<elseif Spell="Regen" MPLT="8">
<cancelspell />
</elseif>
</else>
</if>
<!--Eek! Regen in Dark Arts-->
<elseif BuffActive="DarkArts">
<if Spell="Regen II" MPLT="42">
<changespell Spell="Regen" />
</if>
<elseif Spell="Regen" MPLT="17">
<cancelspell />
</elseif>
</elseif>
<!--No Arts-->
<else>
<if Spell="Regen II" MPLT="36">
<changespell Spell="Regen" />
</if>
<elseif Spell="Regen" MPLT="15">
<cancelspell />
</elseif>
</else>
</if>
<!--Regen gear changes-->
<equip when="precast" set="FastCast"/>
</elseif>
<!--Gear changes for possible Dark Obi spells-->
<elseif spell="Drain|Aspir|Sleep">
<equip when="precast" set="FastCast"/>
<if mode="OR" weatherelement="Dark" day="Darksay">
<equip when="midcast" set="DarkObi"/>
</if>
<else>
<equip when="midcast" set="%Skill"/>
</else>
</elseif>
<!--Gear changes and self sneak cancel for skulker spells-->
<elseif spell="Sneak|Invisible">
<equip when="precast" set="FastCast"/>
<equip when="midcast" set="Skulker"/>
<if Spell="Sneak" BuffActive="Sneak" advanced='"%SpellTarget"="%PlayerName" OR "%SpellTarget"="<me>" OR ("%target"="%PlayerName" AND "%SpellTarget"="<t>")'>
<command when="midcast">cancel 71</command>
<midcastdelay delay="2.3" />
</if>
</elseif>
<!--Gear changes and buff cancel for Stoneskin-->
<elseif spell="Stoneskin">
<equip when="precast" set="FastCast"/>
<equip when="midcast" set="MindSetup"/>
<command when="midcast">cancel 37</command>
<midcastdelay delay="5.9" />
</elseif>
<!--Spells that do not require special enhancement-->
<elseif spell="Aquaveil|Bar*|Blink|Erase|Protect*|*Raise|Regen*|Shell*|*na">
<equip when="precast" set="FastCast"/>
</elseif>
<!--Teleport spells, feel free to change to /p if you're into that sort of thing-->
<elseif spell="Teleport*">
<command when="precast">input /echo Party of %PartyCount for %Spell.</command>
</elseif>
<!--All other spell-->
<else>
<equip when="precast" set="FastCast"/>
<equip when="midcast" set="%Skill"/>
</else>
</elseif>
<elseif type="Ninjutsu">
<equip when="aftercast" set="$CurrentSet"/>
<if spell="Utsusemi: Ichi" BuffActive="Copy Image">
<midcastdelay delay="2.7" />
<command when="midcast">cancel 66</command>
</if>
</elseif>
<else>
<equip when="aftercast" set="$CurrentSet"/>
</else>
</rules>
</spellcast>