Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function get_sets()
- sets = {}
- sets.aftercast_Idle_noSub = {main="Keraunos",sub="Mephitis Grip",ammo="Incantor Stone",
- neck="Twilight Torque",ear1="Nourishing earring",ear2="Loquacious Earring",
- body="Respite Cloak",hands="Serpentes Cuffs",ring1="Defending Ring",ring2="Patricius ring",
- back="Iximulew Cape",waist="Fucho-no-obi",legs="Assiduity Pants",feet="Serpentes Sabots"}
- sets.aftercast_Idle_Sub = {main="Keraunos",sub="Mephitis Grip",ammo="Incantor Stone",
- neck="Twilight Torque",ear1="Nourishing earring",ear2="Loquacious Earring",
- body="Respite Cloak",hands="Serpentes Cuffs",ring1="Defending Ring",ring2="Patricius ring",
- back="Iximulew Cape",waist="Fucho-no-obi",legs="Assiduity Pants",feet="Serpentes Sabots"}
- sets.aftercast_Idle = sets.aftercast_Idle_noSub
- sets.precast_FastCast = {ammo="Incantor Stone",head="Nahtirah Hat",ear2="Loquacious Earring",
- body="Anhur Robe",hands="Gendewitha Gages",back="Swith Cape",legs="Orvail Pants",feet="Chelona Boots"}
- sets.Resting = {main="Chatoyant Staff",sub="Mephitis Grip",
- head="Nahtirah Hat",neck="Twilight Torque",ear1="Lifestorm Earring",ear2="Loquacious Earring",
- body="Hagondes Coat",hands="Nares Cuffs",ring1="Sangoma Ring",ring2="Maquette Ring",
- back="Shadow Mantle",waist="Korin Obi",legs="Nares Trews",feet="Chelona Boots"}
- sets.midcast_ElementalMagic = {main="Keraunos",sub="Mephitis Grip",ammo="Witchstone",
- head="Hagondes Hat +1",
- neck="Eddy necklace",ear1="Friomis Earring",ear2="Hecate's Earring",
- body="Vanir Cotehardie",hands="Otomi Gloves",
- ring1="Prolix ring",ring2="Acumen ring",
- back="Toro Cape",waist="Yamabuki-no-obi",legs="Hagondes pants +1",
- feet="Umbani Boots"}
- sets.midcast_DarkMagic = {main="Keraunos",sub="Mephitis Grip",ammo="Witchstone",
- head="Hagondes Hat +1",
- neck="Eddy necklace",ear1="Friomis Earring",ear2="Hecate's Earring",
- body="Vanir Cotehardie",hands="Otomi Gloves",
- ring1="Prolix ring",ring2="Acumen ring",
- back="Toro Cape",waist="Yamabuki-no-obi",legs="Hagondes pants +1",
- feet="Umbani Boots"}
- sets.midcast_EnfeeblingMagic = {main="Keraunos",sub="Mephitis Grip",ammo="Witchstone",
- head="Hagondes Hat +1",
- neck="Eddy necklace",ear1="Friomis Earring",ear2="Hecate's Earring",
- body="Vanir Cotehardie",hands="Otomi Gloves",
- ring1="Prolix ring",ring2="Acumen ring",
- back="Toro Cape",waist="Yamabuki-no-obi",legs="Hagondes pants +1",
- feet="Umbani Boots"}
- sets.midcast_Impact = {main="Keraunos",sub="Mephitis Grip",ammo="Witchstone",
- head="Hagondes Hat +1",
- neck="Eddy necklace",ear1="Friomis Earring",ear2="Hecate's Earring",
- body="Vanir Cotehardie",hands="Otomi Gloves",
- ring1="Prolix ring",ring2="Acumen ring",
- back="Toro Cape",waist="Yamabuki-no-obi",legs="Hagondes pants +1",
- feet="Umbani Boots"}
- sets.midcast_Embrava = {main="Keraunos",sub="Mephitis Grip",ammo="Witchstone",
- head="Hagondes Hat +1",
- neck="Eddy necklace",ear1="Friomis Earring",ear2="Hecate's Earring",
- body="Vanir Cotehardie",hands="Otomi Gloves",
- ring1="Prolix ring",ring2="Acumen ring",
- back="Toro Cape",waist="Yamabuki-no-obi",legs="Hagondes pants +1",
- feet="Umbani Boots"}
- sets.midcast_EnhancingMagic = {main="Kirin's Pole",sub="Fulcio Grip",ammo="Incantor Stone",
- head="Nahtirah Hat",neck="Colossus's Torque",ear1="Lifestorm Earring",ear2="Loquacious Earring",
- body="Anhur Robe",hands="Gendewitha Gages",
- back="Swith Cape",waist="Ninurta's Sash",legs="Orvail Pants",feet="Chelona Boots"}
- sets.precast_Stun = {main="Keraunos",sub="Mephitis Grip",ammo="Witchstone",
- head="Hagondes Hat +1",
- neck="Eddy necklace",ear1="Friomis Earring",ear2="Hecate's Earring",
- body="Vanir Cotehardie",hands="Otomi Gloves",
- ring1="Prolix ring",ring2="Acumen ring",
- back="Toro Cape",waist="Yamabuki-no-obi",legs="Hagondes pants +1",
- feet="Umbani Boots"}
- sets.midcast_Cure = {main="Keraunos",sub="Mephitis Grip",head="Nahtirah Hat",ear1="Roundel Earring",ear2="Loquacious Earring",
- neck="Orunmila's Torque",body="Heka's Kalasiris",hands="Bokwus Gloves",ring1="Patricius Ring",ring2="Kunaji Ring",
- back="Tempered +1",waist="Witful Belt",legs="Nares Trews",feet="Regal pumps"}
- sets.midcast_Helix = {main="Keraunos",sub="Mephitis Grip",ammo="Witchstone",
- head="Hagondes Hat +1",
- neck="Eddy necklace",ear1="Friomis Earring",ear2="Hecate's Earring",
- body="Vanir Cotehardie",hands="Otomi Gloves",
- ring1="Prolix ring",ring2="Acumen ring",
- back="Toro Cape",waist="Yamabuki-no-obi",legs="Hagondes pants +1",
- feet="Umbani Boots"}
- sets.midcast_Stoneskin = {main="Kirin's Pole",neck="Stone Gorget",waist="Siegel Sash",legs="Shedir Seraweels"}
- sets.Obi = {}
- sets.Obi.Fire = {waist='Karin Obi',back='Twilight Cape',lring='Zodiac Ring'}
- sets.Obi.Earth = {waist='Dorin Obi',back='Twilight Cape',lring='Zodiac Ring'}
- sets.Obi.Water = {waist='Suirin Obi',back='Twilight Cape',lring='Zodiac Ring'}
- sets.Obi.Wind = {waist='Furin Obi',back='Twilight Cape',lring='Zodiac Ring'}
- sets.Obi.Ice = {waist='Hyorin Obi',back='Twilight Cape',lring='Zodiac Ring'}
- sets.Obi.Thunder = {waist='Rairin Obi',back='Twilight Cape',lring='Zodiac Ring'}
- sets.Obi.Light = {waist='Korin Obi',back='Twilight Cape',lring='Zodiac Ring'}
- sets.Obi.Dark = {waist='Anrin Obi',back='Twilight Cape',lring='Zodiac Ring'}
- sets.staves = {}
- sets.staves.damage = {main="Keraunos"}
- sets.staves.damage.Thunder = {main="Keraunos"}
- sets.staves.damage.Fire = {main="Keraunos"}
- sets.staves.accuracy = {main="Keraunos"}
- sets.staves.damage.Thunder = {main="Keraunos"}
- sets.staves.damage.Ice = {main="Keraunos"}
- stuntarg = 'Shantotto'
- end
- function precast(spell,action)
- if spell.english == 'Impact' then
- cast_delay(2)
- equip(sets['precast_FastCast'],{body="Twilight Cloak"})
- if not buffactive['elemental seal'] then
- add_to_chat(8,'--------- Elemental Seal is down ---------')
- end
- elseif spell.skill=='ElementalMagic' and spell.casttime < 3 then
- cast_delay(0.1)
- equip(sets.midcast_ElementalMagic)
- if spell.element == 'Earth' then
- equip({neck="Quanpur Necklace"})
- end
- if spell.element == world.weather_element or spell_element == world.day_element and sets.Obi[spell.element] then
- equip(sets.Obi[spell.element])
- end
- elseif spell.english == 'Stun' then
- cast_delay(0.1)
- equip(sets['precast_Stun'])
- if not buffactive.thunderstorm then
- add_to_chat(8,'--------- Thunderstorm is down ---------')
- elseif not buffactive.klimaform then
- add_to_chat(8,'----------- Klimaform is down -----------')
- end
- if stuntarg ~= 'Shantotto' then
- send_command('@input /t '..stuntarg..' ---- Byrth Stunned!!! ---- ')
- end
- else
- equip(sets['precast_FastCast'])
- cast_delay(0.5)
- end
- if (buffactive.alacrity or buffactive.celerity) and world.weather_element == spell.element then
- equip({feet='Argute Loafers +2'})
- end
- end
- function midcast(spell,action)
- if string.find(spell.english,'Cur') then
- equip(sets.midcast_Cure)
- if spell.element == world.weather_element or spell_element == world.day_element then
- equip({main="Chatoyant Staff"},sets.Obi[spell.element])
- end
- if buffactive.rapture then
- equip({head="Savant's Bonnet +2"})
- end
- elseif spell.english == 'Impact' then
- local tempset = sets['midcast_Impact']
- tempset['body'] = 'Twilight Cloak'
- tempset['head'] = empty
- equip(tempset)
- if spell.element == world.weather_element or spell_element == world.day_element then
- equip(sets.Obi[spell.element])
- end
- if sets.staves.damage[spell.element] then
- equip(sets.staves.damage[spell.element])
- end
- elseif spell.skill=="ElementalMagic" then
- if string.find(spell.english,'helix') then
- equip(sets['midcast_Helix'])
- else
- equip(sets.midcast_ElementalMagic)
- if spell.element=='Earth' then
- equip({neck="Quanpur Necklace"})
- end
- if spell.element == world.weather_element or spell_element == world.day_element then
- equip(sets.Obi[spell.element])
- end
- end
- if buffactive.ebullience then
- equip({head="Savant's Bonnet +2"})
- end
- if buffactive.klimform then
- equip ({feet="Savant's Loafers +2"})
- end
- elseif spell.english == 'Stoneskin' then
- equip(sets['midcast_Stoneskin'])
- elseif spell.skill == 'EnhancingMagic' then
- if spell.english == 'Embrava' then
- equip(sets['midcast_Embrava'])
- if not buffactive.perpetuance then
- add_to_chat(8,'--------- Perpetuance is down ---------')
- end
- if not buffactive.accession then
- add_to_chat(8,'--------- Accession is down ---------')
- end
- if not buffactive.penury then
- add_to_chat(8,'--------- Penury is down ---------')
- end
- end
- if buffactive.perpetuance then
- equip(sets['midcast_EnhancingMagic'],{hands="Savant's Bracers +2"})
- else
- equip(sets['midcast_EnhancingMagic'])
- end
- else
- 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,action)
- 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 status == 'Sublimation: Complete' and gain_or_loss == 'gain' and not 'stunmode' then -- True whether gained or lost
- sets.aftercast_Idle = sets.aftercast_Idle_noSub
- elseif status == 'Sublimation: Activated' and gain_or_loss == 'gain' and not 'stunmode' then
- sets.aftercast_Idle = sets.aftercast_Idle_Sub
- end
- equip(sets.aftercast_Idle)
- end
- function pet_midcast(spell,action)
- end
- function pet_aftercast(spell,action)
- end
- function self_command(command)
- if command == 'stuntarg' then
- stuntarg = target.name
- elseif command == 'stunmode' then
- windower.add_to_chat(100,'Stun Mode')
- if sets.aftercast_Idle ~= sets.precast_Stun then
- stunmode = true
- sets.aftercast_Idle = sets.precast_Stun
- elseif buffactive['Sublimation: Activated'] then
- stunmode = false
- sets.aftercast_Idle = sets.aftercast_Idle_Sub
- else
- stunmode = false
- sets.aftercast_Idle = sets.aftercast_Idle_noSub
- end
- equip(sets.aftercast_Idle)
- end
- 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