Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How do you create functions for an object instance (Constructor-Created) in RBX.Lua ?

Asked by 9 years ago

So, I have this code for a fashion outfit (Fashionbloxx):

local Fashionbloxx = {}
Fashionbloxx.new = function(shirtId,hatId,PantsId)
    local ShirtID = shirtId
    local HatID = hatId
    local PantsID = PantsId
end
function Fashionbloxx
return Fashionbloxx

and I want have a function for an instance of this object defined above that prompts the player to buy all of the clothes with the IDs as Properties for each item in ROBUX ( Aerodian Dollars is to be added later). How do I Do All of this?

Answer this question