LookingForSatchels

45.4k Downloads

11.0.2 API changes

Closed this issue ยท 8 comments

commented

Some changes are easy to fix locally:

local GetAddOnMetadata = C_AddOns.GetAddOnMetadata on top of lua file...

This one i'm not sure how to resolve. Something with how frames are called changed.

1x ...aceLookingForSatchels/LookingForSatchels.lua:357: attempt to call global 'GetBackgroundTexCoordsForRole' (a nil value)
[string "@LookingForSatchels/LookingForSatchels.lua"]:357: in function <...aceLookingForSatchels/LookingForSatchels.lua:68>
[string "@LookingForSatchels/LookingForSatchels.lua"]:784: in function `?'
[string "@LookingForSatchels/LookingForSatchels.lua"]:914: in function <...aceLookingForSatchels/LookingForSatchels.lua:913>
commented

Update:
Found through depreciation... add to the lua file:

  local GetBackgroundTexCoordsForRole = function(role)
		local textureHeight, textureWidth = 128, 256;
		local roleHeight, roleWidth = 75, 75;
		if ( role == "TANK" ) then
			return GetTexCoordsByGrid(2, 1, textureWidth, textureHeight, roleWidth, roleHeight);
		elseif ( role == "HEALER" ) then
			return GetTexCoordsByGrid(1, 1, textureWidth, textureHeight, roleWidth, roleHeight);
		elseif ( role == "DAMAGER" ) then
			return GetTexCoordsByGrid(3, 1, textureWidth, textureHeight, roleWidth, roleHeight);
		else
			error("Role does not have background: "..tostring(role));
		end
	end;
commented

I still cannot find the frame to be honest... but at least no errors. And the button works in the LFG UI.

Probably something else is missing.

Oh found the 'L' it's just a letter L without background in the middle of my screen. So yes something else's broken i think for setting up the frame, though the whole frame setup have changed recently.

commented

I'll look into it, thanks for the detailed report!

commented

I will go with the default UI's way to get these icons, as this will most likely be supported for longer.

https://github.com/tomrus88/BlizzardInterfaceCode/blob/5321290b97b74177bd44a65054d34fd61ce83424/Interface/AddOns/Blizzard_UIPanels_Game/Mainline/RoleSelectionTemplate.lua#L60

If you have trouble moving the letter "L" try "/lfs move". I really have to get around to do some UX updates soon...

commented

To be clear, i've not used LFS for a while now since DPS i play are never in demand... So I'm not sure if no background letter "L" is the appropriate free-floating frame for LSF. And if it is.. then that's fine. It's in the middle cause I've reset the coordinates. I seem to recall it having a little square around itself or something like that but honestly, i've not seriously used LFS since Legion.

commented

No errors in 11.0.2 and it loads. Feel free to close split off UI to new issue and/or close this one.

I don't recall where but i found out that the old way to do boxes wasn't sufficient for addons now... I've fixed it in my addon by following wiki outline to give background texture and color (it was there but was transparent) you can see the changes roughly in the middle here with the frame changes.

I'm not sure if zero background letter as UI is intentional or not:

image

commented

Now I see. As it is, the background is intended to be transparent when the "L" cannot be moved around. I'll close the issue and maybe open another one for the UX stuff

commented

Awesome and thanks. Your call on the UI/UX things.

Note, that by coincidence my weapon is red and the letter is red so it was basically invisible when centered on me in current gear which is the default reset location. This explains why i couldn't find it in above comment, as I didn't know what I was looking for.