Still have questions? Join our Discord server and get real time help.
Log in to vote

Trying to use BindableFunctions to return a dictionary, not working?

Asked by 9 months ago

I'm trying to use a BindableFunction to return a dictionary full of all items, but the script stops running at "script.GetItems.OnInvoke:Connect(function()" and will not return anything.

Attempting to Fire() this BindableFunction will result in the script refusing to run any further.

My code:

local items = {

    [1] = {
        Name = "Copper Shortsword",
        Description = "A rough shortsword made out of copper. Seems rough but fairly lightweight and easy to swing.",
        Icon = "rbxassetid://1589011700",
        Rarity = "Common",
        Stackable = false,
        Armour = nil,
        Weapon = game.ReplicatedStorage.CopperShortsword


    return items
OnInvoke is a callback. User#19524 1 — 9mo

Answer this question