Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function get_sets()
- mote_include_version = 2
- include('Mote-Include.lua')
- include('sammeh_custom_functions.lua')
- end
- function user_setup()
- state.IdleMode:options('Normal','Reraise','DT','MEVA')
- send_command('bind f10 gs c cycle IdleMode')
- send_command('bind f11 gs c berserkmode')
- send_command('bind f12 gs c wslist')
- state.OffenseMode = M{['description']='Engaged Mode', 'Normal','DT'}
- state.BerserkMode = M{['description']='Berserk Mode', 'Normal','Auto'}
- state.WeaponskillMode:options('Normal','ACC')
- select_default_macro_book()
- --send_command('@wait 5;input /lockstyleset 15')
- end
- function init_gear_sets()
- sets.dt = {
- ammo="Staunch Tathlum +1",
- head="Ynglinga Sallet",
- body="Tartarus Platemail",
- hands={ name="Emi. Gauntlets +1", augments={'Accuracy+25','"Dual Wield"+6','Pet: Accuracy+25',}},
- legs="Sulev. Cuisses +2",
- feet="Flam. Gambieras +2",
- neck="Warrior's Beads",
- waist="Ioskeha Belt +1",
- left_ear="Brutal Earring",
- right_ear="Suppanomimi",
- left_ring="Defending Ring",
- right_ring="Niqmaddu Ring",
- back={ name="Cichol's Mantle", augments={'DEX+20','Accuracy+20 Attack+20','Accuracy+10','"Dbl.Atk."+10','Phys. dmg. taken-10%',}}
- }
- sets.engaged = {}
- sets.engaged.Normal = {
- ammo="Ginsen",
- head="Flam. Zucchetto +2",
- body="Dagon Breast.",
- hands="Emi. Gauntlets +1",
- legs="Sulev. Cuisses +2",
- feet="Flam. Gambieras +2",
- neck="Warrior's Beads",
- waist="Ioskeha Belt +1",
- left_ear="Brutal Earring",
- right_ear="Suppanomimi",
- left_ring="Flamma Ring",
- right_ring="Niqmaddu Ring",
- back={ name="Cichol's Mantle", augments={'DEX+20','Accuracy+20 Attack+20','Accuracy+10','"Dbl.Atk."+10','Phys. dmg. taken-10%',}}
- }
- sets.enmity = {}
- sets.engaged.Reraise = set_combine(sets.engaged,{body="Twilight Mail",head="Twilight Helm"})
- sets.engaged.DT = sets.dt
- sets.ws = {
- ammo="Knobkierrie",
- head="Flam. Zucchetto +2",
- body="Dagon Breast.",
- hands="Sulev. Gauntlets +2",
- legs="Sulev. Cuisses +2",
- feet="Flam. Gambieras +2",
- neck="Fotia Gorget",
- waist="Fotia Belt",
- left_ear="Brutal Earring",
- right_ear="Mache Earring +1",
- left_ring="Regal Ring",
- right_ring="Niqmaddu Ring",
- back={ name="Cichol's Mantle", augments={'STR+20','Accuracy+20 Attack+20','STR+10','"Dbl.Atk."+10','Phys. dmg. taken-10%',}},
- }
- sets.ws.vitbased = set_combine(sets.ws,{})
- sets.ws.strbased = set_combine(sets.ws,{})
- sets.ws.magic = {}
- sets.ws.wsd = {}
- sets.ws["King\'s Justice"] = sets.ws.strbased
- sets.ws["Fell Cleve"] = sets.ws.strbased
- sets.ws["Scourge"] = sets.ws.wsd
- sets.ws["Resolution"] = sets.ws.strbased
- --sets.ws["Resolution"] = sets.ws.wsd
- sets.ws["Decimation"] = set_combine(sets.ws,{ammo="Seeth. Bomblet +1",})
- sets.ws["Rampage"] = sets.ws.wsd
- sets.ws["Mistral Axe"] = set_combine(sets.ws.wsd, {})
- sets.ws.savageblade = set_combine(sets.ws.wsd, {})
- sets.ws["Savage Blade"] = set_combine(sets.ws.wsd, {})
- sets.ws["Judgment"] = sets.ws.savageblade
- sets.ws["True Strike"] = sets.ws.wsd
- sets.ws["Black Halo"] = sets.ws.savageblade
- sets.ws["Metatron Torment"] = sets.ws.wsd
- sets.ws["Upheaval"] = sets.ws.vitbased
- sets.ws["Upheaval"].ACC = {}
- sets.ws["Cloudsplitter"] = sets.ws.magic
- sets.ws["Freezebite"] = sets.ws.magic
- sets.ws["Aeolian Edge"] = sets.ws.magic
- sets.ws["Flash Nova"] = sets.ws.magic
- sets.ws["Cataclysm"] = sets.ws.magic
- sets.ws["Earth Crusher"] = sets.ws.magic
- --- PRECAST SETS ---
- sets.precast = {}
- sets.precast.JA = set_combine(sets.enmity, {})
- sets.precast.JA.Berserk = set_combine(sets.precast.JA, {back="Cichol's Mantle",body="Pumm. Lorica +3",feet="Agoge Calligae +3"})
- sets.MaxBerserk = set_combine(sets.precast.JA, {})
- sets.precast.JA.Warcry = set_combine(sets.precast.JA, {head="Agoge mask +3"})
- sets.precast.JA.Aggressor = set_combine(sets.precast.JA, {head="Pummeler's Mask +3",body="Agoge Lorica +3"})
- sets.precast.JA['Mighty Strikes'] = set_combine(sets.precast.JA, {hands="Agoge Mufflers +3"})
- sets.precast.JA['Defender'] = set_combine(sets.precast.JA, {hands="Agoge Mufflers +3"})
- sets.precast.JA['Blood Rage'] = set_combine(sets.precast.JA, {body="Boii Lorica +1"})
- sets.precast.Restraint = set_combine(sets.precast.JA, {hands="Boii Mufflers +1"})
- sets.precast.JA.Tomahawk = set_combine(sets.precast.JA, {ammo="Thr. Tomahawk",feet="Agoge Calligae +3"})
- sets.precast.Ranged = {ammo="Dart"}
- sets.CurePotencyRecv = {}
- sets.precast.WS = sets.ws
- sets.precast.FastCast = {
- ammo="Impatiens",
- head="Ynglinga Sallet",
- body="Tartarus Platemail",
- hands={ name="Leyline Gloves", augments={'Accuracy+15','Mag. Acc.+15','"Mag.Atk.Bns."+15','"Fast Cast"+3',}},
- legs="Arjuna Breeches",
- feet={ name="Amm Greaves", augments={'HP+50','VIT+10','Accuracy+15','Damage taken-2%',}},
- neck="Baetyl Pendant",
- waist="Ioskeha Belt +1",
- left_ear="Etiolation Earring",
- right_ear="Loquac. Earring",
- left_ring="Prolix Ring",
- right_ring="Lebeche Ring",
- back={ name="Cichol's Mantle", augments={'AGI+20','Eva.+20 /Mag. Eva.+20','"Fast Cast"+10','Phys. dmg. taken-10%',}},
- }
- sets.midcast = set_combine(sets.precast.FastCast,{})
- --- AFTERCAST SETS ---
- sets.Idle = {
- ammo="Staunch Tathlum +1",
- head={ name="Valorous Mask", augments={'Pet: Accuracy+28 Pet: Rng. Acc.+28','Pet: Haste+1','Pet: Attack+14 Pet: Rng.Atk.+14',}},
- body="Tartarus Platemail",
- hands="Sulev. Gauntlets +2",
- legs="Sulev. Cuisses +2",
- feet="Hermes' Sandals",
- neck="Sanctity Necklace",
- waist="Flume Belt",
- left_ear="Dawn Earring",
- right_ear="Infused Earring",
- left_ring="Defending Ring",
- right_ring="Patricius Ring",
- back={ name="Cichol's Mantle", augments={'AGI+20','Eva.+20 /Mag. Eva.+20','"Fast Cast"+10','Phys. dmg. taken-10%',}}
- }
- sets.Idle.Current = sets.Idle
- sets.Resting = sets.Idle
- sets.WakeSleep = {neck="Vim Torque"}
- sets.ProtectBuff = {}
- end
- function job_pretarget(spell)
- checkblocking(spell)
- end
- function job_precast(spell)
- handle_equipping_gear(player.status)
- if spell.name == 'Utsusemi: Ichi' and (buffactive['Copy Image (3)'] or buffactive ['Copy Image (4+)']) then
- cancel_spell()
- send_command('@wait 1;')
- equip(sets.Idle.Current)
- return
- end
- if sets.precast.JA[spell.name] then
- equip(sets.precast.JA[spell.name])
- elseif string.find(spell.name,'Cur') and spell.name ~= 'Cursna' then
- equip(sets.precast.Cure)
- elseif spell.skill == 'EnhancingMagic' then
- equip(sets.precast.EnhancingMagic)
- elseif spell.action_type == 'Magic' then
- equip(sets.precast.FastCast)
- end
- if spell.name == 'Ranged' then
- equip(sets.precast.Ranged)
- end
- end
- function job_post_precast(spell)
- if player.tp < 2250 and spell.type == 'WeaponSkill' and player.equipment.main == "Chango" then
- equip({left_ear="Moonshade Earring"})
- windower.add_to_chat(10,"Adding in Moonshade Earring for more TP:"..player.tp)
- elseif player.tp < 2750 and spell.type == 'WeaponSkill' then
- windower.add_to_chat(10,"Adding in Moonshade Earring for more TP:"..player.tp)
- equip({})
- end
- if (world.time >= (17*60) or world.time < (7*60)) and spell.type == 'WeaponSkill' then
- equip({right_ear="Lugra Earring +1"})
- end
- end
- function job_midcast(spell)
- if spell.name == 'Ranged' then
- equip(sets.precast.Ranged)
- end
- if spell.action_type == 'Magic' then
- equip(sets.dtenmity)
- end
- if spell.name:contains('Utsusemi') then
- equip(sets.precast.FastCast)
- end
- end
- function job_post_midcast(spell)
- if spell.name == 'Utsusemi: Ichi' then
- send_command('cancel Copy Image|Copy Image (2)')
- end
- if spell.type == "WeaponSkill" then
- tpspent = spell.tp_cost
- end
- end
- function job_aftercast(spell)
- if state.SpellDebug.value == "On" then
- spelldebug(spell)
- end
- handle_equipping_gear(player.status)
- equip(sets.Idle.Current)
- end
- function job_post_aftercast(spell)
- if spell.type == "WeaponSkill" and state.BerserkMode.value == "Auto" and windower.ffxi.get_ability_recasts()[1] == 0 then
- currentMain = player.equipment.main
- currentSub = player.equipment.sub
- windower.add_to_chat("Current Equipment: "..currentMain.." "..currentSub)
- equip(sets.MaxBerserk)
- send_command("@wait 2.5;input /ja Berserk <me>")
- end
- if spell.name == "Berserk" and state.BerserkMode.value == "Auto" and currentMain and currentSub then
- equip({main=currentMain,sub=currentSub})
- end
- end
- function status_change(new,tab)
- handle_equipping_gear(player.status)
- if new == 'Resting' then
- equip(sets.Resting)
- else
- equip(sets.Idle.Current)
- end
- end
- function job_buff_change(status,gain_or_loss)
- job_handle_equipping_gear(player.status)
- if (gain_or_loss) then
- add_to_chat(4,'------- Gained Buff: '..status..'-------')
- if status == "sleep" then
- equip(sets.WakeSleep)
- end
- if status == "KO" then
- send_command('input /party These tears... they sting-wing....')
- end
- else
- add_to_chat(3,'------- Lost Buff: '..status..'-------')
- end
- end
- function job_self_command(command)
- if command[1]:lower() == "ws" and command[2] ~= nil then
- local EquipedGear = windower.ffxi.get_items()
- local CurrentSkill
- if EquipedGear.equipment.main == nil or EquipedGear.equipment.main == 0 then
- CurrentSkill = "Hand-to-Hand"
- else
- CurrentSkill = res.skills[res.items[windower.ffxi.get_items(EquipedGear.equipment.main_bag, EquipedGear.equipment.main).id].skill].en
- end
- send_command('input /ws '..WeaponSkill[CurrentSkill][command[2]])
- end
- if command[1]:lower() == "wslist" then
- local EquipedGear = windower.ffxi.get_items()
- local CurrentSkill
- if EquipedGear.equipment.main == nil or EquipedGear.equipment.main == 0 then
- CurrentSkill = "Hand-to-Hand"
- else
- CurrentSkill = res.skills[res.items[windower.ffxi.get_items(EquipedGear.equipment.main_bag, EquipedGear.equipment.main).id].skill].en
- end
- windower.add_to_chat(2,"WS List:")
- for i,v in pairs(WeaponSkill[CurrentSkill]) do
- windower.add_to_chat(2,i..") "..v)
- end
- end
- if command[1]:lower() == "berserkmode" then
- currentMain = player.equipment.main
- currentSub = player.equipment.sub
- send_command('gs c cycle BerserkMode')
- end
- end
- function job_state_change(stateField, newValue, oldValue)
- job_handle_equipping_gear(player.status)
- equip(sets.Idle.Current)
- end
- function job_handle_equipping_gear(playerStatus, eventArgs)
- disable_specialgear()
- if buffactive.sleep then
- equip(sets.WakeSleep)
- end
- if playerStatus == 'Idle' then
- equip(sets.Idle.Current)
- end
- if state.IdleMode.value == "Reraise" then
- sets.Idle.Current = set_combine(sets.Idle,{body="Twilight Mail",head="Twilight Helm"})
- elseif state.IdleMode.value == "MEVA" or state.OffenseMode.value == "MEVA" then
- sets.Idle.Current = sets.meva
- elseif state.IdleMode.value == "DT" or state.OffenseMode.value == "DT" then
- if buffactive['Aftermath'] then
- sets.Idle.Current = sets.dtaftermath
- sets.engaged.DT = sets.dtaftermath
- else
- sets.Idle.Current = sets.dt
- sets.engaged.DT = sets.dt
- end
- else
- sets.Idle.Current = sets.Idle
- end
- end
- function select_default_macro_book()
- set_macro_page(9, 1)
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement