SHARE
TWEET

Error Error Terror

a guest Jun 21st, 2018 83 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. function get_sets()
  2. mote_include_version = 2
  3. include('Mote-Include.lua')
  4. include('organizer-lib')
  5. end
  6.  
  7. function job_setup()
  8.     state.OffenseMode:options('None','Locked','HighMP')
  9.     state.CastingMode:options('Normal','Macc','Occult','MBurst','HighMP')
  10.     state.IdleMode:options('Normal','PDT','HighMP')
  11.     state.DefenseMode:options('PDT','MDB')
  12.     MagicBurstIndex = 0
  13.     state.Magic_Burst = M(false, 'Magic_Burst')
  14.     state.AF_Body = M(false, 'AF_Body')
  15.     state.Occult_Acumen = M(false, 'Occult_Acumen')
  16.     send_command('bind ^` gs c toggle Magic_Burst')
  17.     send_command('bind !` gs c toggle AF_Body')
  18.     send_command('bind ^= gs c toggle Occult_Acumen')
  19.     select_default_macro_book()
  20. end
  21.  
  22. function user_unload()
  23.     send_command('unbind ^`')
  24.     send_command('unbind @`')
  25.     send_command('unbind !`')
  26. end
  27.  
  28. function init_gear_sets()
  29.     --- I use specific rules for the different staves that I anticipate using.  I need to acquire a Raetic Staff +1! ---
  30.     sets.precast.JA['Mana Wall'] = {back="Taranus's cape",feet="Wicce Sabots +1"}
  31.     sets.precast.JA['Manafont'] = {body="Arch. Coat +1"}
  32.     sets.precast.FC = {
  33.         ammo="Sapience Orb",
  34.         head={ name="Merlinic Hood", augments={'Mag. Acc.+17 "Mag.Atk.Bns."+17','"Fast Cast"+7','"Mag.Atk.Bns."+13',}},
  35.         body="Zendik Robe",
  36.         hands={ name="Merlinic Dastanas", augments={'Mag. Acc.+23','"Fast Cast"+7','INT+2',}},
  37.         legs={ name="Psycloth Lappas", augments={'MP+80','Mag. Acc.+15','"Fast Cast"+7',}},
  38.         feet={ name="Merlinic Crackows", augments={'"Fast Cast"+7','Mag. Acc.+13','"Mag.Atk.Bns."+12',}},
  39.         neck="Orunmila's Torque",
  40.         waist="Witful Belt",
  41.         left_ear="Etiolation Earring",
  42.         right_ear="Loquac. Earring",
  43.         right_ring="Kishar Ring",
  44.         left_ring="Rahab Ring",
  45.         back={ name="Taranus's Cape", augments={'MP+60','Mag. Acc+20 /Mag. Dmg.+20','MP+20','"Fast Cast"+10',}},
  46.     }
  47.     sets.precast.HighMP = {
  48.         ammo="Strobilus",
  49.         head={ name="Amalric Coif +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
  50.         body={ name="Weather. Robe +1", augments={'MP+120',}},
  51.         hands={ name="Otomi Gloves", augments={'HP+30','MP+30','MP+30',}},
  52.         legs={ name="Amalric Slops +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
  53.         feet={ name="Amalric Nails +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
  54.         neck="Dualism Collar +1",
  55.         waist="Shinjutsu-no-Obi +1",
  56.         left_ear="Etiolation Earring",
  57.         right_ear="Evans Earring",
  58.         left_ring="Mephitas's Ring",
  59.         right_ring="Mephitas's Ring +1",
  60.         back={ name="Bane Cape", augments={'Elem. magic skill +10','Dark magic skill +7','"Mag.Atk.Bns."+4',}},
  61.     }  
  62.     sets.precast.FC['Impact'] = set_combine(sets.precast.FC, {head=empty,body="Twilight Cloak"})
  63.     sets.precast.FC['Enhancing Magic'] = set_combine(sets.precast.FC, {head="Amalric Coif +1", right_ring="Mephitas's Ring +1", waist="Siegel Sash"})
  64.     sets.precast.FC['Elemental Magic'] = set_combine(sets.precast.FC, {
  65.         ammo="Strobilus",
  66.         head={ name="Amalric Coif +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
  67.         body={ name="Dalmatica +1", augments={'Occ. quickens spellcasting +3%','"Fast Cast"+6','Pet: "Mag.Def.Bns."+6',}},
  68.         hands={ name="Merlinic Dastanas", augments={'Mag. Acc.+23','"Fast Cast"+7','INT+2',}},
  69.         legs={ name="Amalric Slops +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
  70.         feet={ name="Amalric Nails +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
  71.         neck="Orunmila's Torque",
  72.         waist="Witful Belt",
  73.         left_ear="Etiolation Earring",
  74.         right_ear="Loquac. Earring",
  75.         left_ring="Mephitas's Ring",
  76.         right_ring="Mephitas's Ring +1",
  77.         back="Perimede Cape",
  78.     })
  79.     sets.precast.FC['Death'] = {
  80.         ammo="Staunch Tathlum +1", --Max MP in Death Set Supercedes Max Mp in FC set
  81.         head={ name="Amalric Coif +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
  82.         body={ name="Weather. Robe +1", augments={'MP+120',}},
  83.         hands={ name="Merlinic Dastanas", augments={'Mag. Acc.+23','"Fast Cast"+7','INT+2',}},
  84.         legs={ name="Amalric Slops +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
  85.         feet={ name="Amalric Nails +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
  86.         neck="Orunmila's Torque",
  87.         waist="Shinjutsu-no-Obi +1",
  88.         left_ear="Etiolation Earring",
  89.         right_ear="Loquac. Earring",
  90.         left_ring="Mephitas's Ring",
  91.         right_ring="Mephitas's Ring +1",
  92.         back={ name="Taranus's Cape", augments={'MP+60','Mag. Acc+20 /Mag. Dmg.+20','MP+20','"Fast Cast"+10',}},
  93.     }
  94.     sets.precast.FC.Laevateinn = set_combine(sets.precast.FC, {
  95.         ammo="Sapience Orb",
  96.         head={ name="Merlinic Hood", augments={'Mag. Acc.+17 "Mag.Atk.Bns."+17','"Fast Cast"+7','"Mag.Atk.Bns."+13',}},
  97.         body="Zendik Robe",
  98.         hands={ name="Merlinic Dastanas", augments={'Mag. Acc.+23','"Fast Cast"+7','INT+2',}},
  99.         legs={ name="Psycloth Lappas", augments={'MP+80','Mag. Acc.+15','"Fast Cast"+7',}},
  100.         feet={ name="Merlinic Crackows", augments={'"Fast Cast"+7','Mag. Acc.+13','"Mag.Atk.Bns."+12',}},
  101.         neck="Orunmila's Torque",
  102.         waist="Witful Belt",
  103.         left_ear="Etiolation Earring",
  104.         right_ear="Loquac. Earring",
  105.         right_ring="Kishar Ring",
  106.         left_ring="Rahab Ring",
  107.         back={ name="Taranus's Cape", augments={'MP+60','Mag. Acc+20 /Mag. Dmg.+20','MP+20','"Fast Cast"+10',}},
  108.     })
  109.     sets.precast.FC.Khatvanga = set_combine(sets.precast.FC.Laevateinn, {
  110.     })
  111.     sets.precast.FC.Lathi = set_combine(sets.precast.FC.Laevateinn, {
  112.     })
  113.     sets.precast.FC.Claustrum = set_combine(sets.precast.FC.Laevateinn, {
  114.     })
  115.     sets.precast.FC.Hvergelmir = {
  116.         ammo="Strobilus",
  117.         head={ name="Amalric Coif +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
  118.         body={ name="Weather. Robe +1", augments={'MP+120',}},
  119.         hands={ name="Otomi Gloves", augments={'HP+30','MP+30','MP+30',}},
  120.         legs={ name="Amalric Slops +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
  121.         feet={ name="Amalric Nails +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
  122.         neck="Dualism Collar +1",
  123.         waist="Witful Belt",
  124.         left_ear="Etiolation Earring",
  125.         right_ear="Evans Earring",
  126.         left_ring="Lebeche Ring",
  127.         right_ring="Mephitas's Ring +1",
  128.         back="Perimede Cape",
  129.     }
  130.     sets.precast.FC['Enhancing Magic'].Hvergelmir = set_combine(sets.precast.FC.Hvergelmir, {
  131.         left_ring="Rahab Ring",
  132.         waist="Siegel Sash",
  133.         back="Bane Cape"
  134.     })
  135.     sets.precast.FC['Elemental Magic'].Hvergelmir = set_combine(sets.precast.FC.Hvergelmir, {
  136.         ammo="Strobilus",
  137.         head={ name="Amalric Coif +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
  138.         body={ name="Weather. Robe +1", augments={'MP+120',}},
  139.         hands={ name="Otomi Gloves", augments={'HP+30','MP+30','MP+30',}},
  140.         legs={ name="Amalric Slops +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
  141.         feet={ name="Amalric Nails +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
  142.         neck="Dualism Collar +1",
  143.         waist="Witful Belt",
  144.         left_ear="Etiolation Earring",
  145.         right_ear="Evans Earring",
  146.         left_ring="Lebeche Ring",
  147.         right_ring="Mephitas's Ring +1",
  148.         back="Perimede Cape",
  149.     })
  150.     sets.precast.FC['Death'].Hvergelmir = set_combine(sets.precast.FC.HighMP, {})
  151.     sets.precast.WS = {
  152.         ammo="Amar Cluster",
  153.         head="Jhakri Coronal +2",
  154.         body="Jhakri Robe +2",
  155.         hands="Jhakri Cuffs +2",
  156.         legs="Jhakri Slops +2",
  157.         feet="Jhakri Pigaches +2",
  158.         neck="Fotia Gorget",
  159.         waist="Fotia Belt",
  160.         left_ear="Moonshade Earring",
  161.         right_ear="Mache Earring +1",
  162.         left_ring="Ramuh Ring +1",
  163.         right_ring="Chirich Ring +1",
  164.         back={ name="Taranus's Cape", augments={'DEX+20','Accuracy+20 Attack+20','DEX+10','Haste+10',}},
  165.     }  
  166.     sets.precast.WSElemental = {
  167.         ammo="Pemphredo Tathlum",
  168.         head={ name="Merlinic Hood", augments={'Mag. Acc.+23 "Mag.Atk.Bns."+23','"Conserve MP"+4','INT+14','Mag. Acc.+15','"Mag.Atk.Bns."+12',}},
  169.         body={ name="Amalric Doublet +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
  170.         hands="Jhakri Cuffs +2",
  171.         legs={ name="Amalric Slops +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
  172.         feet={ name="Amalric Nails +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
  173.         neck="Fotia Gorget",
  174.         waist="Fotia Belt",
  175.         left_ear="Moonshade Earring",
  176.         right_ear="Regal Earring",
  177.         left_ring="Shiva Ring +1",
  178.         right_ring="Shiva Ring +1",
  179.         back={ name="Taranus's Cape", augments={'INT+20','Mag. Acc+20 /Mag. Dmg.+20','INT+10','Weapon skill damage +10%',}},
  180.     }
  181.     sets.precast.WS['Rock Crusher'] = set_combine(sets.precast.WSElemental,{})
  182.     sets.precast.WS['Earth Crusher'] = set_combine(sets.precast.WSElemental,{})
  183.     sets.precast.WS['Starburst'] = set_combine(sets.precast.WSElemental,{})
  184.     sets.precast.WS['Sunburst'] = set_combine(sets.precast.WSElemental,{})
  185.     sets.precast.WS['Cataclysm'] = set_combine(sets.precast.WSElemental,{head="Pixie Hairpin +1", left_ring="Archon Ring"})
  186.     sets.precast.WS['Vidohunir'] = set_combine(sets.precast.WSElemental,{
  187.         head="Pixie Hairpin +1",
  188.         neck="Saevus Pendant +1",
  189.         left_ear="Barkaro. Earring",
  190.         left_ring="Archon Ring",
  191.         waist="Eschan Stone",
  192.     })
  193.     sets.precast.WS['Myrkr'] = set_combine(sets.precast.FC.HighMP,{})
  194.     sets.precast.WS['Spirit Taker'] = set_combine(sets.precast.WS, {
  195.         back={ name="Taranus's Cape", augments={'INT+20','Mag. Acc+20 /Mag. Dmg.+20','INT+10','Weapon skill damage +10%',}},
  196.     }) 
  197.     sets.precast.WS['Gate of Tartarus'] = set_combine(sets.precast.WS, {
  198.         neck="Combatant's Torque",
  199.         left_ear="Mache Earring +1",
  200.         waist="Eschan Stone",
  201.     })
  202.     sets.precast.WS['Shell Crusher'] = set_combine(sets.precast.WS, {
  203.         neck="Combatant's Torque",
  204.         left_ear="Mache Earring +1",
  205.         waist="Eschan Stone",
  206.     })
  207.     sets.midcast.FastRecast = {}
  208.     sets.midcast['Healing Magic'] = {
  209.         ammo="Staunch Tathlum +1",
  210.         head={ name="Vanya Hood", augments={'Healing magic skill +20','"Cure" spellcasting time -7%','Magic dmg. taken -3',}},
  211.         body={ name="Vanya Robe", augments={'Healing magic skill +20','"Cure" spellcasting time -7%','Magic dmg. taken -3',}},
  212.         hands="Reveal. Mitts +1",
  213.         legs={ name="Vanya Slops", augments={'Healing magic skill +20','"Cure" spellcasting time -7%','Magic dmg. taken -3',}},
  214.         feet={ name="Vanya Clogs", augments={'Healing magic skill +20','"Cure" spellcasting time -7%','Magic dmg. taken -3',}},
  215.         neck="Nodens Gorget",
  216.         waist="Gishdubar Sash",
  217.         left_ear="Roundel Earring",
  218.         right_ear="Mendi. Earring",
  219.         left_ring="Stikini Ring +1",
  220.         right_ring="Jann. Ring +1",
  221.         back="Tempered Cape +1",
  222.     }
  223.     sets.midcast['Enhancing Magic'] = set_combine(sets.precast.FC.HighMP,{
  224.         head={ name="Telchine Cap", augments={'Accuracy+14 Attack+14','"Store TP"+6','Enh. Mag. eff. dur. +10',}},
  225.         body={ name="Telchine Chas.", augments={'DEF+16','Enh. Mag. eff. dur. +10',}},
  226.         hands={ name="Telchine Gloves", augments={'Enh. Mag. eff. dur. +10',}},
  227.         legs={ name="Telchine Braconi", augments={'Enh. Mag. eff. dur. +10',}},
  228.         feet={ name="Telchine Pigaches", augments={'Enh. Mag. eff. dur. +10',}},
  229.         right_ear="Andoaa Earring",
  230.         back="Moonlight Cape",
  231.     })
  232.     sets.midcast['Phalanx'] = set_combine(sets.midcast['Enhancing Magic'],{
  233.         hands={ name="Merlinic Dastanas", augments={'"Cure" potency +2%','Pet: "Dbl.Atk."+1 Pet: Crit.hit rate +1','Phalanx +5','Mag. Acc.+17 "Mag.Atk.Bns."+17',}},
  234.         feet={ name="Merlinic Crackows", augments={'Pet: "Mag.Atk.Bns."+24','Enmity-4','Phalanx +3','Accuracy+14 Attack+14',}},
  235.         neck="Incanter's Torque",
  236.         waist="Olympus Sash",
  237.         left_ear="Augment. Earring",
  238.         back="Perimede Cape",
  239.     })
  240.     sets.midcast['Stoneskin'] = set_combine(sets.midcast['Enhancing Magic'],{        
  241.         neck="Nodens Gorget",
  242.         legs="Shedir Seraweels",
  243.         lear="Earthcry Earring",
  244.         waist="Siegel Sash",
  245.     })
  246.     sets.midcast['Aquaveil'] = set_combine(sets.midcast['Enhancing Magic'],{
  247.         head="Amalric Coif +1",
  248.         waist="Emphatikos Rope",
  249.         legs="Shedir Seraweels",
  250.     })
  251.     sets.midcast['Refresh'] = set_combine(sets.midcast['Enhancing Magic'],{
  252.         head="Amalric Coif +1",
  253.         back="Grapevine Cape",
  254.         waist="Gishdubar Sash",
  255.         feet="Inspirited Boots",
  256.     })
  257.     sets.midcast['Enfeebling Magic'] = {
  258.         ammo="Pemphredo Tathlum",
  259.         head="Spae. Petasos +3",
  260.         body="Spaekona's Coat +3",
  261.         hands="Spae. Gloves +3",
  262.         legs="Spae. Tonban +3",
  263.         feet="Spae. Sabots +3",
  264.         neck="Erra Pendant",
  265.         waist="Porous Rope",
  266.         left_ear="Digni. Earring",
  267.         right_ear="Regal Earring",
  268.         left_ring="Stikini Ring +1",
  269.         right_ring="Stikini Ring +1",
  270.         back={ name="Taranus's Cape", augments={'MP+60','Mag. Acc+20 /Mag. Dmg.+20','MP+20','"Fast Cast"+10',}},
  271.     }
  272.     sets.midcast['Poison'] = set_combine(sets.midcast['Enfeebling Magic'],{
  273.         ammo="Pemphredo Tathlum",
  274.         head="Befouled Crown",
  275.         body="Spaekona's Coat +3",
  276.         hands="Spae. Gloves +3",
  277.         legs={ name="Psycloth Lappas", augments={'MP+80','Mag. Acc.+15','"Fast Cast"+7',}},
  278.         feet="Skaoi Boots",
  279.         neck="Incanter's Torque",
  280.         waist="Rumination Sash",
  281.         left_ear="Enfeebling Earring",
  282.         right_ear="Regal Earring",
  283.         left_ring="Stikini Ring +1",
  284.         right_ring="Stikini Ring +1",
  285.         back={ name="Taranus's Cape", augments={'MP+60','Mag. Acc+20 /Mag. Dmg.+20','MP+20','"Fast Cast"+10',}},
  286.     })
  287.     sets.midcast['Poison II'] = sets.midcast['Poison']
  288.     sets.midcast['Slow'] = set_combine(sets.midcast['Enfeebling Magic'],{ammo="Hydrocera", waist="Luminary Sash",})
  289.     sets.midcast['Paralyze'] = set_combine(sets.midcast['Slow'],{})
  290.     sets.midcast['Silence'] = set_combine(sets.midcast['Slow'],{})
  291.     sets.midcast['Distract'] = set_combine(sets.midcast['Slow'],{})
  292.     sets.midcast['Frazzle'] = set_combine(sets.midcast['Slow'],{})
  293.     sets.midcast.ElementalEnfeeble = set_combine(sets.midcast['Enfeebling Magic'],{feet="Archmage's Sabots +3",})
  294.  
  295.     sets.midcast['Dark Magic'] = {
  296.         ammo="Strobilus",
  297.         head="Pixie Hairpin +1",
  298.         body={ name="Helios Jacket", augments={'Mag. Acc.+22','"Drain" and "Aspir" potency +10','MP+21',}},
  299.         hands={ name="Helios Gloves", augments={'Mag. Acc.+20 "Mag.Atk.Bns."+20','"Drain" and "Aspir" potency +10','MP+35',}},
  300.         legs="Spae. Tonban +3",
  301.         feet={ name="Merlinic Crackows", augments={'Mag. Acc.+27','"Drain" and "Aspir" potency +11','INT+4','"Mag.Atk.Bns."+3',}},
  302.         neck="Erra Pendant",
  303.         waist="Fucho-no-Obi",
  304.         left_ear="Etiolation Earring",
  305.         right_ear="Hirudinea Earring",
  306.         right_ring="Evanescence Ring",
  307.         left_ring="Excelsis Ring",
  308.         back={ name="Taranus's Cape", augments={'MP+60','Mag. Acc+20 /Mag. Dmg.+20','MP+20','"Fast Cast"+10',}},
  309.     }
  310.     sets.midcast['Dark Magic'].Macc = set_combine(sets.midcast['Dark Magic'],{
  311.         ammo="Pemphredo Tathlum",
  312.         head="Spae. Petasos +3",
  313.         hands={ name="Arch. Gloves +3", augments={'Reduces Ancient Magic II casting time',}},
  314.         left_ear="Barkaro. Earring",
  315.         right_ear="Regal Earring",
  316.         left_ring="Archon Ring",
  317.     })
  318.     sets.midcast['Dark Magic'].HighMP = set_combine(sets.midcast['Dark Magic'],{
  319.         head="Amalric Coif +1",
  320.         right_ear="Regal Earring",
  321.         left_ring="Mephitas's Ring",
  322.     })    
  323.     sets.midcast['Elemental Magic'] = {
  324.         ammo="Pemphredo Tathlum",
  325.         head={ name="Merlinic Hood", augments={'Mag. Acc.+23 "Mag.Atk.Bns."+23','"Conserve MP"+4','INT+14','Mag. Acc.+15','"Mag.Atk.Bns."+12',}},
  326.         body={ name="Amalric Doublet +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
  327.         hands={ name="Amalric Gages +1", augments={'INT+12','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
  328.         legs={ name="Amalric Slops +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
  329.         feet={ name="Amalric Nails +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
  330.         neck="Saevus Pendant +1",
  331.         waist="Eschan Stone",
  332.         left_ear="Barkaro. Earring",
  333.         right_ear="Regal Earring",
  334.         left_ring="Shiva Ring +1",
  335.         right_ring="Shiva Ring +1",
  336.         back={ name="Taranus's Cape", augments={'INT+20','Mag. Acc+20 /Mag. Dmg.+20','INT+10','"Mag.Atk.Bns."+10',}},
  337.     }
  338.     sets.midcast['Elemental Magic'].Macc = set_combine(sets.midcast['Elemental Magic'], {
  339.         hands={ name="Arch. Gloves +3", augments={'Reduces Ancient Magic II casting time',}},
  340.         feet={ name="Arch. Sabots +3", augments={'Reduces Ancient Magic II MP cost',}},
  341.     })
  342.     sets.midcast['Elemental Magic'].Occult = set_combine(sets.midcast['Elemental Magic'], {
  343.         -- These are for low cost spells.  Don't try to get TP from Occult on these! --
  344.     })
  345.     sets.midcast['Elemental Magic'].MBurst = set_combine(sets.midcast['Elemental Magic'], {
  346.         head="Ea Hat +1",
  347.         body="Ea Houppe. +1",
  348.         legs="Ea Slops +1",
  349.         neck="Mizu. Kubikazari",
  350.         left_ring="Mujin Band",
  351.     })
  352.     sets.midcast['Elemental Magic'].HighMP = set_combine(sets.midcast['Elemental Magic'], {
  353.         ammo="Strobilus",
  354.         head="Amalric Coif +1",
  355.         left_ring="Mephitas's Ring",
  356.         right_ring="Mephitas's Ring +1",
  357.         waist="Shinjutsu-no-Obi +1",
  358.     }) 
  359.     sets.midcast['Elemental Magic'].HighTierNuke = set_combine(sets.midcast['Elemental Magic'], {})
  360.     sets.midcast['Elemental Magic'].HighTierNuke.Macc = set_combine(sets.midcast['Elemental Magic'].HighTierNuke, {
  361.         hands="Arch. Gloves +3",
  362.         feet="Arch. Sabots +3",
  363.     })     
  364.     sets.midcast['Elemental Magic'].HighTierNuke.Occult = set_combine(sets.midcast['Elemental Magic'].HighTierNuke, {
  365.         ammo="Seraphic Ampulla",
  366.         head="Mallquis Chapeau +1",
  367.         legs="Perdition Slops",
  368.         neck="Lissome Necklace",
  369.         waist="Oneiros Rope",
  370.         left_ear="Telos Earring",
  371.         right_ear="Dedition Earring",
  372.         left_ring="Petrov Ring",
  373.         right_ring="Chirich Ring +1",
  374.     })
  375.     sets.midcast['Elemental Magic'].HighTierNuke.MBurst = set_combine(sets.midcast['Elemental Magic'].HighTierNuke, {
  376.         head="Ea Hat +1",
  377.         body="Ea Houppe. +1",
  378.         legs="Ea Slops +1",
  379.         neck="Mizu. Kubikazari",
  380.         left_ring="Mujin Band",
  381.     })
  382.     sets.midcast['Elemental Magic'].HighTierNuke.HighMP = set_combine(sets.midcast['Elemental Magic'].HighMP, {
  383.         body="Spaekona's Coat +3",
  384.     }) 
  385.     sets.midcast['Death'] = {
  386.         ammo="Strobilus",
  387.         head="Pixie Hairpin +1",
  388.         body={ name="Amalric Doublet +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
  389.         hands={ name="Amalric Gages +1", augments={'INT+12','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
  390.         legs={ name="Amalric Slops +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
  391.         feet={ name="Amalric Nails +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
  392.         neck="Dualism Collar +1",
  393.         waist="Shinjutsu-no-Obi +1",
  394.         left_ear="Etiolation Earring",
  395.         right_ear="Evans Earring",
  396.         left_ring="Archon Ring",
  397.         right_ring="Mephitas's Ring +1",
  398.         back={ name="Taranus's Cape", augments={'INT+20','Mag. Acc+20 /Mag. Dmg.+20','INT+10','"Mag.Atk.Bns."+10',}},
  399.     }
  400.     sets.midcast['Death'].Macc = set_combine(sets.midcast.Death, {
  401.         neck="Sanctity Necklace",
  402.         right_ear="Regal Earring",
  403.         left_ear="Barkarole Earring",  
  404.         hands="Spaekona's Gloves +3",
  405.         waist="Porous Rope",
  406.     })
  407.     sets.midcast['Death'].Occult = set_combine(sets.midcast.Death, {
  408.         ammo="Seraphic Ampulla",
  409.         head="Mallquis Chapeau +1",
  410.         legs="Perdition Slops",
  411.         neck="Lissome Necklace",
  412.         waist="Oneiros Rope",
  413.         left_ear="Telos Earring",
  414.         right_ear="Dedition Earring",
  415.         left_ring="Petrov Ring",
  416.         right_ring="Chirich Ring +1",          
  417.     })
  418.     sets.midcast['Death'].MBurst = {
  419.         ammo="Strobilus",
  420.         head="Pixie Hairpin +1",
  421.         body={ name="Amalric Doublet +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
  422.         hands={ name="Amalric Gages +1", augments={'INT+12','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
  423.         legs={ name="Amalric Slops +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
  424.         feet={ name="Amalric Nails +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
  425.         neck="Mizu. Kubikazari",
  426.         waist="Shinjutsu-no-Obi +1",
  427.         left_ear="Barkaro. Earring",
  428.         right_ear="Static Earring",
  429.         left_ring="Archon Ring",
  430.         right_ring="Mephitas's Ring +1",
  431.         back={ name="Taranus's Cape", augments={'INT+20','Mag. Acc+20 /Mag. Dmg.+20','INT+10','"Mag.Atk.Bns."+10',}},
  432.     }
  433.     sets.midcast['Impact'] = set_combine(sets.midcast['Elemental Magic'].HighTierNuke.Occult,{
  434.         head=empty,
  435.         body="Twilight Cloak",
  436.     })
  437.     sets.midcast['Impact'].Macc = set_combine(sets.midcast['Elemental Magic'].HighTierNuke.Macc,{
  438.         head=empty,
  439.         body="Twilight Cloak",
  440.         right_ring="Archon Ring",
  441.     })
  442.     sets.midcast['Impact'].MBurst = set_combine(sets.midcast['Elemental Magic'].HighTierNuke.MBurst,{
  443.         head=empty,
  444.         body="Twilight Cloak",
  445.         hands="Arch. Gloves +3",
  446.         right_ring="Archon Ring",
  447.         feet="Arch. Sabots +3",
  448.     })
  449.     sets.midcast['Comet'] = set_combine(sets.midcast['Elemental Magic'].HighTierNuke, {
  450.         head="Pixie Hairpin +1",
  451.         left_ring="Archon Ring",
  452.     })
  453.     sets.midcast['Klimaform'] = set_combine(sets.precast.FC['Enhancing Magic'], {
  454.         right_ring="Kishar Ring",
  455.         waist="Witful Belt",
  456.     })
  457.     sets.midcast['Klimaform'].HighMP = set_combine(sets.midcast['Klimaform'], {
  458.         hands="Otomi Gloves",
  459.         left_ring="Mephitas's Ring",
  460.         right_ring="Mephitas's Ring +1",
  461.         waist="Shinjutsu-no-Obi +1",
  462.         legs="Amalric Slops +1",
  463.     }) 
  464.     sets.Obi = {waist="Hachirin-no-Obi",}    
  465.     sets.TreasureHunter = {
  466.         head={ name="Merlinic Hood", augments={'Attack+28','Crit. hit damage +2%','"Treasure Hunter"+2','Mag. Acc.+1 "Mag.Atk.Bns."+1',}},
  467.         waist="Chaac Belt",
  468.     }  
  469.     sets.AF_Body = {body="Spaekona's Coat +3",}
  470.     sets.Magic_Burst = {
  471.         head="Ea Hat +1",
  472.         body="Ea Houppe. +1",
  473.         legs="Ea Slops +1",
  474.         neck="Mizu. Kubikazari",
  475.         left_ring="Mujin Band",
  476.     }
  477.     sets.Occult_Acumen = {
  478.         ammo="Seraphic Ampulla",
  479.         head="Mallquis Chapeau +1",
  480.         legs="Perdition Slops",
  481.         neck="Lissome Necklace",
  482.         waist="Oneiros Rope",
  483.         left_ear="Telos Earring",
  484.         right_ear="Dedition Earring",
  485.         left_ring="Petrov Ring",
  486.         right_ring="Chirich Ring +1",
  487.     }
  488.     sets.Helix = {head="Spaekona's Petasos +3", waist="Sekhmet Corset",}
  489.     sets.resting = sets.idle
  490.     sets.idle = {
  491.         ammo="Staunch Tathlum +1",
  492.         head={ name="Spurrina Coif", augments={'"Refresh"+2',}},
  493.         body="Shamash Robe",
  494.         hands={ name="Merlinic Dastanas", augments={'"Dbl.Atk."+4','Magic dmg. taken -2%','"Refresh"+1','Mag. Acc.+17 "Mag.Atk.Bns."+17',}},
  495.         legs="Assid. Pants +1",
  496.         feet="Mallquis Clogs +2",
  497.         neck="Loricate Torque +1",
  498.         waist="Shinjutsu-no-Obi +1",
  499.         left_ear="Genmei Earring",
  500.         right_ear={ name="Darkness Earring", augments={'Phys. dmg. taken -2%','"Resist Poison"+2',}},
  501.         left_ring="Stikini Ring +1",
  502.         right_ring="Stikini Ring +1",
  503.         back="Moonlight Cape",
  504.     }
  505.     sets.idle.PDT = {
  506.         ammo="Staunch Tathlum +1",
  507.         head={ name="Merlinic Hood", augments={'Phys. dmg. taken -5%','"Mag.Atk.Bns."+14',}},
  508.         body="Shamash Robe",
  509.         hands={ name="Merlinic Dastanas", augments={'"Dbl.Atk."+4','Magic dmg. taken -2%','"Refresh"+1','Mag. Acc.+17 "Mag.Atk.Bns."+17',}},
  510.         legs="Assid. Pants +1",
  511.         feet="Mallquis Clogs +2",
  512.         neck="Loricate Torque +1",
  513.         waist="Shinjutsu-no-Obi +1",
  514.         left_ear="Genmei Earring",
  515.         right_ear={ name="Darkness Earring", augments={'Phys. dmg. taken -2%','"Resist Poison"+2',}},
  516.         left_ring="Defending Ring",
  517.         right_ring={ name="Dark Ring", augments={'Magic dmg. taken -6%','Phys. dmg. taken -5%',}},
  518.         back="Moonlight Cape",
  519.     }  
  520.     sets.idle.HighMP = {
  521.         ammo="Strobilus",
  522.         head={ name="Amalric Coif +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
  523.         body={ name="Weather. Robe +1", augments={'MP+120',}},
  524.         hands={ name="Otomi Gloves", augments={'HP+30','MP+30','MP+30',}},
  525.         legs={ name="Amalric Slops +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
  526.         feet={ name="Amalric Nails +1", augments={'MP+80','Mag. Acc.+20','"Mag.Atk.Bns."+20',}},
  527.         neck="Dualism Collar +1",
  528.         waist="Shinjutsu-no-Obi +1",
  529.         left_ear="Etiolation Earring",
  530.         right_ear="Evans Earring",
  531.         left_ring="Mephitas's Ring",
  532.         right_ring="Mephitas's Ring +1",
  533.         back={ name="Bane Cape", augments={'Elem. magic skill +10','Dark magic skill +7','"Mag.Atk.Bns."+4',}},
  534.     }
  535.     sets.idle.Town = sets.idle
  536.     sets.defense.PDT =  {
  537.         ammo="Staunch Tathlum +1",
  538.         head={ name="Merlinic Hood", augments={'Phys. dmg. taken -5%','"Mag.Atk.Bns."+14',}},
  539.         body="Shamash Robe",
  540.         hands={ name="Merlinic Dastanas", augments={'"Dbl.Atk."+4','Magic dmg. taken -2%','"Refresh"+1','Mag. Acc.+17 "Mag.Atk.Bns."+17',}},
  541.         legs="Assid. Pants +1",
  542.         feet="Mallquis Clogs +2",
  543.         neck="Loricate Torque +1",
  544.         waist="Shinjutsu-no-Obi +1",
  545.         left_ear="Genmei Earring",
  546.         right_ear={ name="Darkness Earring", augments={'Phys. dmg. taken -2%','"Resist Poison"+2',}},
  547.         left_ring="Defending Ring",
  548.         right_ring={ name="Dark Ring", augments={'Magic dmg. taken -6%','Phys. dmg. taken -5%',}},
  549.         back="Moonlight Cape",
  550.     }  
  551.     sets.defense.MDB = {}
  552.     sets.Kiting = {feet="Herald's Gaiters"}
  553.     sets.latent_refresh = {waist="Fucho-no-Obi"}
  554.  
  555.     -- Mana Wall idle set
  556.  
  557.     sets.buff['Mana Wall'] = set_combine(sets.idle.PDT,{
  558.         feet="Wicce Sabots +1",
  559.         back={ name="Taranus's Cape", augments={'MP+60','Mag. Acc+20 /Mag. Dmg.+20','MP+20','"Fast Cast"+10',}},
  560.     }) 
  561.     sets.engaged = {}
  562. end
  563.  
  564. function job_precast(spell, action, spellMap, eventArgs)    
  565.     if spell.name == 'Impact' then
  566.         equip({head=empty,body="Twilight Cloak"})
  567.     end
  568.     if spell.action_type == 'Magic' then
  569.         classes.CustomClass = player.equipment.main
  570.         eventArgs.handled = true
  571.     end
  572. end
  573.  
  574. function job_post_midcast(spell, action, spellMap, eventArgs)
  575.     if spell.action_type == 'Magic' then
  576.         if equipSet[spell.english] then
  577.             equipSet = equipSet[spell.english]
  578.         end
  579.         if equipSet[spellMap] then
  580.             equipSet = equipSet[spellMap]
  581.         end
  582.         if equipSet[state.CastingMode.value] then
  583.             equipSet = equipSet[state.CastingMode.value]
  584.         end
  585.         if spell.skill == 'Elemental Magic' then
  586.             if state.Occult_Acumen.value and sets.Occult_Acumen then
  587.                 local equipSet = sets.Occult_Acumen
  588.             end
  589.             if state.Magic_Burst.value and sets.Magic_Burst then
  590.                 local equipSet = sets.Magic_Burst
  591.             end
  592.             if state.AF_Body.value or (string.find(spell.english,'ga') or string.find(spell.english,'ja') or string.find(spell.english,'ra')) then
  593.                 local equipSet = equip(sets.AF_Body)
  594.             end
  595.             if spell.element == world.day_element or spell.element == world.weather_element then
  596.                 if string.find(spell.english,'helix') then
  597.                     equip(sets.Helix)
  598.                 else
  599.                 equip(sets.Obi)
  600.                 end
  601.             end
  602.             equip(equipSet)
  603.         end
  604.         if spell.skill == 'Dark Magic' then
  605.             if state.Occult_Acumen.value and sets.Occult_Acumen then
  606.                 local equipSet = sets.Occult_Acumen
  607.             end
  608.             if state.Magic_Burst.value and sets.Magic_Burst then
  609.                 local equipSet = sets.Magic_Burst
  610.             end
  611.             if state.AF_Body.value then
  612.                 local equipSet = equip(sets.AF_Body)
  613.             end
  614.             if spell.element == world.day_element or spell.element == world.weather_element then
  615.                 equip(sets.Obi)
  616.             end
  617.         end
  618.         equip(equipSet)
  619.     end
  620. end
  621.  
  622. function job_aftercast(spell, action, spellMap, eventArgs)
  623.     if buffactive['Mana Wall'] then
  624.         enable('feet','back')
  625.         equip(sets.buff['Mana Wall'])
  626.         disable('feet','back')
  627.     end
  628.     if not spell.interrupted then
  629.         if spell.english == "Sleep II" or spell.english == "Sleepga II" then -- Sleep II Countdown --
  630.             send_command('wait 60;input /echo Sleep Effect: [WEARING OFF IN 30 SEC.];wait 15;input /echo Sleep Effect: [WEARING OFF IN 15 SEC.];wait 10;input /echo Sleep Effect: [WEARING OFF IN 5 SEC.]')
  631.         elseif spell.english == "Sleep" or spell.english == "Sleepga" then -- Sleep & Sleepga Countdown --
  632.             send_command('wait 30;input /echo Sleep Effect: [WEARING OFF IN 30 SEC.];wait 15;input /echo Sleep Effect: [WEARING OFF IN 15 SEC.];wait 10;input /echo Sleep Effect: [WEARING OFF IN 5 SEC.]')
  633.         elseif spell.english == "Break" or spell.english == "Breakga" then -- Break Countdown --
  634.             send_command('wait 25;input /echo Break Effect: [WEARING OFF IN 5 SEC.]')    
  635.         end
  636.     end
  637. end
  638.  
  639. function refine_various_spells(spell, action, spellMap, eventArgs)
  640.     local aspirs = S{'Aspir','Aspir II','Aspir III'}
  641.     local sleeps = S{'Sleep','Sleep II'}
  642.     local sleepgas = S{'Sleepga','Sleepga II'}
  643.     local newSpell = spell.english
  644.     local spell_recasts = windower.ffxi.get_spell_recasts()
  645.     local cancelling = 'All '..spell.english..' spells are on cooldown. Cancelling spell casting.'
  646.     local spell_index
  647.     if spell_recasts[spell.recast_id] > 0 then
  648.         if spell.skill == 'Elemental Magic' then
  649.             local ele = tostring(spell.element):append('ga')
  650.             --local ele2 = string.sub(ele,1,-2)
  651.                 if table.find(degrade_array[ele],spell.name) then
  652.                     spell_index = table.find(degrade_array[ele],spell.name)
  653.                     if spell_index > 1 then
  654.                         newSpell = degrade_array[ele][spell_index - 1]
  655.                         add_to_chat(8,spell.name..' Canceled: ['..player.mp..'/'..player.max_mp..'MP::'..player.mpp..'%] Casting '..newSpell..' instead.')
  656.                         send_command('@input /ma '..newSpell..' '..tostring(spell.target.raw))
  657.                         eventArgs.cancel = true
  658.                     end
  659.                 else
  660.                     spell_index = table.find(degrade_array[spell.element],spell.name)
  661.                     if spell_index > 1 then
  662.                         newSpell = degrade_array[spell.element][spell_index - 1]
  663.                         add_to_chat(8,spell.name..' Canceled: ['..player.mp..'/'..player.max_mp..'MP::'..player.mpp..'%] Casting '..newSpell..' instead.')
  664.                         send_command('@input /ma '..newSpell..' '..tostring(spell.target.raw))
  665.                         eventArgs.cancel = true
  666.                     end
  667.                 end
  668.         elseif aspirs:contains(spell.name) then
  669.             spell_index = table.find(degrade_array['Aspirs'],spell.name)
  670.             if spell_index > 1 then
  671.                 newSpell = degrade_array['Aspirs'][spell_index - 1]
  672.                 add_to_chat(8,spell.name..' Canceled: ['..player.mp..'/'..player.max_mp..'MP::'..player.mpp..'%] Casting '..newSpell..' instead.')
  673.                 send_command('@input /ma '..newSpell..' '..tostring(spell.target.raw))
  674.                 eventArgs.cancel = true
  675.             end
  676.         elseif sleepgas:contains(spell.name) then
  677.             dex = table.find(degrade_array['Sleepgas'],spell.name)
  678.             if spell_index > 1 then
  679.                 newSpell = degrade_array['Sleepgas'][spell_index - 1]
  680.                 add_to_chat(8,spell.name..' Canceled: ['..player.mp..'/'..player.max_mp..'MP::'..player.mpp..'%] Casting '..newSpell..' instead.')
  681.                 send_command('@input /ma '..newSpell..' '..tostring(spell.target.raw))
  682.                 eventArgs.cancel = true
  683.             end
  684.         end
  685.     end
  686. end
  687.  
  688. function job_buff_change(buff, gain)
  689.     if buff == "Mana Wall" and not gain then
  690.         enable('feet','back')
  691.         handle_equipping_gear(player.status)
  692.     end
  693. end
  694.  
  695. function job_state_change(stateField, newValue, oldValue)
  696.     if stateField == 'Offense Mode' then
  697.         if newValue == 'None' then
  698.             enable('main','sub','range')
  699.         else
  700.             disable('main','sub','range')
  701.         end
  702.     end
  703. end
  704.  
  705. function display_current_job_state(eventArgs)
  706.     eventArgs.handled = true
  707.     local msg = ''
  708.     if state.OffenseMode.value ~= 'None' then
  709.         msg = msg .. 'Combat ['..state.OffenseMode.value..']'
  710.         if state.CombatForm.has_value then
  711.             msg = msg .. ' (' .. state.CombatForm.value .. ')'
  712.         end
  713.         msg = msg .. ', '
  714.     end
  715.     msg = msg .. 'Casting ['..state.CastingMode.value..'], Idle ['..state.IdleMode.value..']'
  716.     if state.Magic_Burst.value then
  717.         msg = msg .. ', MB [ON]'
  718.         else
  719.         msg = msg .. ', MB [OFF]'
  720.     end
  721.     if state.AF_Body.value then
  722.         msg = msg .. ', AF Body [ON]'
  723.         else
  724.         msg = msg .. ', AF Body [OFF]'
  725.     end
  726.     if state.Occult_Acumen.value then
  727.         msg = msg .. ', Occult Acumen [ON]'
  728.         else
  729.         msg = msg .. ', Occult Acumen [OFF]'
  730.     end
  731.     if state.DefenseMode.value ~= 'None' then
  732.         msg = msg .. ', ' .. 'Defense: ' .. state.DefenseMode.value .. ' (' .. state[state.DefenseMode.value .. 'DefenseMode'].value .. ')'
  733.     end
  734.     if state.Kiting.value then
  735.         msg = msg .. ', Kiting [ON]'
  736.     end
  737.     if state.PCTargetMode.value ~= 'default' then
  738.         msg = msg .. ', Target PC: '..state.PCTargetMode.value
  739.     end
  740.     if state.SelectNPCTargets.value == true then
  741.         msg = msg .. ', Target NPCs'
  742.     end
  743.     add_to_chat(122, msg)
  744. end
  745.  
  746. function job_get_spell_map(spell, default_spell_map)
  747.     if spell.skill == 'Elemental Magic' and default_spell_map ~= 'ElementalEnfeeble' then
  748.         if lowTierNukes:contains(spell.english) then
  749.             return 'LowTierNuke'
  750.         else
  751.             return 'HighTierNuke'
  752.         end
  753.     end
  754. end
  755.  
  756. function customize_idle_set(idleSet)
  757.     if player.mpp < 51 then
  758.         idleSet = set_combine(idleSet, sets.latent_refresh)
  759.     end
  760.     if buffactive['Mana Wall'] then
  761.         idleSet = set_combine(idleSet, sets.buff['Mana Wall'])
  762.     end
  763.     return idleSet
  764. end
  765.  
  766. function select_default_macro_book()
  767.     set_macro_page(1, 1)
  768. end
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top