Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function get_sets()
- sets.precast = {}
- sets.precast.JA = {}
- -- Precast Sets
- sets.precast.JA.Nightingale = {feet="Bihu Slippers +1"}
- sets.precast.JA.Troubadour = {body="Bihu Justaucorps +1"}
- sets.precast.JA['Soul Voice'] = {legs="Bihu. Cannions +1"}
- sets.precast.FC = {}
- sets.precast.FC.Song = {main="Felibre's Dague",sub=empty,range=empty,ammo="Impatiens",
- head="Aoidos' Calot +2",neck="Orunmila's Torque",ear1={name="Loquac. Earring",order=5},ear2="Enchntr. Earring +1",
- body="Sheikh Manteel",hands={name="Gendewitha Gages",order=8},ring1="Weather. ring",ring2={name="Prolix Ring",order=7},
- back="Swith Cape +1",waist="Witful Belt",legs={name="Gendewitha Spats",order=9},feet={name="Bihu Slippers +1",order=6}}
- sets.precast.FC.Normal = {sub="Vivid Strap",range=empty,ammo="Impatiens",
- head="Nahtirah Hat",neck="Orunmila's Torque",ear1="Loquac. Earring",ear2="Enchntr. Earring +1",
- body="Marduk's Jubbah +1",hands="Gende. Gages",ring1="Weather. Ring",ring2="Prolix Ring",
- back="Swith Cape +1",waist="Witful Belt",legs="Orvail Pants +1",feet="Chelona Boots +1"}
- sets.precast.FC.Utsu = {head="Nahtirah Hat",neck="Orunmila's Torque",ear1="Loquac. Earring",ear2="Enchntr. Earring +1",
- body="Marduk's Jubbah +1",hands="Gende. Gages",ring1="Weather. Ring",ring2="Prolix Ring",
- back="Swith Cape +1",waist="Witful Belt",legs="Orvail Pants +1",feet="Chelona Boots +1"}
- sets.precast.Cure = {sub="Vivid Strap",range=empty,ammo="Impatiens",
- head="Nahtirah Hat",neck="Ormunmila's Torque",ear1="Loquac. Earring",ear2="Enchntr. Earring +1",
- body="Marduk's Jubbah +1",hands="Gende. Gages",ring1="Weather. Ring",ring2="Prolix Ring",
- back="Pahtli Cape",waist="Witful Belt",legs="Nabu's Shalwar",feet="Chelona Boots +1"}
- sets.precast.EnhancingMagic = {waist="Siegel Sash"}
- sets.precast.FC.Lightning = {main="Apamajas I",sub="Vivid Strap"}
- sets.precast.WS = {}
- sets.precast.WS["Mordant Rime"] = {ammo="Ginsen",
- head="Brioso Roundlet +1",neck="Piper's Torque",ear1="Bladeborn Earring",ear2="Enchntr. Earring +1",
- body="Bihu Jstcorps +1",hands="Brioso Cuffs +1",ring1="Mars's Ring",ring2="Carb. Ring +1",
- back="Kumbira Cape",waist="Demonry Sash",legs="Bihu Cannions +1",feet="Battlecast Gaiters"}
- sets.precast.WS["Rudra's Storm"] = {ammo="Ginsen",
- head="Sukeroku Hachi.",neck="Asperity Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
- body="Bihu Jstcorps +1",hands="Umuthi Gloves",ring1="Ramuh Ring",ring2="Ramuh Ring",
- back="Letalis Mantle",waist="Chiner's Belt +1",legs="Bihu Cannions +1",feet="Battlecast Gaiters"}
- sets.precast.WS["Extenterator"] = {ammo="Ginsen",
- head="Sukeroku Hachi.",neck="Aqua Gorget",ear1="Bladeborn Earring",ear2="Steelflash Earring",
- body="Bihu Jstcorps +1",hands="Brioso Cuffs +1",ring1="Mars's Ring",ring2="Ramuh Ring",
- back="Letalis Mantle",waist="Aqua Belt",legs="Gendewitha Spats",feet="Brioso slippers +1"}
- sets.precast.WS["Evisceration"] = {ammo="Ginsen",
- head="Sukeroku Hachi.",neck="Aqua Gorget",ear1="Bladeborn Earring",ear2="Steelflash Earring",
- body="Bihu Jstcorps +1",hands="Umuthi Gloves",ring1="Ramuh Ring",ring2="Ramuh Ring",
- back="Letalis Mantle",waist="Aqua Belt",legs="Gendewitha Spats",feet="Brioso slippers +1"}
- -- Midcast Sets
- sets.midcast = {}
- sets.midcast.Haste = {main="Terra's Staff",sub="Vivid Strap",range="Angel Lyre",ammo=empty,
- head={name="Nahtirah Hat",order=6},neck="Orunmila's Torque",ear1="Loquac. Earring",ear2={name="Andoaa Earring",order=7},
- body={name="Marduk's Jubbah +1",order=5},hands={name="Gendewitha Gages",order=11},ring1="Weather. Ring",ring2={name="Prolix Ring",order=10},
- back={name="Swith Cape +1",order=8},waist="Phasmida Belt",legs="Brioso Cannions +1",feet={name="Chelona Boots +1",order=9}}
- sets.midcast.Debuff = {main="Lehbrailg +2",sub="Mephitis Grip",range="Gjallarhorn",ammo=empty,
- head="Bihu Roundlet +1",neck="Piper's Torque",ear1="Gwati earring",ear2="Enchntr. Earring +1",
- body="Brioso Justaucorps +1",hands="Bihu Cuffs +1",ring1="Carb. Ring +1",ring2="Carb. Ring +1",
- back="Rhapsode's Cape",waist="Demonry Sash",legs="Brioso Cannions +1",feet="Artsieq Boots"}
- sets.midcast.Enfeeble = {main="Lehbrailg +2",sub="Mephitis Grip",ammo=empty,
- head="Bihu Roundlet +1",neck="Piper's Torque",ear1="Gwati earring",ear2="Enchntr. Earring +1",
- body="Brioso Justaucorps +1",hands="Bihu Cuffs +1",ring1="Weather. Ring",ring2="Sangoma ring",
- back="Rhapsode's Cape",waist="Demonry Sash",legs="Brioso Cannions +1",feet="Artsieq Boots"}
- sets.midcast.Buff = {main="Carnwenhan",sub="Genbu's Shield",
- head="Aoidos' Calot +2",neck="Aoidos' Matinee",ear1="Musical Earring",
- body="Aoidos' Hngrln. +2",hands="Ad. Mnchtte. +2",legs="Mdk. Shalwar +1",feet="Brioso slippers +1"}
- sets.midcast.DBuff = {range="Daurdabla",ammo=empty}
- sets.midcast.GBuff = {range="Gjallarhorn",ammo=empty}
- sets.midcast.Duration = {body="Aoidos' Hngrln. +2",neck="Aoidos' Matinee",legs="Mdk. Shalwar +1",feet="Brioso slippers +1"}
- sets.midcast.Ballad = {legs="Aoidos' Rhing. +2"}
- sets.midcast.Scherzo = {feet="Aoidos' Cothrn. +2"}
- sets.midcast.Lullaby = {hands="Brioso Cuffs +1"}
- sets.midcast.Horde = {neck="String Torque",legs="Bihu Cannions +1",}
- sets.midcast.Base = sets.midcast.Haste
- sets.midcast.Cure = {main="Chatoyant Staff",sub="Curatio Grip",range="Angel Lyre",ammo=empty,
- head="Gende. Caubeen +1",neck="Phalaina Locket",ear2="Gwati earring",
- body="Gende. Bilaut +1",hands="Bokwus Gloves",ring1="Haoma's Ring",ring2="Sirona's Ring",
- back="Tempered Cape +1",waist="Pythia Sash",legs="Bihu Cannions +1",feet="Artsieq Boots"}
- sets.midcast.Stoneskin = {head="Brioso Roundlet +1",body="Marduk's Jubbah +1",hands="Marduk's Dastanas +1",
- legs="Shedir Seraweels",feet="Bihu Slippers +1"}
- sets.midcast.Stun = {main="Lehbrailg +2",sub="Mephitis Grip",range="Angel Lyre",ammo=empty,
- head="Brioso Roundlet +1",neck="Orunmila's Torque",ear1="Gwati Earring",ear2="Moonshade Earring",
- body="Vanir Cotehardie",hands="Lurid Mitts",ring1="Weather. Ring",ring2="Sangoma Ring",
- back="Rhapsode's Cape",waist="Witful Belt",legs="Artsieq Hose",feet="Artsieq Boots"}
- --Aftercast Sets
- sets.aftercast = {}
- sets.aftercast.Regen = {main={name="Terra's Staff",order=1},sub={name="Oneiros Grip",order=2},range="Oneiros Harp",ammo=empty,
- neck="Twilight Torque",ear1={name="Loquac. Earring",order=7},ear2={name="Moonshade Earring",order=5},
- body="Respite Cloak",hands={name="Bihu Cuffs +1",order=9},ring1="Dark Ring",ring2={name="Dark Ring",order=8},
- back="Umbra Cape",waist="Flume Belt",legs={name="Assid. Pants +1",order=6},feet="Gende. Galosh. +1"}
- sets.aftercast.PDT = {main="Terra's Staff",sub="Oneiros Grip",range="Oneiros Harp",ammo=empty,
- head="Bihu Roundlet +1",neck="Twilight Torque",ear1="Loquac. Earring",ear2="Moonshade Earring",
- body="Bihu Jstcorps +1",hands="Bihu Cuffs +1",ring1="Dark Ring",ring2="Dark Ring",
- back="Umbra Cape",waist="Flume Belt",legs="Bihu Cannions +1",feet="Bihu Slippers +1"}
- sets.aftercast.Engaged = {main="Carnwenhan",ammo="Ginsen",
- head="Lithelimb Cap",neck="Iqabi Necklace",ear1="Steelflash Earring",ear2="Bladeborn Earring",
- body="Bihu Jstcorps +1",hands="Umuthi Gloves",ring1="Mars's Ring",ring2="Patricius Ring",
- back="Grounded Mantle +1",waist="Anguinus Belt",legs="Bokwus Slops",feet="Battlecast Gaiters"}
- sets.aftercast.Idle = sets.aftercast.Regen
- DaurdSongs = T{"Herb Pastoral","Goblin Gavotte","Shining Fantasia","Goddess's Hymnus","Scop's Operetta","Fowl Aubade","Puppet's Operetta","Gold Capriccio","Warding Round"}
- send_command('input /macro book 1;wait .1;input /macro set 1')
- timer_reg = {}
- pianissimo_cycle = false
- end
- function pretarget(spell)
- if spell.type == 'BardSong' and spell.target.type and spell.target.type == 'PLAYER' and not buffactive.pianissimo and not spell.target.charmed and not pianissimo_cycle then
- cancel_spell()
- pianissimo_cycle = true
- send_command('input /ja "Pianissimo" <me>;wait 1.5;input /ma "'..spell.name..'" '..spell.target.name..';')
- return
- end
- if spell.name ~= 'Pianissimo' then
- pianissimo_cycle = false
- end
- end
- function precast(spell)
- if spell.type == 'BardSong' then
- equip_song_gear(spell)
- equip(sets.precast.FC.Song)
- elseif string.find(spell.english,'Utsu') then
- equip(sets.precast.FC.Utsu)
- elseif spell.action_type == 'Magic' then
- equip(sets.precast.FC.Normal)
- if string.find(spell.english,'Cur') and spell.name ~= 'Cursna' then
- equip(sets.precast.Cure)
- end
- if spell.skill == 'Enhancing Magic' then
- equip(sets.precast.EnhancingMagic)
- end
- elseif spell.type == 'WeaponSkill' then
- if sets.precast.WS[spell.name] then
- equip(sets.precast.WS[spell.name])
- end
- end
- if sets.precast.FC[tostring(spell.element)] then equip(sets.precast.FC[tostring(spell.element)])
- end
- if sets.precast.JA[spell.english] then equip(sets.precast.JA[spell.english])
- end
- end
- function midcast(spell)
- if spell.type == 'BardSong' then
- equip_song_gear(spell)
- elseif spell.skill == 'Enfeebling Magic' then
- equip(sets.midcast.Enfeeble)
- elseif string.find(spell.english,'Cur') then
- equip(sets.midcast.Base,sets.midcast.Cure)
- elseif spell.english=='Stoneskin' then
- equip(sets.midcast.Base,sets.midcast.Stoneskin)
- elseif spell.skill == 'Enhancing Magic' then
- equip(sets.midcast.Haste)
- elseif spell.english=='Stun' then
- equip(sets.midcast.Stun)
- end
- end
- function aftercast(spell)
- if spell.type and spell.type == 'BardSong' and spell.target and spell.target.type:upper() == 'SELF' then
- local t = os.time()
- -- Eliminate songs that have already expired
- local tempreg = {}
- for i,v in pairs(timer_reg) do
- if v < t then tempreg[i] = true end
- end
- for i,v in pairs(tempreg) do
- timer_reg[i] = nil
- end
- local dur = calculate_duration(spell.name)
- if timer_reg[spell.name] then
- if (timer_reg[spell.name] - t) <= 120 then
- send_command('timers delete "'..spell.name..'"')
- timer_reg[spell.name] = t + dur
- send_command('timers create "'..spell.name..'" '..dur..' down')
- end
- else
- local maxsongs = 2
- if player.equipment.range == 'Daurdabla' then
- maxsongs = maxsongs+2
- end
- if buffactive['Clarion Call'] then
- maxsongs = maxsongs+1
- end
- if maxsongs < table.length(timer_reg) then
- maxsongs = table.length(timer_reg)
- end
- if table.length(timer_reg) < maxsongs then
- timer_reg[spell.name] = t+dur
- send_command('timers create "'..spell.name..'" '..dur..' down')
- else
- local rep,repsong
- for i,v in pairs(timer_reg) do
- if t+dur > v then
- if not rep or rep > v then
- rep = v
- repsong = i
- end
- end
- end
- if repsong then
- timer_reg[repsong] = nil
- send_command('timers delete "'..repsong..'"')
- timer_reg[spell.name] = t+dur
- send_command('timers create "'..spell.name..'" '..dur..' down')
- end
- end
- end
- end
- if player.status == 'Engaged' then
- equip(sets.aftercast.Engaged)
- else
- equip(sets.aftercast.Idle)
- end
- end
- function status_change(new,old)
- if new == 'Engaged' then
- equip(sets.aftercast.Engaged)
- elseif T{'Idle','Resting'}:contains(new) then
- equip(sets.aftercast.Idle)
- end
- end
- function equip_song_gear(spell)
- if DaurdSongs:contains(spell.english) then
- equip(sets.midcast.Base,sets.midcast.DBuff)
- else
- if spell.target.type == 'MONSTER' then
- equip(sets.midcast.Base,sets.midcast.Debuff,sets.midcast.GBuff)
- if buffactive.troubadour or buffactive['elemental seal'] then
- equip(sets.midcast.Duration)
- end
- if string.find(spell.english,'Foe Lullaby') then equip (sets.midcast.Lullaby) end
- if string.find(spell.english,'Horde Lullaby') then equip (sets.midcast.Lullaby,sets.midcast.DBuff,sets.midcast.Horde) end
- else
- equip(sets.midcast.Base,sets.midcast.Buff,sets.midcast.GBuff)
- if string.find(spell.english,'Ballad') then equip(sets.midcast.Ballad) end
- if string.find(spell.english,'Scherzo') then equip(sets.midcast.Scherzo) end
- end
- end
- end
- function calculate_duration(name)
- local mult = 1
- if player.equipment.range == "Daurdabla" then mult = mult + 0.3 end
- if player.equipment.range == "Gjallarhorn" then mult = mult + 0.4 end
- if player.equipment.neck == "Aoidos' Matinee" then mult = mult + 0.1 end
- if player.equipment.feet == "Brioso Slippers +1" then mult = mult + 0.11 end
- if player.equipment.body == "Aoidos' Hngrln. +2" then mult = mult + 0.1 end
- if player.equipment.legs == "Mdk. Shalwar +1" then mult = mult + 0.1 end
- if player.equipment.main == "Legato Dagger" then mult = mult + 0.05 end
- if player.equipment.sub == "Legato Dagger" then mult = mult + 0.05 end
- if player.equipment.main == "Carnwenhan" then mult = mult + 0.5 end
- if string.find(name,'March') and player.equipment.hands == "Ad. Mnchtte. +2" then mult = mult + 0.1 end
- if string.find(name,'Minuet') and player.equipment.body == "Aoidos' Hngrln. +2" then mult = mult + 0.1 end
- if string.find(name,'Madrigal') and player.equipment.head == "Aoidos' Calot +2" then mult = mult + 0.1 end
- if string.find(name,'Ballad') and player.equipment.legs == "Aoidos' Rhing. +2" then mult = mult + 0.1 end
- if string.find(name,'Paeon') and player.equipment.head == "Brioso Roundlet +1" then mult = mult + 0.1 end
- if string.find(name,'Scherzo') and player.equipment.feet == "Aoidos' Cothrn. +2" then mult = mult + 0.1 end
- if buffactive.Troubadour then
- mult = mult*2
- end
- if string.find(name,'Scherzo') and buffactive['Soul Voice'] then
- mult = mult*2
- elseif string.find(name,'Scherzo') and buffactive.marcato then
- mult = mult*1.5
- end
- return mult*120
- end
- --[[windower.register_event('zone change',function (...)
- for i,v in pairs(timer_reg) do
- send_command('timers delete "'..i..'"')
- end
- timer_reg = {}
- end)]]
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement