I have been trying to improve my coding abilities, so I am currently messing around with Object Orientated. My issue is I can not get any member functions of the object to work properly. Im 90% sure this is one of those stupid things that is right in front of your face. Thanks.
Main``
local Supplier = require(script.SupplierHandler)
local Crate = Supplier.NewCrate(CFrame.new(Vector3.new(-38.3, 13.7, 7)))
Crate:PutCrateOnTruck(game.Workspace.Part.CFrame,Crate.Id)
Class
local CrateHandler = {};
CrateHandler.__Index = CrateHandler
local MetaTable = {}
function CrateHandler.NewCrate(Position)
local Crate = {};
setmetatable(Crate,CrateHandler);
setmetatable(MetaTable,Crate);
Crate.Model = SpawnCrate(CrateFolder,Position);
Crate.Opened = false;
Crate.Content = nil;
return Crate;
end
function CrateHandler:CratePickUp()
end
function CrateHandler:PutCrateOnTruck(Object,Position,Id)
end
return CrateHandler