|
Gearswap Support Thread
By kenshynofshiva 2014-08-03 12:56:27
Any way to determine if your busy casting or shooting range or weaponskilling so I can cancel spells?
Lakshmi.Byrth
VIP
サーバ: Lakshmi
Game: FFXI
Posts: 6200
By Lakshmi.Byrth 2014-08-03 13:49:57
midaction() is supposed to do that. It honestly doesn't work that well and I'm still trying to figure out why.
サーバ: Sylph
Game: FFXI
Posts: 305
By Sylph.Elgorian 2014-08-03 21:16:51
How would I add a more then 100MP TP set for THF.lua? for the triple attack ring
I use this on monk:
Code function aftercast(spell)
if player.status =='Engaged' then
if TP_Index == 1 then
if player.mp >= 100 then
equip(sets.TP[sets.TP.index[TP_Index]])
elseif player.mp < 100 then
equip(sets.TP[sets.TP.index[TP_Index]], {ring2="Rajas Ring"})
end
else
equip(sets.TP[sets.TP.index[TP_Index]])
end
else
equip(sets.aftercast.Idle)
end
end
big picture here:
Code function get_sets()
sets.misc = {}
sets.misc.SM = {back="Shadow Mantle"}
sets.misc.Impetus = {body="Tantra Cyclas +2"}
sets.misc.Idle = {
head="Ocelo. Headpiece", neck="Twilight Torque",
body="Hesychast's Cyclas", ring1="Paguroidea Ring", ring2="Sheltered Ring",
feet="Hermes' Sandals" }
sets.misc.Chakra = {
ammo="Tantra Tathlum",
head="Uk'uxkaj Cap", neck="Tjukurrpa Medal", ear1="Soil Pearl", ear2="Soil Pearl",
body="Anchorite's Cyclas +1", hands="Hesychast's Gloves +1", ring1="Terrasoul Ring", ring2="Terrasoul Ring",
back="Anchoret's Mantle", waist="Caudata Belt", legs="Quiahuiz Trousers", feet="Thurandaut Boots +1" }
sets.precast = {}
sets.precast['Perfect Counter'] = {}
sets.precast['Hundred Fists'] = {legs="Hesychast's Hose"}
sets.precast.Boost = {hands="Temple Gloves"}
sets.precast.Counterstance = {feet="Hesychast's Gaiters"}
sets.precast['Formless Strikes'] = {body="Hesychast's Cyclas"}
sets.precast.Dodge = {feet="Anchorite's Gaiters"}
sets.precast.Focus = {head="Temple Crown"}
sets.precast.Mantra = {feet="Hesychast's Gaiters"}
sets.precast.Waltz = {}
sets.precast.FC = {ammo="Impatiens", ear1="Loquacious Earring" }
sets.precast['Shijin Spiral'] = {
ammo="Honed Tathlum",
head="Uk'uxkaj Cap", neck="Asperity Necklace", ear1="Bladeborn Earring", ear2="Steelflash Earring",
body="Qaaxo Harness", hands="Hesychast's Gloves +1", ring1="Epona's Ring", ring2="Jupiter's Ring",
back="Atheling Mantle", waist="Caudata Belt", legs="Manibozho Brais", feet="Espial Socks" }
sets.VS = {}
sets.VS.index = {'DD', 'Acc'}
VS_Index = 1
sets.VS.DD = { -- 119 AF Body
ammo="Potestas Bomblet",
head="Uk'uxkaj Cap", neck="Tjukurrpa Medal", ear1="Brutal Earring", ear2="Moonshade Earring",
body="Anchorite's Cyclas +1", hands="Hesychast's Gloves +1", ring1="Epona's Ring", ring2="Rajas Ring",
back="Atheling Mantle", waist="Caudata Belt", legs="Manibozho Brais", feet="Manibozho Boots" }
sets.VS.Acc = { --letalis mantle
ammo="Honed Tathlum",
head="Uk'uxkaj Cap", neck="Tjukurpa Medal", ear1="Brutal Earring", ear2="Moonshade Earring",
body="Anchorite's Cyclas +1", hands="Hesychast's Gloves +1", ring1="Epona's Ring", ring2="Rajas Ring",
back="Anchoret's Mantle", waist="Caudata Belt", legs="Manibozho Brais", feet="Manibozho Boots" }
sets.TP = {}
sets.TP.index = {'DD','Acc','DT',}
TP_Index = 1
sets.TP.DD = {
ammo="Potestas Bomblet",
head="Uk'uxkaj Cap", neck="Asperity Necklace", ear1="Bladeborn Earring", ear2="Steelflash Earring",
body="Qaaxo Harness", hands="Hesychast's Gloves +1", ring1="Epona's Ring", ring2="Oneiros Ring",
back="Atheling Mantle", waist="Windbuffet Belt", legs="Manibozho Brais", feet="Manibozho Boots" }
sets.TP.Acc = { -- letalis, potentially swap in agasaya/anguinus if still issues
ammo="Honed Tathlum",
head="Uk'uxkaj Cap", neck="Asperity Necklace", ear1="Bladeborn Earring", ear2="Steelflash Earring",
body="Qaaxo Harness", hands="Hesychast's Gloves +1", ring1="Epona's Ring", ring2="Oneiros Ring",
back="Anchoret's Mantle", waist="Windbuffet Belt", legs="Manibozho Brais", feet="Manibozho Boots" }
sets.TP.DT = {
ammo="Tantra Tathlum",
head="Uk'uxkaj Cap", neck="Twilight Torque", ear1="Merman's Earring", ear2="Merman's Earring",
body="Qaaxo Harness", hands="Buremete Gloves", ring1="Dark Ring", ring2="Dark Ring",
back="Mollusca Mantle", waist="Black Belt", legs="Quiahuiz Trousers", feet="Thurandaut Boots +1" }
sets.aftercast = {}
sets.aftercast.Idle = set_combine(sets.TP.DD, sets.misc.Idle)
end
function precast(spell)
if player.equipment.head == 'Reraise Hairpin' then disable('head')
else enable('head') end
if player.equipment.left_ear == 'Reraise Earring' then disable('ear1')
else enable('ear1') end
if player.equipment.right_ear == 'Reraise Earring' then disable('ear2')
else enable('ear2') end
if spell.name=="Chakra" and world.day_element=="Dark" then
equip(set_combine(sets.misc.Chakra, sets.misc.SM))
elseif spell.name=="Chakra" then
equip(sets.misc.Chakra)
end
if sets.precast[spell.english] then
equip(sets.precast[spell.english])
end
if spell.type=="Ninjutsu" then
equip(sets.precast.FC)
end
if (spell.english=="Victory Smite" or spell.english=="Ascetic's Fury") and buffactive['Impetus'] then
equip(set_combine(sets.VS[sets.VS.index[VS_Index]], sets.misc.Impetus))
elseif spell.type=="Victory Smite" or spell.english=="Ascetic's Fury" then
equip(sets.VS[sets.VS.index[VS_Index]])
elseif spell.type=="WeaponSkill" then
equip(sets.precast.WS)
end
if string.find(spell.english,'Waltz') then
equip(sets.precast.Waltz)
end
end
function midcast(spell)
end
function aftercast(spell)
if player.status =='Engaged' then
if TP_Index == 1 then
if player.mp >= 100 then
equip(sets.TP[sets.TP.index[TP_Index]])
elseif player.mp < 100 then
equip(sets.TP[sets.TP.index[TP_Index]], {ring2="Rajas Ring"})
end
else
equip(sets.TP[sets.TP.index[TP_Index]])
end
else
equip(sets.aftercast.Idle)
end
end
function status_change(new,old)
if T{'Idle','Resting'}:contains(new) then
equip(sets.aftercast.Idle)
elseif new == 'Engaged' then
equip(sets.TP[sets.TP.index[TP_Index]])
end
end
function self_command(command)
if command == 'TP' then
TP_Index = TP_Index +1
if TP_Index > 2 then
TP_Index = 1
end
send_command('@ input /echo >>> TP set changed to '..sets.TP.index[TP_Index]..' ')
equip(sets.TP[sets.TP.index[TP_Index]])
end
if command == 'DT' then
TP_Index = 3
send_command('@ input /echo >>> TP set changed to '..sets.TP.index[TP_Index]..' ')
equip(sets.TP[sets.TP.index[TP_Index]])
end
if command == "VS" then
VS_Index = VS_Index +1
if VS_Index > #sets.VS.index then VS_Index = 1 end
send_command('@ input /echo >>> VS set changed to '..sets.VS.index[VS_Index]..' ')
end
end
function select_default_macro_book()
if player.sub_job == 'NIN' then
set_macro_page(3, 1)
elseif player.sub_job == 'DNC' then
set_macro_page(5, 1)
elseif player.sub_job == 'RUN' then
set_macro_page(7, 1)
else
set_macro_page(1, 1)
end
end
[+]
By kenshynofshiva 2014-08-04 12:46:43
That extra elseif can be eliminated simply needs a else:
Code
if player.mp >= 100 then
equip(sets.TP[sets.TP.index[TP_Index]])
else
equip(sets.TP[sets.TP.index[TP_Index]], {ring2="Rajas Ring"})
end
[+]
サーバ: Sylph
Game: FFXI
Posts: 305
By Sylph.Elgorian 2014-08-05 23:39:56
Is there a way to do something similar to this but make it less spamtastic?
Code function buff_change(new,old)
if buffactive['Enmity Boost'] then
send_command('@ input /echo >>> Crusade UP <<<')
else
send_command('@ input /echo >>> Crusade DOWN <<<')
end
if buffactive['Phalanx'] then
send_command('@ input /echo >>> Phalanx UP <<<')
else
send_command('@ input /echo >>> Phalanx DOWN <<<')
end
end
By gdiShun 2014-08-06 00:04:54
Something like:
Code function job_buff_change(buff, gain)
if S{'enmity boost'}:contains(buff:lower()) then
if gain == true then
send_command('@ input /echo >>> Crusade UP <<<')
else
send_command('@ input /echo >>> Crusade DOWN <<<')
end
end
end
I'm not 100% sure gain is boolean.
EDIT/UNDELETE: Sorry, just wanted to make sure it worked. :x
Bismarck.Inference
サーバ: Bismarck
Game: FFXI
Posts: 417
By Bismarck.Inference 2014-08-06 00:07:57
The argument for buff_change is (name,gain), unlike status_change which uses (new,old). Name refers to the buff name, and gain is true if you gained said buff, or false if you lost said buff.
I imagine your problem right now is you're getting the echos every time you get any buff, when you actually just want it to echo when you activate it(seems a little trivial since if you activate you clearly know you have the buff), and the moment its lost.
If my assumptions are correct, you'd want it to look something like this :
Code
function buff_change(name,gain)
if name == 'Enmity Boost' and gain then
send_command('@ input /echo >>> Crusade UP <<<')
elseif name == 'Enmity Boost' and not gain then
send_command('@ input /echo >>> Crusade DOWN <<<')
end
end
Phalanx would be the same except for changing 'Enmity Boost' to 'Phalanx' obviously.
Edit : Or could further generalize using the : Code
if S{'Enmity Boost'}:contains(name) then
suggestion, expanding the table to include everything you'd like to check S{'Enmity Boost','Phalanx','Protect'} for example, then changing your send command lines to
Code
send_command('@ input /echo >>> '..name..' UP <<<')
The upside is you only have to change the table anytime you want to adjust the trigger buffs, and less lines of code. The downside is you get 'Enmity Boost UP' displayed instead of 'Crusade UP', but specific spells that have different buff names like that could be custom mapped if it's that important.
サーバ: Phoenix
Game: FFXI
Posts: 82
By Phoenix.Raistlinmaj 2014-08-06 09:10:12
So.. new to GS and have a couple questions. Messing with the Byrth_Pld sample, I notice it's calling out JA sets as midcast, as well as WS sets, is this correct? I thought it would be precast.
Also I can't seem to figure how to save my work to w/e correct folder within GS, keeps telling me I don't have permission.
サーバ: Sylph
Game: FFXI
Posts: 305
By Sylph.Elgorian 2014-08-06 12:27:08
Bismarck.Inference said: »The argument for buff_change is (name,gain), unlike status_change which uses (new,old). Name refers to the buff name, and gain is true if you gained said buff, or false if you lost said buff.
I imagine your problem right now is you're getting the echos every time you get any buff, when you actually just want it to echo when you activate it(seems a little trivial since if you activate you clearly know you have the buff), and the moment its lost.
If my assumptions are correct, you'd want it to look something like this :
Code
function buff_change(name,gain)
if name == 'Enmity Boost' and gain then
send_command('@ input /echo >>> Crusade UP <<<')
elseif name == 'Enmity Boost' and not gain then
send_command('@ input /echo >>> Crusade DOWN <<<')
end
end
Phalanx would be the same except for changing 'Enmity Boost' to 'Phalanx' obviously.
Edit : Or could further generalize using the : Code
if S{'Enmity Boost'}:contains(name) then
suggestion, expanding the table to include everything you'd like to check S{'Enmity Boost','Phalanx','Protect'} for example, then changing your send command lines to
Code
send_command('@ input /echo >>> '..name..' UP <<<')
The upside is you only have to change the table anytime you want to adjust the trigger buffs, and less lines of code. The downside is you get 'Enmity Boost UP' displayed instead of 'Crusade UP', but specific spells that have different buff names like that could be custom mapped if it's that important.
Thanks for that. Yes... I only really need the DOWN part... but at the time of writing it I put the UP in as well.
Pro/Shell visuals are usually noticeable when gone. Phalanx and Crusade can blend in with Rampart/Zerk/Whatever else and generally don't last as long as pro/shell. Thanks for the (name, gain) tip though! I'll play around with it. :)
EDIT:
Code function buff_change(name,gain)
if name == 'Enmity Boost' and not gain then
send_command('@ input /echo >>> Crusade DOWN <<<')
end
if name == 'Phalanx' and not gain then
send_command('@ input /echo >>> Phalanx DOWN <<<')
end
end
Ended up going with this.
Odin.Dirac
サーバ: Odin
Game: FFXI
Posts: 22
By Odin.Dirac 2014-08-06 22:28:55
midaction() is supposed to do that. It honestly doesn't work that well and I'm still trying to figure out why.
It seems odd to me that gearswap is (or my state tracker is buggy) re-entrant between the 3 casting phases since you can't ever sucessfully start an action before your previous action is finished or interrupted. I'd think that it would be enough for midaction to just keep track of what gearswap is doing without needing to rely on game state, but I don't really know what I'm talking about....
Also, about the resources conflict between spell.recast_id and spell.id you mentioned confused me, since I'm not specifying which to use anywhere. Is it configurable somewhere?
サーバ: Sylph
Game: FFXI
Posts: 1119
By Sylph.Safiyyah 2014-08-07 00:01:42
I'm using a lightly-modified version of Bokura's Gearswap for SAM. Even when I don't meet the conditions, it keeps triggering my STR earring to equip as precast for Fudo/Shoha:
Code if player.status ~= 'Engaged' then -- Cancel WS If You Are Not Engaged. Can Delete It If You Don't Need It --
cancel_spell()
add_to_chat(123,'Unable To Use WeaponSkill: [Disengaged]')
return
else
equipSet = sets.WS
if equipSet[spell.english] then
equipSet = equipSet[spell.english]
end
if Attack == 'ON' then
equipSet = equipSet["ATT"]
end
if equipSet[AccArray[AccIndex]] then
equipSet = equipSet[AccArray[AccIndex]]
end
if buffactive["Samurai Roll"] and equipSet["STP"] and Samurai_Roll == 'ON' then
equipSet = equipSet["STP"]
end
if buffactive.Sekkanoki then -- Equip Unkai Kote +2 When Sekkanoki Is On --
equipSet = set_combine(equipSet,{hands="Unkai Kote +2"})
end
if buffactive.Sengikori then -- Equip Unkai Sune-ate +2 When Sengikori Is On --
equipSet = set_combine(equipSet,{feet="Unkai Sune-ate +2"})
end
if (spell.english == "Tachi: Fudo" or spell.english == "Tachi: Shoha") and (player.tp > 299 or buffactive.Sekkanoki or (player.tp > 199 and buffactive.Hagakure)) then -- Equip Flame Pearl When You Have 300 TP or Sekkanoki On or 200+ TP For Hagakure --
equipSet = set_combine(equipSet,{ear1="Flame Pearl"})
end
equip(equipSet)
end
Anyone else run into this? edit: nevermind. I'm an idiot.
サーバ: Fenrir
Game: FFXI
Posts: 354
By Fenrir.Divinian 2014-08-09 07:22:54
I had asked this before, but thought I had "fixed" it, but the issue cropped up agai very soon after and I have been simply dealing with it. I apologize if this has been said/asked already, but I am having some trouble with the '//gs export sets xml' command. It is leaving certain pieces of gear (both older and newer) out. It has been leaving Izizoeksi out for a while now (I manually add it) and is now not converting new gear sets that I make into an xml.
Is this happening for anyone else? Is there something I am doing wrong? Any advice? Thanks in advance.
This is still happening to me when I use //gs export sets xml. When I make a DD GS, I never put weapons into the actual gear sets so that I can choose which weapons I want to use manually instead of allowing GS to do it. What I do to try and collect the items is create a "dummy" set that does not have a rule attached to it. This does not seem to be working. For example, if I put Usonmunku in a dummy precast_collect set, and then //gs export sets xml, it will not end up in the xml.
Also, //gs export sets xml does not catch gear locks, like mavi kavuk +2 when chain affinity is up.
Thoughts?
By gdiShun 2014-08-09 13:18:11
Does 'gs c update' run your update function or just updates your set to your current status?
Bismarck.Inference
サーバ: Bismarck
Game: FFXI
Posts: 417
By Bismarck.Inference 2014-08-09 17:04:07
Has to be a command you defined in self_command, at which point it will do whatever you tell it to do. Easiest method is to just tell it to run status_change(player.status) which would do the latter.
By gdiShun 2014-08-09 17:29:43
Bismarck.Inference said: »Has to be a command you defined in self_command, at which point it will do whatever you tell it to do. Easiest method is to just tell it to run status_change(player.status) which would do the latter.
Maybe it's a Mote command then? Because it's not in any of my files but it seems to maybe do the later. I'll look.
EDIT: Yeah, it is. And it does just do the latter.
VIP
サーバ: Fenrir
Game: FFXI
Posts: 764
By Fenrir.Motenten 2014-08-09 18:03:09
Does 'gs c update' run your update function or just updates your set to your current status?
If it's based on mine, it will: refresh state.Buff tracking variables, run any job_update function you've defined, and (unless you told it otherwise in job_update) re-equip gear based on your current status. If you add 'user' to the end of it (so 'gs c update user') it will also call the function that displays your current state.
[+]
サーバ: Phoenix
Game: FFXI
Posts: 82
By Phoenix.Raistlinmaj 2014-08-09 18:13:18
So where do I save name_job xml files? and is it in xml or lua? confused here,also bump for my last post, ty in advance.
サーバ: Phoenix
Game: FFXI
Posts: 282
By Phoenix.Chomeymatt 2014-08-09 18:31:37
Save em as .lua files, name them as charactername_job.lua . Save em to Windower 4 folder -> addons -> GearSwap -> data.
VIP
サーバ: Fenrir
Game: FFXI
Posts: 764
By Fenrir.Motenten 2014-08-09 18:36:42
Quote: So.. new to GS and have a couple questions. Messing with the Byrth_Pld sample, I notice it's calling out JA sets as midcast, as well as WS sets, is this correct? I thought it would be precast.
Technically, JAs and weaponskills have their effects calculated at midcast. That's usually ignored, though, because there's nothing of value to equip in precast that you'd have any reason to separate equips for. So basically, you can go either way and it's all pretty much the same.
Quote: Also I can't seem to figure how to save my work to w/e correct folder within GS, keeps telling me I don't have permission.
If you have permissions problems with saving files in the default Windower directory, you can instead save your files in $APPDATA$/Windower/GearSwap (or optionally, $APPDATA$/Windower/GearSwap/<charactername>).
$APPDATA$ depends on your OS. On Windows 7, it would be C:\Users\<username>\AppData\Roaming\Windower. Google 'windows appdata directory' for other operating systems.
Anyway, that directory is explicitly for saving files that the user has full access to, so you don't have to worry about permissions problems editing files in the install directory.
サーバ: Phoenix
Game: FFXI
Posts: 82
By Phoenix.Raistlinmaj 2014-08-09 18:50:50
Cool,thanks, so now about 20 more hours of fiddling to get it halfway where I want it,lol.
Quetzalcoatl.Guthrie
サーバ: Quetzalcoatl
Game: FFXI
Posts: 80
By Quetzalcoatl.Guthrie 2014-08-09 20:11:32
Mote (or anyone else),
In Mote's SMN file, how could I set up a rule to use SMN AF3+2 when using Cure BPs to gain the TP bonus on them?
Thanks!
By Selindrile 2014-08-09 20:38:01
This is more a windower question, but what's the shortcut to bind the \ key, I've tried \ and backslash and even |, if you're not following what I'm asking:
send_command('bind ^\ input /ja "Chivalry" <me>')
send_command('bind !\ input /ja "Palisade" <me>')
send_command('bind ^backslash input /ja "Chivalry" <me>')
send_command('bind !backslash input /ja "Palisade" <me>')
send_command('bind ^| input /ja "Chivalry" <me>')
send_command('bind !| input /ja "Palisade" <me>')
This works fine with backspace, and most keys I've tried, but I can't seem to get it to work with backslash, anyone know?
Leviathan.Vow
サーバ: Leviathan
Game: FFXI
Posts: 125
By Leviathan.Vow 2014-08-09 21:16:07
bind \\ input stuff
Backslash is an escape character.
By Selindrile 2014-08-09 21:18:04
Ah, thanks!
--Correction, still not working for me, just tried:
send_command('bind ^\\ input /ja "Dark Arts" <me>')
send_command('bind !\\ input /ja "Addendum: Black" <me>')
send_command('bind @\\ input /ja "Manifestation" <me>')
send_command('bind \\ input /ja "Manifestation" <me>')
update:
Interestingly that works if I just use a command in the windower console to bind, but it doesn't work when loaded with my lua, which is important as I want these bindings to change from job to job.
Leviathan.Vow
サーバ: Leviathan
Game: FFXI
Posts: 125
By Leviathan.Vow 2014-08-09 22:00:08
From a Lua file: bind \\\\ input stuff.
By Selindrile 2014-08-09 22:20:16
Again, thank you!
サーバ: Sylph
Game: FFXI
Posts: 11
By Sylph.Marvolous 2014-08-10 18:13:31
Having issues with sets.precast.WS["Rudra's Storm"]
No lua errors. However, in game, when I try to //gs equip sets.precast.WS["Rudra's Storm"] - I get an error that says the set does not exist.
VIP
サーバ: Odin
Game: FFXI
Posts: 9534
By Odin.Jassik 2014-08-10 18:21:14
It's case sensitive, make sure that you have capitals in all the right places.
By gdiShun 2014-08-10 18:27:50
Make sure sets.precast is declared somewhere(Unless you're using Mote's which then I don't think it needs to be).
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.
|
|