New To SMN And SMN Mechanics

Eorzea Time
 
 
 
Language: JP EN FR DE
Version 3.1
New Items
342 users online
Forum » FFXI » Jobs » Summoner » New to SMN and SMN Mechanics
New to SMN and SMN Mechanics
Offline
Posts: 227
By Galkapryme 2020-04-02 16:48:27
Link | Quote | Reply
 
Like many people on Asura, I merc'd my SMN to Master. I also kept SMN gear I came across over the years, but it wasn't until recently that I actually started playing it. I ONLY play it (for now) in order to solo Odin's Chamber. While I manage to do it pretty consistently without dying (about 90% of the time), I still fumble around with the mechanics, and I could use some help.

1. My gearswap is ugly and confusing...especially when it comes to knowing what to wear WHILE the Avatar is fighting, but not necessarily for BP.
2. I don't know if BPR gear is the same I'd want to wear for BPW.
3. I got the BP recast thing on lock based on the gear I have.
4. I just found out about JSE staff (can't believe I forgot to check that), and it's being worked on as I type this.
5. I've got good perp gear, but I am trying to strike the balance between perp gear, refresh gear, and AVATAR attack gear.

6. WORST thing is HOW I play SMN. That is, I don't know whether to place all the summons in one macro line and all their abilities/spells on another. That seems like the best method when selecting like the top 10 summons I use, but I can really only select the top 6 BPs. I also tried having each Avatar and it's abilities and spells in its own macro set. THAT is truly cumbersome. I'd appreciate any tips. I've included my current GS Lua. Some of it is untouched, but some I have specifically added my gear. Thus far, I primarily use Ramuh, Ifrit, and Siren. I use Garuda for buffs. Subbing RDM.
Code
-------------------------------------------------------------------------------------------------------------------
-- Setup functions for this job.  Generally should not be modified.
-------------------------------------------------------------------------------------------------------------------

-- Also, you'll need the Shortcuts addon to handle the auto-targetting of the custom pact commands.

--[[
    Custom commands:
    
    gs c petweather
        Automatically casts the storm appropriate for the current avatar, if possible.
    
    gs c siphon
        Automatically run the process to: dismiss the current avatar; cast appropriate
        weather; summon the appropriate spirit; Elemental Siphon; release the spirit;
        and re-summon the avatar.
        
        Will not cast weather you do not have access to.
        Will not re-summon the avatar if one was not out in the first place.
        Will not release the spirit if it was out before the command was issued.
        
    gs c pact [PactType]
        Attempts to use the indicated pact type for the current avatar.
        PactType can be one of:
            cure
            curaga
            buffOffense
            buffDefense
            buffSpecial
            debuff1
            debuff2
            sleep
            nuke2
            nuke4
            bp70
            bp75 (merits and lvl 75-80 pacts)
            astralflow
--]]


-- Initialization function for this job file.
function get_sets()
    mote_include_version = 2

    -- Load and initialize the include file.
    include('Mote-Include.lua')
end

-- Setup vars that are user-independent.  state.Buff vars initialized here will automatically be tracked.
function job_setup()
    state.Buff["Avatar's Favor"] = buffactive["Avatar's Favor"] or false
    state.Buff["Astral Conduit"] = buffactive["Astral Conduit"] or false

    spirits = S{"LightSpirit", "DarkSpirit", "FireSpirit", "EarthSpirit", "WaterSpirit", "AirSpirit", "IceSpirit", "ThunderSpirit"}
    avatars = S{"Carbuncle", "Fenrir", "Diabolos", "Ifrit", "Titan", "Leviathan", "Garuda", "Shiva", "Ramuh", "Odin", "Alexander", "Cait Sith"}

    magicalRagePacts = S{
        'Inferno','Earthen Fury','Tidal Wave','Aerial Blast','Diamond Dust','Judgment Bolt','Searing Light','Howling Moon','Ruinous Omen',
        'Fire II','Stone II','Water II','Aero II','Blizzard II','Thunder II',
        'Fire IV','Stone IV','Water IV','Aero IV','Blizzard IV','Thunder IV',
        'Thunderspark','Burning Strike','Meteorite','Nether Blast','Flaming Crush',
        'Meteor Strike','Heavenly Strike','Wind Blade','Geocrush','Grand Fall','Thunderstorm',
        'Holy Mist','Lunar Bay','Night Terror','Level ? Holy'}


    pacts = {}
    pacts.cure = {['Carbuncle']='Healing Ruby'}
    pacts.curaga = {['Carbuncle']='Healing Ruby II', ['Garuda']='Whispering Wind', ['Leviathan']='Spring Water'}
    pacts.buffoffense = {['Carbuncle']='Glittering Ruby', ['Ifrit']='Crimson Howl', ['Garuda']='Hastega', ['Ramuh']='Rolling Thunder',
        ['Fenrir']='Ecliptic Growl'}
    pacts.buffdefense = {['Carbuncle']='Shining Ruby', ['Shiva']='Frost Armor', ['Garuda']='Aerial Armor', ['Titan']='Earthen Ward',
        ['Ramuh']='Lightning Armor', ['Fenrir']='Ecliptic Howl', ['Diabolos']='Noctoshield', ['Cait Sith']='Reraise II'}
    pacts.buffspecial = {['Ifrit']='Inferno Howl', ['Garuda']='Fleet Wind', ['Titan']='Earthen Armor', ['Diabolos']='Dream Shroud',
        ['Carbuncle']='Soothing Ruby', ['Fenrir']='Heavenward Howl', ['Cait Sith']='Raise II'}
    pacts.debuff1 = {['Shiva']='Diamond Storm', ['Ramuh']='Shock Squall', ['Leviathan']='Tidal Roar', ['Fenrir']='Lunar Cry',
        ['Diabolos']='Pavor Nocturnus', ['Cait Sith']='Eerie Eye'}
    pacts.debuff2 = {['Shiva']='Sleepga', ['Leviathan']='Slowga', ['Fenrir']='Lunar Roar', ['Diabolos']='Somnolence'}
    pacts.sleep = {['Shiva']='Sleepga', ['Diabolos']='Nightmare', ['Cait Sith']='Mewing Lullaby'}
    pacts.nuke2 = {['Ifrit']='Fire II', ['Shiva']='Blizzard II', ['Garuda']='Aero II', ['Titan']='Stone II',
        ['Ramuh']='Thunder II', ['Leviathan']='Water II'}
    pacts.nuke4 = {['Ifrit']='Fire IV', ['Shiva']='Blizzard IV', ['Garuda']='Aero IV', ['Titan']='Stone IV',
        ['Ramuh']='Thunder IV', ['Leviathan']='Water IV'}
    pacts.bp70 = {['Ifrit']='Flaming Crush', ['Shiva']='Rush', ['Garuda']='Predator Claws', ['Titan']='Mountain Buster',
        ['Ramuh']='Chaotic Strike', ['Leviathan']='Spinning Dive', ['Carbuncle']='Meteorite', ['Fenrir']='Eclipse Bite',
        ['Diabolos']='Nether Blast',['Cait Sith']='Regal Scratch'}
    pacts.bp75 = {['Ifrit']='Meteor Strike', ['Shiva']='Heavenly Strike', ['Garuda']='Wind Blade', ['Titan']='Geocrush',
        ['Ramuh']='Thunderstorm', ['Leviathan']='Grand Fall', ['Carbuncle']='Holy Mist', ['Fenrir']='Lunar Bay',
        ['Diabolos']='Night Terror', ['Cait Sith']='Level ? Holy'}
    pacts.astralflow = {['Ifrit']='Inferno', ['Shiva']='Diamond Dust', ['Garuda']='Aerial Blast', ['Titan']='Earthen Fury',
        ['Ramuh']='Judgment Bolt', ['Leviathan']='Tidal Wave', ['Carbuncle']='Searing Light', ['Fenrir']='Howling Moon',
        ['Diabolos']='Ruinous Omen', ['Cait Sith']="Altana's Favor"}

    -- Wards table for creating custom timers   
    wards = {}
    -- Base duration for ward pacts.
    wards.durations = {
        ['Crimson Howl'] = 60, ['Earthen Armor'] = 60, ['Inferno Howl'] = 60, ['Heavenward Howl'] = 60,
        ['Rolling Thunder'] = 120, ['Fleet Wind'] = 120,
        ['Shining Ruby'] = 180, ['Frost Armor'] = 180, ['Lightning Armor'] = 180, ['Ecliptic Growl'] = 180,
        ['Glittering Ruby'] = 180, ['Hastega'] = 180, ['Noctoshield'] = 180, ['Ecliptic Howl'] = 180,
        ['Dream Shroud'] = 180,
        ['Reraise II'] = 3600
    }
    -- Icons to use when creating the custom timer.
    wards.icons = {
        ['Earthen Armor']   = 'spells/00299.png', -- 00299 for Titan
        ['Shining Ruby']    = 'spells/00043.png', -- 00043 for Protect
        ['Dream Shroud']    = 'spells/00304.png', -- 00304 for Diabolos
        ['Noctoshield']     = 'spells/00106.png', -- 00106 for Phalanx
        ['Inferno Howl']    = 'spells/00298.png', -- 00298 for Ifrit
        ['Hastega']         = 'spells/00358.png', -- 00358 for Hastega
        ['Rolling Thunder'] = 'spells/00104.png', -- 00358 for Enthunder
        ['Frost Armor']     = 'spells/00250.png', -- 00250 for Ice Spikes
        ['Lightning Armor'] = 'spells/00251.png', -- 00251 for Shock Spikes
        ['Reraise II']      = 'spells/00135.png', -- 00135 for Reraise
        ['Fleet Wind']      = 'abilities/00074.png', -- 
    }
    -- Flags for code to get around the issue of slow skill updates.
    wards.flag = false
    wards.spell = ''
    
end

-------------------------------------------------------------------------------------------------------------------
-- User setup functions for this job.  Recommend that these be overridden in a sidecar file.
-------------------------------------------------------------------------------------------------------------------

-- Setup vars that are user-dependent.  Can override this function in a sidecar file.
function user_setup()
    state.OffenseMode:options('None', 'Normal', 'Acc')
    state.CastingMode:options('Normal', 'Resistant')
    state.IdleMode:options('Normal', 'PDT')

    gear.perp_staff = {name=""}
    
    select_default_macro_book()
end


-- Define sets and vars used by this job file.
function init_gear_sets()
	
	--------------------------------------
    -- Start defining the sets
    --------------------------------------
	
    -- Augmented gear
	
	Camp = {}
	Camp.FC = { name="Campestres's Cape", augments={'INT+20','"Fast Cast"+10','Mag. Acc.+20 /Mag. Dmg.+20','INT+5','Spell interruption rate down 8%'}}
	Camp.Pet = { name="Campestres's Cape", augments={'Pet: M.Acc.+20 Pet: M.Dmg.+20','Mag. Acc+20 /Mag. Dmg.+20','"Mag.Atk.Bns."+10','Pet: "Regen"+5',}}
	
	
    --------------------------------------
    -- Precast Sets
    --------------------------------------
    
    -- Precast sets to enhance JAs
    sets.precast.JA['Astral Flow'] = {head="Glyphic Horn +1"}
    
    sets.precast.JA['Elemental Siphon'] = {
    main="Chatoyant Staff",
    sub="Vox Grip",
    ammo="Esper Stone +1", -- 20
    head="Baayami Hat +1",
    body="Baayami Robe +1",
    hands={ name="Telchine Gloves", augments={'"Mag.Atk.Bns."+20','"Elemental Siphon"+35',}}, --35
    legs="Baayami Slops +1",
    feet="Beckoner's Pigaches", --50
    neck={ name="Smn. Collar +2", augments={'Path: A',}},
    waist="Lucidity Sash",
    left_ear="Loquac. Earring",
    right_ear="Malignance",
    left_ring="Evoker's Ring",
    right_ring="Varar Ring +1",
    back="Twilight Cape",
}

    sets.precast.JA['Mana Cede'] = {hands="Caller's Bracers +2"}

    -- Pact delay reduction gear I-15, II-11, III-10
    sets.precast.BloodPactWard = {
    main="Espiritus", -- II-2
    sub="Elan Strap +1",
    ammo="Sancus Sachet +1", -- II-7
    head={ name="Glyphic Horn +1", augments={'Enhances "Astral Flow" effect',}}, -- I-7
    body="Glyphic Doublet +1", -- II-2
    hands="Baayami Cuffs +1", -- I-7
    legs="Baayami Slops +1", -- I-8
    feet="Baayami Sabots +1",
    neck={ name="Smn. Collar +2", augments={'Path: A',}},
    waist="Lucidity Sash",
    left_ear="Malignance Earring",
    right_ear="Loquac. Earring",
    left_ring="Stikini Ring +1",
    right_ring="Stikini Ring +1",
    back=Camp.Pet,
}

    sets.precast.BloodPactRage = set_combine(sets.precast.BloodPactWard, {left_ring="Varar Ring +1",right_ring="Varar Ring +1"})	

    -- Fast cast sets for spells
    
    sets.precast.FC = {
    main={ name="Grioavolr", augments={'"Blood Pact" ability delay -2','Pet: DEX+13','Pet: Mag. Acc.+21','Pet: "Mag.Atk.Bns."+25','DMG:+18',}}, --4
    sub="Clerisy Strap", --2
    ammo="Impatiens",
    head={ name="Amalric Coif", augments={'INT+10','Mag. Acc.+20','Enmity-5',}}, --10
    body="Inyan. Jubbah +2", --14
    hands={ name="Helios Gloves", augments={'"Mag.Atk.Bns."+25','"Fast Cast"+4','MP+10',}}, --4
    legs={ name="Lengo Pants", augments={'INT+10','Mag. Acc.+15','"Mag.Atk.Bns."+15','"Refresh"+1',}}, --5
    feet={ name="Amalric Nails", augments={'MP+60','Mag. Acc.+15','"Mag.Atk.Bns."+15',}}, --5
    neck={ name="Smn. Collar +2", augments={'Path: A',}},
    waist="Channeler's Stone", --2
    left_ear="Loquac. Earring", --2
    right_ear="Malignance Earring", --4
    left_ring="Kishar Ring", --4
    right_ring="Lebeche Ring", --2
    back=Camp.FC, --10
}
    sets.precast.FC['Enhancing Magic'] = set_combine(sets.precast.FC, {waist="Siegel Sash"})
	
	sets.precast.FC['Stoneskin'] = set_combine(sets.precast.FC['Enhancing Magic'], {head="Umuthi Hat",hands="Carapacho Cuffs",legs="Doyen Pants"})
	
	sets.precast.FC['Cure'] = {
    main="Raetic Rod +1",
    sub="Sors Shield",
    ammo="Staunch Tathlum +1",
    head={ name="Amalric Coif", augments={'INT+10','Mag. Acc.+20','Enmity-5',}},
    body="Heka's Kalasiris",
    hands="Revealer's Mitts",
    legs="Lengo Pants",
    feet="Vanya Clogs",
    neck="Nodens Gorget",
    waist="Acerbic Sash +1",
    left_ear="Malignance Earring",
    right_ear="Loquac. Earring",
    left_ring="Kishar Ring",
    right_ring="Prolix Ring",
    back=Camp.FC,
}
	
       
    -- Weaponskill sets
    -- Default set for any weaponskill that isn't any more specifically defined
    sets.precast.WS = {}

    -- Specific weaponskill sets.  Uses the base set if an appropriate WSMod version isn't found.
    sets.precast.WS['Myrkr'] = {
	ammo="Strobilus",
    head="Pixie Hairpin +1",
    body={ name="Amalric Doublet +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
    hands={ name="Amalric Gages +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
    legs={ name="Lengo Pants", augments={'INT+10','Mag. Acc.+15','"Mag.Atk.Bns."+15','"Refresh"+1',}},
    feet="Beck. Pigaches",
    neck={ name="Smn. Collar +2", augments={'Path: A',}},
    waist="Eschan Stone",
    left_ear="Thureous Earring",
    right_ear="Loquac. Earring",
    left_ring="Sangoma Ring",
    right_ring="Fenrir Ring +1",
    back="Pahtli Cape",}

    
    --------------------------------------
    -- Midcast sets
    --------------------------------------

    sets.midcast.FastRecast = {
    main={ name="Grioavolr", augments={'Magic burst dmg.+1%','Mag. Acc.+24','"Mag.Atk.Bns."+23',}},
    sub="Clerisy Strap",
    ammo="Impatiens",
    head={ name="Amalric Coif", augments={'INT+10','Mag. Acc.+20','Enmity-5',}},
    body="Baayami Robe +1",
    hands={ name="Helios Gloves", augments={'"Mag.Atk.Bns."+25','"Fast Cast"+4','MP+10',}},
    legs={ name="Lengo Pants", augments={'INT+10','Mag. Acc.+15','"Mag.Atk.Bns."+15','"Refresh"+1',}},
    feet={ name="Amalric Nails", augments={'MP+60','Mag. Acc.+15','"Mag.Atk.Bns."+15',}},
    neck="Loricate Torque +1",
    waist="Witful Belt",
    left_ear="Malignance Earring",
    right_ear="Loquac. Earring",
    left_ring="Kishar Ring",
    right_ring="Lebeche Ring",
    back=Camp.FC,
}

    sets.midcast.Cure = {
    main="Raetic Rod +1", --23~50 + 10(II)
    ammo="Mana Ampulla",
    head="Inyanga Tiara +2",
    body="Heka's Kalasiris", --15
    hands="Revealer's Mitts", --13
    legs="Lengo Pants", 
    feet="Vanya Clogs", -- Healing Mag. Skill +34
    neck="Mizu. Kubikazari",
    waist="Luminary Sash",
    left_ear="Beatific Earring",
    right_ear="Lifestorm Earring",
    left_ring="Janniston Ring",
    right_ring="Menelaus's Ring",
    back="Solemnity Cape",
}

	sets.midcast['Enhancing Magic'] = {
    main={ name="Gada", augments={'"Conserve MP"+4','MND+2','Mag. Acc.+14','"Mag.Atk.Bns."+14',}},
    sub="Ammurapi Shield",
    ammo="Staunch Tathlum +1",
    head="Umuthi Hat",
    body={ name="Telchine Chas.", augments={'Mag. Acc.+22','"Cure" spellcasting time -4%','MP+50',}},
    hands="Inyan. Dastanas +2",
    legs={ name="Telchine Braconi", augments={'"Mag.Atk.Bns."+17','"Fast Cast"+4','Enh. Mag. eff. dur. +9',}},
    feet="Regal Pumps",
    neck="Sanctity Necklace",
    waist="Luminary Sash",
    left_ear="Brachyura Earring",
    right_ear="Impreg. Earring",
    left_ring="Stikini Ring +1",
    right_ring="Stikini Ring +1",
    back="Perimede Cape",
}
	
    sets.midcast.Stoneskin = {head="Umuthi Hat",waist="Siegel Sash", neck="Nodens Gorget"}

    sets.midcast['Elemental Magic'] = {
	main="Raetic Staff +1",
    sub="Khonsu",
    ammo="Pemphredo Tathlum",
    head={ name="Merlinic Hood", augments={'"Mag.Atk.Bns."+25','"Drain" and "Aspir" potency +4','CHR+14','Mag. Acc.+6',}},
    body={ name="Amalric Doublet +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
    hands={ name="Amalric Gages +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
    legs={ name="Amalric Slops +1", augments={'INT+12','Elem. magic skill +20','Dark magic skill +20',}},
    feet={ name="Merlinic Crackows", augments={'Mag. Acc.+25 "Mag.Atk.Bns."+25','"Fast Cast"+3','MND+10','Mag. Acc.+2',}},
    neck="Eddy Necklace",
    waist="Hachirin-no-Obi",
    left_ear="Friomisi Earring",
    right_ear="Crematio Earring",
    left_ring="Shiva Ring +1",
    right_ring="Shiva Ring +1",
    back="Twilight Cape",
}

    sets.midcast['Dark Magic'] = {main={ name="Grioavolr", augments={'Magic burst dmg.+1%','Mag. Acc.+24','"Mag.Atk.Bns."+23',}},
    sub="Khonsu",
    ammo="Dosis Tathlum",
    head="Pixie Hairpin +1",
    body={ name="Amalric Doublet +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
    hands={ name="Amalric Gages +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
    legs={ name="Amalric Slops +1", augments={'INT+12','Elem. magic skill +20','Dark magic skill +20',}},
    feet={ name="Merlinic Crackows", augments={'Mag. Acc.+25 "Mag.Atk.Bns."+25','"Fast Cast"+3','MND+10','Mag. Acc.+2',}},
    neck="Erra Pendant",
    waist="Hachirin-no-Obi",
    left_ear="Friomisi Earring",
    right_ear="Crematio Earring",
    left_ring="Fenrir Ring +1",
    right_ring="Fenrir Ring +1",
    back="Twilight Cape",}


    -- Avatar pact sets.  All pacts are Ability type.
	
    
    sets.midcast.Pet.BloodPactWard = {
	main={ name="Grioavolr", augments={'"Blood Pact" ability delay -2','Pet: DEX+13','Pet: Mag. Acc.+21','Pet: "Mag.Atk.Bns."+25','DMG:+18',}},
    sub="Elan Strap +1",
    ammo="Sancus Sachet +1",
    head={ name="Apogee Crown", augments={'Pet: Attack+20','Pet: "Mag.Atk.Bns."+20','Blood Pact Dmg.+7',}},
    body={ name="Merlinic Jubbah", augments={'"Mag.Atk.Bns."+19','"Drain" and "Aspir" potency +7','CHR+3','Mag. Acc.+14',}},
    hands={ name="Apogee Mitts", augments={'MP+60','Pet: "Mag.Atk.Bns."+30','Blood Pact Dmg.+7',}},
    legs="Avatara Slops",
    feet={ name="Artsieq Boots", augments={'MP+30','Pet: "Mag.Atk.Bns."+20','Pet: Mag. Acc.+20',}},
    neck="Wiglen Gorget",
    waist="Hachirin-no-Obi",
    left_ear="Enchntr. Earring +1",
    right_ear="Loquac. Earring",
    left_ring="Evoker's Ring",
    right_ring="Stikini Ring +1",
    back=Camp.Pet,
}

    sets.midcast.Pet.DebuffBloodPactWard = {
	main={ name="Grioavolr", augments={'"Blood Pact" ability delay -2','Pet: DEX+13','Pet: Mag. Acc.+21','Pet: "Mag.Atk.Bns."+25','DMG:+18',}},
    sub="Elan Strap +1",
    ammo="Sancus Sachet +1",
    head={ name="Apogee Crown", augments={'Pet: Attack+20','Pet: "Mag.Atk.Bns."+20','Blood Pact Dmg.+7',}},
    body={ name="Apo. Dalmatica +1", augments={'Pet: Attack+25','Pet: "Mag.Atk.Bns."+25','Blood Pact Dmg.+8',}},
    hands={ name="Apogee Mitts", augments={'MP+60','Pet: "Mag.Atk.Bns."+30','Blood Pact Dmg.+7',}},
    legs="Avatara Slops",
    feet={ name="Artsieq Boots", augments={'MP+30','Pet: "Mag.Atk.Bns."+20','Pet: Mag. Acc.+20',}},
    neck="Wiglen Gorget",
    waist="Hachirin-no-Obi",
    left_ear="Enchntr. Earring +1",
    right_ear="Loquac. Earring",
    left_ring="Evoker's Ring",
    right_ring="Stikini Ring +1",
    back=Camp.Pet,
}
        
    sets.midcast.Pet.DebuffBloodPactWard.Acc = sets.midcast.Pet.DebuffBloodPactWard
    
	-- Damaging BP +127
    sets.midcast.Pet.PhysicalBloodPactRage = {
	main="Was",
    sub="Elan Strap +1",
    ammo="Sancus Sachet +1",
    head={ name="Apogee Crown +1", augments={'Pet: Attack+25','Pet: "Mag.Atk.Bns."+25','Blood Pact Dmg.+8',}},
    body={ name="Apo. Dalmatica +1", augments={'Pet: Attack+25','Pet: "Mag.Atk.Bns."+25','Blood Pact Dmg.+8',}},
    hands={ name="Apogee Mitts +1", augments={'MP+80','Pet: Attack+35','Blood Pact Dmg.+8',}},
    legs={ name="Apogee Slacks +1", augments={'Pet: STR+20','Blood Pact Dmg.+14','Pet: "Dbl. Atk."+4',}},
    feet={ name="Apogee Pumps +1", augments={'Pet: Attack+25','Pet: "Mag.Atk.Bns."+25','Blood Pact Dmg.+8',}},
    neck={ name="Smn. Collar +2", augments={'Path: A',}},
    waist="Lucidity Sash",
    left_ear="Kyrene's Earring",
    right_ear="Malignance Earring",
    left_ring="Varar Ring +1",
    right_ring="Varar Ring +1",
    back=Camp.Pet,
}

    sets.midcast.Pet.PhysicalBloodPactRage.Acc = sets.midcast.Pet.PhysicalBloodPactRage

    sets.midcast.Pet.MagicalBloodPactRage = set_combine(sets.midcast.Pet.PhysicalBloodPactRage, {
	main={ name="Grioavolr", augments={'"Blood Pact" ability delay -2','Pet: DEX+13','Pet: Mag. Acc.+21','Pet: "Mag.Atk.Bns."+25','DMG:+18',}},hands={ name="Apogee Mitts", augments={'MP+60','Pet: "Mag. Atk. Bns."+30','Blood Pact Dmg.+7',}},})

    sets.midcast.Pet.MagicalBloodPactRage.Acc = sets.midcast.Pet.MagicalBloodPactRage


    -- Spirits cast magic spells, which can be identified in standard ways.
    
    sets.midcast.Pet.WhiteMagic = {legs="Summoner's Spats"}
    
    sets.midcast.Pet['Elemental Magic'] = set_combine(sets.midcast.Pet.BloodPactRage, {legs="Summoner's Spats"})

    sets.midcast.Pet['Elemental Magic'].Resistant = {}
    

    --------------------------------------
    -- Idle/resting/defense/etc sets
    --------------------------------------
    
    -- Resting sets
    sets.resting = {
	main="Boonwell Staff",
    ammo="Mana Ampulla",
    head="Inyanga Tiara +2",
    body="Oracle's Robe",
    hands="Inyan.Dastanas +2",
    legs={ name="Lengo Pants", augments={'INT+10','Mag. Acc.+15','"Mag.Atk.Bns."+15','"Refresh"+1',}},
    feet="Baayami Sabots +1",
    neck="Eidolon Pendant +1",
    waist="Austerity Belt +1",
    left_ear="Rapture Earring",
    right_ear="Loquac. Earring",
    left_ring="Stikini Ring +1",
    right_ring="Stikini Ring +1",
    back="Felicitas Cape +1",
}
    
    -- Idle sets -- perpetuation -25 Refresh +2
    sets.idle = {
	main="Gridarvor", --5
	sub="Elan Strap +1",
    ammo="Staunch Tathlum +1",
    head={ name="Apogee Crown", augments={'Pet: Accuracy+20','"Avatar perpetuation cost"+5','Pet: Damage taken -3%',}}, --5
    body={ name="Glyphic Doublet +1", augments={'Reduces Sp. "Blood Pact" MP cost',}}, --5
    hands="Baayami Cuffs +1",
    legs="Lengo Pants", --4
    feet="Beck. Pigaches", --6
    neck={ name="Smn. Collar +2", augments={'Path: A',}},
    waist="Klouskap Sash +1",
    left_ear="Kyrene's Earring",
    right_ear="Malignance Earring",
    left_ring="Stikini Ring +1",
    right_ring="Stikini Ring +1",
    back=Camp.Pet,
}
	-- not really set yet
    sets.idle.PDT = {main={ name="Grioavolr", augments={'"Blood Pact" ability delay -2','Pet: DEX+13','Pet: Mag. Acc.+21','Pet: "Mag.Atk.Bns."+25','DMG:+18',}},sub="Elan Strap +1",ammo="Sancus Sachet +1",
        head="Convoker's Horn",neck="Summoner's Collar +2",ear1="Kyrene's Earring",ear2="Loquacious Earring",
        body="Glyphic Doublet +1 +1",hands="Inyan. Dastanas +2",ring1="Defending Ring",ring2="Sangoma Ring",
        back=Camp.Pet,}
	
	--------- vanilla lua vvv not set -------
    -- perp costs:
    -- spirits: 7
    -- carby: 11 (5 with mitts)
    -- fenrir: 13
    -- others: 15
    -- avatar's favor: -4/tick
    
    -- Max useful -perp gear is 1 less than the perp cost (can't be reduced below 1)
    -- Aim for -14 perp, and refresh in other slots.
    --------- vanilla lua ^^^ not set -------
	
    -- -perp gear:
    -- Gridarvor: -5
    -- Glyphic Horn +1: -4
    -- Glyphic Doublet +1 +1: -5
    -- Evoker's Ring: -1
    -- Beckoner's Pigaches: -6
	-- Lucidity Sash: -2
    -- total: -23
    
    -- Can make due without either the head or the body, and use +refresh items in those slots.
    
    sets.idle.Avatar = {
	main="Gridarvor",
    sub="Elan Strap +1",
    ammo="Sancus Sachet +1",
    head={ name="Glyphic Horn +1", augments={'Enhances "Astral Flow" effect',}},
    body={ name="Glyphic Doublet +1", augments={'Reduces Sp. "Blood Pact" MP cost',}},
    hands={ name="Apogee Mitts", augments={'MP+60','Pet: "Mag.Atk.Bns."+30','Blood Pact Dmg.+7',}},
    legs={ name="Helios Spats", augments={'Pet: Attack+2 Pet: Rng.Atk.+2','"Avatar perpetuation cost" -4','CHR+10',}},
    feet="Beck. Pigaches",
    neck={ name="Smn. Collar +2", augments={'Path: A',}},
    waist="Lucidity Sash",
    left_ear="Kyrene's Earring",
    right_ear="Loquac. Earring",
    left_ring="Varar Ring +1",
    right_ring="Varar Ring +1",
    back=Camp.Pet,}
	
	------ NONE OF THESE ARE SET/TWEAKED-----
    sets.idle.PDT.Avatar = {main="Espiritus",sub="Elan Strap +1",ammo="Sancus Sachet +1",
        head="Convoker's Horn",neck="Summoner's Collar +2",ear1="Kyrene's Earring",ear2="Loquacious Earring",
        body="Glyphic Doublet +1",hands="Regimen Mittens",ring1="Evoker's Ring",ring2="Defending Ring",
        back="Conveyance Cape",waist="Fucho-no-Obi",legs="Hagondes Pants",feet="Convoker's Pigaches"}

    sets.idle.Spirit = {main={ name="Grioavolr", augments={'"Blood Pact" ability delay -2','Pet: DEX+13','Pet: Mag. Acc.+21','Pet: "Mag.Atk.Bns."+25','DMG:+18',}},sub="Vox Grip",ammo="Sancus Sachet +1",
        head="Convoker's Horn",neck="Summoner's Collar +2",ear1="Kyrene's Earring",ear2="Loquacious Earring",
        body="Glyphic Doublet +1",hands="Serpentes Cuffs",ring1="Evoker's Ring",ring2="Sangoma Ring",
        back="Samanisi Cape",waist="Fucho-no-Obi",legs="Summoner's Spats",feet="Herald's Gaiters"}

    sets.idle.Town = {main="Bolelabunga",sub="Sors Shield",ammo="Sancus Sachet +1",
        head="Convoker's Horn",neck="Summoner's Collar +2",ear1="Kyrene's Earring",ear2="Loquacious Earring",
        body="Glyphic Doublet +1",hands="Serpentes Cuffs",ring1="Sheltered Ring",ring2="Sangoma Ring",
        back="Umbra Cape",waist="Fucho-no-Obi",legs="Nares Trews",feet="Herald's Gaiters"}

    -- Favor uses Caller's Horn instead of Convoker's Horn for refresh
    sets.idle.Avatar.Favor = {head="Caller's Horn +2"}
    sets.idle.Avatar.Melee = {hands="Regimen Mittens",back="Samanisi Cape",waist="Kuku Stone",legs="Convoker's Spats"}
        
    sets.perp = {
	main="Gridarvor", --5
    ammo="Staunch Tathlum +1",
    head={ name="Apogee Crown", augments={'Pet: Accuracy+20','"Avatar perpetuation cost"+5','Pet: Damage taken -3%',}}, --5
    body={ name="Glyphic Doublet +1", augments={'Reduces Sp. "Blood Pact" MP cost',}}, --5
    hands="Baayami Cuffs +1",
    legs="Baayami Slops +1",
    feet="Beck. Pigaches", --6
    neck={ name="Smn. Collar +2", augments={'Path: A',}},
    waist="Klouskap Sash +1",
    left_ear="Kyrene's Earring",
    right_ear="Malignance Earring",
    left_ring="Stikini Ring +1",
    right_ring="Stikini Ring +1",
    back=Camp.Pet,
}

    sets.perp.Alexander = sets.midcast.Pet.BloodPactWard

    sets.perp.staff_and_grip = {main=gear.perp_staff,sub="Elan Strap +1"}
    
    -- Defense sets
    sets.defense.PDT = {}

    sets.defense.MDT = {}

    sets.Kiting = {feet="Herald's Gaiters"}
    
    sets.latent_refresh = {waist="Gishdubar Sash"}
    

    --------------------------------------
    -- Engaged sets
    --------------------------------------
    
    -- Normal melee group (I never really melee)
    sets.engaged = {
    main={ name="Grioavolr", augments={'"Blood Pact" ability delay -2','Pet: DEX+13','Pet: Mag. Acc.+21','Pet: "Mag.Atk.Bns."+25','DMG:+18',}},
    sub="Elan Strap +1",
    ammo="Sancus Sachet +1",
    head={ name="Apogee Crown", augments={'Pet: Attack+20','Pet: "Mag.Atk.Bns."+20','Blood Pact Dmg.+7',}},
    body="Tali'ah Manteel +2",
    hands="Tali'ah Gages +2",
    legs="Tali'ah Sera. +2",
    feet={ name="Psycloth Boots", augments={'Pet: Attack+25','Pet: "Mag.Atk.Bns."+15','Pet: Enmity+7',}},
    neck={ name="Smn. Collar +2", augments={'Path: A',}},
    waist="Lucidity Sash",
    left_ear="Kyrene's Earring",
    right_ear="Evans Earring",
    left_ring="Varar Ring +1",
    right_ring="Varar Ring +1",
    back={ name="Campestres's Cape", augments={'Pet: M.Acc.+20 Pet: M.Dmg.+20','Mag. Acc+17 /Mag. Dmg.+17','"Mag.Atk.Bns."+10',}},
}
end

-------------------------------------------------------------------------------------------------------------------
-- Job-specific hooks for standard casting events.
-------------------------------------------------------------------------------------------------------------------

-- Set eventArgs.handled to true if we don't want any automatic gear equipping to be done.
-- Set eventArgs.useMidcastGear to true if we want midcast gear equipped on precast.
function job_precast(spell, action, spellMap, eventArgs)
    if state.Buff['Astral Conduit'] and pet_midaction() then
        eventArgs.handled = true
    end
end

function job_midcast(spell, action, spellMap, eventArgs)
    if state.Buff['Astral Conduit'] and pet_midaction() then
        eventArgs.handled = true
    end
end

-- Runs when pet completes an action.
function job_pet_aftercast(spell, action, spellMap, eventArgs)
    if not spell.interrupted and spell.type == 'BloodPactWard' and spellMap ~= 'DebuffBloodPactWard' then
        wards.flag = true
        wards.spell = spell.english
        send_command('wait 4; gs c reset_ward_flag')
    end
end

-------------------------------------------------------------------------------------------------------------------
-- Job-specific hooks for non-casting events.
-------------------------------------------------------------------------------------------------------------------

-- Called when a player gains or loses a buff.
-- buff == buff gained or lost
-- gain == true if the buff was gained, false if it was lost.
function job_buff_change(buff, gain)
    if state.Buff[buff] ~= nil then
        handle_equipping_gear(player.status)
    elseif storms:contains(buff) then
        handle_equipping_gear(player.status)
    end
end


-- Called when the player's pet's status changes.
-- This is also called after pet_change after a pet is released.  Check for pet validity.
function job_pet_status_change(newStatus, oldStatus, eventArgs)
    if pet.isvalid and not midaction() and not pet_midaction() and (newStatus == 'Engaged' or oldStatus == 'Engaged') then
        handle_equipping_gear(player.status, newStatus)
    end
end


-- Called when a player gains or loses a pet.
-- pet == pet structure
-- gain == true if the pet was gained, false if it was lost.
function job_pet_change(petparam, gain)
    classes.CustomIdleGroups:clear()
    if gain then
        if avatars:contains(pet.name) then
            classes.CustomIdleGroups:append('Avatar')
        elseif spirits:contains(pet.name) then
            classes.CustomIdleGroups:append('Spirit')
        end
    else
        select_default_macro_book('reset')
    end
end

-------------------------------------------------------------------------------------------------------------------
-- User code that supplements standard library decisions.
-------------------------------------------------------------------------------------------------------------------

-- Custom spell mapping.
function job_get_spell_map(spell)
    if spell.type == 'BloodPactRage' then
        if magicalRagePacts:contains(spell.english) then
            return 'MagicalBloodPactRage'
        else
            return 'PhysicalBloodPactRage'
        end
    elseif spell.type == 'BloodPactWard' and spell.target.type == 'MONSTER' then
        return 'DebuffBloodPactWard'
    end
end

-- Modify the default idle set after it was constructed.
function customize_idle_set(idleSet)
    if pet.isvalid then
        if pet.element == world.day_element then
            idleSet = set_combine(idleSet, sets.perp.Day)
        end
        if pet.element == world.weather_element then
            idleSet = set_combine(idleSet, sets.perp.Weather)
        end
        if sets.perp[pet.name] then
            idleSet = set_combine(idleSet, sets.perp[pet.name])
        end
        gear.perp_staff.name = elements.perpetuance_staff_of[pet.element]
        if gear.perp_staff.name and (player.inventory[gear.perp_staff.name] or player.wardrobe[gear.perp_staff.name]) then
            idleSet = set_combine(idleSet, sets.perp.staff_and_grip)
        end
        if state.Buff["Avatar's Favor"] and avatars:contains(pet.name) then
            idleSet = set_combine(idleSet, sets.idle.Avatar.Favor)
        end
        if pet.status == 'Engaged' then
            idleSet = set_combine(idleSet, sets.idle.Avatar.Melee)
        end
    end
    
    if player.mpp < 51 then
        idleSet = set_combine(idleSet, sets.latent_refresh)
    end
    
    return idleSet
end

-- Called by the 'update' self-command, for common needs.
-- Set eventArgs.handled to true if we don't want automatic equipping of gear.
function job_update(cmdParams, eventArgs)
    classes.CustomIdleGroups:clear()
    if pet.isvalid then
        if avatars:contains(pet.name) then
            classes.CustomIdleGroups:append('Avatar')
        elseif spirits:contains(pet.name) then
            classes.CustomIdleGroups:append('Spirit')
        end
    end
end

-- Set eventArgs.handled to true if we don't want the automatic display to be run.
function display_current_job_state(eventArgs)

end


-------------------------------------------------------------------------------------------------------------------
-- User self-commands.
-------------------------------------------------------------------------------------------------------------------

-- Called for custom player commands.
function job_self_command(cmdParams, eventArgs)
    if cmdParams[1]:lower() == 'petweather' then
        handle_petweather()
        eventArgs.handled = true
    elseif cmdParams[1]:lower() == 'siphon' then
        handle_siphoning()
        eventArgs.handled = true
    elseif cmdParams[1]:lower() == 'pact' then
        handle_pacts(cmdParams)
        eventArgs.handled = true
    elseif cmdParams[1] == 'reset_ward_flag' then
        wards.flag = false
        wards.spell = ''
        eventArgs.handled = true
    end
end


-------------------------------------------------------------------------------------------------------------------
-- Utility functions specific to this job.
-------------------------------------------------------------------------------------------------------------------

-- Cast the appopriate storm for the currently summoned avatar, if possible.
function handle_petweather()
    if player.sub_job ~= 'SCH' then
        add_to_chat(122, "You can not cast storm spells")
        return
    end
        
    if not pet.isvalid then
        add_to_chat(122, "You do not have an active avatar.")
        return
    end
    
    local element = pet.element
    if element == 'Thunder' then
        element = 'Lightning'
    end
    
    if S{'Light','Dark','Lightning'}:contains(element) then
        add_to_chat(122, 'You do not have access to '..elements.storm_of[element]..'.')
        return
    end 
    
    local storm = elements.storm_of[element]
    
    if storm then
        send_command('@input /ma "'..elements.storm_of[element]..'" <me>')
    else
        add_to_chat(123, 'Error: Unknown element ('..tostring(element)..')')
    end
end


-- Custom uber-handling of Elemental Siphon
function handle_siphoning()
    if areas.Cities:contains(world.area) then
        add_to_chat(122, 'Cannot use Elemental Siphon in a city area.')
        return
    end

    local siphonElement
    local stormElementToUse
    local releasedAvatar
    local dontRelease
    
    -- If we already have a spirit out, just use that.
    if pet.isvalid and spirits:contains(pet.name) then
        siphonElement = pet.element
        dontRelease = true
        -- If current weather doesn't match the spirit, but the spirit matches the day, try to cast the storm.
        if player.sub_job == 'SCH' and pet.element == world.day_element and pet.element ~= world.weather_element then
            if not S{'Light','Dark','Lightning'}:contains(pet.element) then
                stormElementToUse = pet.element
            end
        end
    -- If we're subbing /sch, there are some conditions where we want to make sure specific weather is up.
    -- If current (single) weather is opposed by the current day, we want to change the weather to match
    -- the current day, if possible.
    elseif player.sub_job == 'SCH' and world.weather_element ~= 'None' then
        -- We can override single-intensity weather; leave double weather alone, since even if
        -- it's partially countered by the day, it's not worth changing.
        if get_weather_intensity() == 1 then
            -- If current weather is weak to the current day, it cancels the benefits for
            -- siphon.  Change it to the day's weather if possible (+0 to +20%), or any non-weak
            -- weather if not.
            -- If the current weather matches the current avatar's element (being used to reduce
            -- perpetuation), don't change it; just accept the penalty on Siphon.
            if world.weather_element == elements.weak_to[world.day_element] and
                (not pet.isvalid or world.weather_element ~= pet.element) then
                -- We can't cast lightning/dark/light weather, so use a neutral element
                if S{'Light','Dark','Lightning'}:contains(world.day_element) then
                    stormElementToUse = 'Wind'
                else
                    stormElementToUse = world.day_element
                end
            end
        end
    end
    
    -- If we decided to use a storm, set that as the spirit element to cast.
    if stormElementToUse then
        siphonElement = stormElementToUse
    elseif world.weather_element ~= 'None' and (get_weather_intensity() == 2 or world.weather_element ~= elements.weak_to[world.day_element]) then
        siphonElement = world.weather_element
    else
        siphonElement = world.day_element
    end
    
    local command = ''
    local releaseWait = 0
    
    if pet.isvalid and avatars:contains(pet.name) then
        command = command..'input /pet "Release" <me>;wait 1.1;'
        releasedAvatar = pet.name
        releaseWait = 10
    end
    
    if stormElementToUse then
        command = command..'input /ma "'..elements.storm_of[stormElementToUse]..'" <me>;wait 4;'
        releaseWait = releaseWait - 4
    end
    
    if not (pet.isvalid and spirits:contains(pet.name)) then
        command = command..'input /ma "'..elements.spirit_of[siphonElement]..'" <me>;wait 4;'
        releaseWait = releaseWait - 4
    end
    
    command = command..'input /ja "Elemental Siphon" <me>;'
    releaseWait = releaseWait - 1
    releaseWait = releaseWait + 0.1
    
    if not dontRelease then
        if releaseWait > 0 then
            command = command..'wait '..tostring(releaseWait)..';'
        else
            command = command..'wait 1.1;'
        end
        
        command = command..'input /pet "Release" <me>;'
    end
    
    if releasedAvatar then
        command = command..'wait 1.1;input /ma "'..releasedAvatar..'" <me>'
    end
    
    send_command(command)
end


-- Handles executing blood pacts in a generic, avatar-agnostic way.
-- cmdParams is the split of the self-command.
-- gs c [pact] [pacttype]
function handle_pacts(cmdParams)
    if areas.Cities:contains(world.area) then
        add_to_chat(122, 'You cannot use pacts in town.')
        return
    end

    if not pet.isvalid then
        add_to_chat(122,'No avatar currently available. Returning to default macro set.')
        select_default_macro_book('reset')
        return
    end

    if spirits:contains(pet.name) then
        add_to_chat(122,'Cannot use pacts with spirits.')
        return
    end

    if not cmdParams[2] then
        add_to_chat(123,'No pact type given.')
        return
    end
    
    local pact = cmdParams[2]:lower()
    
    if not pacts[pact] then
        add_to_chat(123,'Unknown pact type: '..tostring(pact))
        return
    end
    
    if pacts[pact][pet.name] then
        if pact == 'astralflow' and not buffactive['astral flow'] then
            add_to_chat(122,'Cannot use Astral Flow pacts at this time.')
            return
        end
        
        -- Leave out target; let Shortcuts auto-determine it.
        send_command('@input /pet "'..pacts[pact][pet.name]..'"')
    else
        add_to_chat(122,pet.name..' does not have a pact of type ['..pact..'].')
    end
end


-- Event handler for updates to player skill, since we can't rely on skill being
-- correct at pet_aftercast for the creation of custom timers.
windower.raw_register_event('incoming chunk',
    function (id)
        if id == 0x62 then
            if wards.flag then
                create_pact_timer(wards.spell)
                wards.flag = false
                wards.spell = ''
            end
        end
    end)

-- Function to create custom timers using the Timers addon.  Calculates ward duration
-- based on player skill and base pact duration (defined in job_setup).
function create_pact_timer(spell_name)
    -- Create custom timers for ward pacts.
    if wards.durations[spell_name] then
        local ward_duration = wards.durations[spell_name]
        if ward_duration < 181 then
            local skill = player.skills.summoning_magic
            if skill > 300 then
                skill = skill - 300
                if skill > 200 then skill = 200 end
                ward_duration = ward_duration + skill
            end
        end
        
        local timer_cmd = 'timers c "'..spell_name..'" '..tostring(ward_duration)..' down'
        
        if wards.icons[spell_name] then
            timer_cmd = timer_cmd..' '..wards.icons[spell_name]
        end

        send_command(timer_cmd)
    end
end


-- Select default macro book on initial load or subjob change.
function select_default_macro_book(reset)
    if reset == 'reset' then
        -- lost pet, or tried to use pact when pet is gone
    end
    
    -- Default macro set/book
    set_macro_page(1, 19)
	end
 Bismarck.Firedemon
Offline
Server: Bismarck
Game: FFXI
user: Firedemon
Posts: 1042
By Bismarck.Firedemon 2020-04-02 17:25:53
Link | Quote | Reply
 
Perfect example of putting the cart before the horse.
[+]
 
Offline
Posts:
By 2020-04-02 17:31:47
 Undelete | Edit  | Link | Quote | Reply
 
Post deleted by User.
[+]
Offline
Posts: 494
By Crossbones 2020-04-02 22:12:16
Link | Quote | Reply
 
CPing on SMN is pretty much the best way to learn the job. You can end up in a PT where you MB, or where you buff, or heal, or some combo of those and more. I've played SMN as my main job for the past 4 or 5 years and I still learn something new every time I play it. By skipping CP and paying someone else to play the game for you you've really done yourself a disservice. There are TONs of SMN out there who have absolutely 0 idea how to play their job properly much less optimally, and the job has a bad rep because of it. I suggest you group with people and do random NMs here and there to try to learn some of your toolkit and check out the guides on different gear sets (a lot of your sets are messed up, IDK why merlenic jubbah is anywhere in you BP sets for example). Sorry I don't have any specific tips, you just really have to play the job to learn it.

And no you don't NEED GS for SMN, but you also don't need shoes to get around.
 Asura.Eiryl
Offline
Server: Asura
Game: FFXI
user: Eiryl
By Asura.Eiryl 2020-04-02 22:15:49
Link | Quote | Reply
 
Caerda said: »
I don't use gear swap on smn. It's not needed.

This, but I hate that I can't do the GoB without engaging unless a gs file as loaded.

Also it's really damn annoying when other smns have GoB max dps and no toggle requiring multiple mobs used for am3. GoB for prefight am3 naked ya ***.
Offline
Posts: 12880
By Draylo 2020-04-02 22:27:21
Link | Quote | Reply
 
Why wouldnt you want GS? Only situations I've thought of making macros were in high lag areas like Dynamis D/Escha where you end up bping in -bp timer gear. Otherwise it has its normal uses.
[+]
Offline
Posts: 227
By Galkapryme 2020-04-03 14:05:03
Link | Quote | Reply
 
I think I was unclear about something...I have no real desire to play SMN long-term. I am ONLY using it to support another endeavor. My mains are COR and DRK...and I prefer playing them. I'm working on a mythic, and Odin yields the most points (I know I could just spam T3 like everyone else). I'm looking for a guide, maybe, on macro sets, updated gear sets, etc. But I am strictly looking for information on how to better facilitate fighting Odin. At some point in the future, when I take an interest, I'll actually LEARN SMN in a more traditional fashion.
 
Offline
Posts:
By 2020-04-03 14:10:06
 Undelete | Edit  | Link | Quote | Reply
 
Post deleted by User.
 
Offline
Posts:
By 2020-04-03 14:12:43
 Undelete | Edit  | Link | Quote | Reply
 
Post deleted by User.
[+]
 Bismarck.Firedemon
Offline
Server: Bismarck
Game: FFXI
user: Firedemon
Posts: 1042
By Bismarck.Firedemon 2020-04-03 14:14:50
Link | Quote | Reply
 
Odin is as basic as you get on SMN. Literally you toss an avatar on it, BP, stay out of range, resummon, rinse and repeat. You probably have zero summon skill from paying to burn your ***, so that's probably the reason. Or you literally have no idea how to toss an avatar on a mob, which brings me to my original comment, putting the cart before the horse.
[+]
 
Offline
Posts:
By 2020-04-03 14:21:03
 Undelete | Edit  | Link | Quote | Reply
 
Post deleted by User.
By DeusDisciple 2020-04-03 15:49:33
Link | Quote | Reply
 
The equipment set swaps SE implemented into the game are definitely needed to play Summoner in an optimal way. However the Gearswap addon for Windower is definitely not, and they are not the same thing. You can do the SE equip swaps with vanilla Playonline if you choose to.

I use Ashita primarily and never once used the Gearswap addon. Mostly cause I'm one of those old time career SMN vets from the 75 era on the Playstation 2, starting out in 2004. I'm just used to how we did things back then macro wise that I don't really feel there's a need to use the addon on SMN, at least now that SE implemented the equipment sets. I've never had trouble doing difficult content on the job with the SE sets.
Offline
Posts: 227
By Galkapryme 2020-04-03 19:04:39
Link | Quote | Reply
 
@ Firedemon - My Summoning skill is capped, I have 2 sets of most of the Apogee + gear, I have the Bayammi +1 set, A Was, multiple G-staves (2 from Gaes Fete, and the JSE from Oboro), and I know how to toss an Avatar at Odin just fine. I think you're missing the essence of what I'm saying. I am looking to see if the rinse/repeat strategy is par for the course, or if there might be an easier/quicker way. Also, I wanted to know about game mechanics in terms of the macro sets.

I understand you frown upon playing a character that you haven't work to build. Noted. Again, SMN isn't a job I mean to use long-term. Its sole purpose is to conduct battles such as Odin's Chamber.
Offline
Posts: 227
By Galkapryme 2020-04-03 19:05:57
Link | Quote | Reply
 
Jdove - good to see you, bro. I have been either spamming T3 or buying the Valkyrie items from the AH. pricey, yes, but I wanna just finish this damn Mythic. I've put it off for too long.
Offline
Posts: 42070
By Jetackuu 2020-04-03 19:30:39
Link | Quote | Reply
 
You're wasting your time getting wings to get to Odin and doing odin, the only time you wouldn't be is if you had others buying the t1/2 wings and you were alternating between t3/odin, but it's such a waste of time/effort, just do t3 spam and do your 52 runs like everyone else.

Also lol, the 75 fight as smn should be cake, you're doing it wrong.
Offline
Posts: 494
By Crossbones 2020-04-03 19:34:09
Link | Quote | Reply
 
What part about the odin fight is giving you trouble? Is he killing your pet too fast? Try apogee chaotic to volt strike for distortion and see if that kills him before he can take out your pet. Keep RR up from cait in case you die so you don't lose an hour.
 Bismarck.Nyaarun
Offline
Server: Bismarck
Game: FFXI
user: duo1666
Posts: 1006
By Bismarck.Nyaarun 2020-04-05 13:45:29
Link | Quote | Reply
 
Given i havnt seen this mentioned/listed, and you said you dont know how you want to setup macros

https://www.bg-wiki.com/bg/The_Heretical_Art:_Comprehensive_Summoner_Guide#Abilities_and_Macros

This is a very good setup baseline, and is very, very helpful. It sets you up with a base hub for selecting who you want to summon, then when you select your summon it brings you to the macro page for your current summon, so you can list all their abilities in one area.
 
Offline
Posts:
By 2020-04-05 15:03:26
 Undelete | Edit  | Link | Quote | Reply
 
Post deleted by User.
 Lakshmi.Avereith
Offline
Server: Lakshmi
Game: FFXI
user: Lilianna
Posts: 926
By Lakshmi.Avereith 2020-04-05 15:32:05
Link | Quote | Reply
 
Asura.Dexterm said: »
Your physical bp set is terrible. Probably why you can’t kill it. First clue is you have a Was. Throw that piece of garbage away and stop using SMN now.
Ha, what a ***.
[+]
 Bismarck.Firedemon
Offline
Server: Bismarck
Game: FFXI
user: Firedemon
Posts: 1042
By Bismarck.Firedemon 2020-04-05 16:15:58
Link | Quote | Reply
 
Asura.Dexterm said: »
First clue is you have a Was. Throw that piece of garbage away and stop using SMN now.

While it’s not the greatest, it’s not as bad as you’re saying. It’s a perfectly fine alternative to JSE.
 Shiva.Thorny
Offline
Server: Shiva
Game: FFXI
user: Rairin
Posts: 1155
By Shiva.Thorny 2020-04-05 16:27:33
Link | Quote | Reply
 
Having and using a Was is a stupid decision, as JSE is cheap and easily attainable.

No need to go 2008 bluegartr on the guy though, could just recommend he grab a Gridarvor.
 Bismarck.Firedemon
Offline
Server: Bismarck
Game: FFXI
user: Firedemon
Posts: 1042
By Bismarck.Firedemon 2020-04-05 16:49:03
Link | Quote | Reply
 
OP said he was working on JSE, prolly why he’s using Was.
 
Offline
Posts:
By 2020-04-05 18:58:38
 Undelete | Edit  | Link | Quote | Reply
 
Post deleted by User.
 
Offline
Posts:
By 2020-04-05 19:01:29
 Undelete | Edit  | Link | Quote | Reply
 
Post deleted by User.
 Bismarck.Nyaarun
Offline
Server: Bismarck
Game: FFXI
user: duo1666
Posts: 1006
By Bismarck.Nyaarun 2020-04-05 19:07:03
Link | Quote | Reply
 
Asura.Dexterm said: »
Why would you buy full apogee +1 and bayaami +1 AND jse neck +2 JUST to do old Odin? I don’t see why I’m mean, lol. I’d do some job research first before spending all that gil if I didn’t know how to play a job... but it’s specifically stated that this SMNs purpose is only Odin. Could’ve just geared a blu for a millionth of the price.

They LITERALLY came here for job research and to learn better.
 
Offline
Posts:
By 2020-04-05 19:11:12
 Undelete | Edit  | Link | Quote | Reply
 
Post deleted by User.
 
Offline
Posts:
By 2020-04-05 19:13:20
 Undelete | Edit  | Link | Quote | Reply
 
Post deleted by User.
 
Offline
Posts:
By 2020-04-05 19:16:30
 Undelete | Edit  | Link | Quote | Reply
 
Post deleted by User.
Offline
Posts: 227
By Galkapryme 2020-04-05 19:55:59
Link | Quote | Reply
 
1. I know the gearswap lua needs work. It's an iterative process.
2. I use Was for BP only, but I have multiple staves that I swap out for various reasons (i.e., BP, BP ability delay, basic Avatar melee).
3. When I posted this, I was seeking help, not people telling me how horrible of a SMN I am. For those who attempted to provide advice, I appreciate it.

To respond to some of the follow-ups, my lua has been modified a bit further. I do NOT use every set in the LUA. I just left the ones that were already there and tweaked what I needed based on what gear I have. I'm done with Odin. I started off with Ramuh, but a LS mate advised on using Ifrit, instead. That was some solid advice. I started with Ifrit, then Ramuh for the adds, then finished with Ifrit. Cait Sith's RR was not as useful as I had hoped. I still need to adjust my gearset because the couple times I died with RR up, I did in gear that gave all my HP to the summon. Just bad timing. I raised with 1 HP. I'm starting to teach myself on normal mobs now...just so I can play a little better overall. Here is my CURRENT lua as of today. NOTE: it is an iterative process. So if you're not going to advise on specific changes, please refrain from just telling me it's ***. Example, if I should swap out a piece of equipment, please briefly explain the why...if you have time.
Code
-------------------------------------------------------------------------------------------------------------------
-- Setup functions for this job.  Generally should not be modified.
-------------------------------------------------------------------------------------------------------------------

-- Also, you'll need the Shortcuts addon to handle the auto-targetting of the custom pact commands.

--[[
    Custom commands:
    
    gs c petweather
        Automatically casts the storm appropriate for the current avatar, if possible.
    
    gs c siphon
        Automatically run the process to: dismiss the current avatar; cast appropriate
        weather; summon the appropriate spirit; Elemental Siphon; release the spirit;
        and re-summon the avatar.
        
        Will not cast weather you do not have access to.
        Will not re-summon the avatar if one was not out in the first place.
        Will not release the spirit if it was out before the command was issued.
        
    gs c pact [PactType]
        Attempts to use the indicated pact type for the current avatar.
        PactType can be one of:
            cure
            curaga
            buffOffense
            buffDefense
            buffSpecial
            debuff1
            debuff2
            sleep
            nuke2
            nuke4
            bp70
            bp75 (merits and lvl 75-80 pacts)
            astralflow
--]]


-- Initialization function for this job file.
function get_sets()
    mote_include_version = 2

    -- Load and initialize the include file.
    include('Mote-Include.lua')
end

-- Setup vars that are user-independent.  state.Buff vars initialized here will automatically be tracked.
function job_setup()
    state.Buff["Avatar's Favor"] = buffactive["Avatar's Favor"] or false
    state.Buff["Astral Conduit"] = buffactive["Astral Conduit"] or false

    spirits = S{"LightSpirit", "DarkSpirit", "FireSpirit", "EarthSpirit", "WaterSpirit", "AirSpirit", "IceSpirit", "ThunderSpirit"}
    avatars = S{"Carbuncle", "Fenrir", "Diabolos", "Ifrit", "Titan", "Leviathan", "Garuda", "Shiva", "Ramuh", "Odin", "Alexander", "Cait Sith"}

    magicalRagePacts = S{
        'Inferno','Earthen Fury','Tidal Wave','Aerial Blast','Diamond Dust','Judgment Bolt','Searing Light','Howling Moon','Ruinous Omen',
        'Fire II','Stone II','Water II','Aero II','Blizzard II','Thunder II',
        'Fire IV','Stone IV','Water IV','Aero IV','Blizzard IV','Thunder IV',
        'Thunderspark','Burning Strike','Meteorite','Nether Blast','Flaming Crush',
        'Meteor Strike','Heavenly Strike','Wind Blade','Geocrush','Grand Fall','Thunderstorm',
        'Holy Mist','Lunar Bay','Night Terror','Level ? Holy'}


    pacts = {}
    pacts.cure = {['Carbuncle']='Healing Ruby'}
    pacts.curaga = {['Carbuncle']='Healing Ruby II', ['Garuda']='Whispering Wind', ['Leviathan']='Spring Water'}
    pacts.buffoffense = {['Carbuncle']='Glittering Ruby', ['Ifrit']='Crimson Howl', ['Garuda']='Hastega', ['Ramuh']='Rolling Thunder',
        ['Fenrir']='Ecliptic Growl'}
    pacts.buffdefense = {['Carbuncle']='Shining Ruby', ['Shiva']='Frost Armor', ['Garuda']='Aerial Armor', ['Titan']='Earthen Ward',
        ['Ramuh']='Lightning Armor', ['Fenrir']='Ecliptic Howl', ['Diabolos']='Noctoshield', ['Cait Sith']='Reraise II'}
    pacts.buffspecial = {['Ifrit']='Inferno Howl', ['Garuda']='Fleet Wind', ['Titan']='Earthen Armor', ['Diabolos']='Dream Shroud',
        ['Carbuncle']='Soothing Ruby', ['Fenrir']='Heavenward Howl', ['Cait Sith']='Raise II'}
    pacts.debuff1 = {['Shiva']='Diamond Storm', ['Ramuh']='Shock Squall', ['Leviathan']='Tidal Roar', ['Fenrir']='Lunar Cry',
        ['Diabolos']='Pavor Nocturnus', ['Cait Sith']='Eerie Eye'}
    pacts.debuff2 = {['Shiva']='Sleepga', ['Leviathan']='Slowga', ['Fenrir']='Lunar Roar', ['Diabolos']='Somnolence'}
    pacts.sleep = {['Shiva']='Sleepga', ['Diabolos']='Nightmare', ['Cait Sith']='Mewing Lullaby'}
    pacts.nuke2 = {['Ifrit']='Fire II', ['Shiva']='Blizzard II', ['Garuda']='Aero II', ['Titan']='Stone II',
        ['Ramuh']='Thunder II', ['Leviathan']='Water II'}
    pacts.nuke4 = {['Ifrit']='Fire IV', ['Shiva']='Blizzard IV', ['Garuda']='Aero IV', ['Titan']='Stone IV',
        ['Ramuh']='Thunder IV', ['Leviathan']='Water IV'}
    pacts.bp70 = {['Ifrit']='Flaming Crush', ['Shiva']='Rush', ['Garuda']='Predator Claws', ['Titan']='Mountain Buster',
        ['Ramuh']='Chaotic Strike', ['Leviathan']='Spinning Dive', ['Carbuncle']='Meteorite', ['Fenrir']='Eclipse Bite',
        ['Diabolos']='Nether Blast',['Cait Sith']='Regal Scratch'}
    pacts.bp75 = {['Ifrit']='Meteor Strike', ['Shiva']='Heavenly Strike', ['Garuda']='Wind Blade', ['Titan']='Geocrush',
        ['Ramuh']='Thunderstorm', ['Leviathan']='Grand Fall', ['Carbuncle']='Holy Mist', ['Fenrir']='Lunar Bay',
        ['Diabolos']='Night Terror', ['Cait Sith']='Level ? Holy'}
    pacts.astralflow = {['Ifrit']='Inferno', ['Shiva']='Diamond Dust', ['Garuda']='Aerial Blast', ['Titan']='Earthen Fury',
        ['Ramuh']='Judgment Bolt', ['Leviathan']='Tidal Wave', ['Carbuncle']='Searing Light', ['Fenrir']='Howling Moon',
        ['Diabolos']='Ruinous Omen', ['Cait Sith']="Altana's Favor"}

    -- Wards table for creating custom timers   
    wards = {}
    -- Base duration for ward pacts.
    wards.durations = {
        ['Crimson Howl'] = 60, ['Earthen Armor'] = 60, ['Inferno Howl'] = 60, ['Heavenward Howl'] = 60,
        ['Rolling Thunder'] = 120, ['Fleet Wind'] = 120,
        ['Shining Ruby'] = 180, ['Frost Armor'] = 180, ['Lightning Armor'] = 180, ['Ecliptic Growl'] = 180,
        ['Glittering Ruby'] = 180, ['Hastega'] = 180, ['Noctoshield'] = 180, ['Ecliptic Howl'] = 180,
        ['Dream Shroud'] = 180,
        ['Reraise II'] = 3600
    }
    -- Icons to use when creating the custom timer.
    wards.icons = {
        ['Earthen Armor']   = 'spells/00299.png', -- 00299 for Titan
        ['Shining Ruby']    = 'spells/00043.png', -- 00043 for Protect
        ['Dream Shroud']    = 'spells/00304.png', -- 00304 for Diabolos
        ['Noctoshield']     = 'spells/00106.png', -- 00106 for Phalanx
        ['Inferno Howl']    = 'spells/00298.png', -- 00298 for Ifrit
        ['Hastega']         = 'spells/00358.png', -- 00358 for Hastega
        ['Rolling Thunder'] = 'spells/00104.png', -- 00358 for Enthunder
        ['Frost Armor']     = 'spells/00250.png', -- 00250 for Ice Spikes
        ['Lightning Armor'] = 'spells/00251.png', -- 00251 for Shock Spikes
        ['Reraise II']      = 'spells/00135.png', -- 00135 for Reraise
        ['Fleet Wind']      = 'abilities/00074.png', -- 
    }
    -- Flags for code to get around the issue of slow skill updates.
    wards.flag = false
    wards.spell = ''
    
end

-------------------------------------------------------------------------------------------------------------------
-- User setup functions for this job.  Recommend that these be overridden in a sidecar file.
-------------------------------------------------------------------------------------------------------------------

-- Setup vars that are user-dependent.  Can override this function in a sidecar file.
function user_setup()
    state.OffenseMode:options('None', 'Normal', 'Acc')
    state.CastingMode:options('Normal', 'Resistant')
    state.IdleMode:options('Normal', 'PDT')

    gear.perp_staff = {name=""}
    
    select_default_macro_book()
end


-- Define sets and vars used by this job file.
function init_gear_sets()
	
	--------------------------------------
    -- Start defining the sets
    --------------------------------------
	
    -- Augmented gear
	
	Camp = {}
	Camp.FC = { name="Campestres's Cape", augments={'INT+20','"Fast Cast"+10','Mag. Acc.+20 /Mag. Dmg.+20','INT+5','Spell interruption rate down 8%'}}
	Camp.Pet1 = { name="Campestres's Cape", augments={'Pet: M.Acc.+20 Pet: M.Dmg.+20','Mag. Acc+20 /Mag. Dmg.+20','"Mag.Atk.Bns."+10','Pet: "Regen"+5',}}
	Camp.Pet2 = { name="Campestres's Cape", augments={'Pet: Acc.+20 Pet: R.Acc.+20 Pet: Atk.+20 Pet: R.Atk.+20','Eva.+20 /Mag. Eva.+20','Pet: Attack+10 Pet: Rng.Atk.+10','Pet: "Regen"+10','Pet: Damage taken -5%',}}
	
	
	
    --------------------------------------
    -- Precast Sets
    --------------------------------------
    
    -- Precast sets to enhance JAs
    sets.precast.JA['Astral Flow'] = {head="Glyphic Horn +1"}
    
    sets.precast.JA['Elemental Siphon'] = {
    main="Chatoyant Staff",
    sub="Vox Grip",
    ammo="Esper Stone +1", -- 20
    head="Baayami Hat +1",
    body="Baayami Robe +1",
    hands={ name="Telchine Gloves", augments={'"Mag.Atk.Bns."+20','"Elemental Siphon"+35',}}, --35
    legs="Baayami Slops +1",
    feet="Beckoner's Pigaches", --50
    neck={ name="Smn. Collar +2", augments={'Path: A',}},
    waist="Lucidity Sash",
    left_ear="Loquac. Earring",
    right_ear="Malignance",
    left_ring="Evoker's Ring",
    right_ring="Varar Ring +1",
    back="Twilight Cape",
}

    sets.precast.JA['Mana Cede'] = {hands="Caller's Bracers +2"}

    -- Pact delay reduction gear I-15, II-11, III-10
    sets.precast.BloodPactWard = {
    main="Espiritus", -- II-2
    sub="Elan Strap +1",
    ammo="Sancus Sachet +1", -- II-7
    head={ name="Glyphic Horn +1", augments={'Enhances "Astral Flow" effect',}}, -- I-7
    body="Glyphic Doublet +1", -- II-2
    hands="Baayami Cuffs +1", -- I-7
    legs="Baayami Slops +1", -- I-8
    feet="Baayami Sabots +1",
    neck={ name="Smn. Collar +2", augments={'Path: A',}},
    waist="Lucidity Sash",
    left_ear="Malignance Earring",
    right_ear="Loquac. Earring",
    left_ring="Stikini Ring +1",
    right_ring="Stikini Ring +1",
    back=Camp.Pet1,
}

    sets.precast.BloodPactRage = set_combine(sets.precast.BloodPactWard, {left_ring="Varar Ring +1",right_ring="Varar Ring +1"})	

    -- Fast cast sets for spells
    
    sets.precast.FC = {
    main={ name="Grioavolr", augments={'"Blood Pact" ability delay -2','Pet: DEX+13','Pet: Mag. Acc.+21','Pet: "Mag.Atk.Bns."+25','DMG:+18',}}, --4
    sub="Clerisy Strap +1", --3
    ammo="Impatiens",
    head={ name="Amalric Coif", augments={'INT+10','Mag. Acc.+20','Enmity-5',}}, --10
    body="Inyan. Jubbah +2", --14
    hands={ name="Helios Gloves", augments={'"Mag.Atk.Bns."+25','"Fast Cast"+4','MP+10',}}, --4
    legs={ name="Lengo Pants", augments={'INT+10','Mag. Acc.+15','"Mag.Atk.Bns."+15','"Refresh"+1',}}, --5
    feet={ name="Amalric Nails", augments={'MP+60','Mag. Acc.+15','"Mag.Atk.Bns."+15',}}, --5
    neck={ name="Smn. Collar +2", augments={'Path: A',}},
    waist="Channeler's Stone", --2
    left_ear="Loquac. Earring", --2
    right_ear="Malignance Earring", --4
    left_ring="Kishar Ring", --4
    right_ring="Lebeche Ring", --2
    back=Camp.FC, --10
}
    sets.precast.FC['Enhancing Magic'] = set_combine(sets.precast.FC, {waist="Siegel Sash"})
	
	sets.precast.FC['Stoneskin'] = set_combine(sets.precast.FC['Enhancing Magic'], {head="Umuthi Hat",hands="Carapacho Cuffs",legs="Doyen Pants"})
	
	sets.precast.FC['Cure'] = {
    main="Daybreak",
    sub="Sors Shield",
    ammo="Staunch Tathlum +1",
    head={ name="Amalric Coif", augments={'INT+10','Mag. Acc.+20','Enmity-5',}},
    body="Heka's Kalasiris",
    hands="Revealer's Mitts",
    legs="Lengo Pants",
    feet="Vanya Clogs",
    neck="Nodens Gorget",
    waist="Acerbic Sash +1",
    left_ear="Malignance Earring",
    right_ear="Loquac. Earring",
    left_ring="Kishar Ring",
    right_ring="Prolix Ring",
    back=Camp.FC,
}
	
       
    -- Weaponskill sets
    -- Default set for any weaponskill that isn't any more specifically defined
    sets.precast.WS = {}

    -- Specific weaponskill sets.  Uses the base set if an appropriate WSMod version isn't found.
    sets.precast.WS['Myrkr'] = {
	ammo="Strobilus",
    head="Pixie Hairpin +1",
    body={ name="Amalric Doublet +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
    hands={ name="Amalric Gages +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
    legs={ name="Lengo Pants", augments={'INT+10','Mag. Acc.+15','"Mag.Atk.Bns."+15','"Refresh"+1',}},
    feet="Beck. Pigaches",
    neck={ name="Smn. Collar +2", augments={'Path: A',}},
    waist="Eschan Stone",
    left_ear="Thureous Earring",
    right_ear="Loquac. Earring",
    left_ring="Sangoma Ring",
    right_ring="Fenrir Ring +1",
    back="Pahtli Cape",}

    
    --------------------------------------
    -- Midcast sets
    --------------------------------------

    sets.midcast.FastRecast = {
    main={ name="Grioavolr", augments={'Magic burst dmg.+1%','Mag. Acc.+24','"Mag.Atk.Bns."+23',}},
    sub="Clerisy Strap +1",
    ammo="Impatiens",
    head={ name="Amalric Coif", augments={'INT+10','Mag. Acc.+20','Enmity-5',}},
    body="Baayami Robe +1",
    hands={ name="Helios Gloves", augments={'"Mag.Atk.Bns."+25','"Fast Cast"+4','MP+10',}},
    legs={ name="Lengo Pants", augments={'INT+10','Mag. Acc.+15','"Mag.Atk.Bns."+15','"Refresh"+1',}},
    feet={ name="Amalric Nails", augments={'MP+60','Mag. Acc.+15','"Mag.Atk.Bns."+15',}},
    neck="Loricate Torque +1",
    waist="Witful Belt",
    left_ear="Malignance Earring",
    right_ear="Loquac. Earring",
    left_ring="Kishar Ring",
    right_ring="Lebeche Ring",
    back=Camp.FC,
}

    sets.midcast.Cure = {
    main="Daybreak", --23~50 + 10(II)
    ammo="Mana Ampulla",
    head="Inyanga Tiara +2",
    body="Heka's Kalasiris", --15
    hands="Revealer's Mitts", --13
    legs="Lengo Pants", 
    feet="Vanya Clogs", -- Healing Mag. Skill +34
    neck="Mizu. Kubikazari",
    waist="Luminary Sash",
    left_ear="Beatific Earring",
    right_ear="Lifestorm Earring",
    left_ring="Janniston Ring",
    right_ring="Menelaus's Ring",
    back="Solemnity Cape",
}

	sets.midcast['Enhancing Magic'] = {
    main={ name="Gada", augments={'"Conserve MP"+4','MND+2','Mag. Acc.+14','"Mag.Atk.Bns."+14',}},
    sub="Ammurapi Shield",
    ammo="Staunch Tathlum +1",
    head="Umuthi Hat",
    body={ name="Telchine Chas.", augments={'Mag. Acc.+22','"Cure" spellcasting time -4%','MP+50',}},
    hands="Inyan. Dastanas +2",
    legs={ name="Telchine Braconi", augments={'"Mag.Atk.Bns."+17','"Fast Cast"+4','Enh. Mag. eff. dur. +9',}},
    feet="Regal Pumps",
    neck="Sanctity Necklace",
    waist="Luminary Sash",
    left_ear="Brachyura Earring",
    right_ear="Impreg. Earring",
    left_ring="Stikini Ring +1",
    right_ring="Stikini Ring +1",
    back="Perimede Cape",
}
	
    sets.midcast.Stoneskin = {head="Umuthi Hat",waist="Siegel Sash", neck="Nodens Gorget"}

    sets.midcast['Elemental Magic'] = {
	main="Raetic Staff +1",
    sub="Enki Strap",
    ammo="Pemphredo Tathlum",
    head={ name="Merlinic Hood", augments={'"Mag.Atk.Bns."+25','"Drain" and "Aspir" potency +4','CHR+14','Mag. Acc.+6',}},
    body={ name="Amalric Doublet +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
    hands={ name="Amalric Gages +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
    legs={ name="Amalric Slops +1", augments={'INT+12','Elem. magic skill +20','Dark magic skill +20',}},
    feet={ name="Merlinic Crackows", augments={'Mag. Acc.+25 "Mag.Atk.Bns."+25','"Fast Cast"+3','MND+10','Mag. Acc.+2',}},
    neck="Eddy Necklace",
    waist="Hachirin-no-Obi",
    left_ear="Friomisi Earring",
    right_ear="Crematio Earring",
    left_ring="Shiva Ring +1",
    right_ring="Shiva Ring +1",
    back="Twilight Cape",
}

    sets.midcast['Dark Magic'] = {main={ name="Grioavolr", augments={'Magic burst dmg.+1%','Mag. Acc.+24','"Mag.Atk.Bns."+23',}},
    sub="Enki Strap",
    ammo="Dosis Tathlum",
    head="Pixie Hairpin +1",
    body={ name="Amalric Doublet +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
    hands={ name="Amalric Gages +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
    legs={ name="Amalric Slops +1", augments={'INT+12','Elem. magic skill +20','Dark magic skill +20',}},
    feet={ name="Merlinic Crackows", augments={'Mag. Acc.+25 "Mag.Atk.Bns."+25','"Fast Cast"+3','MND+10','Mag. Acc.+2',}},
    neck="Erra Pendant",
    waist="Hachirin-no-Obi",
    left_ear="Friomisi Earring",
    right_ear="Crematio Earring",
    left_ring="Fenrir Ring +1",
    right_ring="Fenrir Ring +1",
    back="Twilight Cape",}


    -- Avatar pact sets.  All pacts are Ability type.
	
    
    sets.midcast.Pet.BloodPactWard = {
	main={ name="Grioavolr", augments={'"Blood Pact" ability delay -2','Pet: DEX+13','Pet: Mag. Acc.+21','Pet: "Mag.Atk.Bns."+25','DMG:+18',}},
    sub="Elan Strap +1",
    ammo="Sancus Sachet +1",
    head={ name="Apogee Crown", augments={'Pet: Attack+20','Pet: "Mag.Atk.Bns."+20','Blood Pact Dmg.+7',}},
    body={ name="Merlinic Jubbah", augments={'"Mag.Atk.Bns."+19','"Drain" and "Aspir" potency +7','CHR+3','Mag. Acc.+14',}},
    hands={ name="Apogee Mitts", augments={'MP+60','Pet: "Mag.Atk.Bns."+30','Blood Pact Dmg.+7',}},
    legs="Avatara Slops",
    feet={ name="Artsieq Boots", augments={'MP+30','Pet: "Mag.Atk.Bns."+20','Pet: Mag. Acc.+20',}},
    neck="Wiglen Gorget",
    waist="Hachirin-no-Obi",
    left_ear="Enchntr. Earring +1",
    right_ear="Loquac. Earring",
    left_ring="Evoker's Ring",
    right_ring="Stikini Ring +1",
    back=Camp.Pet1,
}

    sets.midcast.Pet.DebuffBloodPactWard = {
	main={ name="Grioavolr", augments={'"Blood Pact" ability delay -2','Pet: DEX+13','Pet: Mag. Acc.+21','Pet: "Mag.Atk.Bns."+25','DMG:+18',}},
    sub="Elan Strap +1",
    ammo="Sancus Sachet +1",
    head={ name="Apogee Crown", augments={'Pet: Attack+20','Pet: "Mag.Atk.Bns."+20','Blood Pact Dmg.+7',}},
    body={ name="Apo. Dalmatica +1", augments={'Pet: Attack+25','Pet: "Mag.Atk.Bns."+25','Blood Pact Dmg.+8',}},
    hands={ name="Apogee Mitts", augments={'MP+60','Pet: "Mag.Atk.Bns."+30','Blood Pact Dmg.+7',}},
    legs="Avatara Slops",
    feet={ name="Artsieq Boots", augments={'MP+30','Pet: "Mag.Atk.Bns."+20','Pet: Mag. Acc.+20',}},
    neck="Wiglen Gorget",
    waist="Hachirin-no-Obi",
    left_ear="Enchntr. Earring +1",
    right_ear="Loquac. Earring",
    left_ring="Evoker's Ring",
    right_ring="Stikini Ring +1",
    back=Camp.Pet1,
}
        
    sets.midcast.Pet.DebuffBloodPactWard.Acc = sets.midcast.Pet.DebuffBloodPactWard
    
	-- Damaging BP +127
    sets.midcast.Pet.PhysicalBloodPactRage = {
	main="Was",
    sub="Elan Strap +1",
    ammo="Sancus Sachet +1",
    head={ name="Apogee Crown +1", augments={'Pet: Attack+25','Pet: "Mag.Atk.Bns."+25','Blood Pact Dmg.+8',}},
    body={ name="Apo. Dalmatica +1", augments={'Pet: Attack+25','Pet: "Mag.Atk.Bns."+25','Blood Pact Dmg.+8',}},
    hands={ name="Apogee Mitts +1", augments={'MP+80','Pet: Attack+35','Blood Pact Dmg.+8',}},
    legs={ name="Apogee Slacks +1", augments={'Pet: STR+20','Blood Pact Dmg.+14','Pet: "Dbl. Atk."+4',}},
    feet={ name="Apogee Pumps +1", augments={'Pet: Attack+25','Pet: "Mag.Atk.Bns."+25','Blood Pact Dmg.+8',}},
    neck={ name="Smn. Collar +2", augments={'Path: A',}},
    waist="Lucidity Sash",
    left_ear="Kyrene's Earring",
    right_ear="Malignance Earring",
    left_ring="Varar Ring +1",
    right_ring="Varar Ring +1",
    back=Camp.Pet2,
}

    sets.midcast.Pet.PhysicalBloodPactRage.Acc = sets.midcast.Pet.PhysicalBloodPactRage

    sets.midcast.Pet.MagicalBloodPactRage = set_combine(sets.midcast.Pet.PhysicalBloodPactRage, {
	main={ name="Grioavolr", augments={'"Blood Pact" ability delay -2','Pet: DEX+13','Pet: Mag. Acc.+21','Pet: "Mag.Atk.Bns."+25','DMG:+18',}},hands={ name="Apogee Mitts", augments={'MP+60','Pet: "Mag. Atk. Bns."+30','Blood Pact Dmg.+7',}},back=Camp.Pet1,})

    sets.midcast.Pet.MagicalBloodPactRage.Acc = sets.midcast.Pet.MagicalBloodPactRage


    -- Spirits cast magic spells, which can be identified in standard ways.
    
    sets.midcast.Pet.WhiteMagic = {legs="Glyphic Spats +3"}
    
    sets.midcast.Pet['Elemental Magic'] = set_combine(sets.midcast.Pet.BloodPactRage, {legs="Glyphic Spats +3"})

    sets.midcast.Pet['Elemental Magic'].Resistant = {}
    

    --------------------------------------
    -- Idle/resting/defense/etc sets
    --------------------------------------
    
    -- Resting sets
    sets.resting = {
	main="Boonwell Staff",
    ammo="Mana Ampulla",
    head="Inyanga Tiara +2",
    body="Oracle's Robe",
    hands="Inyan.Dastanas +2",
    legs={ name="Lengo Pants", augments={'INT+10','Mag. Acc.+15','"Mag.Atk.Bns."+15','"Refresh"+1',}},
    feet="Baayami Sabots +1",
    neck="Eidolon Pendant +1",
    waist="Austerity Belt +1",
    left_ear="Rapture Earring",
    right_ear="Loquac. Earring",
    left_ring="Stikini Ring +1",
    right_ring="Stikini Ring +1",
    back="Felicitas Cape +1",
}
    
    -- Idle sets -- perpetuation -25 Refresh +2
    sets.idle = {
	main="Daybreak",
	sub="Elan Strap +1",
    ammo="Staunch Tathlum +1",
    head={ name="Apogee Crown", augments={'Pet: Accuracy+20','"Avatar perpetuation cost"+5','Pet: Damage taken -3%',}}, --5
    body={ name="Glyphic Doublet +1", augments={'Reduces Sp. "Blood Pact" MP cost',}}, --5
    hands="Baayami Cuffs +1",
    legs="Lengo Pants", --4
    feet="Baayami Sabots +1",
    neck={ name="Smn. Collar +2", augments={'Path: A',}},
    waist="Klouskap Sash +1",
    left_ear="Kyrene's Earring",
    right_ear="Malignance Earring",
    left_ring="Stikini Ring +1",
    right_ring="Stikini Ring +1",
    back=Camp.Pet2,
}
	-- not really set yet
    sets.idle.PDT = {main={ name="Grioavolr", augments={'"Blood Pact" ability delay -2','Pet: DEX+13','Pet: Mag. Acc.+21','Pet: "Mag.Atk.Bns."+25','DMG:+18',}},sub="Elan Strap +1",ammo="Sancus Sachet +1",
        head="Convoker's Horn",neck="Summoner's Collar +2",ear1="Kyrene's Earring",ear2="Loquacious Earring",
        body="Glyphic Doublet +1 +1",hands="Inyan. Dastanas +2",ring1="Defending Ring",ring2="Sangoma Ring",
        back=Camp.Pet2,}
	
	--------- vanilla lua vvv not set -------
    -- perp costs:
    -- spirits: 7
    -- carby: 11 (5 with mitts)
    -- fenrir: 13
    -- others: 15
    -- avatar's favor: -4/tick
    
    -- Max useful -perp gear is 1 less than the perp cost (can't be reduced below 1)
    -- Aim for -14 perp, and refresh in other slots.
    --------- vanilla lua ^^^ not set -------
	
    -- -perp gear:
    -- Gridarvor: -5
    -- Glyphic Horn +1: -4
    -- Glyphic Doublet +1 +1: -5
    -- Evoker's Ring: -1
    -- Beckoner's Pigaches: -6
	-- Lucidity Sash: -2
    -- total: -23
    
    -- Can make due without either the head or the body, and use +refresh items in those slots.
    
    sets.idle.Avatar = {
	main="Gridarvor",
    sub="Elan Strap +1",
    ammo="Sancus Sachet +1",
    head={ name="Glyphic Horn +1", augments={'Enhances "Astral Flow" effect',}},
    body={ name="Glyphic Doublet +1", augments={'Reduces Sp. "Blood Pact" MP cost',}},
    hands={ name="Apogee Mitts", augments={'MP+60','Pet: "Mag.Atk.Bns."+30','Blood Pact Dmg.+7',}},
    legs={ name="Helios Spats", augments={'Pet: Attack+2 Pet: Rng.Atk.+2','"Avatar perpetuation cost" -4','CHR+10',}},
    feet="Baayami Sabots +1",
    neck={ name="Smn. Collar +2", augments={'Path: A',}},
    waist="Lucidity Sash",
    left_ear="Kyrene's Earring",
    right_ear="Loquac. Earring",
    left_ring="Varar Ring +1",
    right_ring="Varar Ring +1",
    back=Camp.Pet1,}
	
	------ NONE OF THESE ARE SET/TWEAKED-----
    sets.idle.PDT.Avatar = {main="Espiritus",sub="Elan Strap +1",ammo="Sancus Sachet +1",
        head="Convoker's Horn",neck="Summoner's Collar +2",ear1="Kyrene's Earring",ear2="Loquacious Earring",
        body="Glyphic Doublet +1",hands="Regimen Mittens",ring1="Evoker's Ring",ring2="Defending Ring",
        back=Camp.Pet2,waist="Fucho-no-Obi",legs="Hagondes Pants",feet="Baayami Sabots +1",}

    sets.idle.Spirit = {main={ name="Grioavolr", augments={'"Blood Pact" ability delay -2','Pet: DEX+13','Pet: Mag. Acc.+21','Pet: "Mag.Atk.Bns."+25','DMG:+18',}},sub="Vox Grip",ammo="Sancus Sachet +1",
        head="Convoker's Horn",neck="Summoner's Collar +2",ear1="Kyrene's Earring",ear2="Loquacious Earring",
        body="Glyphic Doublet +1",hands="Serpentes Cuffs",ring1="Evoker's Ring",ring2="Sangoma Ring",
        back="Samanisi Cape",waist="Fucho-no-Obi",legs="Summoner's Spats",feet="Herald's Gaiters"}

    sets.idle.Town = {main="Bolelabunga",sub="Sors Shield",ammo="Sancus Sachet +1",
        head="Convoker's Horn",neck="Summoner's Collar +2",ear1="Kyrene's Earring",ear2="Loquacious Earring",
        body="Glyphic Doublet +1",hands="Serpentes Cuffs",ring1="Sheltered Ring",ring2="Sangoma Ring",
        back="Umbra Cape",waist="Fucho-no-Obi",legs="Nares Trews",feet="Herald's Gaiters"}

    -- Favor uses Caller's Horn instead of Convoker's Horn for refresh
    sets.idle.Avatar.Favor = {head="Caller's Horn +2"}
	
    sets.idle.Avatar.Melee = {
	main={ name="Gridarvor", augments={'Pet: Accuracy+70','Pet: Attack+70','Pet: "Dbl. Atk."+15',}},
    sub="Elan Strap +1",
    ammo="Staunch Tathlum +1",
    head={ name="Apogee Crown", augments={'Pet: Accuracy+20','"Avatar perpetuation cost"+5','Pet: Damage taken -3%',}},
    body={ name="Apo. Dalmatica +1", augments={'Pet: Attack+25','Pet: "Mag.Atk.Bns."+25','Blood Pact Dmg.+8',}},
    hands={ name="Apogee Mitts +1", augments={'MP+80','Pet: Attack+35','Blood Pact Dmg.+8',}},
    legs={ name="Apogee Slacks +1", augments={'Pet: STR+20','Blood Pact Dmg.+14','Pet: "Dbl. Atk."+4',}},
    feet={ name="Apogee Pumps +1", augments={'Pet: Attack+25','Pet: "Mag.Atk.Bns."+25','Blood Pact Dmg.+8',}},
    neck={ name="Smn. Collar +2", augments={'Path: A',}},
    waist="Klouskap Sash +1",
    left_ear="Kyrene's Earring",
    right_ear="Evans Earring",
    left_ring="Varar Ring +1",
    right_ring="Varar Ring +1",
	back=Camp.Pet2,
}
        
    sets.perp = {
	main="Gridarvor", --5
    ammo="Staunch Tathlum +1",
    head={ name="Apogee Crown", augments={'Pet: Accuracy+20','"Avatar perpetuation cost"+5','Pet: Damage taken -3%',}}, --5
    body={ name="Glyphic Doublet +1", augments={'Reduces Sp. "Blood Pact" MP cost',}}, --5
    hands="Baayami Cuffs +1",
    legs="Baayami Slops +1",
    feet="Baayami Sabots +1",
    neck={ name="Smn. Collar +2", augments={'Path: A',}},
    waist="Klouskap Sash +1",
    left_ear="Kyrene's Earring",
    right_ear="Malignance Earring",
    left_ring="Stikini Ring +1",
    right_ring="Stikini Ring +1",
    back=Camp.Pet2,
}

    sets.perp.Alexander = sets.midcast.Pet.BloodPactWard

    sets.perp.staff_and_grip = {main=gear.perp_staff,sub="Elan Strap +1"}
    
    -- Defense sets
    sets.defense.PDT = {}

    sets.defense.MDT = {}

    sets.Kiting = {feet="Herald's Gaiters"}
    
    sets.latent_refresh = {waist="Gishdubar Sash"}
    

    --------------------------------------
    -- Engaged sets
    --------------------------------------
    
    -- Normal melee group (I never really melee)
    sets.engaged = {
    main={ name="Grioavolr", augments={'"Blood Pact" ability delay -2','Pet: DEX+13','Pet: Mag. Acc.+21','Pet: "Mag.Atk.Bns."+25','DMG:+18',}},
    sub="Elan Strap +1",
    ammo="Sancus Sachet +1",
    head={ name="Apogee Crown", augments={'Pet: Attack+20','Pet: "Mag.Atk.Bns."+20','Blood Pact Dmg.+7',}},
    body="Tali'ah Manteel +2",
    hands="Tali'ah Gages +2",
    legs="Tali'ah Sera. +2",
    feet={ name="Psycloth Boots", augments={'Pet: Attack+25','Pet: "Mag.Atk.Bns."+15','Pet: Enmity+7',}},
    neck={ name="Smn. Collar +2", augments={'Path: A',}},
    waist="Lucidity Sash",
    left_ear="Kyrene's Earring",
    right_ear="Evans Earring",
    left_ring="Varar Ring +1",
    right_ring="Varar Ring +1",
    back=Camp.Pet1,
}
end

-------------------------------------------------------------------------------------------------------------------
-- Job-specific hooks for standard casting events.
-------------------------------------------------------------------------------------------------------------------

-- Set eventArgs.handled to true if we don't want any automatic gear equipping to be done.
-- Set eventArgs.useMidcastGear to true if we want midcast gear equipped on precast.
function job_precast(spell, action, spellMap, eventArgs)
    if state.Buff['Astral Conduit'] and pet_midaction() then
        eventArgs.handled = true
    end
end

function job_midcast(spell, action, spellMap, eventArgs)
    if state.Buff['Astral Conduit'] and pet_midaction() then
        eventArgs.handled = true
    end
end

-- Runs when pet completes an action.
function job_pet_aftercast(spell, action, spellMap, eventArgs)
    if not spell.interrupted and spell.type == 'BloodPactWard' and spellMap ~= 'DebuffBloodPactWard' then
        wards.flag = true
        wards.spell = spell.english
        send_command('wait 4; gs c reset_ward_flag')
    end
end

-------------------------------------------------------------------------------------------------------------------
-- Job-specific hooks for non-casting events.
-------------------------------------------------------------------------------------------------------------------

-- Called when a player gains or loses a buff.
-- buff == buff gained or lost
-- gain == true if the buff was gained, false if it was lost.
function job_buff_change(buff, gain)
    if state.Buff[buff] ~= nil then
        handle_equipping_gear(player.status)
    elseif storms:contains(buff) then
        handle_equipping_gear(player.status)
    end
end


-- Called when the player's pet's status changes.
-- This is also called after pet_change after a pet is released.  Check for pet validity.
function job_pet_status_change(newStatus, oldStatus, eventArgs)
    if pet.isvalid and not midaction() and not pet_midaction() and (newStatus == 'Engaged' or oldStatus == 'Engaged') then
        handle_equipping_gear(player.status, newStatus)
    end
end


-- Called when a player gains or loses a pet.
-- pet == pet structure
-- gain == true if the pet was gained, false if it was lost.
function job_pet_change(petparam, gain)
    classes.CustomIdleGroups:clear()
    if gain then
        if avatars:contains(pet.name) then
            classes.CustomIdleGroups:append('Avatar')
        elseif spirits:contains(pet.name) then
            classes.CustomIdleGroups:append('Spirit')
        end
    else
        select_default_macro_book('reset')
    end
end

-------------------------------------------------------------------------------------------------------------------
-- User code that supplements standard library decisions.
-------------------------------------------------------------------------------------------------------------------

-- Custom spell mapping.
function job_get_spell_map(spell)
    if spell.type == 'BloodPactRage' then
        if magicalRagePacts:contains(spell.english) then
            return 'MagicalBloodPactRage'
        else
            return 'PhysicalBloodPactRage'
        end
    elseif spell.type == 'BloodPactWard' and spell.target.type == 'MONSTER' then
        return 'DebuffBloodPactWard'
    end
end

-- Modify the default idle set after it was constructed.
function customize_idle_set(idleSet)
    if pet.isvalid then
        if pet.element == world.day_element then
            idleSet = set_combine(idleSet, sets.perp.Day)
        end
        if pet.element == world.weather_element then
            idleSet = set_combine(idleSet, sets.perp.Weather)
        end
        if sets.perp[pet.name] then
            idleSet = set_combine(idleSet, sets.perp[pet.name])
        end
        gear.perp_staff.name = elements.perpetuance_staff_of[pet.element]
        if gear.perp_staff.name and (player.inventory[gear.perp_staff.name] or player.wardrobe[gear.perp_staff.name]) then
            idleSet = set_combine(idleSet, sets.perp.staff_and_grip)
        end
        if state.Buff["Avatar's Favor"] and avatars:contains(pet.name) then
            idleSet = set_combine(idleSet, sets.idle.Avatar.Favor)
        end
        if pet.status == 'Engaged' then
            idleSet = set_combine(idleSet, sets.idle.Avatar.Melee)
        end
    end
    
    if player.mpp < 51 then
        idleSet = set_combine(idleSet, sets.latent_refresh)
    end
    
    return idleSet
end

-- Called by the 'update' self-command, for common needs.
-- Set eventArgs.handled to true if we don't want automatic equipping of gear.
function job_update(cmdParams, eventArgs)
    classes.CustomIdleGroups:clear()
    if pet.isvalid then
        if avatars:contains(pet.name) then
            classes.CustomIdleGroups:append('Avatar')
        elseif spirits:contains(pet.name) then
            classes.CustomIdleGroups:append('Spirit')
        end
    end
end

-- Set eventArgs.handled to true if we don't want the automatic display to be run.
function display_current_job_state(eventArgs)

end


-------------------------------------------------------------------------------------------------------------------
-- User self-commands.
-------------------------------------------------------------------------------------------------------------------

-- Called for custom player commands.
function job_self_command(cmdParams, eventArgs)
    if cmdParams[1]:lower() == 'petweather' then
        handle_petweather()
        eventArgs.handled = true
    elseif cmdParams[1]:lower() == 'siphon' then
        handle_siphoning()
        eventArgs.handled = true
    elseif cmdParams[1]:lower() == 'pact' then
        handle_pacts(cmdParams)
        eventArgs.handled = true
    elseif cmdParams[1] == 'reset_ward_flag' then
        wards.flag = false
        wards.spell = ''
        eventArgs.handled = true
    end
end


-------------------------------------------------------------------------------------------------------------------
-- Utility functions specific to this job.
-------------------------------------------------------------------------------------------------------------------

-- Cast the appopriate storm for the currently summoned avatar, if possible.
function handle_petweather()
    if player.sub_job ~= 'SCH' then
        add_to_chat(122, "You can not cast storm spells")
        return
    end
        
    if not pet.isvalid then
        add_to_chat(122, "You do not have an active avatar.")
        return
    end
    
    local element = pet.element
    if element == 'Thunder' then
        element = 'Lightning'
    end
    
    if S{'Light','Dark','Lightning'}:contains(element) then
        add_to_chat(122, 'You do not have access to '..elements.storm_of[element]..'.')
        return
    end 
    
    local storm = elements.storm_of[element]
    
    if storm then
        send_command('@input /ma "'..elements.storm_of[element]..'" <me>')
    else
        add_to_chat(123, 'Error: Unknown element ('..tostring(element)..')')
    end
end


-- Custom uber-handling of Elemental Siphon
function handle_siphoning()
    if areas.Cities:contains(world.area) then
        add_to_chat(122, 'Cannot use Elemental Siphon in a city area.')
        return
    end

    local siphonElement
    local stormElementToUse
    local releasedAvatar
    local dontRelease
    
    -- If we already have a spirit out, just use that.
    if pet.isvalid and spirits:contains(pet.name) then
        siphonElement = pet.element
        dontRelease = true
        -- If current weather doesn't match the spirit, but the spirit matches the day, try to cast the storm.
        if player.sub_job == 'SCH' and pet.element == world.day_element and pet.element ~= world.weather_element then
            if not S{'Light','Dark','Lightning'}:contains(pet.element) then
                stormElementToUse = pet.element
            end
        end
    -- If we're subbing /sch, there are some conditions where we want to make sure specific weather is up.
    -- If current (single) weather is opposed by the current day, we want to change the weather to match
    -- the current day, if possible.
    elseif player.sub_job == 'SCH' and world.weather_element ~= 'None' then
        -- We can override single-intensity weather; leave double weather alone, since even if
        -- it's partially countered by the day, it's not worth changing.
        if get_weather_intensity() == 1 then
            -- If current weather is weak to the current day, it cancels the benefits for
            -- siphon.  Change it to the day's weather if possible (+0 to +20%), or any non-weak
            -- weather if not.
            -- If the current weather matches the current avatar's element (being used to reduce
            -- perpetuation), don't change it; just accept the penalty on Siphon.
            if world.weather_element == elements.weak_to[world.day_element] and
                (not pet.isvalid or world.weather_element ~= pet.element) then
                -- We can't cast lightning/dark/light weather, so use a neutral element
                if S{'Light','Dark','Lightning'}:contains(world.day_element) then
                    stormElementToUse = 'Wind'
                else
                    stormElementToUse = world.day_element
                end
            end
        end
    end
    
    -- If we decided to use a storm, set that as the spirit element to cast.
    if stormElementToUse then
        siphonElement = stormElementToUse
    elseif world.weather_element ~= 'None' and (get_weather_intensity() == 2 or world.weather_element ~= elements.weak_to[world.day_element]) then
        siphonElement = world.weather_element
    else
        siphonElement = world.day_element
    end
    
    local command = ''
    local releaseWait = 0
    
    if pet.isvalid and avatars:contains(pet.name) then
        command = command..'input /pet "Release" <me>;wait 1.1;'
        releasedAvatar = pet.name
        releaseWait = 10
    end
    
    if stormElementToUse then
        command = command..'input /ma "'..elements.storm_of[stormElementToUse]..'" <me>;wait 4;'
        releaseWait = releaseWait - 4
    end
    
    if not (pet.isvalid and spirits:contains(pet.name)) then
        command = command..'input /ma "'..elements.spirit_of[siphonElement]..'" <me>;wait 4;'
        releaseWait = releaseWait - 4
    end
    
    command = command..'input /ja "Elemental Siphon" <me>;'
    releaseWait = releaseWait - 1
    releaseWait = releaseWait + 0.1
    
    if not dontRelease then
        if releaseWait > 0 then
            command = command..'wait '..tostring(releaseWait)..';'
        else
            command = command..'wait 1.1;'
        end
        
        command = command..'input /pet "Release" <me>;'
    end
    
    if releasedAvatar then
        command = command..'wait 1.1;input /ma "'..releasedAvatar..'" <me>'
    end
    
    send_command(command)
end


-- Handles executing blood pacts in a generic, avatar-agnostic way.
-- cmdParams is the split of the self-command.
-- gs c [pact] [pacttype]
function handle_pacts(cmdParams)
    if areas.Cities:contains(world.area) then
        add_to_chat(122, 'You cannot use pacts in town.')
        return
    end

    if not pet.isvalid then
        add_to_chat(122,'No avatar currently available. Returning to default macro set.')
        select_default_macro_book('reset')
        return
    end

    if spirits:contains(pet.name) then
        add_to_chat(122,'Cannot use pacts with spirits.')
        return
    end

    if not cmdParams[2] then
        add_to_chat(123,'No pact type given.')
        return
    end
    
    local pact = cmdParams[2]:lower()
    
    if not pacts[pact] then
        add_to_chat(123,'Unknown pact type: '..tostring(pact))
        return
    end
    
    if pacts[pact][pet.name] then
        if pact == 'astralflow' and not buffactive['astral flow'] then
            add_to_chat(122,'Cannot use Astral Flow pacts at this time.')
            return
        end
        
        -- Leave out target; let Shortcuts auto-determine it.
        send_command('@input /pet "'..pacts[pact][pet.name]..'"')
    else
        add_to_chat(122,pet.name..' does not have a pact of type ['..pact..'].')
    end
end


-- Event handler for updates to player skill, since we can't rely on skill being
-- correct at pet_aftercast for the creation of custom timers.
windower.raw_register_event('incoming chunk',
    function (id)
        if id == 0x62 then
            if wards.flag then
                create_pact_timer(wards.spell)
                wards.flag = false
                wards.spell = ''
            end
        end
    end)

-- Function to create custom timers using the Timers addon.  Calculates ward duration
-- based on player skill and base pact duration (defined in job_setup).
function create_pact_timer(spell_name)
    -- Create custom timers for ward pacts.
    if wards.durations[spell_name] then
        local ward_duration = wards.durations[spell_name]
        if ward_duration < 181 then
            local skill = player.skills.summoning_magic
            if skill > 300 then
                skill = skill - 300
                if skill > 200 then skill = 200 end
                ward_duration = ward_duration + skill
            end
        end
        
        local timer_cmd = 'timers c "'..spell_name..'" '..tostring(ward_duration)..' down'
        
        if wards.icons[spell_name] then
            timer_cmd = timer_cmd..' '..wards.icons[spell_name]
        end

        send_command(timer_cmd)
    end
end


-- Select default macro book on initial load or subjob change.
function select_default_macro_book(reset)
    if reset == 'reset' then
        -- lost pet, or tried to use pact when pet is gone
    end
    
    -- Default macro set/book
    set_macro_page(9, 19)
	end