Gearswap Support Thread

Language: JP EN DE FR
users online
Forum » Windower » Support » Gearswap Support Thread
Gearswap Support Thread
First Page 2 3 ... 184 185
VIP
Offline
Posts: 787
By Lili 2024-12-01 06:38:15
Link | Quote | Reply
 
Bahamut.Bojack said: »
Is there a way to check in-game if the set is correctly finding all the gear? Like a gs command I can type to force it to equip my WS gear for example?

For specific, single sets

open Equipment menu
//gs equip naked
//gs equip sets.precast["Knights of the Rotund"]
(or whatever applicable)

otherwise
//gs showswaps
(prints to chatlog)
 Asura.Chendar
Offline
Server: Asura
Game: FFXI
user: chendar
Posts: 137
By Asura.Chendar 2024-12-01 06:38:45
Link | Quote | Reply
 
Kaffy said: »
Bahamut.Bojack said: »
Is there a way to check in-game if the set is correctly finding all the gear? Like a gs command I can type to force it to equip my WS gear for example?

//gs validate
and
//gs showswaps

^ This. Validate lists any gear that is specified in the lua file, but can't be found in your inventory. Showswaps shows exactly which pieces are swapping on successful swaps.

Also:
//gs equip "nameofset" to force equip a specific set

so as an example, for your basic engaged set:
//gs equip sets.engaged.basic
 Bahamut.Bojack
Online
Server: Bahamut
Game: FFXI
user: Bojack316
Posts: 2102
By Bahamut.Bojack 2024-12-08 13:38:38
Link | Quote | Reply
 
Is there such thing as too much code for GearSwap. Like if I keep adding things that are a bit noobish but it all works will it get to a point that it's too much for the add-on to read, or is minimizing code just for ease of use for the player?
 Bahamut.Noscrying
Online
Server: Bahamut
Game: FFXI
user: NoScrying
Posts: 70
By Bahamut.Noscrying 2024-12-09 01:52:00
Link | Quote | Reply
 
Bahamut.Bojack said: »
Is there such thing as too much code for GearSwap. Like if I keep adding things that are a bit noobish but it all works will it get to a point that it's too much for the add-on to read, or is minimizing code just for ease of use for the player?
I know my game starts chugging if I'm next to a 6-boxer, while it runs fine with a full Dyna PT.
I'm guessing when it's fully automated it spams the *** out of some packets making the rest of us lag, but that's mostly guesswork.
A worse lua would mean more checks, again, guesswork.
 Bahamut.Bojack
Online
Server: Bahamut
Game: FFXI
user: Bojack316
Posts: 2102
By Bahamut.Bojack 2024-12-13 00:15:21
Link | Quote | Reply
 
Working on adding in Gear for specific Job Abilities and Spells and I've noticed that stuff I have in midcast sets seem to also get equipped immediately like the precast gear. Wondering if I'm doing something incorrectly or if that's just how it works.
Code
	sets.precast.BM = {
	    head="Abyss Burgeonet +2",
		left_ear="Loquac. Earring",
}	
   
    sets.precast.WS = {
		ammo="Fracas Grenade",
		body={ name="Miki. Breastplate", augments={'Attack+15','Accuracy+10','STR+10',}},
		left_ear={ name="Moonshade Earring", augments={'Attack+4','TP Bonus +250',}},
		right_ear="Brutal Earring",
		left_ring="Pyrosoul Ring",
		right_ring="Pyrosoul Ring",
}
	sets.JA = {}
	sets.JA['Souleater'] = {
		head="Chaos Burgeonet",
}	    
	sets.JA['Weapon Bash'] = {
		hands="Chaos Gauntlets",
}
	sets.JA['Arcane Circle'] = {
		feet="Chaos Sollerets",
}
	sets.JA['Dark Seal'] = {
		head="Abyss Burgeonet +2",
}	    	    	    	
	sets.MA = {}
	sets.MA['Dread Spikes'] = {
		body="Bale Cuirass +2",
}		
	sets.MA['Absorb-TP'] = {
		hands="Bale Gauntlets +2",
}	    	
	
	sets.idle = {}
    sets.idle.basic = {
		head="Ogier's Helm",
		body="Mekira Meikogai",
		hands="Melaco Mittens",
		legs="Blood Cuisses",
		feet="Phorcys Schuhs",
		neck="Twilight Torque",
		waist="Nierenschutz",
		left_ear="Steelflash Earring",
		right_ear="Bladeborn Earring",
		left_ring={ name="Dark Ring", augments={'Breath dmg. taken -5%','Phys. dmg. taken -5%','Spell interruption rate down -3%',}},
		right_ring={ name="Dark Ring", augments={'Spell interruption rate down -3%','Phys. dmg. taken -5%','Breath dmg. taken -3%',}},
}

	sets.engaged = {}	
	sets.engaged.basic = {
		ammo="Hagneia Stone",
		head="Outrider Mask",
		body="Karieyh Haubert +1",
		hands="Karieyh Moufles +1",
		legs="Outrider Hose",
		feet={ name="Mikinaak Greaves", augments={'Attack+15','Accuracy+10','STR+10',}},
		neck="Ganesha's Mala",
		waist="Goading Belt",
		left_ear="Steelflash Earring",
		right_ear="Bladeborn Earring",
		left_ring="Tyrant's Ring",
		right_ring="Rajas Ring",
		back="Atheling Mantle",		
        }
	

