I’m attempting to detect when the text of a textlabel is clipping through the billboardgui but I can’t seem to find a way. I’ve tried looking through the devforum and google, although I can’t find anything related to this topic. Is it possible to detect when the text is clipping?
Thanks in advance!
I think you should do something with ZIndex
1 Like
There is no direct way of detecting it, however you can compare the TextLabel
size to the size of the BillboardGUI
local textLabel = script.Parent -- replace with your TextLabel
local billboardGui = textLabel.Parent -- replace with your BillboardGui
local function isTextClipping()
local textBounds = textLabel.TextBounds
local guiSize = billboardGui.Size
if textBounds.X > guiSize.X.Offset or textBounds.Y > guiSize.Y.Offset then
return true
else
return false
end
end
1 Like
This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.