Advertisement
ErC8D

GS_SAM v2

Jun 14th, 2014
3,054
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 26.25 KB | None | 0 0
  1. --Gearswap file for Samurai(FFXI) by meh(01/Zerowone/ERC8D)
  2.  
  3. --Gearset advice and TP layout approach advised by Bismarck.Keityan
  4. --Also thanks to Lakshmi.Jassik for crunching out TP returns because I am lazy.
  5. --The update on 06/17/14 made  Jassiks math (pre update values) not so accurate. ^_^
  6.  
  7. --Highly recommend reviewing gearsets and replacing with personal items.
  8.  
  9. --Also recommend changing key bind keys since everyone's keyboard and play style are different. ^ = CTRL, != ALT.
  10.  
  11. function get_sets()
  12.  
  13. --KeyBinds for toggle commands found in self_command function
  14. --F9-(Standard) TPset1,TPset2, TPset3, TPset4
  15. --F10-(Accuracy) TPAcc1, TPAcc2
  16. --F11-(Melee Accuracy WS) Standard,Accuracy,
  17. --F12-(DT) Melee Hybrid, MDEF
  18.  
  19.  
  20. --ALT+F10 -(Ranged TP) Reg, Acc, HiAcc
  21. --ALT+F11-(Ranged WS) Reg, Acc, HiAcc
  22. --ALT+F12- Turtle+Kite(Danzo+PDT set)&(Danzo+MDT set)
  23.  
  24.     send_command('bind f9 gs c toggle TP set')
  25.     send_command('bind f10 gs c toggle Acc set')
  26.     send_command('bind f11 gs c toggle WeaponSkill sets')
  27.     send_command('bind f12 gs c toggle DT set')
  28.  
  29.     send_command('bind !f10 gs c toggle RA set')
  30.     send_command('bind !f11 gs c toggle RA WS sets')
  31.     send_command('bind !f12 gs c toggle DTKite set')
  32.  
  33. --CTR+F9 (Toggles Berserker's Torque on and off)
  34. --CTRL+F10 (Toggles Twilight Armor on and off)
  35.  
  36.     send_command('bind ^f9 gs c toggle BerT set')  
  37.     send_command('bind ^f10 gs c toggle Twi set')  
  38.        
  39. --CTRL+F12 -(Fillmode Toggle)
  40.     send_command('bind ^f12 input //fillmode')
  41.  
  42. -- Windower Keybinds for Job Abilities.
  43. --ctrl+` = Hasso
  44. --alt+` = Seigan
  45.  
  46.     send_command('bind ^` input /ja Hasso <me>')
  47.     send_command('bind !` input /ja Seigan <me>')
  48.  
  49. function file_unload()
  50.    
  51.     send_command('unbind f9')
  52.     send_command('unbind f10')
  53.     send_command('unbind f11')
  54.     send_command('unbind f12')
  55.  
  56.     send_command('unbind !f10')
  57.     send_command('unbind !f11')
  58.     send_command('unbind !f12')
  59.    
  60.     send_command('unbind ^`')
  61.     send_command('unbind !`')
  62.    
  63.     send_command('unbind ^f9')
  64.     send_command('unbind ^f12')
  65.  
  66. end
  67.    
  68. --Job Ability sets for Precast and Midcast Functions--
  69.    
  70. sets.JA = {}
  71.         sets.JA['Meikyo Shisui'] = {feet="Sakonji Sune-Ate +1"}
  72.         sets.JA['Third Eye'] = {legs="Sakonji Haidate +1"}
  73.         sets.JA['Hasso'] = {hands="Wakido Kote +1"}
  74.         sets.JA['Meditate'] = {head="Wakido Kabuto +1",hands="Sakonji Kote"}
  75.         sets.JA['Shikikoyo'] = {legs="Sakonji Haidate +1"}
  76.         sets.JA['Blade Bash'] = {hands="Sakonji Kote"}
  77.         sets.JA['Sengikori'] = {feet="Unkai Sune-Ate +2"}
  78.         sets.JA['Sekkanoki'] = {hands="Unkai Kote +2"}
  79.         sets.JA['Seigan'] = {legs="Sakonji Haidate +1"}
  80.  
  81.  
  82. --TP Sets--
  83.  
  84. --As Monday 06/16/14 TP values will have to be slightly adjusted due to new TP UI.
  85.  
  86. -- Anahera Blade = 494 Delay (if using Lentus Grip = 518.7 Delay). Ideal to have 52-53 STP in gear to 4 hit
  87.  
  88. -- Tsurumaru & Kogarasumaru = 450 Delay (if using Lentus Grip = 472.5 Delay)
  89.  
  90. -- Tsurumaru : With Ionis ideal to have + 49 STP in gear
  91. -- Kogarasumaru: Ideal to have +36 STP in gear to 5 hit
  92.  
  93. -- Amanomurakumo & Masamune = 437 Delay (if using Lentus Grip = 458.85)
  94.  
  95. -- Amanomurakumo: Ideal to have +44 STP in gear to 5 hit
  96. -- Masamune: Ideal to have +44 STP in gear to 5 hit
  97.  
  98. --Range and Ammo slots do not need to be defined as long as the user preferred weapon and ammo are already equipped--
  99. --Assuming user is using either Cibitshavore Path C or Yoichinoyumi as ranged weapon--
  100.  
  101. sets.TP = {}
  102. sets.TP.index = {'TP1','TP2','TP3','TP4','Acc1','Acc2','PDT','MDT','DTK','MDK'}
  103. TP_Index = 1
  104.  
  105. --65 STP
  106. sets.TP.TP1 = {head="Sakonji Kabuto +1",neck="Ganesha's Mala",ear1="Tripudio Earring",ear2="Brutal Earring",
  107.            body="Sakonji Domaru +1",hands="Wakido Kote +1",ring1="Rajas Ring",ring2="K'ayres Ring",
  108.            back="Takaha Mantle",waist="Goading Belt",legs="Wakido Haidate +1",feet="Otronif Boots +1"}
  109.  
  110. --58 STP               
  111. sets.TP.TP2 = set_combine(sets.TP.TP1,{waist="Windbuffet Belt"})
  112.  
  113. --53 STP
  114. sets.TP.TP3 = set_combine(sets.TP.TP2,{feet={"Otronif Boots +1",augments={"DA +2"}}})
  115.  
  116. --47 STP
  117. sets.TP.TP4 = set_combine(sets.TP.TP3,{ear1="Trux Earring"})
  118.  
  119. --37 STP
  120. sets.TP.Acc1 = {head="Yaoyotl Helm",neck="Iqabi Necklace",ear1="Steelflash Earring",ear2="Bladeborn Earring",
  121.             body="Mes'yohi Haubergeon",hands="Wakido Kote +1",ring1="Rajas Ring",ring2="K'ayres Ring",
  122.         back="Takaha Mantle",waist="Dynamic Belt +1",legs={"Otronif Brais +1",augments={"Accuracy +8"}},
  123.         feet="Wakido Sune-Ate +1"}
  124.  
  125. --21 STP                 
  126. sets.TP.Acc2 = set_combine(sets.TP.Acc1,{ring1="Mars's Ring",ring2="Patricius Ring",legs="Xaddi Cuisses"})             
  127.  
  128.  
  129. sets.TP.PDT = {head="Lithelimb Cap",neck="Agitator's Collar",ear1="Steelflash Earring",ear2="Bladeborn Earring",
  130.            body="Otronif Harness +1",hands="Wakido Kote +1",ring1="Defending Ring",ring2="Patricius Ring",
  131.            back="Shadow Mantle",waist="Flume Belt",legs="Xaddi Cuisses",feet="Otronif Boots +1"}
  132.  
  133. sets.TP.MDT = {head="Lithelimb Cap",neck="Twilight Torque",ear1="Sanare Earring",ear2="Mujin Stud",
  134.            body="Otronif Harness +1",hands="Wakido Kote +1",ring1="Defending Ring",ring2="Shadow Ring",
  135.            back="Engulfer Cape",belt="Flume Belt",legs="Otronif Brais +1",feet="Otronif Boots +1"}
  136.  
  137. sets.TP.DTK = set_combine(sets.TP.PDT,{feet="Danzo Sune-Ate"})
  138.  
  139. sets.TP.MDK = set_combine(sets.TP.MDT,{feet="Danzo Sune-Ate"})
  140.  
  141.  
  142. --Range TP--
  143. sets.Utility = {}
  144.  
  145. sets.Utility.Snapshot = {head="Zha'Go's Barbut",neck="Iqabi Necklace",ear1="Clearview Earring",ear2="Matanki Earring",
  146.          body="Nuevo Coselete",hands="Unkai Kote +2",ring1="Hajduk Ring +1",ring2="Hajduk Ring +1",
  147.          back="Jaeger Mantle",waist="Buccaneer's Belt",legs="Mustela Brais",feet="Wakido Sune-Ate +1"}
  148.  
  149. sets.RA = {}
  150. sets.RA.index = {'Reg','Acc','HiAcc'}
  151. RA_Index = 1
  152.  
  153. sets.RA.Reg = {head="Sakonji Kabuto +1",neck="Iqabi Necklace",ear1="Clearview Earring",ear2="Matanki Earring",
  154.            body="Kyujutsugi",hands="Unkai Kote +2",ring1="Rajas Ring",ring2="Hajduk Ring +1",  
  155.            back="Thall Mantle",waist="Buccaneer's Belt",legs="Wakido Haidate",feet="Wakido Sune-Ate +1"}
  156.  
  157. sets.RA.Acc = set_combine(sets.RA.Reg,{ring1="Hajduk Ring +1",legs="Wakido Haidate +1"})
  158.  
  159. sets.RA.HiAcc = set_combine(sets.RA.Acc,{hands="Buremte Gloves",back="Jaeger Mantle",legs="Aetosaur Trousers +1"})
  160.  
  161.  
  162. --Weaponskill Sets--
  163.  
  164. --As of Monday 06/16/14, the Majority of Great Katana Weaponskills are modified by STR
  165. --Weaponskill Sets--
  166.         sets.WS = {}
  167.         sets.WS.index = {'Reg','Acc'}
  168.         WS_Index = 1
  169.        
  170.         sets.WS.Reg = {range="Cibitshavore",
  171.                    head="Otomi helm",neck="Asperity Necklace",ear1="Moonshade earring",ear2="Brutal earring",
  172.                    body="Phorcys Korazin",hands="Boor Bracelets",ring1="Rajas ring",ring2="Ifrit Ring",
  173.                    back="Buquwik cape",waist="Windbuffet Belt",legs="Scuffler's Cosciales",feet="Sak. Sune-Ate +1"}
  174.                    
  175.         sets.WS.Acc = {range="Cibitshavore",
  176.                    head="Yaoyotl helm",neck="Iqabi Necklace",ear1="Moonshade earring",ear2="Brutal earring",
  177.                    body="Sakonji Domaru +1",hands="Boor Bracelets",ring1="Rajas ring",ring2="Ifrit Ring",
  178.                    back="Takaha Mantle",waist="Anguinus Belt",legs="Wakido haidate +1",feet="Ejekamal Boots"}
  179.        
  180.         sets.WS.Sek = set_combine(sets.WS.Reg,{hands="Unkai Kote +2"})
  181.         sets.WS.Sen = set_combine(sets.WS.Reg,{feet="Unkai Sune-Ate +2"})
  182.         sets.WS.R = set_combine(sets.WS.Reg,{neck="Ygnas's Resolve +1"})
  183.         sets.WS.GH = set_combine(sets.WS.Reg,{head="Gavialis Helm"})
  184.  
  185.        
  186.         --Tachi: Shoha--
  187.         sets.Shoha = {}
  188.         sets.Shoha.index = {'Reg','Acc'}
  189.         Shoha_Index = 1
  190.    
  191.         sets.Shoha.Reg = {range="Cibitshavore",
  192.                   head="Otomi helm",neck="Breeze Gorget",ear1="Moonshade earring",ear2="Brutal earring",
  193.                   body="Sakonji Domaru +1",hands="Miki. Gauntlets",ring1="Rajas Ring",ring2="Pyrosoul Ring",
  194.                   back="Atheling Mantle",waist="Windbuffet belt",legs="Scuffler's Cosciales",feet="Sak. Sune-Ate +1"}
  195.                                  
  196.         sets.Shoha.Acc = {range="Cibitshavore",
  197.                   head="Yaoyotl helm",neck="Breeze Gorget",ear1="Moonshade earring",ear2="Brutal earring",
  198.                   body="Sakonji Domaru +1",hands="Miki. Gauntlets",ring1="Rajas Ring",ring2="Pyrosoul Ring",
  199.                   back="Takaha Mantle",waist="Windbuffet belt",legs="Miki. Cuisses",feet="Ejekamal Boots"}
  200.        
  201.         sets.Shoha.Sek = set_combine(sets.Shoha.Reg,{hands="Unkai Kote +2"})
  202.         sets.Shoha.Sen = set_combine(sets.Shoha.Reg,{feet="Unkai Sune-Ate +2"})
  203.         sets.Shoha.R = set_combine(sets.Shoha.Reg,{neck="Ygnas's Resolve +1"})
  204.         sets.Shoha.GH = set_combine(sets.Shoha.Reg,{head="Gavialis Helm"})     
  205.  
  206.  
  207.         --Tachi: Fudo/Tachi: Kaiten--
  208.        
  209.         sets.Fudo = {}
  210.         sets.Fudo.index = {'Reg','Acc'}
  211.         Fudo_Index = 1
  212.    
  213.         sets.Fudo.Reg = {range="Cibitshavore",
  214.                  head="Otomi helm",neck="Light Gorget",ear1="Moonshade earring",ear2="Brutal earring",
  215.                  body="Sakonji Domaru +1",hands="Miki. Gauntlets",ring1="Ifrit ring",ring2="Ifrit Ring",
  216.                  back="Buquwik cape",waist="Light belt",legs="Scuffler's Cosciales",feet="Sak. Sune-Ate +1"}
  217.                                
  218.         sets.Fudo.Acc = {range="Cibitshavore",
  219.                  head="Yaoyotl helm",neck="Light Gorget",ear1="Moonshade earring",ear2="Brutal earring",
  220.                  body="Sakonji Domaru +1",hands="Miki. Gauntlets",ring1="Rajas ring",ring2="Pyrosoul Ring",
  221.                  back="Buquwik cape",waist="Light belt",legs="Miki. Cuisses",feet="Ejekamal Boots"}
  222.        
  223.         sets.Fudo.Sek = set_combine(sets.Fudo.Reg,{hands="Unkai Kote +2"})
  224.         sets.Fudo.Sen = set_combine(sets.Fudo.Reg,{feet="Unkai Sune-Ate +2"})
  225.         sets.Fudo.R = set_combine(sets.Fudo.Reg,{neck="Ygnas's Resolve +1"})
  226.         sets.Fudo.GH = set_combine(sets.Fudo.Reg,{head="Gavialis Helm"})       
  227.  
  228.  
  229.         --Apex Arrow--
  230.         --Range and Ammo slots do not need to be defined as long as the user preferred weapon and ammo are already equipped--
  231.  
  232.         sets.Apex = {}
  233.         sets.Apex.index = {'Reg','Acc'}
  234.         Apex_Index = 1
  235.        
  236.         sets.Apex.Reg = {range="Cibitshavore",ammo="Tulfaire Arrow",
  237.                  head="Sakonji Kabuto +1",neck="Thunder Gorget",ear1="Moonshade Earring",ear2="Breeze Pearl",
  238.                  body="Phorcys Korazin",hands="Unkai Kote +2",ring1="Stormsoul Ring",ring2="Stormsoul Ring",
  239.                  back="Ik Cape",waist="Thunder Belt",legs="Wakido Haidate +1",feet="Wakido Sune-Ate +1"}
  240.        
  241.         sets.Apex.Acc = {range="Cibitshavore",ammo="Tulfaire Arrow",
  242.                  head="Sakonji Kabuto +1",neck="Iqabi Necklace",ear1="Clearview Earring",ear2="Matanki Earring",
  243.                  body="Kyujutsugi",hands="Buremte Gloves",ring1="Hajduk Ring +1",ring2="Hajduk Ring +1",
  244.                  back="Thall Mantle",waist="Thunder Belt",legs="Aetosaur Trousers +1",feet="Wakido Sune-Ate +1"}
  245.        
  246.         sets.Apex.Sek = set_combine(sets.Apex.Reg,{hands="Unkai Kote +2"})
  247.         sets.Apex.Mei = set_combine(sets.Apex.Reg,{feet="Sakonji Sune-Ate +1"})
  248.         sets.Apex.Sen = set_combine(sets.Apex.Reg,{feet="Unkai Sune-Ate +2"})
  249.         sets.Apex.R = set_combine(sets.Apex.Reg,{neck="Ygnas's Resolve +1"})
  250.         sets.Apex.GH = set_combine(sets.Apex.Reg,{head="Gavialis Helm"})
  251.        
  252.         --Namas Arrow--
  253.         sets.Nama = {}
  254.         sets.Nama.index = {'Reg','Acc'}
  255.         Nama_Index = 1
  256.        
  257.         sets.Nama.Reg = {range="Yoichinoyumi",ammo="Tulfaire Arrow",
  258.                 head="Sakonji Kabuto +1",neck="Light Gorget",ear1="Vulcan's Pearl",ear2="Vulcan's Pearl",
  259.                 body="Phorcys Korazin",hands="Unkai Kote +2",ring1="Rajas Ring",ring2="Pyrosoul Ring",
  260.                 back="Buquwik Cape",waist="Light Gorget",legs="Wakido Haidate +1",feet="Wakido Sune-Ate +1"}
  261.                    
  262.         sets.Nama.Acc = {range="Yoichinoyumi",ammo="Tulfaire Arrow",
  263.                 head="Sakonji Kabuto +1",neck="Iqabi Necklace",ear1="Clearview Earring",ear2="Matanki Earring",
  264.                 body="Kyujutsugi",hands="Buremte Gloves",ring1="Hajduk Ring +1",ring2="Hajduk Ring +1",
  265.                 back="Thall Mantle",waist="Light Belt",legs="Aetosaur Trousers +1",feet="Wakido Sune-Ate +1"}
  266.        
  267.         sets.Nama.Sek = set_combine(sets.Nama.Reg,{hands="Unkai Kote +2"})
  268.         sets.Nama.Mei = set_combine(sets.Nama.Reg,{feet="Sakonji Sune-Ate +1"})
  269.         sets.Nama.Sen = set_combine(sets.Nama.Reg,{feet="Unkai Sune-Ate +2"})
  270.         sets.Nama.R = set_combine(sets.Nama.Reg,{neck="Ygnas's Resolve +1"})
  271.         sets.Nama.GH = set_combine(sets.Nama.Reg,{head="Gavialis Helm"})   
  272.  
  273.  
  274. --Twilight/Zombie mode--
  275.  
  276. sets.Twi = {}
  277. sets.Twi.index = {'Off','On'}
  278. Twi_Index = 1
  279.  
  280. sets.Twi.Off = sets.TP[sets.TP.index[TP_Index]]
  281. sets.Twi.On = set_combine(sets.TP[sets.TP.index[TP_Index]],{head="Twilight Helm",body="Twilight Mail"})                        
  282.                                
  283. --Berserker Torque--
  284. sets.BerT = {}
  285. sets.BerT.index = {'Off','On'}
  286. BerT_Index = 1
  287.  
  288. sets.BerT.Off = sets.TP[sets.TP.index[TP_Index]]
  289. sets.BerT.On = set_combine(sets.TP[sets.TP.index[TP_Index]],{neck="Berserker's Torque"})
  290.  
  291.                                
  292. end
  293.  
  294. --Precast Functions--
  295.  
  296. function precast(spell)
  297.     if spell.type == 'JobAbility' then
  298.         if sets.JA[spell.english] then
  299.             equip(sets.JA[spell.english])
  300.         end
  301.     end
  302.    
  303.     if spell.type == 'WeaponSkill' then
  304.         equip(sets.WS[sets.WS.index[WS_Index]])
  305.    
  306.     end
  307.    
  308.     if spell.english == "Tachi: Shoha" then
  309.         equip(sets.Shoha[sets.Shoha.index[Shoha_Index]])
  310.     end
  311.    
  312.     if spell.english == "Tachi: Kaiten" or spell.english == "Tachi: Fudo" then
  313.         equip(sets.Fudo[sets.Fudo.index[Fudo_Index]])
  314.     end
  315.  
  316.     if spell.english == "Apex Arrow" then
  317.         equip(sets.Apex[sets.Apex.index[Apex_Index]])
  318.     end
  319.    
  320.     if spell.english == "Namas Arrow" then
  321.         equip(sets.Nama[sets.Nama.index[Nama_Index]])
  322.     end
  323.    
  324.     if buffactive['Meikyo Shisui'] and spell.english == "Apex Arrow" then
  325.         equip(sets.Apex.Mei)
  326.     end
  327.  
  328.     if buffactive['Meikyo Shisui'] and spell.english == "Namas Arrow" then
  329.         equip(sets.Nama.Mei)
  330.     end
  331.    
  332.     if buffactive['Sekkanoki'] and spell.type == 'WeaponSkill' then
  333.         equip(sets.WS.Sek)
  334.     end
  335.  
  336.     if buffactive['Sekkanoki'] and spell.english == "Tachi: Shoha" then
  337.         equip(sets.Shoha.Sek)
  338.     end
  339.    
  340.     if buffactive['Sekkanoki'] and spell.english == "Tachi: Fudo" then
  341.         equip(sets.Fudo.Sek)
  342.     end
  343.  
  344.     if buffactive['Sekkanoki'] and spell.english == "Tachi: Kaiten" then
  345.         equip(sets.Fudo.Sek)
  346.     end
  347.  
  348.     if buffactive['Sekkanoki'] and spell.english == "Apex Arrow" then
  349.         equip(sets.Apex.Sek)
  350.     end
  351.  
  352.     if buffactive['Sekkanoki'] and spell.english == "Namas Arrow" then
  353.         equip(sets.Nama.Sek)
  354.     end
  355.    
  356.     if buffactive['Sengikori'] and spell.type == 'WeaponSkill' then
  357.         equip(sets.WS.Sen)
  358.     end
  359.  
  360.      if buffactive['Sengikori'] and spell.english == "Tachi: Shoha" then
  361.         equip(sets.Shoha.Sen)
  362.     end
  363.  
  364.      if buffactive['Sengikori'] and spell.english == "Tachi: Fudo" then
  365.         equip(sets.Fudo.Sen)
  366.     end
  367.  
  368.      if buffactive['Sengikori'] and spell.english == "Tachi: Kaiten" then
  369.         equip(sets.Fudo.Sen)
  370.     end
  371.  
  372.      if buffactive['Sengikori'] and spell.english == "Apex Arrow" then
  373.         equip(sets.Apex.Sen)
  374.     end
  375.  
  376.      if buffactive['Sengikori'] and spell.english == "Namas Arrow" then
  377.         equip(sets.Nama.Sen)
  378.     end
  379.  
  380.     if buffactive['Revie Mark'] and spell.type == "WeaponSkill" then
  381.         equip(sets.WS.R)
  382.     end
  383.    
  384.     if buffactive['Reive Mark'] and spell.english == "Tachi: Fudo" then
  385.         equip(sets.Fudo.R)
  386.     end
  387.    
  388.     if buffactive['Reive Mark'] and spell.english == "Tachi: Shoha" then
  389.         equip(sets.Shoha.R)
  390.     end
  391.    
  392.     if spell.english == "Tachi: Fudo" and (world.day == 'Iceday' or world.day == 'Lightsday' or world.day == 'Watersday') then
  393.         equip(sets.Fudo.GH)
  394.     end
  395.    
  396.     if spell.english == "Tachi: Rana" and (world.day == 'Iceday' or world.day == 'Darksday' or world.day == 'Earthsday') then
  397.         equip(sets.WS.GS)
  398.     end
  399.    
  400.     if spell.english == "Tachi: Kasha" and (world.day == 'Darksday' or world.day == 'Firesday' or world.day == 'Lightsday') then
  401.         equip(sets.Fudo.GH)
  402.     end
  403.    
  404.     if spell.english == "Tachi: Shoha" and (world.day == 'Darksday' or world.day == 'Windsday' or world.day == 'Lightiningday') then
  405.         equip(sets.Shoha.GH)
  406.     end
  407.  
  408.     if buffactive['Reive Mark'] and spell.english == "Apex Arrow" then
  409.         equip(sets.Apex.R)
  410.     end
  411.  
  412.     if buffactive['Reive Mark'] and spell.english == "Namas Arrow" then
  413.         equip(sets.Nama.R)
  414.     end
  415.  
  416.     if spell.english == "Apex Arrow" and (world.day == 'Windsday' or world.day == 'Lightsday' or world.day == 'Lightiningday') then
  417.         equip(sets.Apex.GH)
  418.     end
  419.  
  420.     if spell.english == "Namas Arrow" and (world.day == 'Iceday' or world.day == 'Watersday' or world.day == 'Lightsday') then
  421.         equip(sets.Namas.GH)
  422.     end
  423.  
  424.     if spell.name == "Ranged" then
  425.                 equip(sets.Utility.Snapshot)
  426.         end
  427.  
  428.  
  429. end    
  430.  
  431. --Midcast Function if using Ranged Attack to TP--
  432. --Mirror's Precast to ensure desired effects are applied--
  433.  
  434. function midcast(spell,act)
  435.     if spell.name == "Ranged" then
  436.         equip(sets.RA)
  437.     end
  438.    
  439.     if spell.type == 'JobAbility' then
  440.         if sets.JA[spell.english] then
  441.             equip(sets.JA[spell.english])
  442.         end
  443.     end
  444.    
  445.     if spell.type == 'WeaponSkill' then
  446.         equip(sets.WS[sets.WS.index[WS_Index]])
  447.     end
  448.    
  449.     if spell.english == "Tachi: Shoha" then
  450.         equip(sets.Shoha[sets.Shoha.index[Shoha_Index]])
  451.     end
  452.    
  453.     if spell.english == "Tachi: Kaiten" or spell.english == "Tachi: Fudo" then
  454.         equip(sets.Fudo[sets.Fudo.index[Fudo_Index]])
  455.     end
  456.  
  457.     if spell.english == "Apex Arrow" then
  458.         equip(sets.Apex[sets.Apex.index[Apex_Index]])
  459.     end
  460.    
  461.     if spell.english == "Namas Arrow" then
  462.         equip(sets.Nama[sets.Nama.index[Nama_Index]])
  463.     end
  464.    
  465.     if buffactive['Meikyo Shisui'] and spell.english == "Apex Arrow" then
  466.         equip(sets.Apex.Mei)
  467.     end
  468.  
  469.     if buffactive['Meikyo Shisui'] and spell.english == "Namas Arrow" then
  470.         equip(sets.Nama.Mei)
  471.     end
  472.    
  473.     if buffactive['Sekkanoki'] and spell.type == 'WeaponSkill' then
  474.         equip(sets.WS.Sek)
  475.     end
  476.  
  477.     if buffactive['Sekkanoki'] and spell.english == "Tachi: Shoha" then
  478.         equip(sets.Shoha.Sek)
  479.     end
  480.    
  481.     if buffactive['Sekkanoki'] and spell.english == "Tachi: Fudo" then
  482.         equip(sets.Fudo.Sek)
  483.     end
  484.  
  485.     if buffactive['Sekkanoki'] and spell.english == "Tachi: Kaiten" then
  486.         equip(sets.Fudo.Sek)
  487.     end
  488.  
  489.     if buffactive['Sekkanoki'] and spell.english == "Apex Arrow" then
  490.         equip(sets.Apex.Sek)
  491.     end
  492.  
  493.     if buffactive['Sekkanoki'] and spell.english == "Namas Arrow" then
  494.         equip(sets.Nama.Sek)
  495.     end
  496.    
  497.     if buffactive['Sengikori'] and spell.type == 'WeaponSkill' then
  498.         equip(sets.WS.Sen)
  499.     end
  500.  
  501.      if buffactive['Sengikori'] and spell.english == "Tachi: Shoha" then
  502.         equip(sets.Shoha.Sen)
  503.     end
  504.  
  505.      if buffactive['Sengikori'] and spell.english == "Tachi: Fudo" then
  506.         equip(sets.Fudo.Sen)
  507.     end
  508.  
  509.      if buffactive['Sengikori'] and spell.english == "Tachi: Kaiten" then
  510.         equip(sets.Fudo.Sen)
  511.     end
  512.  
  513.      if buffactive['Sengikori'] and spell.english == "Apex Arrow" then
  514.         equip(sets.Apex.Sen)
  515.     end
  516.  
  517.      if buffactive['Sengikori'] and spell.english == "Namas Arrow" then
  518.         equip(sets.Nama.Sen)
  519.     end
  520. if buffactive['Revie Mark'] and spell.type == "WeaponSkill" then
  521.         equip(sets.WS.R)
  522.     end
  523.    
  524.     if buffactive['Reive Mark'] and spell.english == "Tachi: Fudo" then
  525.         equip(sets.Fudo.R)
  526.     end
  527.    
  528.     if buffactive['Reive Mark'] and spell.english == "Tachi: Shoha" then
  529.         equip(sets.Shoha.R)
  530.     end
  531.    
  532.     if spell.english == "Tachi: Fudo" and (world.day == 'Iceday' or world.day == 'Lightsday' or world.day == 'Watersday') then
  533.         equip(sets.Fudo.GH)
  534.     end
  535.    
  536.     if spell.english == "Tachi: Rana" and (world.day == 'Iceday' or world.day == 'Darksday' or world.day == 'Earthsday') then
  537.         equip(sets.WS.GS)
  538.     end
  539.    
  540.     if spell.english == "Tachi: Kasha" and (world.day == 'Darksday' or world.day == 'Firesday' or world.day == 'Lightsday') then
  541.         equip(sets.Fudo.GH)
  542.     end
  543.    
  544.     if spell.english == "Tachi: Shoha" and (world.day == 'Darksday' or world.day == 'Windsday' or world.day == 'Lightiningday') then
  545.         equip(sets.Shoha.GH)
  546.     end
  547.  
  548.     if buffactive['Reive Mark'] and spell.english == "Apex Arrow" then
  549.         equip(sets.Apex.R)
  550.     end
  551.  
  552.     if buffactive['Reive Mark'] and spell.english == "Namas Arrow" then
  553.         equip(sets.Nama.R)
  554.     end
  555.  
  556.     if spell.english == "Apex Arrow" and (world.day == 'Windsday' or world.day == 'Lightsday' or world.day == 'Lightiningday') then
  557.         equip(sets.Apex.GH)
  558.     end
  559.  
  560.     if spell.english == "Namas Arrow" and (world.day == 'Iceday' or world.day == 'Watersday' or world.day == 'Lightsday') then
  561.         equip(sets.Namas.GH)
  562.     end
  563. end
  564.  
  565. function aftercast(spell,act)
  566.    
  567.     if player.status == 'Engaged' and buffactive['Sekkanoki'] then
  568.         equip(sets.JA['Sekkanoki'])
  569.     elseif player.status == 'Engaged' then
  570.         equip(sets.TP[sets.TP.index[TP_Index]])
  571.     end
  572.  
  573.     if player.status == 'Engaged' and buffactive['Meikyo Shisui'] then
  574.         equip(sets.JA['Meikyo Shisui'])
  575.     elseif player.status == 'Engaged' then
  576.         equip(sets.TP[sets.TP.index[TP_Index]])
  577.     end
  578.    
  579.     if player.status == 'Engaged' and buffactive['Sengikori'] then
  580.         equip(sets.JA['Sengikori'])
  581.     elseif player.status == 'Engaged' then
  582.         equip(sets.TP[sets.TP.index[TP_Index]])
  583.     end
  584.  
  585.     if player.status == 'Engaged' and (buffactive['Seigan'] or buffactive['Third Eye']) then
  586.         equip(sets.JA['Seigan'])
  587.     elseif player.status == 'Engaged' then
  588.         equip(sets.TP[sets.TP.index[TP_Index]])
  589.     end
  590.  
  591.     if player.status == 'Engaged' and buffactive['Reive Mark'] then
  592.                 equip{neck="Ygnas's Resolve +1"}
  593.         end
  594. end
  595.  
  596. function buff_change(new)
  597.  
  598.     if buffactive['Sekkanoki'] then
  599.         equip{hands="Unkai Kote +2"}
  600.     end
  601.    
  602.     if buffactive['Meikyo Shisui'] then
  603.         equip{feet="Sakonji Sune-Ate +1"}
  604.     end
  605.    
  606.     if buffactive['Sengikori'] then
  607.         equip{feet="Unkai Sune-Ate +2"}
  608.     end
  609.        
  610.     if buffactive['Third Eye'] or buffactive['Seigan'] then
  611.         equip{legs="Sakonji Haidate +1"}
  612.     end
  613.  
  614.     if player.status == 'Engaged' and buffactive['Reive Mark'] then
  615.                 equip{neck="Ygnas's Resolve +1"}
  616.         end
  617. end
  618.  
  619.  
  620. function status_change(new,old)
  621.     if new == 'Engaged' then
  622.         equip(sets.TP[sets.TP.index[TP_Index]])
  623.     end
  624.  
  625. --Shouldn't really be needed but if it does arise that you have Sekkanoki active and a fodder mob dies before Weaponskill this will keep Unkai on.     
  626.     if buffactive['Sekkanoki'] and new == 'Engaged' then
  627.         equip{hands="Unkai Kote +2"}
  628.     end
  629.    
  630.     if buffactive['Meikyo Shisui'] and new == 'Engaged' then
  631.         equip{feet="Sakonji Sune-Ate +1"}
  632.     end
  633.    
  634.      if buffactive['Sengikori'] and new == 'Engaged' then
  635.                 equip{feet="Unkai Sune-Ate +2"}
  636.         end
  637.  
  638.     if buffactive['Third Eye'] or buffactive['Seigan'] and new == 'Engaged' then
  639.         equip{feet="Sakonji Haidate +1"}
  640.     end    
  641.  
  642.     if player.status == 'Engaged' and buffactive['Reive Mark'] then
  643.                 equip{neck="Ygnas's Resolve +1"}
  644.         end
  645. end
  646.  
  647.  
  648. --Toggle Command functions--
  649. --Gearswap direct command = //gs c toggle 'x' set
  650. --Macro line = /console gs c toggle x set
  651. --ex: console gs c toggle TP set  or //gs c toggle TP set
  652.    
  653.  
  654. function self_command(command)
  655.  
  656. --Separate Toggles to allow user flexibility
  657.  
  658. --Macro line: /console gs c toggle TP set
  659. --Chat line: //gs c toggle TP set
  660. --Toggles between TP1, TP2, TP3, TP4 sets
  661.  
  662. if command == 'toggle TP set' then
  663.         if TP_Index < 4 then
  664.         TP_Index = TP_Index +1
  665.         else TP_Index = 1 end
  666.         send_command('@ input /echo >>> TP Sets Changed to: '..sets.TP.index[TP_Index]..' ')
  667.         equip(sets.TP[sets.TP.index[TP_Index]])
  668.        
  669. --Macro line: /console gs c toggle dTP set
  670. --Chat line: //gs c toggle dTP set
  671. --Toggles down the index from TP4,TP3,TP2,TP1      
  672. elseif command == 'toggle dTP set' then
  673.         if TP_Index < 5 and TP_Index > 1 then
  674.         TP_Index = TP_Index -1
  675.         else TP_Index = 4 end
  676.         send_command('@ input /echo >>> TP Sets Changed to: '..sets.TP.index[TP_Index]..' ')
  677.         equip(sets.TP[sets.TP.index[TP_Index]])
  678.  
  679.  
  680. --Macro line: /console gs c toggle Acc set
  681. --Chat line: //gs c toggle Acc set
  682. --Toggles between Acc1 and Acc2 sets.
  683.     elseif command == 'toggle Acc set' then
  684.         if TP_Index < 6 and TP_Index > 4 then
  685.         TP_Index = TP_Index +1
  686.         else TP_Index = 5 end
  687.         send_command('@ input /echo >>> TP Sets Changed to: '..sets.TP.index[TP_Index]..' ')
  688.         equip(sets.TP[sets.TP.index[TP_Index]])
  689.        
  690. --Macro line: /console gs c toggle DT set
  691. --Chat line: //gs c toggle DT set      
  692. --Toggles between PDT and MDT sets
  693.    
  694.     elseif command == 'toggle DT set' then
  695.         if TP_Index < 8 and TP_Index > 6 then
  696.         TP_Index = TP_Index +1
  697.         else TP_Index = 7 end
  698.         send_command('@ input /echo >>> DT Set Changed to: '..sets.TP.index[TP_Index]..' ')
  699.         equip(sets.TP[sets.TP.index[TP_Index]])
  700.    
  701. --Macro line: /console gs c toggle DTKite set
  702. --Chat line: //gs c toggle DTKite set
  703. --Toggles between the PDT/MDT Kite sets
  704.  
  705.     elseif command == 'toggle DTKite set' then
  706.         if TP_Index < 10 and TP_Index > 8 then
  707.         TP_Index = TP_Index +1
  708.         else TP_Index = 9 end
  709.         send_command('@ input /echo >>> DTKite Set Changed to: '..sets.TP.index[TP_Index]..' ')
  710.         equip(sets.TP[sets.TP.index[TP_Index]])
  711.        
  712. --Macro line: /console gs c toggle Twi set
  713. --Chat line: //gs c toggle Twi set
  714. --Toggles on Twilight Mail and Helm on and off.
  715.  
  716.     elseif command == 'toggle Twi set' then
  717.         Twi_Index = Twi_Index +1
  718.         if Twi_Index > #sets.Twi.index then Twi_Index = 1 end
  719.         send_command('@ input /echo >>> Twilight Set: '..sets.Twi.index[Twi_Index]..' ')
  720.         equip(sets.Twi[sets.Twi.index[Twi_Index]])
  721.        
  722. --Macro line: /console gs c toggle BerT set
  723. --Chat line: //gs c toggle BerT set
  724. --Toggles Berserker Torque on and off.
  725.        
  726.     elseif command == 'toggle BerT set' then
  727.         BerT_Index = BerT_Index +1
  728.         if BerT_Index > #sets.BerT.index then BerT_Index = 1 end
  729.         send_command('@ input /echo >>> Berserker Torque: '..sets.BerT.index[BerT_Index]..' ')
  730.         equip(sets.BerT[sets.BerT.index[BerT_Index]])
  731.        
  732.        
  733. --All Weaponskill sets are set to the "Reg" gear set by default, switching to "Acc" is hardly needed, but the option is nice to have.
  734.  
  735. --Macro line: /console gs c toggle WeaponSkill set
  736. --Chat line: //gs c toggle WeaponSkill set
  737. --Changes all Melee Weaponskill Indicies at once.
  738.     elseif command == 'toggle WeaponSkill sets' then
  739.         WS_Index = WS_Index +1
  740.         if WS_Index > #sets.WS.index then WS_Index = 1 end
  741.         Shoha_Index = Shoha_Index +1
  742.         if Shoha_Index > #sets.Shoha.index then Shoha_Index = 1 end
  743.         Fudo_Index = Fudo_Index +1
  744.         if Fudo_Index > #sets.Fudo.index then Fudo_Index = 1 end
  745.         Kaiten_Index = Kaiten_Index +1
  746.         if Kaiten_Index > #sets.Kaiten.index then Kaiten_Index = 1 end
  747.         send_command('@input /echo >>> All Melee WeaponSkill Sets Changed to: '..sets.WS.index[WS_Index]..' ')
  748.    
  749. --Macro line: /console gs c toggle RA WS sets
  750. --Chat line: /gs c toggle RA WS sets
  751. --Changes defined RA sets, assuming user will only be using Apex and Namas Arrow(s).
  752.  
  753.  
  754.     elseif command == 'toggle RA WS sets' then
  755.         Apex_Index = Apex_Index +1
  756.         if Apex_Index > #sets.Apex.index then Apex_Index = 1 end
  757.         Nama_Index = Nama_Index +1
  758.         if Nama_Index > #sets.Nama.index then Nama_Index = 1 end
  759.         send_command('@input /echo >>> All Ranged WS Sets Changed to: '..sets.Nama.index[Nama_Index]..' ')
  760.        
  761.     elseif command == 'toggle RA set' then
  762.         RA_Index = RA_Index +1
  763.         if RA_Index > #sets.RA.index then RA_Index = 1 end
  764.         send_command('@input /echo >>> Ranged TP Set Changed to: '..sets.RA.index[RA_Index]..' ')
  765.         end
  766.     end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement