Advertisement
Guest User

Untitled

a guest
Dec 10th, 2014
213
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 7.95 KB | None | 0 0
  1. function get_sets()
  2. -- Variables
  3. idletype="maxmp"
  4. fakesongs = S{"Army's Paeon", "Goblin Gavotte"}
  5. -- Sets begin
  6. sets.music = {}
  7.     sets.music.prebuff ={
  8.         main="Felibre's Dague",
  9.         sub="Genbu's Shield",
  10.         range="Pan's Horn",
  11.         head="Aoidos' Calot +2",
  12.         body="Yigit Gomlek",
  13.         hands="Schellenband",
  14.         legs="Aoidos' Rhing. +2",
  15.         feet="Rostrum Pumps",
  16.         neck="Aoidos' Matinee",
  17.         waist="Aoidos' Belt",
  18.         left_ear="Aoidos' Earring",
  19.         right_ear="Loquac. Earring",
  20.         left_ring="Trumpet Ring",
  21.         right_ring="Nereid Ring",
  22.         back="Balladeer's Cape"
  23.     }
  24.     sets.music.midbuff={
  25.         main="Felibre's Dague",
  26.         sub="Genbu's Shield",
  27.         range="Pan's Horn",
  28.         head="Aoidos' Calot +2",
  29.         body="Aoidos' Hngrln. +2",
  30.         hands="Ad. Mnchtte. +2",
  31.         legs="Aoidos' Rhing. +2",
  32.         feet="Aoidos' Cothrn. +2",
  33.         neck="Aoidos' Matinee",
  34.         waist="Aoidos' Belt",
  35.         left_ear="Aoidos' Earring",
  36.         right_ear="Musical Earring",
  37.         left_ring="Trumpet Ring",
  38.         right_ring="Nereid Ring",
  39.         back="Balladeer's Cape"
  40.     }
  41.     sets.music.fakesongs={
  42.         main="Chatoyant Staff",
  43.         sub="Bugard Strap +1",
  44.         range="Pan's Horn",
  45.         head="Wivre Hairpin",
  46.         body="Yigit Gomlek",
  47.         hands="Serpentes Cuffs",
  48.         legs="Sagacity Lappas",
  49.         feet="Serpentes Sabots",
  50.         neck="Phalaina Locket",
  51.         waist="Aoidos' Belt",
  52.         left_ear="Influx Earring",
  53.         right_ear="Gifted Earring",
  54.         left_ring="Bifrost Ring",
  55.         right_ring="Ether Ring",
  56.         back="Felicitas Cape"
  57.     }
  58.     sets.music.enfeeb={
  59.         main="Chatoyant Staff",
  60.         sub="Quire Grip",
  61.         range="Pan's Horn",
  62.         head="Nahtirah Hat",
  63.         body="Aoidos' Hngrln. +2",
  64.         hands="Ad. Mnchtte. +2",
  65.         legs="Aoidos' Rhing. +2",
  66.         feet="Aoidos' Cothrn. +2",
  67.         neck="Wind Torque",
  68.         waist="Aoidos' Belt",
  69.         left_ear="Aoidos' Earring",
  70.         right_ear="Musical Earring",
  71.         left_ring="Omega Ring",
  72.         right_ring="Perception Ring",
  73.         back="Mesmeric Cape"
  74.     }
  75.     sets.music.maxmp={
  76.         main="Chatoyant Staff",
  77.         sub="Bugard Strap +1",
  78.         range="Pan's Horn",
  79.         head="Wivre Hairpin",
  80.         body="Augur's Jaseran",
  81.         hands="Serpentes Cuffs",
  82.         legs="Sagacity Lappas",
  83.         feet="Serpentes Sabots",
  84.         neck="Dualism Collar",
  85.         waist="Aoidos' Belt",
  86.         left_ear="Influx Earring",
  87.         right_ear="Gifted Earring",
  88.         left_ring="Bifrost Ring",
  89.         right_ring="Ether Ring",
  90.         back="Balladeer's Cape"
  91.     }
  92.     sets.music.curepot={
  93.         main="Chatoyant Staff",
  94.         sub="Quire Grip",
  95.         range="Pan's Horn",
  96.         body="Augur's Jaseran",
  97.         hands="Serpentes Cuffs",
  98.         feet="Serpentes Sabots",
  99.         neck="Phalaina Locket",
  100.         left_ear="Loquac. Earring",
  101.         right_ear="Gifted Earring",
  102.         left_ring="Bifrost Ring",
  103.     }
  104.     sets.music.rest={
  105.         main="Chatoyant Staff",
  106.         sub="Bugard Strap +1",
  107.         range="Pan's Horn",
  108.         head="Wivre Hairpin",
  109.         body="Augur's Jaseran",
  110.         hands="Serpentes Cuffs",
  111.         legs="Sagacity Lappas",
  112.         feet="Avocat Pigaches",
  113.         neck="Eidolon Pendant",
  114.         waist="Aoidos' Belt",
  115.         left_ear="Graiai Earring",
  116.         right_ear="Gifted Earring",
  117.         left_ring="Bifrost Ring",
  118.         right_ring="Ether Ring",
  119.         back="Felicitas Cape"
  120.     }
  121.     sets.music.stoneskin={
  122.         waist="Siegel Sash"
  123.     }
  124.     sets.music.idlerun = set_combine(sets.music.maxmp, {feet="Aoidos' Cothrn. +2"})
  125.  
  126. -- Instruments
  127. sets.instruments={}
  128.     sets.instruments.marchetude = set_combine(sets.music.midbuff,{range="Langeleik"})--hands="Aoidos Mnchtte. +2"})
  129.     sets.instruments.finalelullaby= set_combine(sets.music.enfeeb,{range="Pan's Horn"})
  130.     sets.instruments.ballad= set_combine(sets.music.midbuff,{range="Eminent Flute"})--legs="Aoidos Rhing. +2"})
  131.     sets.instruments.minne= {range="Syrinx"}
  132.     sets.instruments.madrigalprelude= set_combine(sets.music.midbuff,{range="Cantabank's Horn"})--head="Aoidos' Calot +2",})
  133.     sets.instruments.mambomazurka= {range="Vihuela"}
  134.     sets.instruments.requiem= set_combine(sets.music.enfeeb,{range="Requiem Flute"})
  135.     sets.instruments.paeon= {range="Eminent Flute"}
  136.     sets.instruments.carol= {range="Eminent Flute"}
  137.     sets.instruments.minuet= set_combine(sets.music.midbuff,{range="Eminent Flute",})--body="Aoidos' Hngrln +2",})
  138.     sets.instruments.elegy= set_combine(sets.music.enfeeb,{range="Syrinx"})
  139.     sets.instruments.fakesongs = set_combine(sets.music.fakesongs, {range="Terpander"})
  140.    
  141. end
  142. -- Rules -----------------------------------------------------------------------------------------------
  143. -------------------------------------------------------------------------------------------------------------------
  144. -- Precast Rules
  145. -------------------------------------------------------------------------------------------------------------------
  146. function precast(spell)
  147.     if spell.action_type == 'Magic' then
  148.         if spell.type=='BardSong' then
  149.             equip(sets.music.prebuff)
  150.         end
  151.     end
  152.     if string.find(spell.english,'Cur') and spell.english ~= "Cursna" then
  153.         equip(sets.music.curepot)
  154.     end
  155.     -- KEEP THIS LAST IN PRECAST
  156.     if spell.prefix=="/magic" and player.mp>404 then
  157.         equip(sets.music.maxmp)
  158.     end
  159. end
  160. ----------------------------------------------------------------------------------------
  161. -- Midcast Rules
  162. ----------------------------------------------------------------------------------------
  163. function midcast(spell)
  164.     if spell.action_type == 'Magic' then
  165.         if spell.type=='BardSong' then
  166.             equip(sets.music.midbuff)
  167.         end
  168.     end
  169.     -- Rules for changing instruments
  170.     if spell.english:find ('March') or spell.english:find ('Etude') then
  171.         equip(sets.instruments.marchetude)
  172.     elseif spell.english:find ('Finale') or spell.english:find ('Lullaby') then
  173.         equip(sets.instruments.finalelullaby)
  174.     elseif spell.english:find ('Ballad') then
  175.         equip(sets.instruments.ballad)
  176.     elseif spell.english:find ('Elegy') or spell.english:find ('Minne') then
  177.         equip(sets.instruments.minne)
  178.     elseif spell.english:find ('Madrigal') or spell.english:find ('Prelude') then
  179.         equip(sets.instruments.madrigalprelude)
  180.     elseif spell.english:find ('mambo') or spell.english:find ('mazurka') then
  181.         equip(sets.instruments.mambomazurka)
  182.     elseif spell.english:find ('Requiem') then
  183.         equip(sets.instruments.requiem)
  184.     elseif spell.english:find ('Paeon') then
  185.         equip(sets.instruments.paeon)
  186.     elseif spell.english:find ('Carol') then
  187.         equip(sets.instruments.carol)
  188.     elseif spell.english:find ('Minuet') then
  189.         equip(sets.instruments.minuet)
  190.     elseif fakesongs:contains(spell.name) then
  191.         equip(sets.instruments.fakesongs)
  192.         add_to_chat(206,'<<<<<<< Fake Song >>>>>>>')
  193.     end
  194.    
  195.  
  196.     if spell.english:find('Lullaby') then
  197.         equip(sets.instruments.finalelullaby)
  198.     elseif spell.english:find('Finale') then
  199.         equip(sets.instruments.finalelullaby)
  200.     else
  201.         equip(sets.instruments.enfeeb)
  202.     end
  203.  
  204.    
  205.     if string.find(spell.english,'Cur') and spell.english ~= "Cursna" then
  206.         equip(sets.music.curepot)
  207.     end
  208.     -- KEEP THIS IT LAST IN MIDCAST
  209.     if spell.prefix=="/magic" and player.mp>404 then
  210.         equip(sets.music.maxmp)
  211.     end
  212. end
  213. -------------------------------------------------------------------------------------------------------------------
  214. -- Aftercast Rules
  215. -------------------------------------------------------------------------------------------------------------------
  216. function aftercast(spell)
  217.     if player.status=='Engaged' then
  218.         equip(sets.engaged.tp)
  219.     else
  220.         equip(sets.music[idletype])
  221.     end
  222. end
  223. -- Stoneskin and Siegal Sash
  224. function precast(spell)
  225.     if spell.english=="Stoneskin" then
  226.         equip(sets.music.stoneskin)
  227.     end
  228. end
  229. -- Pianissimo Rules
  230.  function pretarget(spell,action)
  231.     if spell.type == "BardSong" and spell.target.name == player.name and buffactive.Pianissimo then
  232.         change_target('<t>')
  233.     end
  234. end
  235. -- Function Change
  236. function status_change(new,old)
  237.     if new=='Engaged' then 
  238.         equip(sets.engaged.tp)
  239.     else
  240.         equip(sets.music[idletype])
  241.     end
  242. end
  243. -- Mode change- allows to change back to different things after engaging or casting
  244.  function self_command(command)
  245.     if command =="idletoggle" then
  246.         if idletype=="maxmp" then
  247.             idletype="idlerun"
  248.             status_change(player.status)
  249.             add_to_chat(206, "Idle Running Boots")
  250.         else
  251.             idletype="maxmp"
  252.             status_change(player.status)
  253.             add_to_chat(206, "Idle Regen/Refresh Boots")
  254.         end
  255.     end
  256. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement