so i kind of want my code to look like this..
local function something() -- make sure to put this inside a pcall() function
local item
for i,v in pairs(slot:GetChildren()) do -- gets item inside selected
if v:IsA("Model") then
item = v
end
end
func(item.Name)(item.Animation,slot.Name) -- item.Name == the func name
end
something()
end
so basicly my idea is to put hole bunch of functions inside a script and when a player wants to use a item. it calls the function by the name of the item. for example if somone used a apple the script would find whats inside the slot (apple) and then call the function with its name and the arguments. let me know if this is kind of hard to understand and ill try to explain it better. thanks

1 comment
load string but you shouldn't have it on