Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Summoner Gearswap Avatar Issue #2167

Open
dionys1s opened this issue Feb 24, 2022 · 5 comments
Open

Summoner Gearswap Avatar Issue #2167

dionys1s opened this issue Feb 24, 2022 · 5 comments

Comments

@dionys1s
Copy link

After one of the February 2022 updates, Gearswap no longer recognizes when an avatar is summoned. Every other set for SMN seems to still work except for the perpetuation set. Now it immediately puts me back in idle gear after the avatar has been summoned as if I have no avatar out.

@RubenatorX
Copy link
Collaborator

You'd have to provide example code that exhibits the behavior

@dionys1s
Copy link
Author

Thanks for the quick response. Honestly I dont really know what I would need to provide you in order to be helpful. I'm using Kinematics SMN gearswap. I could paste it here if that would help

@dionys1s
Copy link
Author

dionys1s commented Feb 25, 2022

Link to the gearswap - https://github.com/Kinematics/GearSwap-Jobs/blob/master/SMN.lua
I can't get the code to paste in a pretty fashion. But here is something i thought might be useful

-- 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
handle_equipping_gear(player.status)
elseif storms:contains(buff) then
handle_equipping_gear(player.status)
end
end

-- Called when the player's pet's status changes.
-- This is also called after pet_change after a pet is released. Check for pet validity.
function job_pet_status_change(newStatus, oldStatus, eventArgs)
if pet.isvalid and not midaction() and not pet_midaction() and (newStatus == 'Engaged' or oldStatus == 'Engaged') then
handle_equipping_gear(player.status, newStatus)
end
end

-- Called when a player gains or loses a pet.
-- pet == pet structure
-- gain == true if the pet was gained, false if it was lost.
function job_pet_change(petparam, gain)
classes.CustomIdleGroups:clear()
if gain then
if avatars:contains(pet.name) then
classes.CustomIdleGroups:append('Avatar')
elseif spirits:contains(pet.name) then
classes.CustomIdleGroups:append('Spirit')
end
else
select_default_macro_book('reset')
end
end

-- Modify the default idle set after it was constructed.
function customize_idle_set(idleSet)
if pet.isvalid then
if pet.element == world.day_element then
idleSet = set_combine(idleSet, sets.perp.Day)
end
if pet.element == world.weather_element then
idleSet = set_combine(idleSet, sets.perp.Weather)
end
if sets.perp[pet.name] then
idleSet = set_combine(idleSet, sets.perp[pet.name])
end
gear.perp_staff.name = elements.perpetuance_staff_of[pet.element]
if gear.perp_staff.name and (player.inventory[gear.perp_staff.name] or player.wardrobe[gear.perp_staff.name]) then
idleSet = set_combine(idleSet, sets.perp.staff_and_grip)
end
if state.Buff["Avatar's Favor"] and avatars:contains(pet.name) then
idleSet = set_combine(idleSet, sets.idle.Avatar.Favor)
end
if pet.status == 'Engaged' then
idleSet = set_combine(idleSet, sets.idle.Avatar.Melee)
end
end

if player.mpp < 51 then
    idleSet = set_combine(idleSet, sets.latent_refresh)
end

return idleSet

end

-- 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)
classes.CustomIdleGroups:clear()
if pet.isvalid then
if avatars:contains(pet.name) then
classes.CustomIdleGroups:append('Avatar')
elseif spirits:contains(pet.name) then
classes.CustomIdleGroups:append('Spirit')
end
end
end

@RubenatorX
Copy link
Collaborator

RubenatorX commented Feb 25, 2022

I just tested Kinematics on retail and it appears to be working fine. So, it may be a problem with your code/gear/setup/situation/etc but I'd need to see your actual lua and hear more about what you're doing, where you are, etc, (reproduction steps), what you're expecting to happen, and what is happening instead. May be easier in the windower discord in the #gearswap-support channel (link to the discord found at the top of windower.net)

@dionys1s
Copy link
Author

Thanks, I'll do that

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants