Item Search
     
BG-Wiki Search
Page 43 of 302 FirstFirst ... 33 41 42 43 44 45 53 93 ... LastLast
Results 841 to 860 of 6036

Thread: Gearswap Help Thread!     submit to reddit submit to twitter

  1. #841
    BG Content
    Join Date
    Jul 2007
    Posts
    22,390
    BG Level
    10
    FFXI Server
    Lakshmi
    Blog Entries
    1

    Quote Originally Posted by Martel View Post
    Can you floor or round up the results of arithmetic in gearswap? If so, how? I suppose it's not really an issue for what I'm doing right now. but seeing 49.483333333333 pop up is kinda annoying.
    math.floor(number)

  2. #842
    Old Merits
    Join Date
    Sep 2010
    Posts
    1,094
    BG Level
    6
    FFXI Server
    Ragnarok

    Thanks. ^^

  3. #843
    Cerberus
    Join Date
    Aug 2010
    Posts
    446
    BG Level
    4
    FFXIV Character
    Alistrianna Galanodel
    FFXIV Server
    Hyperion

    Fixed my own issue. Forgot to update the sidecar files.

  4. #844
    RIDE ARMOR
    Join Date
    Oct 2013
    Posts
    20
    BG Level
    1

    After I download the script, how do I use it? I am interested in the Scholar one. Thanks

  5. #845
    Old Odin
    Join Date
    Oct 2006
    Posts
    6,198
    BG Level
    8
    FFXI Server
    Asura

    gearswap stoped swaping midcast equipment since the last update, at least it isnt chaning anything in for me, didnt change anything on my .lua (not useing motentens one, wrote one myself). this only occurs to the nuke equipment, which is the only set carring defined augments (Hagondes)

  6. #846
    An exploitable mess of a card game
    Join Date
    Sep 2008
    Posts
    13,197
    BG Level
    9
    FFXIV Character
    Gouka Mekkyaku
    FFXIV Server
    Gilgamesh
    FFXI Server
    Diabolos

    Throw the lua and all additional lua files (If using motenten's) to the data folder.

  7. #847
    Sea Torques
    Join Date
    Jun 2012
    Posts
    570
    BG Level
    5
    FFXI Server
    Asura
    WoW Realm
    The Scryers

    hmmm still no solution for the "buff_change" function? or isnt a gs issue?

  8. #848
    Old Odin
    Join Date
    Oct 2006
    Posts
    6,198
    BG Level
    8
    FFXI Server
    Asura

    Quote Originally Posted by Damane View Post
    gearswap stoped swaping midcast equipment since the last update, at least it isnt chaning anything in for me, didnt change anything on my .lua (not useing motentens one, wrote one myself). this only occurs to the nuke equipment, which is the only set carring defined augments (Hagondes)
    EDIT: removing the augments description did indeed fix this issue for me... sadly means I cant discerne augmented equipment anymore

  9. #849
    CoP Dynamis
    Join Date
    Mar 2013
    Posts
    275
    BG Level
    4
    FFXI Server
    Odin

    I have a question regarding using macros to bring up specific sets. Example for such a situation is say I see a BLM mob casting flare 2 on me after it slept me, and I want to use a command to bring up a set that's defined in my job specific lua. How would I go about invoking it? I tried to go to the documentation page at windower.net but it seems there isn't one up for gearswap.

  10. #850
    Chram
    Join Date
    Sep 2007
    Posts
    2,526
    BG Level
    7
    FFXI Server
    Fenrir

    Quote Originally Posted by Alistrianna View Post
    Motenten, been using your SMN gearswap for quite some time and I've been noticing its swapping gear too fast sometimes on Blood Pacts. Is there any particular reason it might be doing that? I notice it most on Flaming Crush, where I tend to be back in Idle before the BP even finishes.
    It shouldn't. It should only revert to idle gear after you receive the packet indicating that the bloodpact has finished. Realize, though, that text display in the chat log is often a second or two after you receive the packet, so it could very well be just an illusion that you're swapping before the pact is complete. You'd need to test with pacts where you could be absolutely certain that the gear was or was not in place when the pact was completed.

  11. #851
    Old Merits
    Join Date
    Sep 2010
    Posts
    1,094
    BG Level
    6
    FFXI Server
    Ragnarok

    Is there a way to check buffs using IDs rather than names in gearswap?

  12. #852
    Melee Summoner
    Join Date
    Mar 2014
    Posts
    25
    BG Level
    1

    Hello everyone, actually i have huge problem whit gearswap & mote include (and mote rdm files and sch files).

    when i sub BLM, i can't cast sleepga, when i try i get this message :
    "Psylo can't cast sleepga"

    Anyone have an idea about this ?

    Can't do it with maccro or just by magic menu.

    Its pretty anoying ^^

    Help ^^

  13. #853
    Puppetmaster
    Join Date
    Dec 2010
    Posts
    62
    BG Level
    2
    FFXI Server
    Asura

    i think im having the same problem too, for blood pact: ward its working as intended, but for blood pact: rage, it seems to be switching back to idle too fast, before the animation even goes off, unless i'm a little bit laggy.
    updated my gs based on your current job specific hooks and seems to be working fine now

  14. #854
    BG Content
    Join Date
    Jul 2007
    Posts
    22,390
    BG Level
    10
    FFXI Server
    Lakshmi
    Blog Entries
    1

    Spoiler: show
    Quote Originally Posted by Byrthnoth View Post
    Okay, so I have a few updates and general questions. I'm trying to update my issues list ( https://github.com/Byrth/Lua/issues ). Currently I have 9 open issues:
    * 3 of these are unfixable (the two Battlemod ones and player.equipment). I'd close these, but I don't want people to open similar issues.
    * 2 of them are trivial but not done (pet_acquired() for Charm and changing cast_delay()'s implementation in pretarget)
    * 2 of them are real and difficult to fix - Disabling abilities that people can't use and switching to using the resources library are each probably a day of work.

    * 1 of them might be impossible (precast vs. pretarget issue for the spellcast emulator program)
    * 1 of them might already work - Does anyone know if Shortcuts' target creation works in Ballista? I haven't done Ballista in over a year and haven't had a chance to test it.
    Please let me know if you guys find issues, want libraries exposed, etc. Just open issues at the link above and I'll do it.

    Beyond that, LuaCore's event_unregister issue is really the only barrier stopping GearSwap from attaining all the functionality that I had envisioned. When event_unregister is fixed it will become possible to add custom user events without occasionally crashing when you change jobs, which is the current problem. After this is implemented I will likely also introduce a ../Gearswap/data/libs folder where people can push common include files (at the discretion of the people maintaining the windower repository) for the entire userbase to enjoy.

    The way that windower.register_event() has been implemented within the GearSwap user environment allows you to change gear in response to any arbitrary event. Similar events, ie. triggering gear changes based on time of day, weather changes, day changes, area name, etc., could be clustered into common include "libraries." These libs could be used by people that don't necessarily understand the underlying code (much like GearSwap's native events). Less savory events, like one responding to monster TP moves, would never be added to the common repository.


    GearSwap is built with the intention of being fairly resistant to FFXI client changes. There are fairly few hardcoded resources (all in statics.lua) and mostly it relies on LuaCore. As long as LuaCore and the resources are maintained (and don't change too much), GearSwap will likely not break. Once I have solved the four addressable issues above and unregister_event is fixed / I've reacted to it, I will likely take GearSwap out of beta and simultaneously freeze its development. It has reached its goal, I'd say.


    To update this, I have:
    * Changed cast_delay()'s implementation so that using it in precast and pretarget pause at different points. Before, using it in either phase would cause a delay after precast.
    * Put in a preliminary filter for abilities and spells that you cannot use. Also, changed ResourceExtractor so that a perfect filter will be possible in the future.
    ** Updated ResourceExtractor to export resources in both .xml and .lua.
    ** Added job levels for spells to the .lua version of the spells resource.
    ** Added monster species/TP moves/TP costs to the .lua version of the items resource.
    * Switched GearSwap from using my custom xml resources parser to using the resources library.
    * Got confirmation that shortcuts' target creation works in Ballista.

    Arcon also fixed event registration / unregistration, so it's open season on everything I mentioned in the quoted/spoilered post. My remaining GearSwap beta to-do list is:
    * Smush the few minor bugs that still live in my issue tracker.
    * See the .lua resources get released and transition GearSwap to filter usable abilities based off them.
    * Create the GearSwap/libs folder on Github, adjust GearSwap to check it, and add a few seed libraries.
    * Comment my GearSwap code more thoroughly.

  15. #855
    Sea Torques
    Join Date
    Jul 2010
    Posts
    516
    BG Level
    5
    FFXI Server
    Bahamut

    I'm not sure I understand the need for a cast_delay() in GearSwap. When might I need to use it?

  16. #856
    BG Content
    Join Date
    Jul 2007
    Posts
    22,390
    BG Level
    10
    FFXI Server
    Lakshmi
    Blog Entries
    1

    You could use it for something like Pianissimo if you wanted.

    Related to the above: I potentially just broke everything on -dev.

  17. #857
    Relic Shield
    Join Date
    Sep 2007
    Posts
    1,740
    BG Level
    6
    FFXI Server
    Sylph

    Currently using Mote's SAM gearswap, I tried looking at various other gearswaps and such to see how to lock a piece of gear if it's equipped but wasn't able to really find anything. Main thing I want to lock is the ranged slot if Yoichinoyumi is equipped, would anyone happen to know if/how to make that work?

    Code:
    -------------------------------------------------------------------------------------------------------------------
    -- Initialization function that defines sets and variables to be used.
    -------------------------------------------------------------------------------------------------------------------
    
    -- IMPORTANT: Make sure to also get the Mote-Include.lua file (and its supplementary files) to go with this.
    
    -- Initialization function for this job file.
    function get_sets()
    	-- Load and initialize the include file.
    	include('Mote-Include.lua')
    end
    
    
    -- Setup vars that are user-independent.
    function job_setup()
    	state.CombatForm = get_combat_form()
    	
    	state.Buff.Sekkanoki = buffactive.sekkanoki or false
    	state.Buff.Sengikori = buffactive.sengikori or false
    	state.Buff['Meikyou Shisui'] = buffactive['Meikyou Shisui'] or false
    end
    
    
    -- Setup vars that are user-dependent.  Can override this function in a sidecar file.
    function user_setup()
    	-- Options: Override default values
    	options.OffenseModes = {'Normal', 'Acc', 'Adoulin', 'Bow'}
    	options.DefenseModes = {'Normal', 'PDT', 'MDT', 'Reraise'}
    	options.WeaponskillModes = {'Normal', 'Acc', 'Att', 'Mod'}
    	options.CastingModes = {'Normal'}
    	options.IdleModes = {'Normal'}
    	options.RestingModes = {'Normal'}
    	options.PhysicalDefenseModes = {'PDT', 'Reraise'}
    	options.MagicalDefenseModes = {'MDT'}
    
    	state.Defense.PhysicalMode = 'PDT'
    
    	-- Additional local binds
    	send_command('bind ^` input /ja "Hasso" <me>')
    	send_command('bind !` input /ja "Seigan" <me>')
    
    	select_default_macro_book()
    end
    
    
    -- Called when this job file is unloaded (eg: job change)
    function file_unload()
    	if binds_on_unload then
    		binds_on_unload()
    	end
    
    	send_command('unbind ^`')
    	send_command('unbind !-')
    end
    
    
    -- Define sets and vars used by this job file.
    function init_gear_sets()
    	--------------------------------------
    	-- Start defining the sets
    	--------------------------------------
    	
    	-- Precast Sets
    	-- Precast sets to enhance JAs
    	sets.precast.JA.Meditate = {head="Myochin Kabuto +1",hands="Saotome Kote +2"}
    	sets.precast.JA['Warding Circle'] = {head="Myochin Kabuto +1"}
    	sets.precast.JA['Blade Bash'] = {hands="Saotome Kote +2"}
    
    	-- Waltz set (chr and vit)
    	sets.precast.Waltz = {ammo="Sonia's Plectrum",
    		head="Yaoyotl Helm",
    		body="Otronif Harness",hands="Buremte Gloves",ring1="Spiral Ring",
    		back="Iximulew Cape",waist="Caudata Belt",legs="Karieyh Brayettes +1",feet="Otronif Boots"}
    		
    	-- Don't need any special gear for Healing Waltz.
    	sets.precast.Waltz['Healing Waltz'] = {}
    
           
    	-- Weaponskill sets
    	-- Default set for any weaponskill that isn't any more specifically defined
    	sets.precast.WS = {ammo="Thew Bomblet",
    		head="Yaoyotl Helm",neck="Asperity Necklace",ear1="Brutal Earring",ear2="Moonshade Earring",
    		body="Phorcys Korazin",hands="Otronif Gloves",ring1="Rajas Ring",ring2="Spiral Ring",
    		back="Atheling Mantle",waist="Caudata Belt",legs="Karieyh Brayettes +1",feet="Karieyh Sollerets +1"}
    	sets.precast.WS.Acc = set_combine(sets.precast.WS, {back="Letalis Mantle"})
    
    	-- Specific weaponskill sets.  Uses the base set if an appropriate WSMod version isn't found.
    	sets.precast.WS['Tachi: Fudo'] = set_combine(sets.precast.WS, {neck="Snow Gorget"})
    	sets.precast.WS['Tachi: Fudo'].Acc = set_combine(sets.precast.WS.Acc, {neck="Snow Gorget"})
    	sets.precast.WS['Tachi: Fudo'].Mod = set_combine(sets.precast.WS['Tachi: Fudo'], {waist="Snow Belt"})
    
    	sets.precast.WS['Tachi: Shoha'] = set_combine(sets.precast.WS, {neck="Thunder Gorget"})
    	sets.precast.WS['Tachi: Shoha'].Acc = set_combine(sets.precast.WS.Acc, {neck="Thunder Gorget"})
    	sets.precast.WS['Tachi: Shoha'].Mod = set_combine(sets.precast.WS['Tachi: Shoha'], {waist="Thunder Belt"})
    
    	sets.precast.WS['Tachi: Rana'] = set_combine(sets.precast.WS, {neck="Snow Gorget",ear1="Bladeborn Earring",ear2="Steelflash Earring",})
    	sets.precast.WS['Tachi: Rana'].Acc = set_combine(sets.precast.WS.Acc, {neck="Snow Gorget",ear1="Bladeborn Earring",ear2="Steelflash Earring",})
    	sets.precast.WS['Tachi: Rana'].Mod = set_combine(sets.precast.WS['Tachi: Rana'], {waist="Snow Belt"})
    
    	sets.precast.WS['Tachi: Kasha'] = set_combine(sets.precast.WS, {neck="Light Gorget",waist="Light Belt"})
    
    	sets.precast.WS['Tachi: Gekko'] = set_combine(sets.precast.WS, {neck="Snow Gorget",waist="Snow Belt"})
    
    	sets.precast.WS['Tachi: Yukikaze'] = set_combine(sets.precast.WS, {neck="Snow Gorget",waist="Snow Belt"})
    
    	sets.precast.WS['Tachi: Ageha'] = set_combine(sets.precast.WS, {neck="Soil Gorget",waist="Soil Belt"})
    
    	sets.precast.WS['Tachi: Jinpu'] = set_combine(sets.precast.WS, {neck="Soil Gorget",waist="Soil Belt"})
    
    
    	-- Midcast Sets
    	sets.midcast.FastRecast = {
    		head="Yaoyotl Helm",
    		body="Otronif Harness",hands="Otronif Gloves",
    		legs="Phorcys Dirs",feet="Otronif Boots"}
    
    	
    	-- Sets to return to when not performing an action.
    	
    	-- Resting sets
    	sets.resting = {neck="Wiglen Gorget",ring1="Sheltered Ring",ring2="Paguroidea Ring"}
    	
    
    	-- Idle sets (default idle set not needed since the other three are defined, but leaving for testing purposes)
    	sets.idle.Town = {main="Tsurumaru", sub="Pole Grip",ammo="Thew Bomblet",
    		head="Yaoyotl Helm",neck="Asperity Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Otronif Harness",hands="Otronif Gloves",ring1="Sheltered Ring",ring2="Paguroidea Ring",
    		back="Atheling Mantle",waist="Flume Belt",legs="Phorcys Dirs",feet="Danzo Sune-ate"}
    	
    	sets.idle.Field = {
    		head="Yaoyotl Helm",neck="Wiglen Gorget",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Otronif Harness",hands="Otronif Gloves",ring1="Sheltered Ring",ring2="Paguroidea Ring",
    		back="Shadow Mantle",waist="Flume Belt",legs="Karieyh Brayettes +1",feet="Danzo Sune-ate"}
    
    	sets.idle.Weak = {
    		head="Twilight Helm",neck="Wiglen Gorget",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Twilight Mail",hands="Buremte Gloves",ring1="Sheltered Ring",ring2="Paguroidea Ring",
    		back="Shadow Mantle",waist="Flume Belt",legs="Karieyh Brayettes +1",feet="Danzo Sune-ate"}
    	
    	-- Defense sets
    	sets.defense.PDT = {ammo="Iron Gobbet",
    		head="Yaoyotl Helm",neck="Twilight Torque",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Otronif Harness",hands="Otronif Gloves",ring1="Dark Ring",ring2="Dark Ring",
    		back="Shadow Mantle",waist="Flume Belt",legs="Karieyh Brayettes +1",feet="Otronif Boots"}
    
    	sets.defense.Reraise = {
    		head="Twilight Helm",neck="Twilight Torque",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Twilight Mail",hands="Buremte Gloves",ring1="Dark Ring",ring2="Paguroidea Ring",
    		back="Shadow Mantle",waist="Flume Belt",legs="Karieyh Brayettes +1",feet="Otronif Boots"}
    
    	sets.defense.MDT = {ammo="Demonry Stone",
    		head="Yaoyotl Helm",neck="Twilight Torque",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Otronif Harness",hands="Otronif Gloves",ring1="Sheltered Ring",ring2="Paguroidea Ring",
    		back="Engulfer Cape",waist="Flume Belt",legs="Karieyh Brayettes +1",feet="Otronif Boots"}
    
    	sets.Kiting = {feet="Danzo Sune-ate"}
    
    	sets.Reraise = {head="Twilight Helm",body="Twilight Mail"}
    
    	-- Engaged sets
    
    	-- Variations for TP weapon and (optional) offense/defense modes.  Code will fall back on previous
    	-- sets if more refined versions aren't defined.
    	-- If you create a set with both offense and defense modes, the offense mode should be first.
    	-- EG: sets.engaged.Dagger.Accuracy.Evasion
    	
    	-- Normal melee group
    	-- Delay 450 GK, 25 Save TP => 65 Store TP for a 5-hit (25 Store TP in gear)
    	sets.engaged = {ammo="Thew Bomblet",
    		head="Yaoyotl Helm",neck="Asperity Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Karieyh Haubert +1",hands="Otronif Gloves",ring1="Rajas Ring",ring2="K'ayres Ring",
    		back="Atheling Mantle",waist="Goading Belt",legs="Unkai Haidate +2",feet="Otronif Boots"}
    	sets.engaged.Acc = {ammo="Thew Bomblet",
    		head="Yaoyotl Helm",neck="Asperity Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Karieyh Haubert +1",hands="Otronif Gloves",ring1="Rajas Ring",ring2="K'ayres Ring",
    		back="Letalis Mantle",waist="Goading Belt",legs="Unkai Haidate +2",feet="Otronif Boots"}
    	sets.engaged.PDT = {ammo="Thew Bomblet",
    		head="Yaoyotl Helm",neck="Twilight Torque",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Otronif Harness",hands="Otronif Gloves",ring1="Dark Ring",ring2="K'ayres Ring",
    		back="Iximulew Cape",waist="Goading Belt",legs="Unkai Haidate +2",feet="Otronif Boots"}
    	sets.engaged.Acc.PDT = {ammo="Honed Tathlum",
    		head="Yaoyotl Helm",neck="Twilight Torque",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Otronif Harness",hands="Otronif Gloves",ring1="Dark Ring",ring2="K'ayres Ring",
    		back="Letalis Mantle",waist="Goading Belt",legs="Unkai Haidate +2",feet="Otronif Boots"}
    	sets.engaged.Reraise = {ammo="Thew Bomblet",
    		head="Twilight Helm",neck="Torero Torque",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Twilight Mail",hands="Otronif Gloves",ring1="Beeline Ring",ring2="K'ayres Ring",
    		back="Ik Cape",waist="Goading Belt",legs="Unkai Haidate +2",feet="Otronif Boots"}
    	sets.engaged.Acc.Reraise = {ammo="Thew Bomblet",
    		head="Twilight Helm",neck="Torero Torque",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Twilight Mail",hands="Otronif Gloves",ring1="Beeline Ring",ring2="K'ayres Ring",
    		back="Letalis Mantle",waist="Goading Belt",legs="Unkai Haidate +2",feet="Otronif Boots"}
    		
    	-- Melee sets for in Adoulin, which has an extra 10 Save TP for weaponskills.
    	-- Delay 450 GK, 35 Save TP => 89 Store TP for a 4-hit (49 Store TP in gear), 2 Store TP for a 5-hit
    	sets.engaged.Adoulin = {ammo="Thew Bomblet",
    		head="Yaoyotl Helm",neck="Asperity Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Karieyh Haubert +1",hands="Otronif Gloves",ring1="Rajas Ring",ring2="K'ayres Ring",
    		back="Takaha Mantle",waist="Goading Belt",legs="Unkai Haidate +2",feet="Otronif Boots"}
    	sets.engaged.Adoulin.Acc = {ammo="Thew Bomblet",
    		head="Yaoyotl Helm",neck="Asperity Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Unkai Domaru +2",hands="Otronif Gloves",ring1="Rajas Ring",ring2="K'ayres Ring",
    		back="Letalis Mantle",waist="Goading Belt",legs="Unkai Haidate +2",feet="Otronif Boots"}
    	sets.engaged.Adoulin.PDT = {ammo="Thew Bomblet",
    		head="Yaoyotl Helm",neck="Twilight Torque",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Otronif Harness",hands="Otronif Gloves",ring1="Dark Ring",ring2="K'ayres Ring",
    		back="Iximulew Cape",waist="Goading Belt",legs="Unkai Haidate +2",feet="Otronif Boots"}
    	sets.engaged.Adoulin.Acc.PDT = {ammo="Honed Tathlum",
    		head="Yaoyotl Helm",neck="Twilight Torque",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Otronif Harness",hands="Otronif Gloves",ring1="Dark Ring",ring2="K'ayres Ring",
    		back="Letalis Mantle",waist="Goading Belt",legs="Unkai Haidate +2",feet="Otronif Boots"}
    	sets.engaged.Adoulin.Reraise = {ammo="Thew Bomblet",
    		head="Twilight Helm",neck="Twilight Torque",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Twilight Mail",hands="Otronif Gloves",ring1="Beeline Ring",ring2="K'ayres Ring",
    		back="Ik Cape",waist="Goading Belt",legs="Unkai Haidate +2",feet="Otronif Boots"}
    	sets.engaged.Adoulin.Acc.Reraise = {ammo="Thew Bomblet",
    		head="Twilight Helm",neck="Twilight Torque",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Twilight Mail",hands="Otronif Gloves",ring1="Beeline Ring",ring2="K'ayres Ring",
    		back="Letalis Mantle",waist="Goading Belt",legs="Unkai Haidate +2",feet="Otronif Boots"}
    
    
    	sets.buff.Sekkanoki = {hands="Unkai Kote +2"}
    	sets.buff.Sengikori = {feet="Unkai Sune-ate +2"}
    	sets.buff['Meikyou Shisui'] = {feet="Saotome Sune-ate +2"}
    end
    
    
    -------------------------------------------------------------------------------------------------------------------
    -- Job-specific hooks that are called to process player actions at specific points in time.
    -------------------------------------------------------------------------------------------------------------------
    
    -- Set eventArgs.handled to true if we don't want any automatic target handling to be done.
    function job_pretarget(spell, action, spellMap, eventArgs)
    	if spell.type:lower() == 'weaponskill' then
    		-- Change any GK weaponskills to polearm weaponskill if we're using a polearm.
    		if player.equipment.main=='Quint Spear' or player.equipment.main=='Quint Spear' then
    			if spell.english:startswith("Tachi:") then
    				send_command('@input /ws "Penta Thrust" '..spell.target.raw)
    				eventArgs.cancel = true
    			end
    		end
    	end
    end
    
    -- Run after the default precast() is done.
    -- eventArgs is the same one used in job_precast, in case information needs to be persisted.
    function job_post_precast(spell, action, spellMap, eventArgs)
    	if spell.type:lower() == 'weaponskill' then
    		if state.Buff.Sekkanoki then
    			equip(sets.buff.Sekkanoki)
    		end
    		if state.Buff.Sengikori then
    			equip(sets.buff.Sengikori)
    		end
    		if state.Buff['Meikyou Shisui'] then
    			equip(sets.buff['Meikyou Shisui'])
    		end
    	end
    end
    
    
    -- Set eventArgs.handled to true if we don't want any automatic gear equipping to be done.
    function job_midcast(spell, action, spellMap, eventArgs)
    	if spell.action_type == 'Magic' then
    		equip(sets.midcast.FastRecast)
    	end
    end
    
    -- Run after the default midcast() is done.
    -- eventArgs is the same one used in job_midcast, in case information needs to be persisted.
    function job_post_midcast(spell, action, spellMap, eventArgs)
    	-- Effectively lock these items in place.
    	if state.DefenseMode == 'Reraise' or
    		(state.Defense.Active and state.Defense.Type == 'Physical' and state.Defense.PhysicalMode == 'Reraise') then
    		equip(sets.Reraise)
    	end
    end
    
    -- Set eventArgs.handled to true if we don't want any automatic gear equipping to be done.
    function job_aftercast(spell, action, spellMap, eventArgs)
    	if not spell.interrupted then
    		if state.Buff[spell.english] ~= nil then
    			state.Buff[spell.english] = true
    		end
    	end
    end
    
    
    -------------------------------------------------------------------------------------------------------------------
    -- Customization hooks for idle and melee sets, after they've been automatically constructed.
    -------------------------------------------------------------------------------------------------------------------
    
    -------------------------------------------------------------------------------------------------------------------
    -- General hooks for other events.
    -------------------------------------------------------------------------------------------------------------------
    
    -- Called when a player gains or loses a buff.
    -- buff == buff gained or lost
    -- gain == true if the buff was gained, false if it was lost.
    function job_buff_change(buff, gain)
    	if state.Buff[buff] ~= nil then
    		state.Buff[buff] = gain
    	end
    end
    
    -- Called when the player's subjob changes.
    function sub_job_change(newSubjob, oldSubjob)
    	select_default_macro_book()
    end
    
    -------------------------------------------------------------------------------------------------------------------
    -- User code that supplements self-commands.
    -------------------------------------------------------------------------------------------------------------------
    
    -- Called by the 'update' self-command, for common needs.
    -- Set eventArgs.handled to true if we don't want automatic equipping of gear.
    function job_update(cmdParams, eventArgs)
    	state.CombatForm = get_combat_form()
    end
    
    -- Set eventArgs.handled to true if we don't want the automatic display to be run.
    function display_current_job_state(eventArgs)
    
    end
    
    -------------------------------------------------------------------------------------------------------------------
    -- Utility functions specific to this job.
    -------------------------------------------------------------------------------------------------------------------
    
    function get_combat_form()
    	if areas.Adoulin:contains(world.area) and buffactive.ionis then
    		return 'Adoulin'
    	end
    end
    
    -- Select default macro book on initial load or subjob change.
    function select_default_macro_book()
    	-- Default macro set/book
    	if player.sub_job == 'WAR' then
    		set_macro_page(1, 11)
    	elseif player.sub_job == 'DNC' then
    		set_macro_page(2, 11)
    	elseif player.sub_job == 'THF' then
    		set_macro_page(3, 11)
    	elseif player.sub_job == 'NIN' then
    		set_macro_page(4, 11)
    	else
    		set_macro_page(1, 11)
    	end
    end

  18. #858
    Melee Summoner
    Join Date
    Jan 2014
    Posts
    27
    BG Level
    1

    I have been using Bokura's lua's and converted all my jobs to gearswap, I'm very happy with them all so far apart from my JA sets wont work on RUN (Swordplay works but no others) I dont have 10 posts yet so i cant post link to my pastebin... its pastebin . com / u / Amadis

    Also i get a error pop up when i use <stnpc> for WS in macros, spells and other stuff work fine with <stnpc> but WS i get a error, is there any way around that?

    Thanks in advance :D

  19. #859
    Hydra
    Join Date
    Feb 2014
    Posts
    131
    BG Level
    3
    FFXI Server
    Quetzalcoatl

    Quote Originally Posted by IceSylph View Post
    Currently using Mote's SAM gearswap, I tried looking at various other gearswaps and such to see how to lock a piece of gear if it's equipped but wasn't able to really find anything. Main thing I want to lock is the ranged slot if Yoichinoyumi is equipped, would anyone happen to know if/how to make that work?

    Code:
    -------------------------------------------------------------------------------------------------------------------
    -- Initialization function that defines sets and variables to be used.
    -------------------------------------------------------------------------------------------------------------------
    
    -- IMPORTANT: Make sure to also get the Mote-Include.lua file (and its supplementary files) to go with this.
    
    -- Initialization function for this job file.
    function get_sets()
    	-- Load and initialize the include file.
    	include('Mote-Include.lua')
    end
    
    
    -- Setup vars that are user-independent.
    function job_setup()
    	state.CombatForm = get_combat_form()
    	
    	state.Buff.Sekkanoki = buffactive.sekkanoki or false
    	state.Buff.Sengikori = buffactive.sengikori or false
    	state.Buff['Meikyou Shisui'] = buffactive['Meikyou Shisui'] or false
    end
    
    
    -- Setup vars that are user-dependent.  Can override this function in a sidecar file.
    function user_setup()
    	-- Options: Override default values
    	options.OffenseModes = {'Normal', 'Acc', 'Adoulin', 'Bow'}
    	options.DefenseModes = {'Normal', 'PDT', 'MDT', 'Reraise'}
    	options.WeaponskillModes = {'Normal', 'Acc', 'Att', 'Mod'}
    	options.CastingModes = {'Normal'}
    	options.IdleModes = {'Normal'}
    	options.RestingModes = {'Normal'}
    	options.PhysicalDefenseModes = {'PDT', 'Reraise'}
    	options.MagicalDefenseModes = {'MDT'}
    
    	state.Defense.PhysicalMode = 'PDT'
    
    	-- Additional local binds
    	send_command('bind ^` input /ja "Hasso" <me>')
    	send_command('bind !` input /ja "Seigan" <me>')
    
    	select_default_macro_book()
    end
    
    
    -- Called when this job file is unloaded (eg: job change)
    function file_unload()
    	if binds_on_unload then
    		binds_on_unload()
    	end
    
    	send_command('unbind ^`')
    	send_command('unbind !-')
    end
    
    
    -- Define sets and vars used by this job file.
    function init_gear_sets()
    	--------------------------------------
    	-- Start defining the sets
    	--------------------------------------
    	
    	-- Precast Sets
    	-- Precast sets to enhance JAs
    	sets.precast.JA.Meditate = {head="Myochin Kabuto +1",hands="Saotome Kote +2"}
    	sets.precast.JA['Warding Circle'] = {head="Myochin Kabuto +1"}
    	sets.precast.JA['Blade Bash'] = {hands="Saotome Kote +2"}
    
    	-- Waltz set (chr and vit)
    	sets.precast.Waltz = {ammo="Sonia's Plectrum",
    		head="Yaoyotl Helm",
    		body="Otronif Harness",hands="Buremte Gloves",ring1="Spiral Ring",
    		back="Iximulew Cape",waist="Caudata Belt",legs="Karieyh Brayettes +1",feet="Otronif Boots"}
    		
    	-- Don't need any special gear for Healing Waltz.
    	sets.precast.Waltz['Healing Waltz'] = {}
    
           
    	-- Weaponskill sets
    	-- Default set for any weaponskill that isn't any more specifically defined
    	sets.precast.WS = {ammo="Thew Bomblet",
    		head="Yaoyotl Helm",neck="Asperity Necklace",ear1="Brutal Earring",ear2="Moonshade Earring",
    		body="Phorcys Korazin",hands="Otronif Gloves",ring1="Rajas Ring",ring2="Spiral Ring",
    		back="Atheling Mantle",waist="Caudata Belt",legs="Karieyh Brayettes +1",feet="Karieyh Sollerets +1"}
    	sets.precast.WS.Acc = set_combine(sets.precast.WS, {back="Letalis Mantle"})
    
    	-- Specific weaponskill sets.  Uses the base set if an appropriate WSMod version isn't found.
    	sets.precast.WS['Tachi: Fudo'] = set_combine(sets.precast.WS, {neck="Snow Gorget"})
    	sets.precast.WS['Tachi: Fudo'].Acc = set_combine(sets.precast.WS.Acc, {neck="Snow Gorget"})
    	sets.precast.WS['Tachi: Fudo'].Mod = set_combine(sets.precast.WS['Tachi: Fudo'], {waist="Snow Belt"})
    
    	sets.precast.WS['Tachi: Shoha'] = set_combine(sets.precast.WS, {neck="Thunder Gorget"})
    	sets.precast.WS['Tachi: Shoha'].Acc = set_combine(sets.precast.WS.Acc, {neck="Thunder Gorget"})
    	sets.precast.WS['Tachi: Shoha'].Mod = set_combine(sets.precast.WS['Tachi: Shoha'], {waist="Thunder Belt"})
    
    	sets.precast.WS['Tachi: Rana'] = set_combine(sets.precast.WS, {neck="Snow Gorget",ear1="Bladeborn Earring",ear2="Steelflash Earring",})
    	sets.precast.WS['Tachi: Rana'].Acc = set_combine(sets.precast.WS.Acc, {neck="Snow Gorget",ear1="Bladeborn Earring",ear2="Steelflash Earring",})
    	sets.precast.WS['Tachi: Rana'].Mod = set_combine(sets.precast.WS['Tachi: Rana'], {waist="Snow Belt"})
    
    	sets.precast.WS['Tachi: Kasha'] = set_combine(sets.precast.WS, {neck="Light Gorget",waist="Light Belt"})
    
    	sets.precast.WS['Tachi: Gekko'] = set_combine(sets.precast.WS, {neck="Snow Gorget",waist="Snow Belt"})
    
    	sets.precast.WS['Tachi: Yukikaze'] = set_combine(sets.precast.WS, {neck="Snow Gorget",waist="Snow Belt"})
    
    	sets.precast.WS['Tachi: Ageha'] = set_combine(sets.precast.WS, {neck="Soil Gorget",waist="Soil Belt"})
    
    	sets.precast.WS['Tachi: Jinpu'] = set_combine(sets.precast.WS, {neck="Soil Gorget",waist="Soil Belt"})
    
    
    	-- Midcast Sets
    	sets.midcast.FastRecast = {
    		head="Yaoyotl Helm",
    		body="Otronif Harness",hands="Otronif Gloves",
    		legs="Phorcys Dirs",feet="Otronif Boots"}
    
    	
    	-- Sets to return to when not performing an action.
    	
    	-- Resting sets
    	sets.resting = {neck="Wiglen Gorget",ring1="Sheltered Ring",ring2="Paguroidea Ring"}
    	
    
    	-- Idle sets (default idle set not needed since the other three are defined, but leaving for testing purposes)
    	sets.idle.Town = {main="Tsurumaru", sub="Pole Grip",ammo="Thew Bomblet",
    		head="Yaoyotl Helm",neck="Asperity Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Otronif Harness",hands="Otronif Gloves",ring1="Sheltered Ring",ring2="Paguroidea Ring",
    		back="Atheling Mantle",waist="Flume Belt",legs="Phorcys Dirs",feet="Danzo Sune-ate"}
    	
    	sets.idle.Field = {
    		head="Yaoyotl Helm",neck="Wiglen Gorget",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Otronif Harness",hands="Otronif Gloves",ring1="Sheltered Ring",ring2="Paguroidea Ring",
    		back="Shadow Mantle",waist="Flume Belt",legs="Karieyh Brayettes +1",feet="Danzo Sune-ate"}
    
    	sets.idle.Weak = {
    		head="Twilight Helm",neck="Wiglen Gorget",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Twilight Mail",hands="Buremte Gloves",ring1="Sheltered Ring",ring2="Paguroidea Ring",
    		back="Shadow Mantle",waist="Flume Belt",legs="Karieyh Brayettes +1",feet="Danzo Sune-ate"}
    	
    	-- Defense sets
    	sets.defense.PDT = {ammo="Iron Gobbet",
    		head="Yaoyotl Helm",neck="Twilight Torque",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Otronif Harness",hands="Otronif Gloves",ring1="Dark Ring",ring2="Dark Ring",
    		back="Shadow Mantle",waist="Flume Belt",legs="Karieyh Brayettes +1",feet="Otronif Boots"}
    
    	sets.defense.Reraise = {
    		head="Twilight Helm",neck="Twilight Torque",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Twilight Mail",hands="Buremte Gloves",ring1="Dark Ring",ring2="Paguroidea Ring",
    		back="Shadow Mantle",waist="Flume Belt",legs="Karieyh Brayettes +1",feet="Otronif Boots"}
    
    	sets.defense.MDT = {ammo="Demonry Stone",
    		head="Yaoyotl Helm",neck="Twilight Torque",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Otronif Harness",hands="Otronif Gloves",ring1="Sheltered Ring",ring2="Paguroidea Ring",
    		back="Engulfer Cape",waist="Flume Belt",legs="Karieyh Brayettes +1",feet="Otronif Boots"}
    
    	sets.Kiting = {feet="Danzo Sune-ate"}
    
    	sets.Reraise = {head="Twilight Helm",body="Twilight Mail"}
    
    	-- Engaged sets
    
    	-- Variations for TP weapon and (optional) offense/defense modes.  Code will fall back on previous
    	-- sets if more refined versions aren't defined.
    	-- If you create a set with both offense and defense modes, the offense mode should be first.
    	-- EG: sets.engaged.Dagger.Accuracy.Evasion
    	
    	-- Normal melee group
    	-- Delay 450 GK, 25 Save TP => 65 Store TP for a 5-hit (25 Store TP in gear)
    	sets.engaged = {ammo="Thew Bomblet",
    		head="Yaoyotl Helm",neck="Asperity Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Karieyh Haubert +1",hands="Otronif Gloves",ring1="Rajas Ring",ring2="K'ayres Ring",
    		back="Atheling Mantle",waist="Goading Belt",legs="Unkai Haidate +2",feet="Otronif Boots"}
    	sets.engaged.Acc = {ammo="Thew Bomblet",
    		head="Yaoyotl Helm",neck="Asperity Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Karieyh Haubert +1",hands="Otronif Gloves",ring1="Rajas Ring",ring2="K'ayres Ring",
    		back="Letalis Mantle",waist="Goading Belt",legs="Unkai Haidate +2",feet="Otronif Boots"}
    	sets.engaged.PDT = {ammo="Thew Bomblet",
    		head="Yaoyotl Helm",neck="Twilight Torque",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Otronif Harness",hands="Otronif Gloves",ring1="Dark Ring",ring2="K'ayres Ring",
    		back="Iximulew Cape",waist="Goading Belt",legs="Unkai Haidate +2",feet="Otronif Boots"}
    	sets.engaged.Acc.PDT = {ammo="Honed Tathlum",
    		head="Yaoyotl Helm",neck="Twilight Torque",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Otronif Harness",hands="Otronif Gloves",ring1="Dark Ring",ring2="K'ayres Ring",
    		back="Letalis Mantle",waist="Goading Belt",legs="Unkai Haidate +2",feet="Otronif Boots"}
    	sets.engaged.Reraise = {ammo="Thew Bomblet",
    		head="Twilight Helm",neck="Torero Torque",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Twilight Mail",hands="Otronif Gloves",ring1="Beeline Ring",ring2="K'ayres Ring",
    		back="Ik Cape",waist="Goading Belt",legs="Unkai Haidate +2",feet="Otronif Boots"}
    	sets.engaged.Acc.Reraise = {ammo="Thew Bomblet",
    		head="Twilight Helm",neck="Torero Torque",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Twilight Mail",hands="Otronif Gloves",ring1="Beeline Ring",ring2="K'ayres Ring",
    		back="Letalis Mantle",waist="Goading Belt",legs="Unkai Haidate +2",feet="Otronif Boots"}
    		
    	-- Melee sets for in Adoulin, which has an extra 10 Save TP for weaponskills.
    	-- Delay 450 GK, 35 Save TP => 89 Store TP for a 4-hit (49 Store TP in gear), 2 Store TP for a 5-hit
    	sets.engaged.Adoulin = {ammo="Thew Bomblet",
    		head="Yaoyotl Helm",neck="Asperity Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Karieyh Haubert +1",hands="Otronif Gloves",ring1="Rajas Ring",ring2="K'ayres Ring",
    		back="Takaha Mantle",waist="Goading Belt",legs="Unkai Haidate +2",feet="Otronif Boots"}
    	sets.engaged.Adoulin.Acc = {ammo="Thew Bomblet",
    		head="Yaoyotl Helm",neck="Asperity Necklace",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Unkai Domaru +2",hands="Otronif Gloves",ring1="Rajas Ring",ring2="K'ayres Ring",
    		back="Letalis Mantle",waist="Goading Belt",legs="Unkai Haidate +2",feet="Otronif Boots"}
    	sets.engaged.Adoulin.PDT = {ammo="Thew Bomblet",
    		head="Yaoyotl Helm",neck="Twilight Torque",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Otronif Harness",hands="Otronif Gloves",ring1="Dark Ring",ring2="K'ayres Ring",
    		back="Iximulew Cape",waist="Goading Belt",legs="Unkai Haidate +2",feet="Otronif Boots"}
    	sets.engaged.Adoulin.Acc.PDT = {ammo="Honed Tathlum",
    		head="Yaoyotl Helm",neck="Twilight Torque",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Otronif Harness",hands="Otronif Gloves",ring1="Dark Ring",ring2="K'ayres Ring",
    		back="Letalis Mantle",waist="Goading Belt",legs="Unkai Haidate +2",feet="Otronif Boots"}
    	sets.engaged.Adoulin.Reraise = {ammo="Thew Bomblet",
    		head="Twilight Helm",neck="Twilight Torque",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Twilight Mail",hands="Otronif Gloves",ring1="Beeline Ring",ring2="K'ayres Ring",
    		back="Ik Cape",waist="Goading Belt",legs="Unkai Haidate +2",feet="Otronif Boots"}
    	sets.engaged.Adoulin.Acc.Reraise = {ammo="Thew Bomblet",
    		head="Twilight Helm",neck="Twilight Torque",ear1="Bladeborn Earring",ear2="Steelflash Earring",
    		body="Twilight Mail",hands="Otronif Gloves",ring1="Beeline Ring",ring2="K'ayres Ring",
    		back="Letalis Mantle",waist="Goading Belt",legs="Unkai Haidate +2",feet="Otronif Boots"}
    
    
    	sets.buff.Sekkanoki = {hands="Unkai Kote +2"}
    	sets.buff.Sengikori = {feet="Unkai Sune-ate +2"}
    	sets.buff['Meikyou Shisui'] = {feet="Saotome Sune-ate +2"}
    end
    
    
    -------------------------------------------------------------------------------------------------------------------
    -- Job-specific hooks that are called to process player actions at specific points in time.
    -------------------------------------------------------------------------------------------------------------------
    
    -- Set eventArgs.handled to true if we don't want any automatic target handling to be done.
    function job_pretarget(spell, action, spellMap, eventArgs)
    	if spell.type:lower() == 'weaponskill' then
    		-- Change any GK weaponskills to polearm weaponskill if we're using a polearm.
    		if player.equipment.main=='Quint Spear' or player.equipment.main=='Quint Spear' then
    			if spell.english:startswith("Tachi:") then
    				send_command('@input /ws "Penta Thrust" '..spell.target.raw)
    				eventArgs.cancel = true
    			end
    		end
    	end
    end
    
    -- Run after the default precast() is done.
    -- eventArgs is the same one used in job_precast, in case information needs to be persisted.
    function job_post_precast(spell, action, spellMap, eventArgs)
    	if spell.type:lower() == 'weaponskill' then
    		if state.Buff.Sekkanoki then
    			equip(sets.buff.Sekkanoki)
    		end
    		if state.Buff.Sengikori then
    			equip(sets.buff.Sengikori)
    		end
    		if state.Buff['Meikyou Shisui'] then
    			equip(sets.buff['Meikyou Shisui'])
    		end
    	end
    end
    
    
    -- Set eventArgs.handled to true if we don't want any automatic gear equipping to be done.
    function job_midcast(spell, action, spellMap, eventArgs)
    	if spell.action_type == 'Magic' then
    		equip(sets.midcast.FastRecast)
    	end
    end
    
    -- Run after the default midcast() is done.
    -- eventArgs is the same one used in job_midcast, in case information needs to be persisted.
    function job_post_midcast(spell, action, spellMap, eventArgs)
    	-- Effectively lock these items in place.
    	if state.DefenseMode == 'Reraise' or
    		(state.Defense.Active and state.Defense.Type == 'Physical' and state.Defense.PhysicalMode == 'Reraise') then
    		equip(sets.Reraise)
    	end
    end
    
    -- Set eventArgs.handled to true if we don't want any automatic gear equipping to be done.
    function job_aftercast(spell, action, spellMap, eventArgs)
    	if not spell.interrupted then
    		if state.Buff[spell.english] ~= nil then
    			state.Buff[spell.english] = true
    		end
    	end
    end
    
    
    -------------------------------------------------------------------------------------------------------------------
    -- Customization hooks for idle and melee sets, after they've been automatically constructed.
    -------------------------------------------------------------------------------------------------------------------
    
    -------------------------------------------------------------------------------------------------------------------
    -- General hooks for other events.
    -------------------------------------------------------------------------------------------------------------------
    
    -- Called when a player gains or loses a buff.
    -- buff == buff gained or lost
    -- gain == true if the buff was gained, false if it was lost.
    function job_buff_change(buff, gain)
    	if state.Buff[buff] ~= nil then
    		state.Buff[buff] = gain
    	end
    end
    
    -- Called when the player's subjob changes.
    function sub_job_change(newSubjob, oldSubjob)
    	select_default_macro_book()
    end
    
    -------------------------------------------------------------------------------------------------------------------
    -- User code that supplements self-commands.
    -------------------------------------------------------------------------------------------------------------------
    
    -- Called by the 'update' self-command, for common needs.
    -- Set eventArgs.handled to true if we don't want automatic equipping of gear.
    function job_update(cmdParams, eventArgs)
    	state.CombatForm = get_combat_form()
    end
    
    -- Set eventArgs.handled to true if we don't want the automatic display to be run.
    function display_current_job_state(eventArgs)
    
    end
    
    -------------------------------------------------------------------------------------------------------------------
    -- Utility functions specific to this job.
    -------------------------------------------------------------------------------------------------------------------
    
    function get_combat_form()
    	if areas.Adoulin:contains(world.area) and buffactive.ionis then
    		return 'Adoulin'
    	end
    end
    
    -- Select default macro book on initial load or subjob change.
    function select_default_macro_book()
    	-- Default macro set/book
    	if player.sub_job == 'WAR' then
    		set_macro_page(1, 11)
    	elseif player.sub_job == 'DNC' then
    		set_macro_page(2, 11)
    	elseif player.sub_job == 'THF' then
    		set_macro_page(3, 11)
    	elseif player.sub_job == 'NIN' then
    		set_macro_page(4, 11)
    	else
    		set_macro_page(1, 11)
    	end
    end
    I haven't tested this since I'm at work. There's multiple ways to do what you're asking, but this is my first thought.

    Look for the job_update() and the job_setup() functions. Add the line state.CombatWeapon = get_combat_weapon() just below state.CombatForm = get_combat_form() in both places.

    Like this.
    Code:
    function job_update(cmdParams, eventArgs)
    	state.CombatForm = get_combat_form()
    	state.CombatWeapon = get_combat_weapon()
    end
    Add the function below, in the area that get_combat_form() function is defined. (line 458)
    Code:
    function get_combat_weapon()
        if player.equipment.range == 'Yoichinoyumi' then
            return 'Yoichi'
        end
    end
    Then, you'll need to create sets for 'Yoichi'

    sets.engaged.Yoichi = { }
    sets.engaged.Acc.Yoichi = { }
    sets.precast.WS['Namas Arrow'] = { }
    sets.engaged.Adoulin.Yoichi = { }
    sets.engaged.Adoulin.Yoichi.Acc = { }

    edit :
    I'm building a Yoichi now, so I went ahead and made these changes to my sam.lua. I can't link since I don't have 10 posts yet, but you can view mine here. github.com/AlanWarren/gearswap/blob/master/SAM.lua

    This isn't really "locking" a slot, but the end result is the same. If you really just want to lock a slot, my sam.lua does that for Sakonji Haidate, when I'm in PDT mode, and Third Eye is up. You should be able to do the same if player.equipment.range == "Yoichinoyumi"

    HTH

  20. #860
    Relic Shield
    Join Date
    Sep 2007
    Posts
    1,740
    BG Level
    6
    FFXI Server
    Sylph

    Quote Originally Posted by Orestes View Post
    I haven't tested this since I'm at work. There's multiple ways to do what you're asking, but this is my first thought.

    Look for the job_update() and the job_setup() functions. Add the line state.CombatWeapon = get_combat_weapon() just below state.CombatForm = get_combat_form() in both places.

    Like this.
    Code:
    function job_update(cmdParams, eventArgs)
    	state.CombatForm = get_combat_form()
    	state.CombatWeapon = get_combat_weapon()
    end
    Add the function below, in the area that get_combat_form() function is defined. (line 458)
    Code:
    function get_combat_weapon()
        if player.equipment.range == 'Yoichinoyumi' then
            return 'Yoichi'
        end
    end
    Then, you'll need to create sets for 'Yoichi'

    sets.engaged.Yoichi = { }
    sets.engaged.Acc.Yoichi = { }
    sets.precast.WS['Namas Arrow'] = { }
    sets.engaged.Adoulin.Yoichi = { }
    sets.engaged.Adoulin.Yoichi.Acc = { }

    edit :
    I'm building a Yoichi now, so I went ahead and made these changes to my sam.lua. I can't link since I don't have 10 posts yet, but you can view mine here. github.com/AlanWarren/gearswap/blob/master/SAM.lua

    This isn't really "locking" a slot, but the end result is the same. If you really just want to lock a slot, my sam.lua does that for Sakonji Haidate, when I'm in PDT mode, and Third Eye is up. You should be able to do the same if player.equipment.range == "Yoichinoyumi"

    HTH
    Much appreciated. At work now so can't check it , but will when I get home. Thanks, buddy.

Page 43 of 302 FirstFirst ... 33 41 42 43 44 45 53 93 ... LastLast

Similar Threads

  1. Replies: 6547
    Last Post: 2014-07-08, 22:45