end

function precast(spell)
    if  spell.type == 'BlackMagic' then
            equip(sets.precast.BM)
	elseif sets.JA[spell.name] then
            equip(sets.JA[spell.name])        
    elseif  spell.type ~= 'JobAbility' then
        equip(sets.precast.FC)
    end
end
 
 function midcast(spell)
	if  sets.MA[spell.name] then
        equip(sets.MA[spell.name])
	end
end


When I cast Dread Spikes for example, my precast set equips immediately (Abyss Head +2 and Loc. Earring) but it seems like the Bale Cuirass +2 from the midcast function also gets equipped immediately. Just to test it, I added my Idle set left earring into the midcast set for Dread Spikes and it seems to take priority over the earring in the precast set. What I mean is I have the equipviewer addon and the Loc. Earring no longer blinks in before Dread Spikes begins.
 Bahamut.Bojack
Online
Server: Bahamut
Game: FFXI
user: Bojack316
Posts: 2102
By Bahamut.Bojack 2024-12-13 00:16:31
Link | Quote | Reply
 
I think I just figured out my own problem. I didn't have the opening line to designate midcast sets.

Edit: Nevermind. I added sets.midcast = {} before the midcast sets start and the Loc. Earring is still not appearing when I cast Dread Spikes. I suspect I've done something wrong here.
 Bahamut.Bojack
Online
Server: Bahamut
Game: FFXI
user: Bojack316
Posts: 2102
By Bahamut.Bojack 2024-12-13 00:24:02
Link | Quote | Reply
 
When I use Souleater I can see the very slight delay where it equips my AF head before the ability is used, but when I cast Endark the spell starts immediately without any delay and the precast set is equipped what looks like simultaneously. I expect my precast gear for spells is not actually getting equpped Before the spell begins.

Edit:
I removed this redundant code
Code
elseif  spell.type ~= 'JobAbility' then
        equip(sets.precast.FC)
    end


since all my spells are BlackMagic I thought maybe the redundant code was messing something up, but it still functions the same. The Loc. earring is still not being equipped before Dread Spikes begins.
Offline
Posts: 375
By Kaffy 2024-12-13 00:35:22
Link | Quote | Reply
 
Instead of relying on equipviewer or opening the actual equipment menu, use //gs showswaps. It prints everything to the chatlog so you can be sure what is swapping and when.
[+]
 Bahamut.Bojack
Online
Server: Bahamut
Game: FFXI
user: Bojack316
Posts: 2102
By Bahamut.Bojack 2024-12-13 00:41:48
Link | Quote | Reply
 
Oh I didn't realize that was a thing. It does show 3 swaps happening including a precast swap with the earring. So I guess it does actually work. The split second delay when I activated souleater seemed so noticable by comparison it didn't feel like it was working for spells like it was supposed to.
Offline
Posts: 49
By Genoxd 2024-12-13 01:50:46
Link | Quote | Reply
 
I could be wrong, but I believe that's because of the way gearswap sends packets. My vague recollection is gearswap will send the precast, ability/spell usage, and midcast together. The server will always process them in order they are sent within the packet so you'll never see the precast set equipped. This behavior is what allows you to properly equip midcast gear even when quickcast procs for an "instant" cast.

edit: ability/spell usage not ability
VIP
Offline
Posts: 787
By Lili 2024-12-13 02:44:51
Link | Quote | Reply
 
Genoxd said: »
I could be wrong, but I believe that's because of the way gearswap sends packets. My vague recollection is gearswap will send the precast, ability/spell usage, and midcast together. The server will always process them in order they are sent within the packet so you'll never see the precast set equipped. This behavior is what allows you to properly equip midcast gear even when quickcast procs for an "instant" cast.

edit: ability/spell usage not ability

This person here is correcto

The delay is because of packet delays. FFXI is not an instantaneous game, it only talks to the server twice a second.
[+]
 Bahamut.Bojack
Online
Server: Bahamut
Game: FFXI
user: Bojack316
Posts: 2102
By Bahamut.Bojack 2024-12-18 18:49:23
Link | Quote | Reply
 
I've returned for some assistance. So I am now at the point where I would like to add keybinds into my gearswap luas. I added in some keybinds and after they didn't work I was not including motes. Here's what I have currently (gear swaps still work, but keybinds do not).

From the top down to first gear set I have:
Code
function get_sets()
    mote_include_version = 2

    -- Load and initialize the include file.
    include('Mote-Include.lua')
end


function user_setup()

    -- ^ stands for the Ctrl key.
    -- ! stands for the Alt key. 
    -- @ stands for the Windows key.
    -- ~ stands for the Shift Key
    -- # stands for the App Key

    send_command('bind !numpad4 input /ja "Spectral Jig" <me>')
    send_command('bind !numpad1 input /ja "Flee" <me>')
    send_command('bind !numpad7 input /ja "Hide" <me>')

end

function user_unload()
    send_command('unbind !numpad4')
    send_command('unbind !numpad7')
    send_command('unbind !numpad1')
end

function get_sets()

    sets.precast = {}
	
   
    sets.precast.WS = {


And the rest after the gear sets I have:
Code
function precast(spell)
	if  spell.type == 'WeaponSkill' then
            equip(sets.precast.WS)
    elseif spell.name == 'Spectral Jig' and buffactive.sneak then
		windower.ffxi.cancel_buff(71)			
	elseif sets.JA[spell.name] then
            equip(sets.JA[spell.name])
	end	
end

function midcast(spell)
	if spell.action_type == "Ranged Attack" then
		equip(sets.midcast.RA)
	end
end
 
function aftercast(spell)
	if player.status == 'Engaged' then
       equip(sets.engaged.basic) 
    else
       equip(sets.idle.basic) 
    end
end
  
function idle()
    if player.status == 'Engaged' then
        equip(sets.engaged.basic) 
    else
        equip(sets.idle.basic) 
    end
end


function status_change(new,old)
    if new == 'Engaged' then
        equip(sets.engaged.basic)
    else
        equip(sets.idle.basic)
    end
end


As is, the gear swaps work, bu no keybinds. If I change the function right before my gear sets to 'function init_gear_sets' instead and reload the lua the keybinds do work so I know the keybind coding is ok, but then my gear swapping no longer functions. Obviously there are some fundamental things about creating a working lua that I'm not quite understanding lol. Any advice?
 Bahamut.Ayasha
Online
Server: Bahamut
Game: FFXI
user: Ayasha
Posts: 95
By Bahamut.Ayasha 2024-12-18 22:04:09
Link | Quote | Reply
 
Can you please post your lua in its entirety? I appreciate that you are trying to learn without having others just give you the answer - that is awesome by the way! - but it would go a long way to help you solve your problem if we could see your code to help diagnose. My thought is that there is probably a a misplaced bracket, parenthesis or curly brace somewhere, or an END in the wrong place, or a misspelled function name. Sometimes mistakes can be made such that the lua will still run, and the lua engine won't have any complaints or give you any indication as to what the problem is.

The reason that changing the name of your init_gear_sets() function makes the keybinds work but kills the actual gearswapping function of the lua is that you were actually redefining the "get_sets()" function in the gearsets section. This overwrites the original function, and it won't even execute the keybind portion of code, or anything else in the first instance of the function. You can have as many functions of the same name throughout the code as you like, but only the last one in the list will be in effect while the code is in memory. I think that this is causing the necessary include files for Mote's based luas to not load as well, which will render most of the useful functions in your code non-functional, or at least the enhanced features won't function properly. Virtually all of the functions in Mote's based luas won't work without the includes. There is a lot to it. Someone please correct me if I'm wrong here, or if I'm misstating how functions load at launch in lua.

Long story short: one major problem is you have a function get_sets() at the top of your lua, and you redefined it for the gearsets initializing portion. Change the second one back to init_gear_sets() as that is a standard for Mote's based luas. Your problem is elsewhere.
First Page 2 3 ... 184 185
Log in to post.