Sziasztok! Irtam egy alap itemrendszert, WorthlessCynomys videója alapján, viszont az a gond, hogyha egyszerre nyomok bal és jobb klikket a hamburgerre mondjuk, akkor kiírja, hogy megettem, de nem törli az itemet. Ezt hogyan tudnám kijavítani?
(Videók amik alapján írtam: 
https://www.youtube.com/watch?v=TGphzLbcAtohttps://www.youtube.com/watch?v=bYeJIM38P9khttps://www.youtube.com/watch?v=7MKkAkgELe4)
addEventHandler("onClientClick", root,
	function(button, state)
		if (isInventoryVisible) then
			local cX, cY = getCursorPosition();
			if (button == "left") then
				if (state == "up") then
					if (dragNDrop[1]) then
						onDropEnd();
					end
					if (windowMove[1]) then
						windowMove = {false, false};
					end
				else
					local isSlotClick = false;
					local clickedSlot = false;
					for i, slot in ipairs(slots) do
						if (isInBox(slot[1], slot[2], slot[3], slot[4])) then
							clickedSlot = i;
							isSlotClick = slot;
							break;
						end
					end
					if not (isSlotClick) then
						windowMove = { cX-invWindow[1], cY-invWindow[2] };
					else
						if (isSlotClick[5][1]) then
							dragNDrop = {isSlotClick[5], clickedSlot};
							slots[clickedSlot][5] = {false};
						end
					end
				end
			elseif (button == "right") then
				if (state == "up") then
					local isSlotClick = false;
					for i, slot in ipairs(slots) do
						if (isInBox(slot[1], slot[2], slot[3], slot[4])) then
							if (slot[5][1]) then
								onItemClick(slot[5], i);
								break;
							end
							isSlotClick = slot;
							break;
						end
					end
				end
			end
		end
	end
);