Vamperica

TAGGEO

Jun 20th, 2017
72
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. -------------------------------------------------------------------------------------------------------------------
  2. -- Initialization function that defines sets and variables to be used.
  3. -------------------------------------------------------------------------------------------------------------------
  4.  
  5. -- IMPORTANT: Make sure to also get the Mote-Include.lua file (and its supplementary files) to go with this.
  6.  
  7. -- Initialization function for this job file.
  8. function get_sets()
  9.     -- Load and initialize the include file.
  10.     include('Mote-Include.lua')
  11. end
  12.  
  13. -- Setup vars that are user-independent.
  14. function job_setup()
  15.  
  16. end
  17.  
  18. -- Setup vars that are user-dependent.  Can override this function in a sidecar file.
  19. function user_setup()
  20.     -- Options: Override default values
  21.     options.CastingModes = {'Normal', 'Resistant'}
  22.     options.OffenseModes = {'Normal','Staff','Club','StaffACC','ClubACC'}
  23.     options.DefenseModes = {'Normal'}
  24.     options.WeaponskillModes = {'Normal'}
  25.     options.IdleModes = {'Normal','Hybrid','PDT','petPDT'}
  26.     options.RestingModes = {'Normal'}
  27.     options.PhysicalDefenseModes = {'PDT'}
  28.     options.MagicalDefenseModes = {'MDT'}
  29.  
  30.     state.Defense.PhysicalMode = 'PDT'
  31.  
  32.     lowTierNukes = S{'Stone', 'Water', 'Aero', 'Fire', 'Blizzard', 'Thunder',
  33.         'Stone II', 'Water II', 'Aero II', 'Fire II', 'Blizzard II', 'Thunder II',
  34.         'Stone III', 'Water III', 'Aero III', 'Fire III', 'Blizzard III', 'Thunder III',
  35.         'Stonega', 'Waterga', 'Aeroga', 'Firaga', 'Blizzaga', 'Thundaga',
  36.         'Stonega II', 'Waterga II', 'Aeroga II', 'Firaga II', 'Blizzaga II', 'Thundaga II', 'Stonera', 'Thundara', 'Fira', 'Blizzara',
  37.         'Aerora', 'Watera'}
  38.  
  39.     -- Default macro set/book
  40.     set_macro_page(1, 1)
  41. end
  42.  
  43. -- Called when this job file is unloaded (eg: job change)
  44. function file_unload()
  45.     if binds_on_unload then
  46.         binds_on_unload()
  47.     end
  48. end
  49.  
  50.  
  51. -- Define sets and vars used by this job file.
  52. function init_gear_sets()
  53.     --------------------------------------
  54.     -- Start defining the sets
  55.     --------------------------------------
  56.  
  57.     -- Precast Sets
  58.  
  59.     -- Precast sets to enhance JAs
  60.     sets.precast.JA['Life Cycle'] = {body="Geomancy Tunic +1"}
  61.     sets.precast.JA['Bolster'] = {body="Bagua Tunic"}
  62.     sets.precast.JA['Curative Recantation'] = {hands="Bagua Mitaines +1"}
  63.     sets.precast.JA['Mending Halation'] = {legs="Bagua Pants +1"}
  64.     sets.precast.JA['Radial Arcana'] = {feet="Bagua Sandals +1"}   
  65.  
  66.     -- Fast cast sets for spells
  67.  
  68.     sets.precast.FC = {
  69.         head={ name="Vanya Hood", augments={'MP+50','"Fast Cast"+10','Haste+2%',}},
  70.         legs="Geomancy Pants +1",
  71.         feet="Vanya Clogs",
  72.         left_ear="Loquac. Earring",
  73.         left_ring="Prolix Ring",
  74.         right_ring="Kishar Ring",
  75.         back="Pahtku Cape",
  76.         }
  77.  
  78.     sets.precast.FC.Cure = set_combine(sets.precast.FC, {})
  79.  
  80.     sets.precast.FC.Stoneskin = set_combine(sets.precast.FC, {})
  81.  
  82.        
  83.     -- Weaponskill sets
  84.     -- Default set for any weaponskill that isn't any more specifically defined
  85.     sets.precast.WS = {}
  86.  
  87.     -- Specific weaponskill sets.  Uses the base set if an appropriate WSMod version isn't found.
  88.     sets.precast.WS['Flash Nova'] = set_combine(sets.precast.WS, {})
  89.  
  90.     sets.precast.WS['Exudation'] = set_combine(sets.precast.WS, {})
  91.        
  92.     sets.precast.WS['Hexa Strike'] = set_combine(sets.precast.WS, {})
  93.  
  94.     sets.precast.WS['Starlight'] = set_combine(sets.precast.WS, {})
  95.  
  96.     sets.precast.WS['Moonlight'] = set_combine(sets.precast.WS, {})
  97.  
  98.     sets.precast.WS['Retribution'] = set_combine(sets.precast.WS, {})
  99.  
  100.     sets.precast.WS['Cataclysm'] = set_combine(sets.precast.WS, {})
  101.  
  102.     -- Midcast Sets
  103.  
  104.     sets.midcast.FastRecast = set_combine(sets.precast.FC, {})
  105.  
  106.     sets.midcast.Geomancy = {
  107.         main="Solstice", --5
  108.         head="Vanya Hood",
  109. --      feet="Vanya Clogs",
  110.         neck="Bagua Charm +2",
  111.         Range="Dunna", --18
  112.         hands="Geomancy Mitaines +1", --15
  113.         left_ring={name="Stikini Ring +1", bag="Wardrobe"}, --8x2
  114.         right_ring={name="Stikini Ring +1", bag="Wardrobe2"}, --8x2    
  115.         feet="Medium's Sabots", --5
  116.         waist="Austerity Belt +1",
  117.         back="Lifestream Cape", --14
  118.         }
  119.  
  120.     -- Cure potency =
  121.     sets.midcast.Cure = {
  122.         main="Raetic Rod +1", --25
  123.         head="Vanya Hood", --10
  124.         feet="Vanya Clogs", --10
  125.         neck="Phalaina Locket", --4
  126.         waist="Austerity Belt +1",
  127.         left_ear="Loquacious Earring",
  128.         right_ear="Beatific Earring",
  129.         left_ring="Haoma's Ring",
  130.         right_ring="Janniston Ring",
  131.         }
  132.  
  133.     sets.midcast.Stoneskin = set_combine(sets.midcast.FC, {})
  134.  
  135.     sets.midcast.Protectra = set_combine(sets.precast.FC, {})
  136.  
  137.     sets.midcast.Shellra = set_combine(sets.precast.FC, {})
  138.  
  139.     -- Custom Spell Classes
  140.     sets.midcast['Enfeebling Magic'] = set_combine(sets.precast.FC, {})
  141.  
  142.     sets.midcast.IntEnfeebles = set_combine(sets.precast.FC, {})
  143.  
  144.     sets.midcast.ElementalEnfeeble = sets.midcast['Enfeebling Magic']
  145.  
  146.     sets.midcast['Dark Magic'] = set_combine(sets.precast.FC, {})
  147.  
  148.         -- Elemental Magic sets are default for handling low-tier nukes.
  149.     sets.midcast.LowTierNuke = set_combine(sets.precast.FC, {
  150.         body="Witching Robe",
  151.         feet="Medium's Sabots",
  152.         neck="Sanctity Necklace",
  153.         })
  154.  
  155.     sets.midcast.LowTierNuke.Resistant = set_combine(sets.midcast.LowTierNuke, {})
  156.  
  157.     -- Custom classes for high-tier nukes.
  158.     sets.midcast.HighTierNuke = set_combine(sets.midcast.LowTierNuke, {})
  159.  
  160.     sets.midcast.HighTierNuke.Resistant = set_combine(sets.midcast.HighTierNuke, {})
  161.  
  162.     -- Sets to return to when not performing an action.
  163.  
  164.     -- Resting sets
  165.     sets.resting = {}
  166.  
  167.  
  168.     -- Idle sets (default idle set not needed since the other three are defined, but leaving for testing purposes)
  169.  
  170.     sets.idle.Field = {
  171.         main="Bolelabunga",
  172.         sub="Sors Shield",
  173.         range={ name="Dunna", augments={'MP+20','Mag. Acc.+10','"Fast Cast"+3',}},
  174.         head={ name="Vanya Hood", augments={'MP+50','"Fast Cast"+10','Haste+2%',}},
  175.         body={ name="Witching Robe", augments={'MP+50','Mag. Acc.+15','"Mag.Atk.Bns."+15','"Refresh"+1',}},
  176.         hands="Geomancy Mitaines +1",
  177.         legs="Assiduity Pants",
  178.         feet="Geomancy Sandals +1",
  179.         neck="Loricate Torque +1",
  180.         waist="Fucho-no-Obi",
  181.         left_ear="Loquac. Earring",
  182.         right_ear="Infused Earring",
  183.         left_ring="Defending Ring",
  184.         right_ring={name="Stikini Ring +1", bag="Wardrobe2"},
  185.         back={ name="Mecisto. Mantle", augments={'Cap. Point+48%','HP+12','Attack+3','DEF+6',}},
  186.         }
  187.  
  188. sets.idle.Town = set_combine(sets.idle.Field, {})
  189.  
  190.     sets.idle.Field.PDT = set_combine(sets.idle.Field, {})
  191.  
  192.     sets.idle.Weak = set_combine(sets.idle.Field, {})
  193.  
  194.     -- Defense sets
  195.  
  196.     sets.defense.PDT = set_combine(sets.idle.Field, {
  197.         main="Solstice", --4%
  198.         neck="Bagua Charm +2", --Absorb 10%
  199.         Range="Dunna", --5%
  200.         hands="Geomancy Mitaines +1", --11%(13)
  201.         back="Lifestream Cape", --4% (10 PDT)
  202.         })
  203.  
  204.     sets.defense.MDT = sets.defense.PDT
  205.  
  206.     sets.Kiting = {feet="Herald's Gaiters"}
  207.  
  208.     -- Engaged sets
  209.  
  210.     -- Variations for TP weapon and (optional) offense/defense modes.  Code will fall back on previous
  211.     -- sets if more refined versions aren't defined.
  212.     -- If you create a set with both offense and defense modes, the offense mode should be first.
  213.     -- EG: sets.engaged.Dagger.Accuracy.Evasion
  214.  
  215.     -- Normal melee group
  216.     sets.engaged = {}
  217. end
  218.  
  219. -------------------------------------------------------------------------------------------------------------------
  220. -- Job-specific hooks that are called to process player actions at specific points in time.
  221. -------------------------------------------------------------------------------------------------------------------
  222.  
  223. -- Set eventArgs.handled to true if we don't want any automatic gear equipping to be done.
  224. -- Set eventArgs.useMidcastGear to true if we want midcast gear equipped on precast.
  225. function job_precast(spell, action, spellMap, eventArgs)
  226.  
  227. end
  228.  
  229. -- Run after the general precast() is done.
  230. function job_post_precast(spell, action, spellMap, eventArgs)
  231.  
  232. end
  233.  
  234.  
  235. -- Set eventArgs.handled to true if we don't want any automatic gear equipping to be done.
  236. function job_midcast(spell, action, spellMap, eventArgs)
  237.     if spell.action_type == 'Magic' then
  238.         -- Default base equipment layer of fast recast.
  239.         equip(sets.midcast.FastRecast)
  240.     end
  241. end
  242.  
  243. -- Custom spell mapping.
  244. function job_get_spell_map(spell, default_spell_map)
  245.     if spell.skill == 'Elemental Magic' and default_spell_map ~= 'ElementalEnfeeble' then
  246.         if lowTierNukes:contains(spell.english) then
  247.             return 'LowTierNuke'
  248.         else
  249.             return 'HighTierNuke'
  250.         end
  251.     end
  252. end
  253. -- Run after the general midcast() is done.
  254. function job_post_midcast(spell, action, spellMap, eventArgs)
  255.  
  256. end
  257.  
  258. -- Set eventArgs.handled to true if we don't want any automatic gear equipping to be done.
  259. function job_aftercast(spell, action, spellMap, eventArgs)
  260.  
  261. end
  262.  
  263.  
  264. -------------------------------------------------------------------------------------------------------------------
  265. -- Customization hooks for idle and melee sets, after they've been automatically constructed.
  266. -------------------------------------------------------------------------------------------------------------------
  267.  
  268. function customize_idle_set(idleSet)
  269.     return idleSet
  270. end
  271.  
  272. function customize_melee_set(meleeSet)
  273.     return meleeSet
  274. end
  275.  
  276. -------------------------------------------------------------------------------------------------------------------
  277. -- General hooks for other events.
  278. -------------------------------------------------------------------------------------------------------------------
  279.  
  280. -- Called when the player's status changes.
  281. function job_status_change(newStatus,oldStatus)
  282.  
  283. end
  284.  
  285. -- Called when a player gains or loses a buff.
  286. -- buff == buff gained or lost
  287. -- gain == true if the buff was gained, false if it was lost.
  288. function job_buff_change(buff, gain)
  289.     --handle_equipping_gear(player.status)
  290. end
  291.  
  292.  
  293. -------------------------------------------------------------------------------------------------------------------
  294. -- User code that supplements self-commands.
  295. -------------------------------------------------------------------------------------------------------------------
  296.  
  297. -- Called for custom player commands.
  298. function job_self_command(cmdParams, eventArgs)
  299.  
  300. end
  301.  
  302. -- Called by the 'update' self-command.
  303. function job_update(cmdParams, eventArgs)
  304.  
  305. end
  306.  
  307. -- Function to display the current relevant user state when doing an update.
  308. -- Return true if display was handled, and you don't want the default info shown.
  309. function display_current_job_state()
  310.  
  311. end
  312.  
  313. -------------------------------------------------------------------------------------------------------------------
  314. -- Utility functions specific to this job.
  315. -------------------------------------------------------------------------------------------------------------------
Add Comment
Please, Sign In to add comment