Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function get_sets()
- sets.aftercast_Idle_refresh = {main="Owleyes",sub="Genbu's Shield",ammo="Incantor Stone",
- head="Orvail Corona +1",neck="Twilight Torque",ear1="Novia Earring",ear2="Loquacious Earring",
- body="Bokwus Robe",hands="Serpentes Cuffs",ring1="Prolix Ring",ring2="Jelly Ring",
- back="Umbra Cape",waist="Witful Belt",legs="Orvail Pants +1",feet="Serpentes Sabots"}
- sets.aftercast_Idle = sets.aftercast_Idle_refresh
- sets.aftercast_Move = set_combine(sets.aftercast_Idle_refresh,{feet="Desert Boots"})
- sets.precast_FastCast = {ammo="Incantor Stone",head="Nahtirah Hat",ear2="Loquacious Earring",
- neck="Orison Locket",back="Swith Cape",legs="Orvail Pants +1",feet="Chelona Boots +1"}
- sets.Resting = {main="Boonwell Staff",sub="Mephitis Grip",
- head="Orvail Corona +1",neck="Grandiose Chain",ear1="Antivenom Earring",ear2="Loquacious Earring",
- body="Bokwus Robe",back="Umbra Cape",legs="Nares Trews",feet="Chelona Boots +1"}
- sets.midcast_EnfeeblingMagic = {main="Eminent Wand",sub="Genbu's Shield",ammo="Savant's Treatise",
- head="Nahtirah Hat",neck="Enfeebling Torque",ear1="Lifestorm Earring",ear2="Psystorm Earring",
- body="Bokwus robe",hands="Hagondes Cuffs",ring1="Omega Ring",ring2="Tamas Ring",
- back="Merciful Cape",waist="Cognition Belt",legs="Orvail Pants +1",feet="Weatherspoon Boots"}
- sets.midcast_EnhancingMagic = {main="Kirin's Pole",sub="Fulcio Grip",ammo="Incantor Stone",
- head="Nahtirah Hat",neck="Orison Locket",ear1="Lifestorm Earring",ear2="Loquacious Earring",
- body="Bokwus Robe",hands="Gendewitha Gages",
- back="Swith Cape",waist="Witful Belt",legs="Orvail Pants +1",feet="Chelona Boots +1"}
- sets.midcast_Cure = {main="Tefnut Wand",sub="Genbu's Shield",head="Orison Cap +1",neck="Orison Locket",
- body="Nefer Kalasiris",hands="Weatherspoon Gloves",back="Tempered Cape"}
- sets.midcast_Stoneskin = {main="Kirin's Pole",neck="Stone Gorget",waist="Siegel Sash",legs="Shedir Seraweels"}
- sets.midcast_DebuffRemoval = {ammo="Incantor Stone",head="Orison Cap +2",neck="Malison Medallion",ear2="Loquacious Earring",
- body="Orison Bliaurd +2",hands="Orison Mitts +2",ring1="Ephedra Ring", ring2="Sirona's Ring",
- back="Swith Cape",waist="Cascade Belt",legs="Gendewitha Spats",feet="Gendewitha Galoshes"}
- sets.Obi = {}
- sets.Obi.Fire = {waist='Karin Obi',back='Twilight Cape'}
- sets.Obi.Earth = {waist='Dorin Obi',back='Twilight Cape'}
- sets.Obi.Water = {waist='Suirin Obi',back='Twilight Cape'}
- sets.Obi.Wind = {waist='Furin Obi',back='Twilight Cape'}
- sets.Obi.Ice = {waist='Hyorin Obi',back='Twilight Cape'}
- sets.Obi.Thunder = {waist='Rairin Obi',back='Twilight Cape'}
- sets.Obi.Light = {waist='Korin Obi',back='Twilight Cape'}
- sets.Obi.Dark = {waist='Anrin Obi',back='Twilight Cape'}
- sets.staves = {}
- sets.staves.damage = {}
- sets.staves.accuracy = {}
- sets.staves.damage.Thunder = {main="Apamajas II"}
- end
- function precast(spell)
- if spell.skill=='ElementalMagic' and spell.casttime < 3 then
- equip(sets.midcast_ElementalMagic)
- if spell.element == world.weather_element or spell_element == world.day_element and sets.Obi[spell.element] then
- equip(sets.Obi[spell.element])
- end
- else
- equip(sets['precast_FastCast'])
- end
- end
- function midcast(spell)
- if spell.skill=='HealingMagic' then
- if T{"Cure*","Curaga*"}:contains(spell.name) then
- equip(sets.midcast_Cure)
- elseif T{"Paralyna","Silena","Viruna","Erase","Cursna","Stona","Blindna","Poisona"}:contains(spell.name) then
- equip (sets['midcast_DebuffRemoval'])
- else
- equip(sets.midcast_DebuffRemoval)
- end
- elseif spell.skill=="ElementalMagic" then
- equip(sets.midcast_ElementalMagic)
- if spell.element == world.weather_element or spell_element == world.day_element then
- equip(sets.Obi[spell.element])
- end
- elseif spell.english == 'Stoneskin' then
- equip(sets['midcast_Stoneskin'])
- elseif spell.skill == 'EnhancingMagic' then
- weathercheck(spell.element,sets['midcast_'..spell.skill])
- end
- if spell.english == 'Sneak' then
- send_command('@wait 1.8;cancel 71;')
- end
- end
- function aftercast(spell)
- equip(sets['aftercast_Idle'])
- if spell.english == 'Sleep' or spell.english == 'Sleepga' then
- send_command('@wait 50;input /echo ------- '..spell.english..' is wearing off in 10 seconds -------')
- elseif spell.english == 'Sleep II' or spell.english == 'Sleepga II' then
- send_command('@wait 80;input /echo ------- '..spell.english..' is wearing off in 10 seconds -------')
- elseif spell.english == 'Break' or spell.english == 'Breakga' then
- send_command('@wait 20;input /echo ------- '..spell.english..' is wearing off in 10 seconds -------')
- end
- end
- function status_change(new,tab)
- if new == 'Resting' then
- equip(sets['Resting'])
- else
- equip(sets['aftercast_Idle'])
- end
- end
- function buff_change(status,gain_or_loss)
- if buffactive['Sandstorm'] then
- sets.aftercast_Idle = sets.aftercast_Move
- send_command('@wait 1; input /echo ------- Processed Movement Speed Gear Swap -------')
- end
- equip(sets.aftercast_Idle)
- end
- function self_command(command)
- if buffactive['Sanstorm'] then
- sets.aftercast_Idle = sets.aftercast_Idle_Move
- else
- sets.aftercast_Idle = sets.aftercast_Idle_Refresh
- end
- equip(sets.aftercast_Idle)
- end
- -- This function is user defined, but never called by GearSwap itself. It's just a user function that's only called from user functions. I wanted to check the weather and equip a weather-based set for some spells, so it made sense to make a function for it instead of replicating the conditional in multiple places.
- function weathercheck(spell_element,set)
- if spell_element == world.weather_element or spell_element == world.day_element then
- equip(set,sets['Obi_'..spell_element])
- else
- equip(set)
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement