Does anyone know why my TextButtons are acting like THIS

This is not delayed at all, I am spamming left click to hopefully fire the “Activated” function, however, it’s not working at all unless it’s “Large Pouch” - to me it seems like the TextButtons aren’t the same size as they show, as they only fire the “Activated” function when I click in specific locations.

Currently I am experimenting and trying to create a skyrim inventory type of system, I have TextButtons with the following script controlling them all:

        InventoryFrame.Inventory.Inventory.ChildAdded:Connect(function(Item)
        Item.Activated:Connect(function()
            print("Clicked")
            SelectedItem = Item
            OptionsFrame.Visible = true
            OptionsFrame.Rarity.Text = "Item Rarity: "..ItemData[Item.Name].Rarity
            OptionsFrame.Description.Text = ItemData[Item.Name].Description
            OptionsFrame.Namez.Text = ItemData[Item.Name].Name
        end)

– Current situation
https://gyazo.com/e9ab244639b1fd1301d3228ade2b4668

– This Large Pouch is working perfectly however the others aren’t.
https://gyazo.com/dc302337d55f7d410e9945cf8c9058d7

image

Sorry, but I don’t understand what you mean, is it that they’re delayed or what’s happening.

You need to click in a specific location to activate the TextButton for some reason, however, the Large Pouch’s TextButton is working perfectly. I really need to fix this however, I am unaware as to why it’s doing this - it’s as if the TextButton has a different size than is being shown to me.

If it’s a textbutton, wouldn’t it be better to use MouseButton1Click? I’ve never used activated, and it doesnt seem like there’s anything wrong, however try this.

        InventoryFrame.Inventory.Inventory.ChildAdded:Connect(function(Item)
        Item.MouseButton1Click:Connect(function()
            print("Clicked")
            SelectedItem = Item
            OptionsFrame.Visible = true
            OptionsFrame.Rarity.Text = "Item Rarity: "..ItemData[Item.Name].Rarity
            OptionsFrame.Description.Text = ItemData[Item.Name].Description
            OptionsFrame.Namez.Text = ItemData[Item.Name].Name
        end)

I should’ve said, I’ve used both types.

Hm. Maybe it has to do with a gui layout error? ZIndex or Sizes, I’m not sure. It doesn’t seem like there should be anything wrong with it.

What are the Active property values for the text labels and the buttons?

If the labels have Active true then you won’t be able to click on the button when your mouse is also over the label.

Make sure no other GUI elements are active and over the area that you’re struggling to click.

Thank you so much; I was completely unaware as to that “Active” property solution, now that I think of it - it makes so much more sense, as the “Activated” function is permanently toggled true/on/active due to the “Active” being constantly toggled true/on/activated.