Advertisement
Arnan

BLU Lua 29/10/215

Oct 29th, 2015
238
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 73.73 KB | None | 0 0
  1.  
  2.         -----------------------------------------------
  3.         -- *** Arnan Blue Mage Gearswap Lua File *** --
  4.         -----------------------------------------------
  5.            
  6.             -- Things to ADD --
  7.                 -- New spells (other than Mighty Guard)
  8.                 -- Problem: AM timers dont work in Salvage
  9.                 -- Add buff ID for chat log buff warnings
  10.  
  11.         ----------
  12.         -- Sets --
  13.         ----------
  14.  
  15. function get_sets()
  16.         AccIndex = 1
  17.         AccArray = {"LowACC","MidACC","HighACC","MaxACC"} -- 4 Levels Of Accuracy Sets For TP/WS. Default ACC Set Is LowACC.
  18.         WeaponIndex = 2
  19.         WeaponArray = {"Single","DW3","DW4"} -- Amount of Dual Wield used for TP. Default is DW3 --
  20.         IdleIndex = 1
  21.         IdleArray = {"Full","DT"} -- Default Idle Set Is Full --
  22.         Armor = 'None'
  23.         target_distance = 6 -- Set Default Distance Here --
  24.         Thaumas = 'OFF' -- Set Default Thaumas Coat ON or OFF Here --
  25.         MB = 'OFF' -- Set Default Magic Burst ON or OFF Here --
  26.         Cure_Spells = {"Cure","Cure II","Cure III","Cure IV"} -- Cure Degradation --
  27.         Curaga_Spells = {"Curaga","Curaga II"} -- Curaga Degradation --
  28.         send_command('input /macro book 20;wait .1;input /macro set 1') -- Change Default Macro Book Here --
  29.         add_to_chat(158,'-[Blue Mage Lua Loaded]-')
  30.         add_to_chat(158,'Dual Wield: '..WeaponArray[WeaponIndex])
  31.         add_to_chat(158,'Accuracy Level: ' .. AccArray[AccIndex])
  32.        
  33.         PhysicalBlueMagic = S{
  34.                         'Asuran Claws','Bludgeon','Body Slam','Feather Storm','Mandibular Bite','Queasyshroom',
  35.                         'Power Attack','Ram Charge','Saurian Slide','Screwdriver','Sickle Slash','Smite of Rage',
  36.                         'Spinal Cleave','Spiral Spin','Sweeping Gouge','Terror Touch'}
  37.  
  38.         PhysicalBlueMagic_STR = S{
  39.                         'Battle Dance','Bloodrake','Death Scissors','Dimensional Death','Empty Thrash',
  40.                         'Quadrastrike','Uppercut','Tourbillion','Thrashing Assault','Vertical Cleave',
  41.                         'Whirl of Rage'}
  42.  
  43.         PhysicalBlueMagic_DEX = S{
  44.                         'Amorphic Spikes','Barbed Crescent','Claw Cyclone','Disseverment','Foot Kick',
  45.                         'Frenetic Rip','Goblin Rush','Hysteric Barrage','Paralyzing Triad','Seedspray',
  46.                         'Sinker Drill','Vanity Dive'}
  47.  
  48.         PhysicalBlueMagic_VIT = S{
  49.                         'Cannonball','Delta Thrust','Glutinous Dart','Grand Slam','Quad. Continuum',
  50.                         'Sprout Smack'}
  51.  
  52.         PhysicalBlueMagic_AGI = S{
  53.                         'Benthic Typhoon','Helldive','Hydro Shot','Jet Stream','Pinecone Bomb','Wild Oats'}
  54.                
  55.         BlueMagic_PhysicalACC = S{
  56.                         'Heavy Strike'}
  57.  
  58.         MagicalBlueMagic = S{
  59.                         'Acrid Stream','Anvil Lightning','Crashing Thunder','Charged Whisker','Droning Whirlwind','Firespit',
  60.                         'Foul Waters','Gates of Hades','Leafstorm','Molting Plumage','Nectarous Deluge','Polar Roar',
  61.                         'Regurgitation','Rending Deluge','Scouring Spate','Searing Tempest','Silent Storm','Spectral Floe',
  62.                         'Subduction','Tem. Upheaval','Thermal Pulse','Thunderbolt','Uproot','Water Bomb'}
  63.                        
  64.         BlueMagic_Dark = S{
  65.                         'Atra. Libations','Blood Saber','Dark Orb','Death Ray','Eyes On Me',
  66.                         'Evryone. Grudge','Palling Salvo','Tenebral Crush'}
  67.        
  68.         BlueMagic_Light = S{
  69.                         'Blinding Fulgor','Diffusion Ray','Magic Hammer','Rail Cannon','Retinal Glare'}
  70.        
  71.         BlueMagic_Earth = S{
  72.                         'Embalming Earth','Entomb','Sandspin'}
  73.  
  74.         BlueMagic_Accuracy = S{
  75.                         '1000 Needles','Absolute Terror','Auroral Drape','Awful Eye','Blank Gaze','Blistering Roar',
  76.                         'Blood Drain','Blood Saber','Chaotic Eye','Cimicine Discharge','Cold Wave','Digest','Corrosive Ooze',
  77.                         'Demoralizing Roar','Dream Flower','Enervation','Feather Tickle','Filamented Hold','Frightful Roar',
  78.                         'Geist Wall','Hecatomb Wave','Infrasonics','Light of Penance','Lowing','Mind Blast','Mortal Ray',
  79.                         'MP Drainkiss','Osmosis','Reaving Wind','Sheep Song','Soporific','Sound Blast','Stinking Gas',
  80.                         'Sub-zero Smash','Triumphant Roar','Venom Shell','Voracious Trunk','Yawn'}
  81.  
  82.         BlueMagic_Breath = S{
  83.                         'Bad Breath','Flying Hip Press','Final Sting','Frost Breath','Heat Breath','Magnetite Cloud',
  84.                         'Poison Breath','Radiant Breath','Self Destruct','Thunder Breath','Wind Breath'}
  85.  
  86.         BlueMagic_Buff = S{
  87.                         'Carcharian Verve','Diamondhide','Metallic Body','Magic Barrier',"Occultation",
  88.                         'Orcish Counterstance','Plasma Charge','Pyric Bulwark','Reactor Cool'}
  89.                            
  90.         BlueMagic_Healing = S{
  91.                         'Healing Breeze','Magic Fruit','Plenilune Embrace','Pollen','Restoral','Wild Carrot'}
  92.                        
  93.         BlueMagic_HPCure = S{
  94.                         'White Wind'}
  95.  
  96.         BlueMagic_Stun = S{
  97.                         'Blitzstrahl','Temporal Shift'}
  98.        
  99.         BlueMagic_PhysicalStun = S{
  100.                         'Frypan','Head Butt','Sudden Lunge','Tail slap','Whirl of Rage'}       
  101.        
  102.         BlueMagic_Emnity = S{
  103.                         'Actinic Burst','Exuviation','Fantod','Jettatura'}     
  104.  
  105.         BlueMagic_Diffusion = S{
  106.                         'Amplification','Cocoon','Exuviation','Feather Barrier','Harden Shell','Memento Mori','Metallic Body',
  107.                         'Mighty Guard','Plasma Charge','Reactor Cool','Refueling','Saline Coat','Warm-Up','Zephyr Mantle'}
  108.  
  109.         BlueMagic_Unbridled = S{
  110.                         'Absolute Terror','Bilgestorm','Blistering Roar','Bloodrake','Carcharian Verve',
  111.                         'Droning Whirlwind','Gates of Hades','Harden Shell','Mighty Guard','Pyric Bulwark',
  112.                         'Thunderbolt','Tourbillion'}
  113.                        
  114.         --------------------
  115.         -- Idle/Town Sets --
  116.         --------------------
  117.         sets.Idle = {
  118.                         ammo="Iron Gobbet",
  119.                         head="Spurrina coif",
  120.                         neck="Bathy Choker +1",
  121.                         ear1="Ethereal Earring",
  122.                         ear2="Genmei Earring",
  123.                         body="Mekosu. Harness",
  124.                         hands="Serpentes Cuffs",
  125.                         ring1="Defending Ring",
  126.                         ring2="Paguroidea Ring",
  127.                         back="Umbra Cape",
  128.                         waist="Flume Belt +1",
  129.                         legs="Carmine Cuisses",
  130.                         feet="Serpentes Sabots"}
  131.         sets.Idle.Full = set_combine(sets.Idle,{})
  132.         sets.Idle.DT = set_combine(sets.Idle,{
  133.                         head="Spurrina Coif",
  134.                         neck="Loricate Collar +1",
  135.                         ear1="Darkness Earring",
  136.                         body="Vrikodara Jupon",
  137.                         hands="Qaaxo Mitaines",
  138.                         ring2="Gelatinous Ring +1",
  139.                         feet="Iuitl Gaiters +1"})
  140.  
  141.         -------------
  142.         -- TP Sets --
  143.         -------------
  144.          sets.TP = {
  145.                         ammo="Ginsen",
  146.                         head="Adhemar Bonnet",
  147.                         neck="Asperity Necklace",
  148.                         ear1="Suppanomimi",
  149.                         ear2="Eabani Earring",
  150.                         body="Adhemar Jacket",
  151.                         hands="Adhemar Wristbands",
  152.                         ring1="Petrov Ring",
  153.                         ring2="Epona's Ring",
  154.                         back="Bleating Mantle",
  155.                         waist="Shetal Stone",
  156.                         legs="Samnuha Tights",
  157.                         feet={ name="Taeon Boots", augments={'Accuracy+17 Attack+17','"Dual Wield"+5','STR+5 DEX+5',}}}
  158.         sets.TP.MidACC = {
  159.                         ammo="Ginsen",
  160.                         head="Dampening Tam",
  161.                         neck="Lissome Necklace",
  162.                         ear1="Suppanomimi",
  163.                         ear2="Eabani Earring",
  164.                         body="Adhemar Jacket",
  165.                         hands="Adhemar Wristbands",
  166.                         ring1="Petrov Ring",
  167.                         ring2="Epona's Ring",
  168.                         back="Lupine Cape",
  169.                         waist="Shetal Stone",
  170.                         legs="Samnuha Tights",
  171.                         feet={ name="Taeon Boots", augments={'Accuracy+17 Attack+17','"Dual Wield"+5','STR+5 DEX+5',}}}
  172.         sets.TP.HighACC = {
  173.                         ammo="Falcon Eye",
  174.                         head="Dampening Tam",
  175.                         neck="Subtlety Spec.",
  176.                         ear1="Suppanomimi",
  177.                         ear2="Eabani Earring",
  178.                         body="Adhemar Jacket",
  179.                         hands="Adhemar Wristbands",
  180.                         ring1="Petrov Ring",
  181.                         ring2="Epona's Ring",
  182.                         back="Ground. Mantle +1",
  183.                         waist="Shetal Stone",
  184.                         legs="Samnuha Tights",
  185.                         feet={ name="Taeon Boots", augments={'Accuracy+17 Attack+17','"Dual Wield"+5','STR+5 DEX+5',}}}
  186.         sets.TP.MaxACC = {
  187.                         ammo="Falcon Eye",
  188.                         head="Dampening Tam",
  189.                         neck="Subtlety Spec.",
  190.                         ear1="Suppanomimi",
  191.                         ear2="Eabani Earring",                 
  192.                         body="Adhemar Jacket",
  193.                         hands="Adhemar Wristbands",
  194.                         ring1="Ramuh Ring +1",
  195.                         ring2="Ramuh Ring +1",
  196.                         back="Ground. Mantle +1",
  197.                         waist="Shetal Stone",
  198.                         legs="Samnuha Tights",
  199.                         feet={ name="Taeon Boots", augments={'Accuracy+17 Attack+17','"Dual Wield"+5','STR+5 DEX+5',}}}
  200.  
  201.         ---------------------------
  202.         -- Single Weapon TP Sets --
  203.         ---------------------------
  204.         sets.TP.Single = {
  205.                         ammo="Ginsen",
  206.                         head="Dampening Tam",
  207.                         neck="Asperity Necklace",
  208.                         ear1="Tripudio Earring",
  209.                         ear2="Brutal Earring",
  210.                         body="Adhemar Jacket",
  211.                         hands="Adhemar Wristbands",
  212.                         ring1="Petrov Ring",
  213.                         ring2="Epona's Ring",
  214.                         back="Bleating Mantle",
  215.                         waist="Windbuffet Belt +1",
  216.                         legs="Samnuha Tights",
  217.                         feet="Carmine Greaves"}
  218.         sets.TP.Single.MidACC = set_combine(sets.TP.Single,{
  219.                         ammo="Falcon Eye",
  220.                         back="Lupine Cape"})
  221.         sets.TP.Single.HighACC = set_combine(sets.TP.Single.MidACC,{
  222.                         ear2="Zennaroi Earring",
  223.                         neck="Subtlety Spec."})
  224.         sets.TP.Single.MaxACC = set_combine(sets.TP.Single.HighACC,{                        
  225.                         ear1="Cessance Earring",
  226.                         ring1="Ramuh Ring +1",
  227.                         back="Ground. Mantle +1",
  228.                         waist="Kentarch Belt +1",
  229.                         feet={ name="Taeon Boots", augments={'Accuracy+18 Attack+18','"Triple Atk."+2','DEX+9',}}})
  230.  
  231.         -- Single Weapon Capped Magic Haste Sets --
  232.         sets.TP.Single.HighHaste = set_combine(sets.TP.Single,{})
  233.         sets.TP.Single.MidACC.HighHaste = set_combine(sets.TP.Single.MidACC,{})
  234.         sets.TP.Single.HighACC.HighHaste = set_combine(sets.TP.Single.HighACC,{})
  235.         sets.TP.Single.MaxACC.HighHaste = set_combine(sets.TP.Single.MaxACC,{})
  236.  
  237.         -- Single Weapon AM3 Sets --
  238.         sets.TP.Single.AM3 = set_combine(sets.TP.Single,{})
  239.         sets.TP.Single.MidACC.AM3 = set_combine(sets.TP.Single.MidACC,{})
  240.         sets.TP.Single.HighACC.AM3 = set_combine(sets.TP.Single.HighACC,{})
  241.         sets.TP.Single.MaxACC.AM3 = set_combine(sets.TP.Single.MaxACC,{})
  242.        
  243.         -- Single Weapon AM3 Capped Magic Haste Sets --
  244.         sets.TP.Single.HighHaste.AM3 = set_combine(sets.TP.Single,{})
  245.         sets.TP.Single.MidACC.HighHaste.AM3 = set_combine(sets.TP.Single.MidACC,{})
  246.         sets.TP.Single.HighACC.HighHaste.AM3 = set_combine(sets.TP.Single.HighACC,{})
  247.         sets.TP.Single.MaxACC.HighHaste.AM3 = set_combine(sets.TP.Single.MaxACC,{})
  248.  
  249.         ----------------------------
  250.         -- Dual Wield III TP Sets --
  251.         ----------------------------
  252.         sets.TP.DW3 = set_combine(sets.TP,{})
  253.         sets.TP.DW3.MidACC = set_combine(sets.TP.MidACC,{})
  254.         sets.TP.DW3.HighACC = set_combine(sets.TP.HighACC,{})
  255.         sets.TP.DW3.MaxACC = set_combine(sets.TP.MaxACC,{
  256.                         ear2="Zennaroi Earring"})
  257.  
  258.         -- Dual Wield III Capped Magic Haste Sets --
  259.         sets.TP.DW3.HighHaste =  set_combine(sets.TP,{
  260.                         ear1="Cessance Earring",
  261.                         ear2="Brutal Earring",
  262.                         waist="Windbuffet Belt +1",
  263.                         feet={ name="Taeon Boots", augments={'Accuracy+18 Attack+18','"Triple Atk."+2','DEX+9',}}})
  264.         sets.TP.DW3.MidACC.HighHaste =  set_combine(sets.TP.MidACC,{
  265.                         ear1="Cessance Earring",
  266.                         ear2="Brutal Earring",
  267.                         waist="Windbuffet Belt +1",
  268.                         feet={ name="Taeon Boots", augments={'Accuracy+18 Attack+18','"Triple Atk."+2','DEX+9',}}})
  269.         sets.TP.DW3.HighACC.HighHaste =  set_combine(sets.TP.HighACC,{
  270.                         ear1="Cessance Earring",
  271.                         ear2="Brutal Earring",
  272.                         waist="Windbuffet Belt +1",
  273.                         feet={ name="Taeon Boots", augments={'Accuracy+18 Attack+18','"Triple Atk."+2','DEX+9',}}})
  274.         sets.TP.DW3.MaxACC.HighHaste =  set_combine(sets.TP.MaxACC,{
  275.                         ear1="Cessance Earring",
  276.                         ear2="Zennaroi Earring",
  277.                         waist="Kentarch Belt +1",
  278.                         feet={ name="Taeon Boots", augments={'Accuracy+18 Attack+18','"Triple Atk."+2','DEX+9',}}})
  279.                            
  280.         -- Dual Wield III AM3 Sets --
  281.         sets.TP.DW3.AM3 = set_combine(sets.TP,{})
  282.         sets.TP.DW3.MidACC.AM3 = set_combine(sets.TP.MidACC,{})
  283.         sets.TP.DW3.HighACC.AM3 = set_combine(sets.TP.HighACC,{})
  284.         sets.TP.DW3.MaxACC.AM3 = set_combine(sets.TP.MaxACC,{
  285.                         ear2="Zennaroi Earring"})
  286.  
  287.         -- Dual Wield III AM3 Capped Magic Haste Sets --
  288.         sets.TP.DW3.HighHaste.AM3 =  set_combine(sets.TP,{
  289.                         ear1="Cessance Earring",
  290.                         ear2="Tripudio Earring",
  291.                         waist="Windbuffet Belt +1",
  292.                         feet={ name="Taeon Boots", augments={'Accuracy+18 Attack+18','"Triple Atk."+2','DEX+9',}}})
  293.         sets.TP.DW3.MidACC.HighHaste.AM3 = set_combine(sets.TP.MidACC,{
  294.                         ear1="Cessance Earring",
  295.                         ear2="Tripudio Earring",
  296.                         waist="Windbuffet Belt +1",
  297.                         feet={ name="Taeon Boots", augments={'Accuracy+18 Attack+18','"Triple Atk."+2','DEX+9',}}})
  298.         sets.TP.DW3.HighACC.HighHaste.AM3 = set_combine(sets.TP.HighACC,{
  299.                         ear1="Cessance Earring",
  300.                         ear2="Tripudio Earring",
  301.                         waist="Windbuffet Belt +1",
  302.                         feet={ name="Taeon Boots", augments={'Accuracy+18 Attack+18','"Triple Atk."+2','DEX+9',}}})
  303.         sets.TP.DW3.MaxACC.HighHaste.AM3 = set_combine(sets.TP.MaxACC,{
  304.                         ear1="Cessance Earring",
  305.                         ear2="Zennaroi Earring",
  306.                         waist="Kentarch Belt +1",
  307.                         feet={ name="Taeon Boots", augments={'Accuracy+18 Attack+18','"Triple Atk."+2','DEX+9',}}})
  308.                                
  309.         ---------------------------
  310.         -- Dual Wield IV TP Sets --
  311.         ---------------------------
  312.         sets.TP.DW4 = set_combine(sets.TP,{
  313.                         waist="Windbuffet Belt +1"})
  314.         sets.TP.DW4.MidACC = set_combine(sets.TP.MidACC,{
  315.                         waist="Windbuffet Belt +1"})
  316.         sets.TP.DW4.HighACC = set_combine(sets.TP.HighACC,{
  317.                         waist="Windbuffet Belt +1"})
  318.         sets.TP.DW4.MaxACC = set_combine(sets.TP.MaxACC,{
  319.                         ear2="Zennaroi Earring",
  320.                         waist="Kentarch Belt +1"})
  321.  
  322.         -- Dual Wield IV Capped Magic Haste Sets --
  323.         sets.TP.DW4.HighHaste =  set_combine(sets.TP,{
  324.                         ear1="Cessance Earring",
  325.                         ear2="Brutal Earring",
  326.                         waist="Windbuffet Belt +1",
  327.                         feet="Carmine Greaves"})
  328.         sets.TP.DW4.MidACC.HighHaste =  set_combine(sets.TP.MidACC,{
  329.                         ear1="Cessance Earring",
  330.                         ear2="Brutal Earring",
  331.                         waist="Windbuffet Belt +1",
  332.                         feet="Carmine Greaves"})
  333.         sets.TP.DW4.HighACC.HighHaste =  set_combine(sets.TP.HighACC,{
  334.                         ear1="Cessance Earring",
  335.                         ear2="Brutal Earring",
  336.                         waist="Windbuffet Belt +1",
  337.                         feet="Carmine Greaves"})
  338.         sets.TP.DW4.MaxACC.HighHaste =  set_combine(sets.TP.MaxACC,{
  339.                         ear1="Cessance Earring",
  340.                         ear2="Zennaroi Earring",
  341.                         waist="Kentarch Belt +1",
  342.                         feet="Carmine Greaves"})
  343.  
  344.         -- Dual Wield IV AM3 Sets --
  345.         sets.TP.DW4.AM3 = set_combine(sets.TP,{
  346.                         waist="Windbuffet Belt +1"})
  347.         sets.TP.DW4.MidACC.AM3 = set_combine(sets.TP.MidACC,{
  348.                         waist="Windbuffet Belt +1"})
  349.         sets.TP.DW4.HighACC.AM3 = set_combine(sets.TP.HighACC,{
  350.                         waist="Windbuffet Belt +1"})
  351.         sets.TP.DW4.MaxACC.AM3 = set_combine(sets.TP.MaxACC,{
  352.                         ear2="Zennaroi Earring",
  353.                         waist="Kentarch Belt +1"})
  354.  
  355.         -- Dual Wield IV AM3 Capped Magic Haste Sets --
  356.         sets.TP.DW4.HighHaste.AM3 =  set_combine(sets.TP,{
  357.                         ear1="Cessance Earring",
  358.                         ear2="Tripudio Earring",
  359.                         back="Lupine Cape",
  360.                         waist="Windbuffet Belt +1",
  361.                         feet="Carmine Greaves"})
  362.         sets.TP.DW4.MidACC.HighHaste.AM3 = set_combine(sets.TP.MidACC,{
  363.                         ear1="Cessance Earring",
  364.                         ear2="Tripudio Earring",
  365.                         waist="Windbuffet Belt +1",
  366.                         feet="Carmine Greaves"})
  367.         sets.TP.DW4.HighACC.HighHaste.AM3 = set_combine(sets.TP.HighACC,{
  368.                         ear1="Cessance Earring",
  369.                         ear2="Tripudio Earring",
  370.                         waist="Windbuffet Belt +1",
  371.                         feet="Carmine Greaves"})
  372.         sets.TP.DW4.MaxACC.HighHaste.AM3 = set_combine(sets.TP.MaxACC,{
  373.                         ear1="Cessance Earring",
  374.                         ear2="Zennaroi Earring",
  375.                         waist="Kentarch Belt +1",
  376.                         feet="Carmine Greaves"})
  377.                        
  378.         -- TP Thaumas Coat --
  379.         sets.TP.Thaumas = {body="Thaumas Coat"}
  380.  
  381.         -----------------------
  382.         -- Damage Taken Sets --
  383.         -----------------------
  384.        
  385.         -- PDT Set --
  386.         sets.PDT = {
  387.                         ammo="Iron Gobbet",
  388.                         head="Lithelimb Cap",
  389.                         neck="Loricate Collar +1",
  390.                         ear1="Ethereal Earring",
  391.                         ear2="Eabani Earring",
  392.                         body="Emet Harness +1",
  393.                         hands="Qaaxo Mitaines",
  394.                         ring1="Defending Ring",
  395.                         ring2="Gelatinous Ring +1",
  396.                         back="Umbra Cape",
  397.                         waist="Flume Belt +1",
  398.                         legs="Iuitl Tights +1",
  399.                         feet="Iuitl Gaiters +1"}
  400.  
  401.         -- MDT Set --
  402.         sets.MDT = set_combine(sets.PDT,{
  403.                         ammo="Vanir Battery",
  404.                         head="Dampening Tam",
  405.                         hands="Telchine Gloves",
  406.                         ear1="Sanare Earring",
  407.                         ear2="Eabani Earring",
  408.                         Ring2="Shadow Ring",
  409.                         back="Engulfer Cape +1",
  410.                         legs="Telchine Braconi",
  411.                         feet="Telchine Pigaches"})
  412.  
  413.         -- Hybrid Sets --
  414.         sets.TP.Hybrid = set_combine(sets.PDT,{
  415.                         ammo="Ginsen",
  416.                         ear1="Suppanomimi",
  417.                         ear2="Brutal Earring",
  418.                         hands="Adhemar Wristbands",
  419.                         waist="Shetal Stone",
  420.                         legs="Samnuha Tights"})
  421.         sets.TP.Hybrid.MidACC = set_combine(sets.TP.Hybrid,{
  422.                         ammo="Falcon Eye",
  423.                         ear2="Zennaroi Earring"})
  424.         sets.TP.Hybrid.HighACC = set_combine(sets.TP.Hybrid.MidACC,{
  425.                         hands="Qaaxo Mitaines",
  426.                         back="Ground. Mantle +1"})
  427.         sets.TP.Hybrid.MaxACC = set_combine(sets.TP.Hybrid.HighACC,{
  428.                         neck="Subtlety Spec.",
  429.                         waist="Kentarch Belt +1"})
  430.                        
  431.         -- Hybrid High Haste Sets --
  432.         sets.TP.Hybrid.HighHaste = set_combine(sets.PDT,{
  433.                         ammo="Ginsen",
  434.                         ear1="Suppanomimi",
  435.                         ear2="Brutal Earring",
  436.                         hands="Adhemar Wristbands",
  437.                         waist="Windbuffet Belt +1",
  438.                         legs="Samnuha Tights"})
  439.         sets.TP.Hybrid.MidACC.HighHaste = set_combine(sets.TP.Hybrid.HighHaste,{
  440.                         ammo="Falcon Eye",
  441.                         ear2="Zennaroi Earring"})
  442.         sets.TP.Hybrid.HighACC.HighHaste = set_combine(sets.TP.Hybrid.MidACC.HighHaste,{
  443.                         hands="Qaaxo Mitaines",
  444.                         back="Ground. Mantle +1"})
  445.         sets.TP.Hybrid.MaxACC.HighHaste = set_combine(sets.TP.Hybrid.HighACC.HighHaste,{
  446.                         neck="Subtlety Spec.",
  447.                         waist="Kentarch Belt +1"})
  448.  
  449.         -- Kiting Set --
  450.         sets.Kiting =  set_combine(sets.PDT,{
  451.                         ear2="Genmei Earring",
  452.                         body="Vrikodara Jupon",
  453.                         legs="Carmine Cuisses",
  454.                         feet="Hippo. Socks +1"})
  455.  
  456.         -----------------------
  457.         -- Weapon Skill Sets --
  458.         -----------------------
  459.  
  460.         -- WS Base Sets --
  461.         sets.WS = {
  462.                         ammo="Floestone",
  463.                         head="Adhemar Bonnet",
  464.                         neck="Fotia Gorget",
  465.                         ear1="Moonshade Earring",
  466.                         ear2="Brutal Earring",
  467.                         body="Adhemar Jacket",
  468.                         hands="Adhemar Wristbands",
  469.                         ring1="Ifrit Ring",
  470.                         ring2="Epona's Ring",
  471.                         back="Bleating Mantle",
  472.                         waist="Fotia Belt",
  473.                         legs="Samnuha Tights",
  474.                         feet="Thereoid Greaves"}
  475.         sets.WS.MidACC = {
  476.                         ammo="Falcon Eye",
  477.                         head="Dampening Tam",
  478.                         neck="Fotia Gorget",
  479.                         ear1="Moonshade Earring",
  480.                         ear2="Brutal Earring",
  481.                         body="Adhemar Jacket",
  482.                         hands="Adhemar Wristbands",
  483.                         ring1="Ifrit Ring",
  484.                         ring2="Epona's Ring",
  485.                         back="Bleating Mantle",
  486.                         waist="Fotia Belt",
  487.                         legs="Samnuha Tights",
  488.                         feet={ name="Taeon Boots", augments={'Accuracy+18 Attack+18','"Triple Atk."+2','DEX+9',}}}
  489.         sets.WS.HighACC = {
  490.                         ammo="Falcon Eye",
  491.                         head="Dampening Tam",
  492.                         neck="Fotia Gorget",
  493.                         ear1="Moonshade Earring",
  494.                         ear2="Brutal Earring",
  495.                         body="Adhemar Jacket",
  496.                         hands="Adhemar Wristbands",
  497.                         ring1="Ramuh Ring +1",
  498.                         ring2="Epona's Ring",
  499.                         back="Letalis Mantle",
  500.                         waist="Fotia Belt",
  501.                         legs="Samnuha Tights",
  502.                         feet={ name="Taeon Boots", augments={'Accuracy+18 Attack+18','"Triple Atk."+2','DEX+9',}}}
  503.         sets.WS.MaxACC = {
  504.                         ammo="Falcon Eye",
  505.                         head="Dampening Tam",
  506.                         neck="Fotia Gorget",
  507.                         ear1="Moonshade Earring",
  508.                         ear2="Zennaroi Earring",
  509.                         body="Adhemar Jacket",
  510.                         hands="Adhemar Wristbands",
  511.                         ring1="Ramuh Ring +1",
  512.                         ring2="Ramuh Ring +1",
  513.                         back="Ground. Mantle +1",
  514.                         waist="Fotia Belt",
  515.                         legs="Samnuha Tights",
  516.                         feet={ name="Taeon Boots", augments={'Accuracy+18 Attack+18','"Triple Atk."+2','DEX+9',}}}
  517.                        
  518.         -- Magic WS Base Set --
  519.         sets.WS.MABWS = {
  520.                         ammo="Ghastly Tathlum +1",
  521.                         head="Helios Band",
  522.                         neck="Eddy Necklace",
  523.                         ear1="Friomisi Earring",
  524.                         ear2="Crematio Earring",
  525.                         body="Samnuha Coat",
  526.                         hands="Amalric Gages",
  527.                         ring1="Acumen Ring",
  528.                         ring2="Shiva Ring +1",
  529.                         back="Cornflower Cape",
  530.                         waist="Eschan Stone",
  531.                         legs="Hagondes Pants +1",
  532.                         feet="Amalric nails"}
  533.        
  534.         -----------------------------
  535.         -- Sword Weapon Skill Sets --
  536.         -----------------------------
  537.  
  538.         -- Chant du Cygne Sets --
  539.         sets.WS["Chant du Cygne"] = set_combine(sets.WS,{
  540.                         ammo="Jukukik Feather",
  541.                         ring1="Ramuh Ring +1",
  542.                         back="Rancorous Mantle"})
  543.         sets.WS["Chant du Cygne"].MidACC = set_combine(sets.WS.MidACC,{
  544.                         ammo="Jukukik Feather",
  545.                         head="Adhemar Bonnet",
  546.                         ring1="Ramuh Ring +1",
  547.                         back="Rancorous Mantle",
  548.                         feet="Thereoid Greaves"})
  549.         sets.WS["Chant du Cygne"].HighACC = set_combine(sets.WS.HighACC,{
  550.                         ring1="Ramuh Ring +1",
  551.                         back="Rancorous Mantle",
  552.                         feet="Thereoid Greaves"})
  553.         sets.WS["Chant du Cygne"].MaxACC = set_combine(sets.WS.MaxACC,{})
  554.  
  555.         -- Requiescat Sets --
  556.         sets.WS.Requiescat = set_combine(sets.WS,{
  557.                         ammo="Hydrocera",
  558.                         head="Lilitu Headpiece",
  559.                         ring1="Rufescent Ring"})
  560.         sets.WS.Requiescat.MidACC = set_combine(sets.WS.MidACC,{
  561.                         ammo="Hydrocera",
  562.                         ring1="Rufescent Ring"})
  563.         sets.WS.Requiescat.HighACC = set_combine(sets.WS.HighACC,{
  564.                         ring1="Rufescent Ring"})
  565.         sets.WS.Requiescat.MaxACC = set_combine(sets.WS.MaxACC,{})
  566.  
  567.         -- Expiacion Sets --
  568.         sets.WS.Expiacion = set_combine(sets.WS,{
  569.                         head="Lilitu Headpiece",
  570.                         neck="Caro Necklace",
  571.                         ear2="Ishvara Earring",
  572.                         waist="Grunfeld Rope"})
  573.         sets.WS.Expiacion.MidACC = set_combine(sets.WS.MidACC,{
  574.                         head="Lilitu Headpiece",
  575.                         neck="Caro Necklace",
  576.                         ear2="Ishvara Earring",
  577.                         waist="Grunfeld Rope"})
  578.         sets.WS.Expiacion.HighACC = set_combine(sets.WS.HighACC,{
  579.                         neck="Subtlety Spec.",
  580.                         ear2="Ishvara Earring",
  581.                         waist="Grunfeld Rope"})
  582.         sets.WS.Expiacion.MaxACC = set_combine(sets.WS.MaxACC,{
  583.                         neck="Subtlety Spec.",
  584.                         waist="Kentarch Belt +1"})
  585.        
  586.         -- Savage Blade Set --
  587.         sets.WS["Savage Blade"] = set_combine(sets.WS,{
  588.                         head="Lilitu Headpiece",
  589.                         neck="Caro Necklace",
  590.                         ear2="Ishvara Earring",
  591.                         waist="Grunfeld Rope"})
  592.         sets.WS["Savage Blade"].MidACC = set_combine(sets.WS.MidACC,{
  593.                         head="Lilitu Headpiece",
  594.                         neck="Caro Necklace",
  595.                         ear2="Ishvara Earring",
  596.                         waist="Grunfeld Rope"})
  597.         sets.WS["Savage Blade"].HighACC = set_combine(sets.WS.HighACC,{
  598.                         neck="Subtlety Spec.",
  599.                         ear2="Ishvara Earring",
  600.                         waist="Grunfeld Rope"})
  601.         sets.WS["Savage Blade"].MaxACC = set_combine(sets.WS.MaxACC,{
  602.                         neck="Subtlety Spec.",
  603.                         waist="Kentarch Belt +1"})
  604.        
  605.         -- Vorpal Blade Sets --
  606.         sets.WS["Vorpal Blade"] = set_combine(sets.WS,{
  607.                         back="Rancorous Mantle"})
  608.         sets.WS["Vorpal Blade"].MidACC = set_combine(sets.WS.MidACC,{
  609.                         head="Adhemar Bonnet",
  610.                         back="Rancorous Mantle",
  611.                         feet="Thereoid Greaves"})
  612.         sets.WS["Vorpal Blade"].HighACC = set_combine(sets.WS.HighACC,{
  613.                         back="Rancorous Mantle",
  614.                         feet="Thereoid Greaves"})
  615.         sets.WS["Vorpal Blade"].MaxACC = set_combine(sets.WS.MaxACC,{})
  616.        
  617.         -- Circle Blade Sets --
  618.         sets.WS["Circle Blade"] = set_combine(sets.WS,{
  619.                         head="Lilitu Headpiece",
  620.                         ear1="Ishvara Earring"})
  621.         sets.WS["Circle Blade"].MidACC = set_combine(sets.WS.MidACC,{
  622.                         ear1="Ishvara Earring"})
  623.         sets.WS["Circle Blade"].HighACC = set_combine(sets.WS.HighACC,{
  624.                         ear1="Ishvara Earring"})
  625.         sets.WS["Circle Blade"].MaxACC = set_combine(sets.WS.MaxACC,{})    
  626.        
  627.         -- Sanguine Blade Set --
  628.         sets.WS["Sanguine Blade"] = set_combine(sets.WS.MABWS,{
  629.                         head="Pixie Hairpin +1",
  630.                         ring1="Archon Ring"})
  631.         sets.WS["Sanguine Blade"].MidACC = set_combine(sets.WS.MABWS,{
  632.                         head="Pixie Hairpin +1",
  633.                         ring1="Archon Ring"})
  634.         sets.WS["Sanguine Blade"].HighACC = set_combine(sets.WS.MABWS,{
  635.                         head="Pixie Hairpin +1",
  636.                         ring1="Archon Ring"})
  637.         sets.WS["Sanguine Blade"].MaxACC = set_combine(sets.WS.MABWS,{
  638.                         head="Pixie Hairpin +1",
  639.                         ring1="Archon Ring"})
  640.        
  641.         ----------------------------
  642.         -- Club Weapon Skill Sets --
  643.         ----------------------------
  644.        
  645.         -- Realmrazer Sets --
  646.         sets.WS.Realmrazer = set_combine(sets.WS,{
  647.                         ammo="Hydrocera",
  648.                         head="Dampening Tam",
  649.                         ring1="Rufescent Ring"})
  650.         sets.WS.Realmrazer.MidACC = set_combine(sets.WS.MidACC,{
  651.                         ammo="Hydrocera",
  652.                         ring1="Rufescent Ring"})
  653.         sets.WS.Realmrazer.HighACC = set_combine(sets.WS.HighACC,{
  654.                         ring1="Rufescent Ring"})
  655.         sets.WS.Realmrazer.MaxACC = set_combine(sets.WS.MaxACC,{})
  656.  
  657.         -- Black Halo Sets --
  658.         sets.WS["Black Halo"] = set_combine(sets.WS,{
  659.                         ammo="Hydrocera",
  660.                         head="Dampening Tam",
  661.                         ring1="Rufescent Ring"})
  662.         sets.WS["Black Halo"].MidACC = set_combine(sets.WS.MidACC,{
  663.                         ammo="Hydrocera",
  664.                         ring1="Rufescent Ring"})
  665.         sets.WS["Black Halo"].HighACC = set_combine(sets.WS.HighACC,{
  666.                         ring1="Rufescent Ring"})
  667.         sets.WS["Black Halo"].MaxACC = set_combine(sets.WS.MaxACC,{})
  668.        
  669.         -- True Strike Sets --
  670.         sets.WS["True Strike"] = set_combine(sets.WS,{
  671.                         head="Adhemar Bonnet",
  672.                         ear2="Ishvara Earring",
  673.                         feet="Thereoid Greaves"})
  674.         sets.WS["True Strike"].MidACC = set_combine(sets.WS.MidACC,{
  675.                         head="Adhemar Bonnet",
  676.                         ear2="Ishvara Earring",
  677.                         feet="Thereoid Greaves"})
  678.         sets.WS["True Strike"].HighACC = set_combine(sets.WS.HighACC,{
  679.                         head="Adhemar Bonnet",
  680.                         ear2="Ishvara Earring",
  681.                         feet="Thereoid Greaves"})
  682.         sets.WS["True Strike"].MaxACC = set_combine(sets.WS.MaxACC,{})
  683.        
  684.         -- Judgment Sets --
  685.         sets.WS.Judgment = set_combine(sets.WS,{
  686.                         head="Lilitu Headpiece",
  687.                         ear2="Ishvara Earring"})
  688.         sets.WS.Judgment.MidACC = set_combine(sets.WS.MidACC,{
  689.                         head="Lilitu Headpiece",
  690.                         ear2="Ishvara Earring"})
  691.         sets.WS.Judgment.HighACC = set_combine(sets.WS.HighACC,{
  692.                         ear2="Ishvara Earring"})
  693.         sets.WS.Judgment.MaxACC = set_combine(sets.WS.MaxACC,{})
  694.        
  695.         -- Flash Nova Set --
  696.         sets.WS["Flash Nova"] = set_combine(sets.WS.MABWS,{})
  697.         sets.WS["Flash Nova"].MidACC = set_combine(sets.WS.MABWS,{})
  698.         sets.WS["Flash Nova"].HighACC = set_combine(sets.WS.MABWS,{})
  699.         sets.WS["Flash Nova"].MaxACC = set_combine(sets.WS.MABWS,{})
  700.        
  701.         ----------------------
  702.         -- Job Ability Sets --
  703.         ----------------------
  704.        
  705.         -- Blue Mage JA Sets --
  706.         sets.JA = {}
  707.         sets.JA['Azure Lore'] = {hands="Luh. Bazubands +1"}
  708.         sets['Chain Affinity'] = {head="Hashishin Kavuk +1",ring2="Mujin Band",feet="Assim. Charuqs +1"}
  709.         sets.Efflux = {legs="Hashishin Tayt +1"}
  710.         sets['Burst Affinity'] = {feet="Hashi. Basmak +1"}
  711.         sets.Convergence = {head="Luh. Keffiyeh +1"}
  712.         sets.Diffusion = {feet="Luhlaza Charuqs +1"}
  713.        
  714.         -- Enmity JA Set --
  715.         sets.JA.Enmity = set_combine(sets.PDT,{
  716.                         ammo="Iron Gobbet",
  717.                         head="Rabid Visor",
  718.                         neck="Unmoving Collar +1",
  719.                         ear1="Trux Earring",
  720.                         ear2="Cryptic Earring",
  721.                         body="Emet Harness +1",
  722.                         ring1="Petrov Ring",
  723.                         ring2="Eihwaz Ring",
  724.                         back="Fravashi Mantle",
  725.                         waist="Goading Belt",
  726.                         legs="Zoar Subligar +1"})
  727.        
  728.         -- /WAR JA Sets --
  729.         sets.JA.Provoke = set_combine(sets.JA.Enmity,{})
  730.         sets.JA.Warcry = set_combine(sets.JA.Enmity,{})
  731.        
  732.         -- /PLD JA Sets --
  733.         sets.JA["Shield Bash"] = set_combine(sets.JA.Enmity,{})
  734.         sets.JA.Sentinel = set_combine(sets.JA.Enmity,{})
  735.         sets.JA["Holy Circle"] = set_combine(sets.JA.Enmity,{})
  736.        
  737.         -- /DRK JA Sets --
  738.         sets.JA.Souleater = set_combine(sets.JA.Enmity,{})
  739.         sets.JA["Last Resort"] = set_combine(sets.JA.Enmity,{})
  740.         sets.JA["Arcane Circle"] = set_combine(sets.JA.Enmity,{})
  741.        
  742.         -- /DNC JA Sets --
  743.         sets.Waltz = {
  744.                         ammo="Iron Gobbet",
  745.                         head="Carmine Mask",
  746.                         neck="Loricate Collar +1",
  747.                         ear1="Darkness Earring",
  748.                         ear2="Genmei Earring",
  749.                         body="Vrikodara Jupon",
  750.                         hands="Amalric Gages",
  751.                         ring1="Defending Ring",
  752.                         ring2="Gelatinous Ring +1",
  753.                         back="Swith Cape +1",
  754.                         waist="Chaac Belt",
  755.                         legs="Hashishin Tayt +1",
  756.                         feet="Hippo. Socks +1"}
  757.         sets.Step = {
  758.                         ammo="Hydrocera",
  759.                         head="Dampening Tam",
  760.                         neck="Voltsurge Torque",
  761.                         ear1="Lifestorm Earring",
  762.                         ear2="Psystorm Earring",
  763.                         body="Hashishin Mintan +1",
  764.                         hands="Leyline Gloves",
  765.                         ring1="Balrahn's Ring",
  766.                         ring2="Sangoma Ring",
  767.                         back="Cornflower Cape",
  768.                         waist="Chaac Belt",
  769.                         legs="Psycloth Lappas",
  770.                         feet="Iuitl Gaiters +1"}
  771.         sets.Flourish = set_combine(sets.Step,{})
  772.  
  773.         -- /RUN JA Sets --
  774.         sets.JA.Lunge = {
  775.                         ammo="Ghastly Tathlum +1",
  776.                         head="Helios Band",
  777.                         neck="Eddy Necklace",
  778.                         ear1="Friomisi Earring",
  779.                         ear2="Crematio Earring",
  780.                         body="Samnuha Coat",
  781.                         hands="Amalric Gages",
  782.                         ring1="Acumen Ring",
  783.                         ring2="Shiva Ring +1",
  784.                         back="Cornflower Cape",
  785.                         waist="Eschan Stone",
  786.                         legs="Hagondes Pants +1",
  787.                         feet="Amalric nails"}
  788.         sets.JA.Swipe = set_combine(sets.JA.Lunge,{})
  789.        
  790.         --------------------
  791.         -- Pre-Cast Sets --
  792.         --------------------
  793.        
  794.         -- Base Pre-Cast Set --
  795.         sets.Precast = {
  796.                         ammo="Impatiens",
  797.                         head="Carmine Mask",
  798.                         neck="Voltsurge Torque",
  799.                         ear1="Loquac. Earring",
  800.                         ear2="Genmei Earring",
  801.                         body="Taeon Tabard",
  802.                         hands="Leyline Gloves",
  803.                         ring1="Lebeche Ring",
  804.                         ring2="Prolix Ring",
  805.                         back="Swith Cape +1",
  806.                         waist="Witful Belt",
  807.                         legs="Psycloth Lappas",
  808.                         feet="Amalric nails"}
  809.        
  810.         -- Fast Cast Set --
  811.         sets.Precast.FastCast = set_combine(sets.Precast,{})
  812.                        
  813.         -- Pre-Cast Blue Magic --
  814.         sets.Precast['Blue Magic'] = set_combine(sets.Precast,{body="Hashishin Mintan +1"})
  815.                        
  816.         -- Pre-Cast Enhancing Magic --
  817.         sets.Precast['Enhancing Magic'] = set_combine(sets.Precast,{waist="Siegel Sash"})
  818.        
  819.         -- Cure Precast Set --
  820.         sets.Precast.Cure = set_combine(sets.Precast.FastCast,{ear2="Mendi. Earring",waist="Acerbic Sash +1"})
  821.  
  822.         ------------------------------------
  823.         -- Mid-Cast Sets (Non-Blue Magic) --
  824.         ------------------------------------
  825.  
  826.         -- Mid-Cast Base Set --
  827.         sets.Midcast = {
  828.                         ammo="Impatiens",
  829.                         head="Carmine Mask",
  830.                         neck="Voltsurge Torque",
  831.                         ear1="Loquac. Earring",
  832.                         ear2="Genmei Earring",
  833.                         body="Taeon Tabard",
  834.                         hands="Leyline Gloves",
  835.                         ring1="Defending Ring",
  836.                         ring2="Prolix Ring",
  837.                         back="Swith Cape +1",
  838.                         waist="Witful Belt",
  839.                         legs="Psycloth Lappas",
  840.                         feet="Amalric nails"}
  841.  
  842.         -- Magic Haste Set --
  843.         sets.Midcast.Haste = set_combine(sets.Midcast,{})
  844.                        
  845.         -- Magic Attack Bonus Set --
  846.         sets.Midcast.MAB = {
  847.                         main="Gabaxorea",
  848.                         sub="Gabaxorea",
  849.                         ammo="Ghastly Tathlum +1",
  850.                         head="Helios Band",
  851.                         neck="Eddy Necklace",
  852.                         ear1="Friomisi Earring",
  853.                         ear2="Crematio Earring",
  854.                         body="Samnuha Coat",
  855.                         hands="Amalric Gages",
  856.                         ring1="Acumen Ring",
  857.                         ring2="Shiva Ring +1",
  858.                         back="Cornflower Cape",
  859.                         waist="Eschan Stone",
  860.                         legs="Hagondes Pants +1",
  861.                         feet="Amalric nails"}
  862.                        
  863.         -- Magic Burst Set --
  864.         sets.Midcast.MB = {ring1="Mujin Band",ring2="Locus Ring"}
  865.  
  866.         -- Magic Accuracy Set --
  867.         sets.Midcast.MACC = {
  868.                         ammo="Hydrocera",
  869.                         head="Dampening Tam",
  870.                         neck="Incanter's Torque",
  871.                         ear1="Lifestorm Earring",
  872.                         ear2="Psystorm Earring",
  873.                         body="Hashishin Mintan +1",
  874.                         hands="Leyline Gloves",
  875.                         ring1="Balrahn's Ring",
  876.                         ring2="Sangoma Ring",
  877.                         back="Cornflower Cape",
  878.                         waist="Eschan Stone",
  879.                         legs="Psycloth Lappas",
  880.                         feet="Hashi. Basmak +1"}
  881.                        
  882.         -- Magic Enmity Set --
  883.         sets.Midcast.MagicEnmity = set_combine(sets.Midcast,{
  884.                         ammo="Iron Gobbet",
  885.                         head="Rabid Visor",
  886.                         neck="Unmoving Collar +1",
  887.                         ear1="Trux Earring",
  888.                         ear2="Cryptic Earring",
  889.                         body="Emet Harness +1",
  890.                         ring1="Petrov Ring",
  891.                         ring2="Eihwaz Ring",
  892.                         back="Fravashi Mantle",
  893.                         waist="Goading Belt",
  894.                         legs="Zoar Subligar +1"})
  895.        
  896.         -- Enhancing Magic Base Set --
  897.         sets.Midcast['Enhancing Magic'] = {
  898.                         head="Carmine Mask",
  899.                         neck="Incanter's Torque",
  900.                         ear1="Andoaa Earring",
  901.                         body="Telchine Chas.",
  902.                         hands="Ayao's Gages",
  903.                         back="Merciful Cape",
  904.                         waist="Olympus Sash",
  905.                         legs="Carmine Cuisses",
  906.                         feet="Fea's Pigaches"}
  907.        
  908.         -- Elemental Magic Set --
  909.         sets.Midcast['Elemental Magic'] = set_combine(sets.Midcast.MAB,{})
  910.  
  911.         -- Enfeebling Magic Set --
  912.         sets.Midcast['Enfeebling Magic'] = set_combine(sets.Midcast.MACC,{
  913.                         head="Carmine Mask",
  914.                         feet="Medium's Sabots"})
  915.        
  916.         -- Dark Magic Set --
  917.         sets.Midcast['Dark Magic'] = set_combine(sets.Midcast.MACC,{})
  918.        
  919.         -- Flash Set --
  920.         sets.Midcast.Flash = set_combine(sets.Midcast.MagicEnmity,{})
  921.        
  922.         -- Repose Set --
  923.         sets.Midcast.Repose = set_combine(sets.Midcast.MACC,{})
  924.        
  925.         -- Stoneskin Set --
  926.         sets.Midcast.Stoneskin = set_combine(sets.Midcast['Enhancing Magic'],{waist="Siegel Sash"})
  927.                        
  928.         -- Enfeebling Ninjutsu Set --
  929.         sets.Midcast.Enfeebling_Ninjutsu = set_combine(sets.Midcast.MACC,{})
  930.        
  931.         -- Elemental Ninjutsu Set --
  932.         sets.Midcast.Elemental_Ninjutsu = set_combine(sets.Midcast.MAB,{})
  933.  
  934.         -----------------------------------------------------
  935.         -- For Cure Spells & The Listed Healing Blue Magic --
  936.         -----------------------------------------------------
  937.        
  938.         -- Cure Set --
  939.         sets.Midcast.Cure = {
  940.                         ammo="Hydrocera",
  941.                         head="Telchine Cap",
  942.                         neck="Phalaina Locket",
  943.                         ear1="Lifestorm Earring",
  944.                         ear2="Mendi. Earring",
  945.                         body="Vrikodara Jupon",
  946.                         hands="Telchine Gloves",
  947.                         ring1="Rufescent Ring",
  948.                         ring2="Levia. Ring",
  949.                         back="Tempered Cape",
  950.                         waist="Chuq'aba Belt",
  951.                         legs="Telchine Braconi",
  952.                         feet="Medium's Sabots"}
  953.                        
  954.         -- Self Cures --
  955.         sets.Midcast.SelfCure = set_combine(sets.Midcast.Cure,{
  956.                         ring2="Kunaji Ring",
  957.                         waist="Chuq'aba Belt"})
  958.                        
  959.         -- HP-up Cures --
  960.         sets.Midcast.HPCure = set_combine(sets.Midcast.Cure,{
  961.                         ring2="Kunaji Ring",
  962.                         waist="Chuq'aba Belt"})
  963.        
  964.         ------------------------------
  965.         -- Mid-Cast Blue Magic Sets --
  966.         ------------------------------
  967.        
  968.          -- Blue Magic Base Mid-Cast Set --
  969.         sets.Midcast['Blue Magic'] = set_combine(sets.Midcast,{hands="Hashi. Bazu. +1"})
  970.  
  971.         -- For The Listed Physical Type Blue Magic --
  972.         sets.Midcast.PhysicalBlueMagic = {
  973.                         ammo="Floestone",
  974.                         head="Lilitu Headpiece",
  975.                         neck="Caro Necklace",
  976.                         ear1="Cessance Earring",
  977.                         ear2="Zennaroi Earring",
  978.                         body="Adhemar Jacket",
  979.                         hands="Adhemar Wristbands",
  980.                         ring1="Ifrit Ring",
  981.                         ring2="Ifrit Ring",
  982.                         back="Cornflower Cape",
  983.                         waist="Grunfeld Rope",
  984.                         legs="Samnuha Tights",
  985.                         feet="Thereoid Greaves"}
  986.  
  987.         -- BlueMagic STR Set --
  988.         sets.Midcast.PhysicalBlueMagic_STR = set_combine(sets.Midcast.PhysicalBlueMagic,{})
  989.  
  990.         -- BlueMagic STR/DEX Set --
  991.         sets.Midcast.PhysicalBlueMagic_DEX = set_combine(sets.Midcast.PhysicalBlueMagic,{
  992.                         ring1="Ramuh Ring +1",
  993.                         ring2="Ramuh Ring +1"})
  994.  
  995.         -- BlueMagic STR/VIT Set --
  996.         sets.Midcast.PhysicalBlueMagic_VIT = set_combine(sets.Midcast.PhysicalBlueMagic,{
  997.                         ammo="Iron Gobbet"})
  998.  
  999.         -- BlueMagic STR/AGI Set --
  1000.         sets.Midcast.PhysicalBlueMagic_AGI = set_combine(sets.Midcast.PhysicalBlueMagic,{})
  1001.        
  1002.         -- Physical Acc Blue Magic --
  1003.         sets.Midcast.BlueMagic_PhysicalACC = {
  1004.                         ammo="Falcon Eye",
  1005.                         head="Dampening Tam",
  1006.                         neck="Subtlety Spec.",
  1007.                         ear1="Cessance Earring",
  1008.                         ear2="Zennaroi Earring",
  1009.                         body="Adhemar Jacket",
  1010.                         hands="Adhemar Wristbands",
  1011.                         ring1="Ramuh Ring +1",
  1012.                         ring2="Ramuh Ring +1",
  1013.                         back="Ground. Mantle +1",
  1014.                         waist="Kentarch Belt +1",
  1015.                         legs="Samnuha Tights",
  1016.                         feet={ name="Taeon Boots", augments={'Accuracy+18 Attack+18','"Triple Atk."+2','DEX+9',}}}
  1017.  
  1018.         -- For The Listed Magical Type BlueMagic --
  1019.         sets.Midcast.MagicalBlueMagic = set_combine(sets.Midcast.MAB,{})
  1020.        
  1021.         -- Dark Based Magical Blue Magic --
  1022.         sets.Midcast.BlueMagic_Dark = set_combine(sets.Midcast.MAB,{head="Pixie Hairpin +1",ring1="Archon Ring"})
  1023.        
  1024.         -- Light Based Magical Blue Magic --
  1025.         sets.Midcast.BlueMagic_Light = set_combine(sets.Midcast.MAB,{}) -- Insert Weatherspoon Ring Here --
  1026.  
  1027.         -- Earth Based Magical Blue Magic --
  1028.         sets.Midcast.BlueMagic_Earth = set_combine(sets.Midcast.MAB,{neck="Quanpur Necklace"})
  1029.  
  1030.         -- Magic Accuracy For The Listed BlueMagic --
  1031.         sets.Midcast.BlueMagic_Accuracy = set_combine(sets.Midcast.MACC,{})
  1032.  
  1033.         -- Stun Set For The Listed BlueMagic --
  1034.         sets.Midcast.BlueMagic_Stun = set_combine(sets.Midcast.MACC,{})
  1035.                        
  1036.         -- Physical Stun Blue Magic --
  1037.         sets.Midcast.BlueMagic_PhysicalStun = set_combine(sets.Midcast.MACC,{
  1038.                         neck="Voltsurge Torque",
  1039.                         body="Hashishin Mintan +1",
  1040.                         hands="Leyline Gloves",
  1041.                         feet="Iuitl Gaiters +1"})
  1042.  
  1043.         -- Buff Set For The Listed Blue Magic --
  1044.         sets.Midcast.BlueMagic_Buff = {
  1045.                         ammo="Impatiens",
  1046.                         head="Luh. Keffiyeh +1",
  1047.                         neck="Incanter's Torque",
  1048.                         ear1="Loquac. Earring",
  1049.                         ear2="Genmei Earring",
  1050.                         body="Assim. Jubbah +1",
  1051.                         hands="Hashi. Bazu. +1",
  1052.                         ring1="Defending Ring",
  1053.                         ring2="Gelatinous Ring +1",
  1054.                         back="Cornflower Cape",
  1055.                         legs="Hashishin Tayt +1",
  1056.                         waist="Hachirin-no-Obi",
  1057.                         feet="Luhlaza Charuqs +1"}
  1058.  
  1059.         -- Breath Set For The Listed Blue Magic --
  1060.         sets.Midcast.BlueMagic_Breath = set_combine(sets.Midcast,{head="Luh. Keffiyeh +1"})
  1061.        
  1062.         -- White Wind Set --
  1063.         sets.Midcast.BlueMagic_HPCure = set_combine(sets.Midcast.HPCure,{})
  1064.        
  1065.         -- Enmity Sets For the Listed Blue Magic --
  1066.         sets.Midcast.BlueMagic_Emnity = set_combine(sets.Midcast.MagicEnmity,{})
  1067.  
  1068. end
  1069.  
  1070.         ----------------
  1071.         -- Pre-Target --
  1072.         ----------------
  1073.  
  1074. function pretarget(spell,action)
  1075.         if (spell.type:endswith('Magic') or spell.type == "Ninjutsu") and buffactive.silence then -- Auto Use Echo Drops If You Are Silenced --
  1076.                 cancel_spell()
  1077.                 send_command('input /item "Echo Drops" <me>')
  1078.         elseif spell.english == "Berserk" and buffactive.Berserk then -- Change Berserk To Aggressor If Berserk Is On --
  1079.                 cancel_spell()
  1080.                 send_command('Aggressor')
  1081.         elseif spell.english:ifind("Cure") and player.mp<actualCost(spell.mp_cost) then -- Cure Degradation --
  1082.                 degrade_spell(spell,Cure_Spells)
  1083.         elseif spell.english:ifind("Curaga") and player.mp<actualCost(spell.mp_cost) then -- Curaga Degradation --
  1084.                 degrade_spell(spell,Curaga_Spells)
  1085.         return
  1086.     end
  1087. end
  1088.  
  1089.         --------------
  1090.         -- Pre-Cast --
  1091.         --------------
  1092.        
  1093. function precast(spell,action)
  1094.     if spell.type == "WeaponSkill" then
  1095.         if player.status ~= 'Engaged' then -- Cancel WS If You Are Not Engaged. Can Delete It If You Don't Need It --
  1096.             cancel_spell()
  1097.             add_to_chat(123,'Unable To Use WeaponSkill: [Disengaged]')
  1098.             return
  1099.         else
  1100.             equipSet = sets.WS
  1101.             if equipSet[spell.english] then
  1102.                 equipSet = equipSet[spell.english]
  1103.             end
  1104.             if equipSet[AccArray[AccIndex]] then
  1105.                 equipSet = equipSet[AccArray[AccIndex]]
  1106.             end
  1107.             if buffactive['Reive Mark'] then -- Equip Ygnas's Resolve +1 During Reive --
  1108.                 equipSet = set_combine(equipSet,{neck="Ygnas's Resolve +1"})
  1109.             end
  1110.             if buffactive['Sneak Attack'] or buffactive['Trick Attack'] then -- Equip Crit damage+ gear during WS when Sneak or Trick Attack are active --
  1111.                 equipSet = set_combine(equipSet,{head="Adhemar Bonnet",feet="Thereoid Greaves"})
  1112.             end
  1113.                 if spell.english == "Chant du Cygne" and player.tp > 2900 then  -- Different Earrings for 2900+ TP Weapon Skills --
  1114.                     equipSet = set_combine(equipSet,{ear1="Cessance Earring"})  
  1115.                 elseif spell.english == "Requiescat" and player.tp > 2900 then
  1116.                     equipSet = set_combine(equipSet,{ear1="Lifestorm Earring"})  
  1117.                 elseif spell.english == "Expiacion" and player.tp > 2900 then
  1118.                     equipSet = set_combine(equipSet,{ear1="Ishvara Earring",ear2="Brutal Earring"})
  1119.                 elseif spell.english == "Savage Blade" and player.tp > 2900 then
  1120.                         equipSet = set_combine(equipSet,{ear1="Ishvara Earring",ear2="Brutal Earring"})
  1121.                 elseif spell.english == "Vorpal Blade" and player.tp > 2900 then
  1122.                         equipSet = set_combine(equipSet,{ear1="Cessance Earring"})
  1123.                 elseif spell.english == "Realmrazer" and player.tp > 2900 then
  1124.                         equipSet = set_combine(equipSet,{ear1="Lifestorm Earring"})  
  1125.                 elseif spell.english == "Black Halo" and player.tp > 2900 then
  1126.                         equipSet = set_combine(equipSet,{ear1="Cessance Earring"})
  1127.                 elseif spell.english == "Judgment" and player.tp > 2900 then
  1128.                         equipSet = set_combine(equipSet,{ear1="Ishvara Earring",ear2="Brutal Earring"})
  1129.                 elseif spell.english == "True Strike" and player.tp > 2900 then
  1130.                         equipSet = set_combine(equipSet,{ear1="Ishvara Earring",ear2="Brutal Earring"})    
  1131.                 elseif spell.english == "Sanguine Blade" and world.day == "Darksday" or world.weather_element == "Dark" then -- Hachirin-no-Obi for Day/Weather Magical Weapon Skills --
  1132.                         equipSet = set_combine(equipSet,{waist="Hachirin-no-Obi"})                     
  1133.                 elseif spell.english == "Flash Nova" and world.day == "Lightsday" or world.weather_element == "Light" then
  1134.                         equipSet = set_combine(equipSet,{waist="Hachirin-no-Obi"})                 
  1135.                 end
  1136.                 equip(equipSet)
  1137.                 end
  1138.         elseif spell.type == "JobAbility" or spell.type == "Ward" or spell.type == "Effusion" then
  1139.                 if sets.JA[spell.english] then
  1140.                         equip(sets.JA[spell.english])
  1141.                 end        
  1142.         elseif spell.type == "Rune" then
  1143.                 equip(sets.JA.Enmity)              
  1144.         elseif spell.type:endswith('Magic') or spell.type == "Ninjutsu" then
  1145.                 if buffactive.silence  then -- Cancel Magic or Ninjutsu If You Are Silenced --
  1146.                         cancel_spell()
  1147.                         add_to_chat(123, spell.name..' Canceled: [Silenced]')
  1148.                         return
  1149.                 else
  1150.                         if (string.find(spell.english,'Cur') or BlueMagic_Healing:contains(spell.english) or BlueMagic_HPCure:contains(spell.english))  and spell.english ~= "Cursna" then
  1151.                                 equip(sets.Precast.Cure)
  1152.                         elseif string.find(spell.english,'Utsusemi') then
  1153.                                 if buffactive['Copy Image (3)'] or buffactive['Copy Image (4)'] then
  1154.                                         cancel_spell()
  1155.                                         add_to_chat(123, spell.english .. ' Canceled: [3+ Images]')
  1156.                                         return
  1157.                         else
  1158.                             equip(sets.Precast.FastCast)
  1159.                         end
  1160.                         elseif sets.Precast[spell.skill] then
  1161.                                 equip(sets.Precast[spell.skill])
  1162.                         else
  1163.                         equip(sets.Precast.FastCast)
  1164.             end
  1165.         end
  1166.         elseif string.find(spell.type,'Flourish') then
  1167.                 if spell.english == "Animated Flourish" then
  1168.                         equip(sets.Enmity)
  1169.                 else
  1170.                         equip(sets.Flourish)
  1171.                 end
  1172.         elseif spell.type == "Step" then
  1173.                 equip(sets.Step)
  1174.         elseif spell.type == "Waltz" then
  1175.                 refine_waltz(spell,action)
  1176.                 equip(sets.Waltz)
  1177.         elseif spell.english == 'Spectral Jig' and buffactive.Sneak then
  1178.                 cast_delay(0.2)
  1179.                 send_command('cancel Sneak')
  1180.         end
  1181. end
  1182.            
  1183.         --------------
  1184.         -- Mid-Cast --
  1185.         --------------
  1186.            
  1187. function midcast(spell,action)
  1188.         equipSet = {}
  1189.         if spell.type:endswith('Magic') or spell.type == 'Ninjutsu' or spell.type == 'Trust' then
  1190.                 equipSet = sets.Midcast
  1191.                 if equipSet[spell.english] then
  1192.                         equipSet = equipSet[spell.english]
  1193.                 elseif (string.find(spell.english,'Cur') or BlueMagic_Healing:contains(spell.english)) and spell.english ~= "Cursna" then
  1194.                         if spell.target.name == player.name then
  1195.                                 equipSet = equipSet.SelfCure
  1196.                         else
  1197.                                 equipSet = equipSet.Cure
  1198.                         end
  1199.                         elseif BlueMagic_HPCure:contains(spell.english) then
  1200.                                 equipSet = equipSet.BlueMagic_HPCure
  1201.                 elseif string.find(spell.english,'Protect') or string.find(spell.english,'Shell') then
  1202.                         if spell.target.name == player.name then
  1203.                                 equipSet = set_combine(sets.Haste,{ring1="Sheltered Ring"})
  1204.                         end    
  1205.                 elseif spell.english:startswith('Refresh') or spell.english:startswith('Haste') or spell.english:startswith('Flurry') or spell.english:startswith('Blink') or spell.english:startswith('Regen') or spell.english:endswith('Spikes') then
  1206.                                 equipSet = sets.Haste
  1207.                 elseif spell.english == "Stoneskin" then
  1208.                         if buffactive.Stoneskin then
  1209.                                 send_command('@wait 2.8;cancel stoneskin')
  1210.                     end
  1211.                                 equipSet = equipSet.Stoneskin
  1212.                 elseif PhysicalBlueMagic:contains(spell.english) or PhysicalBlueMagic_STR:contains(spell.english) or PhysicalBlueMagic_DEX:contains(spell.english) or PhysicalBlueMagic_VIT:contains(spell.english) or PhysicalBlueMagic_AGI:contains(spell.english) or BlueMagic_PhysicalACC:contains(spell.english) then
  1213.                         if PhysicalBlueMagic_STR:contains(spell.english) then
  1214.                                 equipSet = equipSet.PhysicalBlueMagic_STR
  1215.                         elseif PhysicalBlueMagic_DEX:contains(spell.english) then
  1216.                                 equipSet = equipSet.PhysicalBlueMagic_DEX
  1217.                         elseif PhysicalBlueMagic_VIT:contains(spell.english) then
  1218.                                 equipSet = equipSet.PhysicalBlueMagic_VIT
  1219.                         elseif PhysicalBlueMagic_AGI:contains(spell.english) then
  1220.                                 equipSet = equipSet.PhysicalBlueMagic_AGI
  1221.                         elseif PhysicalBlueMagic:contains(spell.english) then
  1222.                                 equipSet = equipSet.PhysicalBlueMagic
  1223.                         elseif BlueMagic_PhysicalACC:contains(spell.english) then
  1224.                                 equipSet = equipSet.BlueMagic_PhysicalACC
  1225.                         end
  1226.                         if buffactive['Chain Affinity'] then
  1227.                                 equipSet = set_combine(equipSet,sets['Chain Affinity'])
  1228.                         end
  1229.                         if buffactive.Efflux then
  1230.                                 equipSet = set_combine(equipSet,sets.Efflux)
  1231.                         end
  1232.                 elseif MagicalBlueMagic:contains(spell.english) or BlueMagic_Dark:contains(spell.english) or BlueMagic_Light:contains(spell.english) or BlueMagic_Earth:contains(spell.english) then
  1233.                         if MagicalBlueMagic:contains(spell.english) then
  1234.                                 equipSet = equipSet.MagicalBlueMagic
  1235.                         elseif BlueMagic_Dark:contains(spell.english) then
  1236.                                 equipSet = equipSet.BlueMagic_Dark
  1237.                         elseif BlueMagic_Light:contains(spell.english) then
  1238.                                 equipSet = equipSet.BlueMagic_Light
  1239.                         elseif BlueMagic_Earth:contains(spell.english) then
  1240.                                 equipSet = equipSet.BlueMagic_Earth
  1241.                         end
  1242.                         if buffactive['Burst Affinity'] then
  1243.                                 equipSet = set_combine(equipSet,sets['Burst Affinity'])
  1244.                         end
  1245.                         if world.day_element == spell.element or world.weather_element == spell.element then
  1246.                                 equipSet = set_combine(equipSet,{waist='Hachirin-no-Obi'})
  1247.                         end
  1248.                         if buffactive.Convergence then
  1249.                                 equipSet = set_combine(equipSet,sets.Convergence)
  1250.                         end
  1251.                         if MB == 'ON' then
  1252.                                 equipSet = set_combine(equipSet,sets.Midcast.MB)
  1253.                         end
  1254.                         equip(equipSet)
  1255.                 elseif BlueMagic_Accuracy:contains(spell.english) then
  1256.                         equipSet = equipSet.BlueMagic_Accuracy
  1257.                 elseif BlueMagic_Stun:contains(spell.english) then
  1258.                         equipSet = equipSet.BlueMagic_Stun
  1259.                 elseif BlueMagic_PhysicalStun:contains(spell.english) then
  1260.                         equipSet = equipSet.BlueMagic_PhysicalStun
  1261.                 elseif BlueMagic_Emnity:contains(spell.english) then
  1262.                         equipSet = equipSet.BlueMagic_Emnity                       
  1263.                 elseif BlueMagic_Buff:contains(spell.english) then
  1264.                         equipSet = equipSet.BlueMagic_Buff
  1265.                 elseif BlueMagic_Diffusion:contains(spell.english) and buffactive.Diffusion then
  1266.                         equipSet = set_combine(equipSet,sets.Diffusion)
  1267.                 elseif BlueMagic_Breath:contains(spell.english) then
  1268.                         equipSet = equipSet.BlueMagic_Breath
  1269.                 elseif spell.english == "Stoneskin" then
  1270.                         if buffactive.Stoneskin then
  1271.                                 send_command('@wait 2.8;cancel stoneskin')
  1272.                         end
  1273.                         equipSet = equipSet.Stoneskin
  1274.                 elseif spell.english == "Sneak" then
  1275.                         if spell.target.name == player.name and buffactive['Sneak'] then
  1276.                                 send_command('cancel sneak')
  1277.                         end
  1278.                         equipSet = equipSet.Haste
  1279.                 elseif string.find(spell.english,'Utsusemi') then
  1280.                         if spell.english == 'Utsusemi: Ichi' and (buffactive['Copy Image'] or buffactive['Copy Image (2)']) then
  1281.                                 send_command('@wait 1.7;cancel Copy Image*')
  1282.                         end
  1283.                         equipSet = equipSet.Haste
  1284.                 elseif spell.english == 'Monomi: Ichi' then
  1285.                         if buffactive['Sneak'] then
  1286.                                 send_command('@wait 1.7;cancel sneak')
  1287.                         end
  1288.                         equipSet = equipSet.Haste
  1289.                 elseif spell.english:startswith('Tonko') then
  1290.                         equipSet = equipSet.Haste
  1291.                 elseif spell.english:startswith('Jabaku') or spell.english:startswith('Hojo') or spell.english:startswith('Kurayami') or spell.english:startswith('Dokumori') then
  1292.                         equipSet = equipSet.Enfeebling_Ninjutsu
  1293.                 elseif spell.english:startswith('Katon') or spell.english:startswith('Suiton') or spell.english:startswith('Doton') or spell.english:startswith('Hyoton') or spell.english:startswith('Huton') or spell.english:startswith('Raiton') then
  1294.                         equipSet = equipSet.Elemental_Ninjutsu
  1295.                 if (world.day_element == spell.element or world.weather_element == spell.element) then
  1296.                         equipSet = set_combine(equipSet,{waist="Hachirin-no-Obi"})
  1297.                 end
  1298.                 if MB == 'ON' then
  1299.                         equipSet = set_combine(equipSet,sets.Midcast.MB)
  1300.                 end
  1301.         elseif equipSet[spell.skill] then
  1302.             equipSet = equipSet[spell.skill]
  1303.         end
  1304.                 if spell.skill == 'Elemental Magic' or spell.english:startswith('Cur') or spell.english:startswith('Aspir') or spell.english:startswith('Drain') or spell.english:startswith('White Wind') then
  1305.                 if (world.day_element == spell.element or world.weather_element == spell.element) then
  1306.                         equipSet = set_combine(equipSet,{waist="Hachirin-no-Obi"})
  1307.                 end
  1308.                 if MB == 'ON' then
  1309.                         equipSet = set_combine(equipSet,sets.Midcast.MB)
  1310.                 end
  1311.                 end
  1312.     elseif equipSet[spell.english] then
  1313.         equipSet = equipSet[spell.english]
  1314.     end
  1315.     equip(equipSet)
  1316. end
  1317.        
  1318.         ----------------
  1319.         -- After-Cast --
  1320.         ----------------
  1321.        
  1322. function aftercast(spell,action)
  1323.         if spell.type == "WeaponSkill" and not spell.interrupted then
  1324.                 send_command('wait 0.2;gs c TP')
  1325.         elseif spell.english == "Sleep II" or spell.english == "Repose" or spell.english == "Dream Flower" then -- Sleep II//Repose/Dream Flower Countdown --
  1326.             send_command('wait 60;input /echo Sleep II/Dream Flower Effect: [WEARING OFF IN 30 SEC.];wait 15;input /echo Sleep II/Dream Flower Effect: [WEARING OFF IN 15 SEC.];wait 10;input /echo Sleep II/Dream Flower Effect: [WEARING OFF IN 5 SEC.]')
  1327.         elseif spell.english == "Sleep" or spell.english == "Sleepga" or spell.english == "Sheep Song" then -- Sleep/Sleepga/Sheep Song Countdown --
  1328.             send_command('wait 30;input /echo Sleep/Sheep Song Effect: [WEARING OFF IN 30 SEC.];wait 15;input /echo Sleep/Sheep Song Effect: [WEARING OFF IN 15 SEC.];wait 10;input /echo Sleep/Sheep Song Effect: [WEARING OFF IN 5 SEC.]')
  1329.         end
  1330.     status_change(player.status)
  1331. end
  1332.         -------------------
  1333.         -- Status Change --
  1334.         -------------------
  1335.        
  1336. function status_change(new,old)
  1337.         if Armor == 'PDT' then
  1338.                 equip(sets.PDT)
  1339.         elseif Armor == 'MDT' then
  1340.                 equip(sets.MDT)
  1341.         elseif Armor == 'Kiting' then
  1342.                 equip(sets.Kiting)
  1343.         elseif new == 'Engaged' then
  1344.                 equipSet = sets.TP
  1345.         if Armor == 'Hybrid' and equipSet["Hybrid"] then
  1346.                 equipSet = equipSet["Hybrid"]
  1347.         end
  1348.         if equipSet[WeaponArray[WeaponIndex]] then
  1349.                 equipSet = equipSet[WeaponArray[WeaponIndex]]
  1350.         end
  1351.         if equipSet[AccArray[AccIndex]] then
  1352.                 equipSet = equipSet[AccArray[AccIndex]]
  1353.         end
  1354.         if (buffactive.March and (buffactive.Embrava or buffactive.Haste or buffactive['Mighty Guard']) or (buffactive.Haste == 2) or (buffactive['Mighty Guard']) and (buffactive.Embrava or buffactive.Haste)) and equipSet["HighHaste"] then
  1355.                 equipSet = equipSet["HighHaste"]
  1356.         end
  1357.         if buffactive["Aftermath: Lv.3"] and equipSet["AM3"] then
  1358.                 equipSet = equipSet["AM3"]
  1359.         end
  1360.         if Thaumas == 'ON' then
  1361.                 equipSet = set_combine(equipSet,sets.TP.Thaumas)
  1362.         end
  1363.         equip(equipSet)
  1364.     elseif new == 'Idle' then
  1365.         equipSet = sets.Idle
  1366.         if equipSet[IdleArray[IdleIndex]] then
  1367.             equipSet = equipSet[IdleArray[IdleIndex]]
  1368.         end
  1369.         if buffactive['Reive Mark'] then -- Equip Ygnas's Resolve +1 During Reive --
  1370.             equipSet = set_combine(equipSet,{neck="Ygnas's Resolve +1"})
  1371.         end
  1372.         if world.area:endswith('Adoulin') then
  1373.             equipSet = set_combine(equipSet,{}) -- Add Councilor's Garb to equip in Adoulin --
  1374.         end
  1375.         equip(equipSet)
  1376.     end
  1377. end
  1378.        
  1379.  
  1380.  
  1381.         -----------------
  1382.         -- Buff Change --
  1383.         -----------------
  1384.    
  1385. function buff_change(buff,gain,buff_table)
  1386.         buff = string.lower(buff)
  1387.         if buff == "aftermath: lv.3" and player.equipment.main == 'Tizona' then -- AM3 Timer/Countdown --
  1388.                 if gain then
  1389.                         send_command('timers create "Aftermath: Lv.3" 180 down')
  1390.                 else
  1391.                         send_command('timers delete "Aftermath: Lv.3"')
  1392.                         add_to_chat(123,'AM3: [OFF]')
  1393.                 end
  1394.         elseif buff == 'azure lore' then -- Azure Lore Timer --
  1395.                 if gain then
  1396.                         send_command('timers create "Azure Lore" 40 down')
  1397.                 else
  1398.                         send_command('timers delete "Azure Lore"')
  1399.                 end    
  1400.         elseif buff == 'chain affinity' then -- Chain Affinity Timer --
  1401.                 if gain then
  1402.                         send_command('timers create "Chain Affinity" 30 down')
  1403.                 else
  1404.                         send_command('timers delete "Chain Affinity"')
  1405.                 end        
  1406.         elseif buff == 'burst affinity' then -- Burst Affinity Timer --
  1407.                 if gain then
  1408.                         send_command('timers create "Burst Affinity" 30 down')
  1409.                 else
  1410.                         send_command('timers delete "Burst Affinity"')
  1411.                 end    
  1412.         elseif buff == 'efflux' then -- Efflux Timer --
  1413.                 if gain then
  1414.                         send_command('timers create "Efflux" 60 down')
  1415.                 else
  1416.                         send_command('timers delete "Efflux"')
  1417.                 end    
  1418.         elseif buff == 'diffusion' then -- Diffusion Timer --
  1419.                 if gain then
  1420.                         send_command('timers create "Diffusion" 60 down')
  1421.                 else
  1422.                         send_command('timers delete "Diffusion"')
  1423.                 end    
  1424.         elseif buff == 'unbridled learning' then -- Unbridled Learning Timer --
  1425.                 if gain then
  1426.                         send_command('timers create "Unbridled Learning" 60 down')
  1427.                 else
  1428.                         send_command('timers delete "Unbridled Learning"')
  1429.                 end    
  1430.         elseif buff == 'unbridled wisdom' then -- Unbridled Wisdom Timer --
  1431.                 if gain then
  1432.                         send_command('timers create "Unbridled Wisdom" 60 down')
  1433.                 else
  1434.                         send_command('timers delete "Unbridled Wisdom"')
  1435.                 end                    
  1436.         elseif buff == 'transcendency' then -- Brew Timer --
  1437.                 if gain then
  1438.                         send_command('timers create "Transcendency" 180 down')
  1439.                 else
  1440.                         send_command('timers delete "Transcendency"')
  1441.                         add_to_chat(123,'Transcendency: [OFF]')
  1442.                 end            
  1443.         elseif buff == 'weakness' then -- Weakness Timer --
  1444.                 if gain then
  1445.                         send_command('timers create "Weakness" 300 up')
  1446.                 else
  1447.                         send_command('timers delete "Weakness"')
  1448.                 end
  1449.         elseif buff == 'doom' then -- Doom Party Chat --
  1450.                 if gain then
  1451.                         send_command('input /party Doom')
  1452.                 else
  1453.                         send_command('input /party Doom off')
  1454.                         add_to_chat(158,'Doom: [OFF]')
  1455.                 end
  1456.         elseif buff == 'curse' then -- Curse Party Chat --
  1457.                 if gain then
  1458.                         send_command('input /party Curse')
  1459.                 else
  1460.                         add_to_chat(158,'Curse: [OFF]')
  1461.                 end
  1462.         elseif buff_table['id'] == 91 then -- Nat. Meditation --
  1463.                 if not gain then
  1464.                         add_to_chat(123,'Nat. Meditation: [OFF]')
  1465.                 end
  1466.         elseif buff_table['id'] == 93 then -- Cocoon Notification --
  1467.                 if not gain then
  1468.                         add_to_chat(123,'Cocoon: [OFF]')
  1469.                 end    
  1470.         elseif buff_table['id'] == 33 then -- Haste --
  1471.                 if not gain then
  1472.                         add_to_chat(123,'Haste: [OFF]')
  1473.                 end    
  1474.         elseif buff_table['id'] == 147 then -- Attack Down --
  1475.                 if not gain then
  1476.                         add_to_chat(158,'Attack Down: [OFF]')
  1477.                 end
  1478.         elseif buff_table['id'] == 149 then -- Defense Down --
  1479.                 if not gain then
  1480.                         add_to_chat(158,'Defense Down: [OFF]')
  1481.                 end    
  1482.         elseif buff_table['id'] == 13  then    -- Slow --
  1483.                 if gain then
  1484.                         send_command('input /party Slowed')
  1485.                 else
  1486.                         add_to_chat(158,'Slow: [OFF]')
  1487.                 end
  1488.         elseif buff_table['id'] == 42 then -- Regen --
  1489.                 if not gain then
  1490.                         add_to_chat(123,'Regen: [OFF]')
  1491.                 end    
  1492.         elseif buff_table['id'] == 43 then -- Refresh --
  1493.                 if not gain then
  1494.                         add_to_chat(123,'Refresh: [OFF]')
  1495.                 end
  1496.         elseif buff_table['id'] == 152 then -- Magic Barrier --
  1497.                 if not gain then
  1498.                         add_to_chat(123,'Magic Barrier: [OFF]')
  1499.                 end    
  1500.         elseif buff_table['id'] == 116 then -- Phalanx --
  1501.                 if not gain then
  1502.                         add_to_chat(123,'Phalanx: [OFF]')
  1503.                 end    
  1504.         elseif buff_table['id'] == 36 then -- Blink/Occultation --
  1505.                 if not gain then
  1506.                         add_to_chat(123,'Blink: [OFF]')
  1507.                 end    
  1508.         elseif buff == 'mighty guard' then -- Mighty Guard --
  1509.                 if not gain then
  1510.                         add_to_chat(123,'Mighty Guard: [OFF]')
  1511.                 end    
  1512.         elseif buff == 'food' then -- Food --
  1513.                 if not gain then
  1514.                         add_to_chat(123,'Food: [OFF]')
  1515.                 end
  1516.         elseif buff == 'terror' then -- Terror --
  1517.                 if not gain then
  1518.                         add_to_chat(158,'Terror: [OFF]')
  1519.                 end
  1520.         elseif buff == 'stun' then -- Stun --
  1521.                 if not gain then
  1522.                         add_to_chat(158,'Stun: [OFF]')
  1523.                 end    
  1524.         elseif buff == 'amnesia' then -- Amnesia --
  1525.                 if not gain then
  1526.                         add_to_chat(158,'Amnesia: [OFF]')
  1527.                 end                
  1528.         elseif buff == 'sleep' then -- Sleep --
  1529.                 if gain then
  1530.                         send_command('input /party ZZZ')
  1531.                 else
  1532.                         add_to_chat(158,'Sleep: [OFF]')
  1533.                 end        
  1534.         end
  1535.         if buffactive.Terror or buffactive.Stun or buffactive.Petrification or buffactive.Sleep and gain then -- Lock PDT When You Are Terrorised/Stunned/Petrified/Slept --
  1536.                 equip({
  1537.                         ammo="Iron Gobbet",
  1538.                         head="Lithelimb Cap",
  1539.                         neck="Loricate Collar +1",
  1540.                         ear1="Ethereal Earring",
  1541.                         ear2="Eabani Earring",
  1542.                         body="Emet Harness +1",
  1543.                         hands="Qaaxo Mitaines",
  1544.                         ring1="Defending Ring",
  1545.                         ring2="Gelatinous Ring +1",
  1546.                         back="Umbra Cape",
  1547.                         waist="Flume Belt +1",
  1548.                         legs="Iuitl Tights +1",
  1549.                         feet="Iuitl Gaiters +1"})
  1550.         else
  1551.         if not midaction() then
  1552.                 status_change(player.status)
  1553.                 end
  1554.         end
  1555. end
  1556.  
  1557.  
  1558.         -------------------------------------------------------------------------------------
  1559.         -- In Game: //gs c (command), Macro: /console gs c (command), Bind: gs c (command) --
  1560.         -------------------------------------------------------------------------------------
  1561.        
  1562. function self_command(command)
  1563.         if command == 'C1' then -- Accuracy Level Toggle --
  1564.                 AccIndex = (AccIndex % #AccArray) + 1
  1565.                 add_to_chat(158,'Accuracy Level: ' .. AccArray[AccIndex])
  1566.                 status_change(player.status)
  1567.         elseif command == 'C17' then -- DW Toggle --
  1568.                 WeaponIndex = (WeaponIndex % #WeaponArray) + 1
  1569.                 add_to_chat(158,'Dual Wield: '..WeaponArray[WeaponIndex])
  1570.                 status_change(player.status)
  1571.         elseif command == 'C5' then -- Auto Update Gear Toggle --
  1572.                 status_change(player.status)
  1573.                 add_to_chat(158,'Auto Update Gear')
  1574.         elseif command == 'C2' then -- Hybrid Toggle --
  1575.                 if Armor == 'Hybrid' then
  1576.                         Armor = 'None'
  1577.                         add_to_chat(123,'Hybrid Set: [Unlocked]')
  1578.                 else
  1579.                         Armor = 'Hybrid'
  1580.                         add_to_chat(158,'Hybrid Set: '..AccArray[AccIndex])
  1581.                 end
  1582.                 status_change(player.status)
  1583.         elseif command == 'C7' then -- PDT Toggle --
  1584.                 if Armor == 'PDT' then
  1585.                         Armor = 'None'
  1586.                         add_to_chat(123,'PDT Set: [Unlocked]')
  1587.                 else
  1588.                         Armor = 'PDT'
  1589.                         add_to_chat(158,'PDT Set: [Locked]')
  1590.                 end
  1591.                 status_change(player.status)
  1592.         elseif command == 'C15' then -- MDT Toggle --
  1593.                 if Armor == 'MDT' then
  1594.                         Armor = 'None'
  1595.                         add_to_chat(123,'MDT Set: [Unlocked]')
  1596.                 else
  1597.                         Armor = 'MDT'
  1598.                         add_to_chat(158,'MDT Set: [Locked]')
  1599.                 end
  1600.                 status_change(player.status)
  1601.         elseif command == 'C12' then -- Kiting Toggle --
  1602.                 if Armor == 'Kiting' then
  1603.                         Armor = 'None'
  1604.                         add_to_chat(123,'Kiting Set: [Unlocked]')
  1605.                 else
  1606.                         Armor = 'Kiting'
  1607.                         add_to_chat(158,'Kiting Set: [Locked]')
  1608.                 end
  1609.                 status_change(player.status)
  1610.         elseif command == 'C16' then -- Thaumas Coat Toggle --
  1611.                 if Thaumas == 'ON' then
  1612.                         Thaumas = 'OFF'
  1613.                         add_to_chat(123,'Thaumas Coat: [OFF]')
  1614.         else
  1615.                         Thaumas = 'ON'
  1616.                         add_to_chat(158,'Thaumas Coat: [ON]')
  1617.         end
  1618.         elseif command == 'C18' then -- Magic Burst Toggle --
  1619.                 if MB == 'ON' then
  1620.                         MB = 'OFF'
  1621.                         add_to_chat(123,'Magic Burst: [OFF]')
  1622.         else
  1623.                         MB = 'ON'
  1624.                         add_to_chat(158,'Maic Burst: [ON]')
  1625.         end
  1626.                 status_change(player.status)
  1627.         elseif command == 'C8' then -- Distance Toggle --
  1628.                 if player.target.distance then
  1629.                         target_distance = math.floor(player.target.distance*10)/10
  1630.                         add_to_chat(158,'Distance: '..target_distance)
  1631.         else
  1632.                         add_to_chat(123,'No Target Selected')
  1633.         end
  1634.         elseif command == 'C6' then -- Idle Toggle --
  1635.                 IdleIndex = (IdleIndex % #IdleArray) + 1
  1636.                 add_to_chat(158,'Idle Set: ' .. IdleArray[IdleIndex])
  1637.                 status_change(player.status)
  1638.         elseif command == 'TP' then
  1639.                 add_to_chat(158,'TP Return: ['..tostring(player.tp)..']')
  1640.         elseif command:match('^SC%d$') then
  1641.                 send_command('//' .. sc_map[command])
  1642.         end
  1643.        
  1644. end
  1645.         -----------
  1646.         -- Misc. --
  1647.         -----------
  1648.        
  1649. function actualCost(originalCost)
  1650.         if buffactive["Penury"] then
  1651.                 return originalCost*.5
  1652.         elseif buffactive["Light Arts"] then
  1653.                 return originalCost*.9
  1654.         else
  1655.                 return originalCost
  1656.         end
  1657. end
  1658.  
  1659. function degrade_spell(spell,degrade_array)
  1660.         spell_index = table.find(degrade_array,spell.name)
  1661.         if spell_index>1 then
  1662.                 new_spell = degrade_array[spell_index - 1]
  1663.                 change_spell(new_spell,spell.target.raw)
  1664.                 add_to_chat(8,spell.name..' Canceled: ['..player.mp..'/'..player.max_mp..'MP::'..player.mpp..'%] Casting '..new_spell..' instead.')
  1665.         end
  1666. end
  1667.  
  1668. function find_player_in_alliance(name)
  1669.     for i,v in ipairs(alliance) do
  1670.         for k,p in ipairs(v) do
  1671.             if p.name == name then
  1672.                 return p
  1673.             end
  1674.         end
  1675.     end
  1676. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement