Looking at the BackpackScript.lua located here, the changes needed appear to be:
if ToolTip and tool:IsA('Tool') then --NOTE: HopperBin
ToolTip.Text = tool.ToolTip
local width = ToolTip.TextBounds.X + TOOLTIP_BUFFER
ToolTip.Size = UDim2.new(0, width, 0, TOOLTIP_HEIGHT)
ToolTip.Position = UDim2.new(0.5, -width / 2, 0, TOOLTIP_OFFSET)
end
To
if ToolTip and tool:IsA('Tool') then --NOTE: HopperBin
ToolTip.Text = tool.ToolTip
local width = ToolTip.TextBounds.X + TOOLTIP_BUFFER
local height = ToolTip.TextBounds.Y + TOOLTIP_BUFFER
ToolTip.Size = UDim2.new(0, width, 0, height)
ToolTip.Position = UDim2.new(0.5, -width / 2, 0, TOOLTIP_OFFSET - height)
end
This calculates the height based on TextBounds instead of using a global.
local TOOLTIP_BUFFER = 6
local TOOLTIP_HEIGHT = 16
local TOOLTIP_OFFSET = -25 -- From top
To
local TOOLTIP_BUFFER = 6
local TOOLTIP_OFFSET = -9 -- From top
This removes the now-unused TOOLTIP_HEIGHT global and adjusts the TOOLTIP_OFFSET global to 16 pixels lower, so that the y placement is no longer automatically being adjusted.
Using newlines would allow us to include extra information about the tool in the tooltip, like ammo remaining or damage.