|
Gearswap Support Thread
Server: Valefor
Game: FFXI
Posts: 2
By Valefor.Middleeast 2017-06-28 01:16:03
Hello im looking for help with COR lua.
I want to add the roll value to my add_to_chat and send_command
in add_to_chat for main chat log that isnt spammed
in send_command send for doing rolls from main character
thanks in advance
these are the sections in my lua from lua made by other people: Code function job_setup()
-- Whether to use Luzaf's Ring
state.LuzafRing = M(true, "Luzaf's Ring")
-- Whether a warning has been given for low ammo
state.warned = M(false)
define_roll_values()
end
function job_aftercast(spell, action, spellMap, eventArgs)
if spell.type == 'CorsairRoll' and not spell.interrupted then
display_roll_info(spell)
end
end
function define_roll_values()
rolls = {
["Corsair's Roll"] = {lucky=5, unlucky=9, bonus="Experience Points"}
end
function display_roll_info(spell)
rollinfo = rolls[spell.english]
local rollsize = (state.LuzafRing.value and 'L') or 'S'
if rollinfo then
add_to_chat(158, spell.english..' **'..rollinfo.bonus..'** Lucky, '..tostring(rollinfo.lucky)..' Unlucky, '..tostring(rollinfo.unlucky)..'.')
send_command('send middleeast input /echo _____________Lucky, '..tostring(rollinfo.lucky)..',____________Unlucky, '..tostring(rollinfo.unlucky)..'.')
end
By Squabble 2017-06-28 01:39:40
Could anyone help me figure out why this rule doesn't seem to work in my PLD lua?
Code function job_buff_change(buff, gain)
if state.Buff[buff] ~= nil then
handle_equipping_gear(player.status)
end
if buff == "Doom" then
if gain then
equip(sets.Doom)
send_command('@input /p Cursna - Doomed')
send_command('@input /item "Holy Water" <me>')
disable('ring1', 'ring2', 'legs')
elseif not gain and not player.status == "Dead" and not player.status == "Engaged Dead" then
enable('ring1', 'ring2', 'legs')
send_command('input /p Doom removed, Thank you.')
handle_equipping_gear(player.status)
else
enable('ring1', 'ring2', 'legs')
send_command('input /p '..player.name..' is no longer Doomed Thank you !')
end
end
end
I'm using mote's includes.
Server: Fenrir
Game: FFXI
Posts: 9
By Fenrir.Dracosam 2017-06-28 06:13:57
Is there a reason you decided to change the original doom function in my lua? The way you're trying to do it seems over-complicated.
Try one of these, maybe it'll help:
Code
1
state.Buff.Doom = buffactive['doom'] or false
Code
1
state.Buff.Doom = buffactive['doomed'] or false
it wasn't working that why i try to change it :( i guess that something else somehwere in code. when i tested it with protect it needed to go 2 time up to get it to work.
Code
state.Buff.Doom = buffactive['doom'] or false
the fonction job_setup() is only call once when you change job right ? was wondering how state.buff.doom is modified is so. that in mote include ?
Server: Sylph
Game: FFXI
Posts: 184
By Sylph.Subadai 2017-06-28 17:38:35
There is a comment in the PLD lua on Mote's github that says that states will be tracked if defined in job_setup(). I never tested Doom myself, so maybe there is a bug or something. Maybe I'll go die to the tree a few times and see if I can't figure it out, if I get some time.
By Squabble 2017-06-28 19:28:41
I was testing with the tree last night and couldn't get it to work; I tried changing the buff from Doom to Berserk, Warcy, etc. and couldn't get anything to trigger with the rule written as is.
By Squabble 2017-06-28 20:17:33
So I was just digging through the mote includes and saw an example for the weakness timer creation and this rule seems to work (at least for other buffs, haven't tested it on doom yet): Code function job_buff_change(buff, gain)
if state.Buff[buff] ~= nil then
handle_equipping_gear(player.status)
end
if buff:lower() == 'doom' then
if gain then
equip(sets.Doom)
send_command('@input /p Cursna - Doomed')
send_command('@input /item "Holy Water" <me>')
disable('ring1', 'ring2', 'legs')
elseif not gain and not player.status == "Dead" and not player.status == "Engaged Dead" then
enable('ring1', 'ring2', 'legs')
send_command('input /p Doom removed, Thank you.')
handle_equipping_gear(player.status)
else
enable('ring1', 'ring2', 'legs')
send_command('input /p '..player.name..' is no longer Doomed Thank you !')
end
end
end
Asura.Arnan
Server: Asura
Game: FFXI
Posts: 132
By Asura.Arnan 2017-06-30 03:06:41
is there a way to key bind the play/pause, stop and track skip buttons on my laptop through gearswap?
Bahamut.Odaru
Server: Bahamut
Game: FFXI
By Bahamut.Odaru 2017-07-01 00:45:07
How would I modify the following to check for Klimaform and equip Arbatel Loafers +1 when Klimform is active, else use whatever is defined in the nuke index? Right now I simply have Loafers written in, but this sometimes results in a loss of damage if Klimaform wears off mid cast. Every time I try to alter it I break something, any help would be greatly appreciated.
Code if Nuke:contains(spell.name) then
equip(sets.Nuke[sets.Nuke.index[Nuke_ind]])
if (spell.element == world.day_element or spell.element == world.weather_element) then
equip(equip(sets.Nuke[sets.Nuke.index[Nuke_ind]]), sets.Obi)
else
equip({waist="Refoccilation Stone"})
end
end
Server: Shiva
Game: FFXI
Posts: 357
By Shiva.Berzerk 2017-07-01 00:55:04
How would I modify the following to check for Klimaform and equip Arbatel Loafers +1 when Klimform is active, else use whatever is defined in the nuke index? Right now I simply have Loafers written in, but this sometimes results in a loss of damage if Klimaform wears off mid cast. Every time I try to alter it I break something, any help would be greatly appreciated.
Code if Nuke:contains(spell.name) then
equip(sets.Nuke[sets.Nuke.index[Nuke_ind]])
if (spell.element == world.day_element or spell.element == world.weather_element) then
equip(equip(sets.Nuke[sets.Nuke.index[Nuke_ind]]), sets.Obi)
else
equip({waist="Refoccilation Stone"})
end
end
I didn't make this, pretty sure it's a Kinematic's GS, but it has this rule for Klimaform equip and it seems to work for me:
Code
-- Equip sets appropriate to the active buffs, relative to the spell being cast.
function apply_grimoire_bonuses(spell, action, spellMap)
if state.Buff.Perpetuance and spell.type =='WhiteMagic' and spell.skill == 'Enhancing Magic' then
equip(sets.buff['Perpetuance'])
end
if state.Buff.Rapture and (spellMap == 'Cure' or spellMap == 'Curaga') then
equip(sets.buff['Rapture'])
end
if spell.skill == 'Elemental Magic' then --or spellMap ~= 'ElementalEnfeeble'
if state.Buff.Ebullience and spell.english ~= 'Impact' then
equip(sets.buff['Ebullience'])
end
if state.Buff.Immanence then
equip(sets.buff['Immanence'])
end
if state.Buff.Klimaform and spell.skill == "Elemental Magic" and spell.element == world.weather_element then
equip(sets.buff['Klimaform'])
end
end
if state.Buff.Penury then equip(sets.buff['Penury']) end
if state.Buff.Parsimony then equip(sets.buff['Parsimony']) end
if state.Buff.Celerity then equip(sets.buff['Celerity']) end
if state.Buff.Alacrity then equip(sets.buff['Alacrity']) end
end
Bahamut.Odaru
Server: Bahamut
Game: FFXI
By Bahamut.Odaru 2017-07-01 01:06:20
I just want to change
Code
if Nuke:contains(spell.name) then
equip(sets.Nuke[sets.Nuke.index[Nuke_ind]])
if (spell.element == world.day_element or spell.element == world.weather_element) then
equip(equip(sets.Nuke[sets.Nuke.index[Nuke_ind]]), sets.Obi)
else
equip({waist="Refoccilation Stone"})
end
end
to something like
Code
if Nuke:contains(spell.name) then
if (buffactive.Klimaform) then
equip(equip(sets.Nuke[sets.Nuke.index[Nuke_ind]]), {feet="Arbatel loafers +1"})
else
equip(sets.Nuke[sets.Nuke.index[Nuke_ind]])
end
if (spell.element == world.day_element or spell.element == world.weather_element) then
equip(equip(sets.Nuke[sets.Nuke.index[Nuke_ind]]), sets.Obi)
else
equip({waist="Refoccilation Stone"})
end
end
Writing it this way, I can load it without errors but the feet don't swap, and I'm not sure that I'm writing it in such a way that it doesn't mess up the Obi check.
EDIT: I think its working properly now, I was missing a { in one of the lines but it seems to be functioning properly now. Thank you for your suggestion, Berzerk.
Server: Shiva
Game: FFXI
Posts: 357
By Shiva.Berzerk 2017-07-01 01:16:57
I'm not that well-versed in gearswap rules but would you be able to do: Code
equip(equip(set_combine(sets.Nuke.index[Nuke_ind]]), {feet="Arbatel loafers +1"})
Bahamut.Odaru
Server: Bahamut
Game: FFXI
By Bahamut.Odaru 2017-07-01 01:18:40
I'm not that well-versed in gearswap rules but would you be able to do: Code
equip(equip(set_combine(sets.Nuke.index[Nuke_ind]]), {feet="Arbatel loafers +1"}
I was able to get it working. Yeah, I've seen quite a few luas that use the combine sets function but I've never written anything out like that. :o
Server: Shiva
Game: FFXI
Posts: 357
By Shiva.Berzerk 2017-07-01 01:27:57
Awesome! Did you have to modify what I posted? Just curious because I'm trying to learn gearswap but haven't tried messing with a rule like this before.
Bahamut.Odaru
Server: Bahamut
Game: FFXI
By Bahamut.Odaru 2017-07-01 17:50:20
Awesome! Did you have to modify what I posted? Just curious because I'm trying to learn gearswap but haven't tried messing with a rule like this before.
I just fixed what I wrote out myself, and it appeared to be working but now it isn't... ; ;
I'm new to it myself, I use standalone LUAs because I just glaze over trying to interpret the ones that use the mote/include files. Though, the ones I've been using seem to work out well enough, I'm not sure what the other versions offer that I'm not utilizing that I would need. I only really use them for glorified gearswapping, I've seen some LUAs that automatically use JAs and whatnot in response to actions/conditions and none of that really interests me, so for now what I have is enough.
I'm still trying to figure out how to make my midcast function swap feet properly, here's what I currently have written:
Code if Nuke:contains(spell.name) then
if (buffactive.Klimaform) then
equip(equip(sets.Nuke[sets.Nuke.index[Nuke_ind]]), {feet="Arbatel loafers +1"})
else
equip(sets.Nuke[sets.Nuke.index[Nuke_ind]])
end
if (spell.element == world.day_element or spell.element == world.weather_element) then
equip(equip(sets.Nuke[sets.Nuke.index[Nuke_ind]]), sets.Obi)
else
equip({waist="Refoccilation Stone"})
end
end
It loads fine, and everything works except Arbatel Loafers +1 swapping in when Klimaform is active. Any suggestions would be greatly appreciated.
Bahamut.Ayasha
Server: Bahamut
Game: FFXI
Posts: 89
By Bahamut.Ayasha 2017-07-01 21:03:17
Try changing the line: Code
if (buffactive.Klimaform) then
to: Code
if buffactive['Klimaform'] then
It is really hard to help you debug without being able to see the entire lua. I may be able to dig further in to see if there's any other errors if you post it in its entirety.
Also, a potential issue you are having is in the flow of that code block. In plain English it is doing this:
Check if the list 'Nuke' contains an element that matches the spell.
If so, check if Klimaform is active
If so, equip your nuking set that matches the spell, then equip your boots. If not, just equip your nuking set.
Check if the spell element matches the day/weather element.
If so, equip your nuking set, then equip your obi. If not, just equip your Refoccilation Stone.
End of function.
So, what it is doing is likely equipping your boots (if the function is working properly at all) and then equipping OVER that set with your nuking/obi set because you will almost necessarily be using the spell with the appropriate -storm spell. A fix you could implement would be to put your Klimaform check after the line:
Code
equip(equip(sets.Nuke[sets.Nuke.index[Nuke_ind]]), sets.Obi)
A very rough draft of how that entire function would look is something like this: Code
if (spell.element == world.day_element or spell.element == world.weather_element) and Nuke:contains(spell.name) then
equip(equip(sets.Nuke[sets.Nuke.index[Nuke_ind]]), sets.Obi)
if buffactive['Klimaform'] then
equip({feet="Arbatel loafers +1"})
end
elseif Nuke:contains(spell.name) and not (spell.element == world.day_element or spell.element == world.weather_element) then
equip(sets.Nuke[sets.Nuke.index[Nuke_ind]])
else
equip({waist="Refoccilation Stone"})
end
I hope this helps. But, again, it would be helpful if you posted the document in its entirety.
[+]
Server: Ragnarok
Game: FFXI
Posts: 853
By Ragnarok.Erikthecleric 2017-07-02 01:40:46
I'm having an issue with my SCH GS in the section where it's supposed to lock Back if CP mantle, or Rings if Warp/CP ring but it isn't doing it. Admittely my GS are usually a mix of other GS (this part from Bokura's GS)so I am having trouble seeing what the issue is myself though T_T...
Mantle/Ring lock section:
Code
function check_equip_lock()
if player.equipment.left_ring == "Warp Ring" or player.equipment.left_ring == "Capacity Ring" or player.equipment.right_ring == "Warp Ring" or player.equipment.right_ring == "Capacity Ring" then
disable('ring1','ring2')
elseif player.equipment.back == "Mecisto. Mantle" or player.equipment.back == "Aptitude Mantle +1" or player.equipment.back == "Aptitude Mantle" then
disable('back')
elseif Lock_Main == 'ON' then
disable('main','sub')
else
enable('main','sub','ring1','ring2','back')
end
end
Entire GS:
Code
function get_sets()
Lock_Main = 'OFF'
sets.precast = {}
sets.precast.CureCast = {Ammo="Impatiens",
Head="Merlinic Hood", Ear1="Loquacious Earring", Ear2="Nourishing Earring",
Body="Heka's Kalasiris", Hands="Augur's Gloves", Ring1="Ephedra Ring", Ring2="Sirona's Ring",
Back="Pahtli Cape", Waist="Witful Belt"}
sets.precast.FastCast = {Ammo="Impatiens",
Head="Merlinic Hood", Ear1="Loquacious Earring",
Body="Anhur Robe", Hands="Merlinic Dastanas",
Back="Perimede Cape", Waist="Witful Belt"}
sets.precast.Enhancing = {Main="Kirin's Pole", Sub="Fulcio Grip", Ammo="Savant's Treatise",
Head="Savant's Bonnet +2", Neck="Incanter's torque",
Body="Anhur Robe", Hands="Augur's Gloves",
Back="Perimede Cape", Waist="Olympus Sash", Legs="Scholar's Pants", Feet="Rubeus Boots"}
sets.precast.Elecast = {Neck="Stoicheion Medal"}
sets.precast.Stoneskin = set_combine(sets.precast.FastCast, {Waist="Olympus Sash"})
sets.precast.engagedPCure = set_combine(sets.precast.CureCast, {Main="Tamaxchi", Sub="Genbu's Shield"})
-----------------------
sets.midcast = {}
sets.midcast.CurePotency = {Main="Tamaxchi", Sub="Genbu's Shield", Ammo="Impatiens",
Head="Merlinic Hood", Neck="Incanter's Torque", Ear1="Roundel Earring", Ear2="Nourishing Earring",
Body="Heka's Kalasiris", Hands="Augur's Gloves", Ring1="Ephedra Ring", Ring2="Sirona's Ring",
Back="Tempered Cape +1", Waist="Korin Obi", Legs="Scholar's Pants", Feet="Rubeus Boots"}
sets.midcast.Enfeebling = {Main="Akademos", Sub="Bugard Leather Strap+1", Ammo="Savant's Treatise",
Head="Merlinic Hood", Neck="Incanter's Torque",
Body="Merlinic Jubbah", Hands="Merlinic Dastanas", Ring1="Icesoul Ring", Ring2="Strendu Ring",
Back="Aurist's Cape +1",Legs="Merlinic Shalwar", Feet="Rubeus Boots"}
sets.midcast.Enhancing = {Main="Kirin's Pole", Sub="Fulcio Grip", Ammo="Savant's Treatise",
Head="Savant's Bonnet +2", Neck="Incanter's torque",
Body="Anhur Robe", Hands="Augur's Gloves",
Back="Perimede Cape", Waist="Olympus Sash", Legs="Scholar's Pants", Feet="Rubeus Boots"}
sets.midcast.Haste = {Ammo="Impatiens",
Head="Merlinic Hood", Ear1="Loquacious Earring",
Body="Merlinic Jubbah", Hands="Merlinic Dastanas",
Waist="Witful Belt", Legs="Merlinic Shalwar"}
sets.midcast.Nuke ={Main="Akademos", Sub="", Ammo="Savant's Treatise",
Head="Merlinic Hood", Neck="Sanctity Necklace", Ear1="Hecate's Earring", Ear2="Friomisi Earring",
Body="Merlinic Jubbah", Hands="Merlinic Dastanas", Ring1="Icesoul Ring", Ring2="Strendu Ring",
Back="Hecate's Cape", Waist="Cognition Belt", Legs="Merlinic Shalwar", Feet="Rubeus Boots"}
sets.midcast.Macc = set_combine(sets.midcast.Nuke), {Back="Aurist's Cape +1"}
sets.midcast.ImmaNuke = set_combine(sets.midcast.Nuke, {Hands="Savant's Bracers +2"})
sets.midcast.engagedCure = set_combine(sets.midcast.CurePotency, {Main="Tamaxchi", Sub="Genbu's Shield"})
sets.midcast.Regen = set_combine(sets.midcast.CurePotency, {Head="Savant's Bonnet +2"})
sets.midcast.Perp1 = set_combine(sets.midcast.Enhancing, {Hands="Savant's Bracers +2"})
sets.midcast.Perp2 = set_combine(sets.midcast.Haste, {Hands="Savant's Bracers +2"})
sets.midcast.Perp3 = set_combine(sets.midcast.Regen, {Hands="Savant's Bracers +2"})
-----------------------
sets.aftercast = {}
sets.aftercast.engaged = {Main="Tamaxchi", Sub="Genbu's Shield",
Head="Merlinic Hood", Neck="Sanctity Necklace", Ear1="Ghillie Earring", Ear2="Brutal Earring",
Body="Merlinic Jubbah", Hands="Thrift Gloves +1",
Back="Aurist's Cape +1", Waist="Swift Belt", Legs="Assiduity Pants +1"}
sets.aftercast.idle = {Main="Akademos", Sub="Mensch Strap", Ammo="Homiliary",
Head="Nefer Khat +1", Neck="Sanctity Necklace", Ear1="Loquacious Earring", Ear2="Moonshade Earring",
Body="Heka's Kalasiris", Hands="Serpentes cuffs", Ring1="Paguroidea ring", Ring2="Sheltered Ring",
Back="Shadow Mantle", Waist="Witful Belt", Legs="Assiduity Pants +1", Feet="Herald's Gaiters"}
sets.aftercast.rest = {Main="Chatoyant Staff"}
end
-----------------------------------------------------------------------------------
function precast(spell)
if spell.skill == 'Healing Magic' then
if player.status == "Engaged" then
equip(sets.precast.engagedPCure)
elseif spell.name:startswith('Cura') or spell.name:startswith('Cure') then
equip(sets.precast.CureCast)
else
equip(sets.precast.FastCast)
end
elseif spell.skill == "Enhancing Magic" then
if spell.name:startswith('Bar') or spell.english == "Embrava" then
equip(sets.precast.Enhancing)
elseif spell.english == "Stoneskin" then
equip(sets.precast.Stoneskin)
else
equip(sets.precast.FastCast)
end
elseif spell.skill == "Elemental Magic" then
equip(sets.precast.EleCast)
elseif spell.skill == "Enfeebling Magic" then
equip(sets.precast.FastCast)
elseif spell.skill == "Dark Magic" then
equip(sets.precast.FastCast)
end
end
-----------------------------------------------------------------------------------
function midcast(spell)
if spell.skill == "Healing Magic" then
if player.status == "Engaged" then
equip(sets.midcast.engagedCure)
elseif spell.name:startswith('Cura') or spell.name:startswith('Cur') then
if buffactive['Rapture'] then
equip(sets.midcast.Regen)
else
equip(sets.midcast.CurePotency)
end
else
equip(sets.midcast.Haste)
end
elseif spell.skill == "Enhancing Magic" then
if spell.english == "Embrava" or spell.english == "Phalanx" or spell.english == "Aquaveil" or spell.name:startswith('Bar') then
if buffactive['Perpetuance'] then
equip(sets.midcast.Perp1)
else
equip(sets.midcast.Enhancing)
end
elseif spell.name:startswith('Regen') then
if buffactive['Perpetuance'] then
equip(sets.midcast.Perp3)
else
equip(sets.midcast.Regen)
end
elseif buffactive['Perpetuance'] then
equip(sets.midcast.Perp2)
else
equip(sets.midcast.Haste)
end
elseif spell.skill == "Elemental Magic" then
if buffactive['Immanence'] then
equip(sets.midcast.ImmaNuke)
else
equip(sets.midcast.Nukes)
end
elseif spell.skill == "Enfeebling Magic" then
equip(sets.midcast.Enfeebling)
elseif spell.skill == "Dark Magic" then
equip(sets.midcast.Macc)
end
end
-----------------------------------------------------------------------------------
function aftercast(spell)
if player.status == "Engaged" then
equip(sets.aftercast.engaged)
elseif player.status == "Idle" then
equip(sets.aftercast.idle)
end
end
-----------------------------------------------------------------------------------
function status_change(new,old)
check_equip_lock()
if new == 'Idle' then
equip(sets.aftercast.idle)
elseif new == 'Resting' then
equip(sets.aftercast.rest)
elseif new == 'Engaged' then
equip(sets.aftercast.engaged)
end
end
----------------------------------------------------------------------------------
function self_command(command)
if command == 'C3' then
if Lock_Main == 'ON' then
Lock_Main = 'OFF'
add_to_chat(123,'Main Weapon: [Unlocked]')
else
Lock_Main = 'ON'
add_to_chat(158,'Main Weapon: [Locked]')
end
status_change(player.status)
elseif command:match('^SC%d$') then
send_command('//' .. sc_map[command])
end
status_change(player.status)
end
-----------------------------------------------------------------------------------
function check_equip_lock()
if player.equipment.left_ring == "Warp Ring" or player.equipment.left_ring == "Capacity Ring" or player.equipment.right_ring == "Warp Ring" or player.equipment.right_ring == "Capacity Ring" then
disable('ring1','ring2')
elseif player.equipment.back == "Mecisto. Mantle" or player.equipment.back == "Aptitude Mantle +1" or player.equipment.back == "Aptitude Mantle" then
disable('back')
elseif Lock_Main == 'ON' then
disable('main','sub')
else
enable('main','sub','ring1','ring2','back')
end
end
-----------------------------------------------------------------------------------
function buff_change(name,gain)
if name == "silence" and gain =="True" then
send_command('@input /item "Echo Drops" <me>')
end
end
function select_default_macro_book()
set_macro_page(1, 2)
end
Bahamut.Ayasha
Server: Bahamut
Game: FFXI
Posts: 89
By Bahamut.Ayasha 2017-07-02 03:09:22
Forgive me for making assumptions on this, but I believe the reason it isn't locking your sets is because you never actually incur a status change. I'm assuming you do your stuff in a disengaged status. You can add a call to check_equip_lock() as the first line in your precast function and in your buff_change function to circumvent that.
Also, the way you have the check_equip_lock function set up is that it will only unlock your gear if NONE of the prerequisites are met, which can end up causing a lot of headaches. You should set it up so that it has a unique if/else block for each slot(s) you wish to have lock or unlock automatically.
Here's an example using your function:
Code
function check_equip_lock()
if player.equipment.left_ring == "Warp Ring" or player.equipment.left_ring == "Capacity Ring" or player.equipment.right_ring == "Warp Ring" or player.equipment.right_ring == "Capacity Ring" then
disable('ring1','ring2')
else
enable('ring1','ring2')
end
if player.equipment.back == "Mecisto. Mantle" or player.equipment.back == "Aptitude Mantle +1" or player.equipment.back == "Aptitude Mantle" then
disable('back')
else
enable('back')
end
if Lock_Main == 'ON' then
disable('main','sub')
else
enable('main','sub')
end
end
I haven't tested this, but hopefully will give you an idea of how to fix it. Best of luck!
[+]
Server: Ragnarok
Game: FFXI
Posts: 853
By Ragnarok.Erikthecleric 2017-07-02 03:18:48
I may have eventually figured something like this out, but yes that did the trick. TYVM. The GS referenced wasn't like that, but is much more in depth so there's probably a lot more going on in that I really catch.
Server: Ragnarok
Game: FFXI
Posts: 853
By Ragnarok.Erikthecleric 2017-07-02 17:15:48
Is there any way to get that code ^ to be split up?
Code function check_equip_lock()
if player.equipment.right_ring == "Warp Ring" or player.equipment.right_ring == "Capacity Ring" then
disable('ring2')
else
enable('ring2')
end
if player.equipment.left_ring == "Warp Ring" or player.equipment.left_ring == "Capacity Ring" then
disable('ring1')
else
enable('ring1')
end
if player.equipment.back == "Mecisto. Mantle" then
disable('back')
else
enable('back')
end
end
This ends up locking both left and right ring. When I take the right ring off, the left stays locked even though the right ring swaps. I have to play with it a little more, but from my observation it seems that they swap correctly until I put a warp ring on, then the left ring will not swap after that.
edit:
Fresh reloading yielded left ring still being locked from the start.
edit #2:
I'm just an idiot and mispelled my left ring lol.
Asura.Sagaxi
Server: Asura
Game: FFXI
Posts: 112
By Asura.Sagaxi 2017-07-05 14:01:38
If I have the following code in my lua :
Code if buffactive['Flurry'] then
equip(sets.precast.RA)
add_to_chat(122,"Flurry found")
else
equip(sets.precast.RA.noFlurry)
add_to_chat(122,"No flurry")
end
Can I do the same with buffactive['Flurry II'] to differienciate them? If not, what would be another way?
Thanks in advance!
Lakshmi.Elidyr
Server: Lakshmi
Game: FFXI
Posts: 912
By Lakshmi.Elidyr 2017-07-05 14:07:40
If I have the following code in my lua :
Code if buffactive['Flurry'] then
equip(sets.precast.RA)
add_to_chat(122,"Flurry found")
else
equip(sets.precast.RA.noFlurry)
add_to_chat(122,"No flurry")
end
Can I do the same with buffactive['Flurry II'] to differienciate them? If not, what would be another way?
Thanks in advance!
Some one can correct me if I am wrong, but I believe it is pulled from res.buffs which there for would not have two different versions. Flurry is flurry, similar to enlight, or haste.
[+]
Lakshmi.Veika
Server: Lakshmi
Game: FFXI
Posts: 48
By Lakshmi.Veika 2017-07-09 11:30:48
If I had multiple pieces of Herculean gear of the same piece with different augments. How would I go about separating them in my gearswap?
Bismarck.Lilmartio
Server: Bismarck
Game: FFXI
Posts: 47
By Bismarck.Lilmartio 2017-07-09 12:19:41
If I had multiple pieces of Herculean gear of the same piece with different augments. How would I go about separating them in my gearswap? If you like your lua to be nice and clean then you'll want to put the gear into your globals.
Method 1:
1) In game do //gs export for each piece of gear that you want, then find your export folder (should be located with your job luas)
2) Copy the line with the piece you want
Should look something like this: legs={ name="Herculean Trousers", augments={'Accuracy+10','Weapon skill damage +4%','STR+10',}}
3) Then go into your Globals and look for "Default items for utility gear values" and create a line in "Default items for utility gear values" labeling that piece of gear. For example, if the piece you've chosen is a WS piece then label it as:
gear.herc_legs_WS = legs={ name="Herculean Trousers", augments={'Accuracy+10','Weapon skill damage +4%','STR+10',}},
4) Go into your actual job lua and insert your piece as you labeled it in your globals in the gear slot, in this case it would be under legs. Example of this would be:
legs=herc_legs_WS,
This is one way of doing it. There is another way, but it tends to get messy. I personally don't really care about neatness as long is it gets the job done.
Method 2:
1) Same as Method 1
2) Same as Method 1
3) Go into your job lua and insert it into the piece, this example would be legs:
legs={ name="Herculean Trousers", augments={'Accuracy+10','Weapon skill damage +4%','STR+10',}},
And that's it. Hope this helped in anyway.
If I have the following code in my lua :
Code if buffactive['Flurry'] then
equip(sets.precast.RA)
add_to_chat(122,"Flurry found")
else
equip(sets.precast.RA.noFlurry)
add_to_chat(122,"No flurry")
end
Can I do the same with buffactive['Flurry II'] to differienciate them? If not, what would be another way?
Thanks in advance! You can do this, but you'll have to set a toggle.
state.FlurryMode = M{['description']='Flurry Mode', 'Flurry II', 'Flurry I'}
Then set your toggle button, In my case I have it set to this:
send_command('bind @delete gs c cycle FlurryMode')
which is windows button and delete. Code function job_post_precast(spell, action, spellMap, eventArgs)
if spell.action_type == 'Ranged Attack' then
if state.FlurryMode.value == 'Flurry II' and (buffactive[265] or buffactive[581]) then
equip(sets.precast.RA.Flurry2)
elseif state.FlurryMode.value == 'Flurry I' and (buffactive[265] or buffactive[581]) then
equip(sets.precast.RA.Flurry1)
end
Hope this helps.
Leviathan.Isiolia
Server: Leviathan
Game: FFXI
Posts: 468
By Leviathan.Isiolia 2017-07-09 12:36:42
If I had multiple pieces of Herculean gear of the same piece with different augments. How would I go about separating them in my gearswap?
First, equip each of them and type this:
You should get a message saying that Gearswap is exporting your current gear.
Now, you can go into where you have Windower installed, and look in addons\Gearswap\data for the export folder. In there will be .lua(s) named by character and export date. You can always sort by date modified to make it easier.
Anyway, open one up, and the augmented gear will have the full augment list there.
For example, a JSE cape: Code back={ name="Ogma's cape", augments={'DEX+20','Accuracy+20 Attack+20','"Store TP"+10',}},
Copy everything between the outer brackets and open your job's .lua file if it's not already.
Technically, you can use that in place of the equipment name, but that'll get messy, if not annoying to update.
Instead, what we can now is define variables for augmented items to use instead. I like to put them right before defining sets, though I'm not sure it matters.
So, continuing the example, that cape and other augmented stuff from my RUN LUA: Code jsecape_DA = { name="Ogma's cape", augments={'STR+20','Accuracy+20 Attack+20','"Dbl.Atk."+10',}}
jsecape_STP = { name="Ogma's cape", augments={'DEX+20','Accuracy+20 Attack+20','"Store TP"+10',}}
idle_HercHand = { name="Herculean Gloves", augments={'Rng.Acc.+18','Spell interruption rate down -8%','"Refresh"+1','Accuracy+7 Attack+7','Mag. Acc.+2 "Mag.Atk.Bns."+2',}}
idle_HercFeet = { name="Herculean Boots", augments={'Mag. Acc.+27','CHR+7','"Refresh"+1','Accuracy+1 Attack+1','Mag. Acc.+6 "Mag.Atk.Bns."+6',}}
melee_HercHand = { name="Herculean Gloves", augments={'Accuracy+16 Attack+16','"Triple Atk."+3','Accuracy+6','Attack+15',}}
melee_HercFeet = { name="Herculean Boots", augments={'Accuracy+25 Attack+25','"Triple Atk."+1','STR+7','Accuracy+10',}}
Having defined the armor pieces that way, you can simply use the variable name to equip them.
For example: Code
sets.TP.Standard = {ammo="Ginsen",
head="Adhemar Bonnet",neck="Lissome necklace", ear1="Brutal earring", ear2="Cessance earring",
body="Adhemar Jacket",hands=melee_HercHand,ring1="Epona's ring",ring2="Petrov Ring",
back=jsecape_STP,waist="Windbuffet Belt +1",legs="Samnuha Tights",feet=melee_HercFeet}
Note that you don't need quotes around the variable names.
Also, notice that augments that may show up as a single stat may technically be combining two augments, which is why it's much better to use the //gs export command to ensure accuracy.
Hopefully that makes sense.
By Feanorsof 2017-07-11 18:31:09
Is there any way to get something like this working?
Code if main == 'Ukonvasara' then
send_command('input //exec war_gaxe.txt')
elseif main == 'Ragnarok' then
send_command('input //exec war_gsword.txt')
elseif main == 'Loxotic Mace +1' then
send_command('input //exec war_club.txt')
elseif main == 'Reikiko' then
send_command('input //exec war_sword.txt')
elseif main == 'Barbarity' then
send_command('input //exec war_axe.txt')
end
I have something similar that works for sub jobs but would like something based on weapon
Code if player.sub_job == 'BLU' then
send_command('input //exec run_blu.txt')
elseif player.sub_job == 'WAR' then
send_command('input //exec run_war.txt')
elseif player.sub_job == 'DRK' then
send_command('input //exec run_drk.txt')
elseif player.sub_job == 'SAM' then
send_command('input //exec run_sam.txt')
elseif player.sub_job == 'NIN' then
send_command('input //exec run_nin.txt')
end
Shiva.Hiep
Server: Shiva
Game: FFXI
Posts: 669
By Shiva.Hiep 2017-07-14 11:44:38
Having issues since recent updates where gearswap sends don't work on alt characters. Any solutions?
Quetzalcoatl.Landsoul
Server: Quetzalcoatl
Game: FFXI
Posts: 78
By Quetzalcoatl.Landsoul 2017-07-22 12:12:06
Can i make gearswap reconize what weapon i have and depending on weapon it equips different tp sets?
I've tried
or
But neither gearswap reconizes that it swaps the propperiate set.
Phoenix.Habar
Server: Phoenix
Game: FFXI
Posts: 19
By Phoenix.Habar 2017-08-03 07:33:17
I'm running into this problem where when casting elemental magic gearswap won't revert back to idle.
short spells have almost no issue.
Stone seems to trigger it sometimes and equip remains in midcast
Stone 2 has more chance of it being stuck in midcast and so on...
seems to have something to do with casting time?
Tried several lua files all seem to run into the same issue.
Server: Asura
Game: FFXI
Posts: 9
By Asura.Vdoubleo 2017-08-04 06:02:07
Getting lua runtime error: gearswap/equip_processing.lua:246: attempt to index field '?' (a nil value) when equipping the new Hepatizon Sapara +1 since the new update.
Seen someone mention having this issue with moonbow whistle when that updated but didn't see how it was resolved.
I imagine its an equipment list somewhere that needs updating but I have no clue how to do it so gearswap doesn't swap gear if i put this sword on at the moment. Anyone else experiencing this? or know a fix?
Just looking for someone to explain this addon a bit for me. It looks like it is an alternative to Spellcast.
Is it going to be replacing Spellcast? In which ways is it better or worse. I don't know any programming but I've slowly learned more and more about spellcast and the 'language' used in gearswap is confusing to me.
It says it uses packets so it potentially could be more detectable? but does that also eliminate any lag that spellcast may encounter?
I plan on redoing my PUP xml to include pet casting sets thanks to the new addon petschool. I'm just not sure if it's worth it to just wait until gearswap gets more popular or to go ahead and do it in spellcast.
If anyone could give me more info I'd greatly appreciate it.
|
|