Pick up a single item from stack only, not split stack

Is there a shortcut to pick up a single item from a stack without bringing up the split stack menu and having to click 1 every time?

/run hooksecurefunc(StackSplitFrame, "ChooseFrameType", function(self, maxStack, parent, anchor, anchorTo, stackCount) if IsAltKeyDown() then self.OkayButton:Click() end end)

If both the Shift and Alt keys are down, pickup one (or whatever the default is) of …

1 Like

Hmm maybe I’m using it wrong. I copied and pasted that into a macro, held Shift/Alt and pressed the keybind for the macro while my cursor was over the stack and nothing happens.

Run the macro once you’ve logged in (or copy/paste everything but the /run to the website addon.bool.no to download as an addon)

Shift-Alt click say a stacked item in your bags and it will automaticaly pick up 1 (or whatever the default is) and the SplitStackFrame is automatically closed leaving the 1 item on the cursor.

Shift clicking a stack will leave the SplitStackFrame open as per usual.

Hmmm still not working ht–://imgur.com/a/z0F1IIB here’s screen shots of the addon creation page, I copied and pasted it all except “/run” and it has the errors I saw in BugSack and that the addon is showing up in my addon list.

I just realized, it might have helped if I had stated that this is the TBC 20th Anniversary version of the game sorry :upside_down_face:

for Anniversary it would be:

/run hooksecurefunc("OpenStackSplitFrame", function(self) if IsAltKeyDown() then StackSplitOkayButton:Click() end end)
1 Like

It kind of works? But its very laggy, it will pick up the item and it can take 10-15 seconds before it will let me place it in my bag somewhere. I made the addon version on addon.bool.no/

It’s almost instant for me (in Anniversary).
It shouldn’t take any longer than opening the StackSplitFrame (shift-click) and clicking the Okay button because that’s all it is doing.

It can take half a second (or less) once you drop the item (click an empty back slot) for it to show up because the game has to query to make sure the slot is available etc. etc.

Yeah it’s just not working for me, the only error I see in BugSack is:

14x 1 Item from stack/core.lua:1: hooksecurefunc(): ChooseFrameType is not a function

Locals:

I don’t know where it’s coming from though? I disabled the addon based on the macro text you posted and the error is still there after relaunching the game.

That error means you are using the Retail script in Anniversary (or classic or MoP classic)

IDK what that means, what is “the Retail script”? I copied the part you posted earlier:

/run hooksecurefunc(“OpenStackSplitFrame”, function(self) if IsAltKeyDown() then StackSplitOkayButton:Click() end end)

The top script I posted is for retail.

The second one is for the classics.

The classic version does not contain the term ChooseFrameType which was in the error you posted

1 Like

If you want something you can just use for all current game versions (Midnight [retail], Vanilla [classic-era], TBC [Anniversary], MoP [classic]) then pasting the following to addon.bool.no to download and copy to the AddOns folders for whichever game version(s) you want…

if StackSplitFrame.ChooseFrameType then
	hooksecurefunc(StackSplitFrame, "ChooseFrameType", function(self, maxStack, parent, anchor, anchorTo, stackCount)
		if IsAltKeyDown() then
			self.OkayButton:Click()
		end
	end)
elseif OpenStackSplitFrame then
	hooksecurefunc("OpenStackSplitFrame", function(self)
		if IsAltKeyDown() then
			StackSplitOkayButton:Click()
		end
	end)
end
2 Likes