local snd = {}
snd.__index = snd
self = setmetatable(snd,{})
self.allocateMaterials = {
["Concrete"] = {"Conc", 5};
["Fabric"] = {"Conc", 5};
["Grass"] = {"Grass", 5};
["Slate"] = {"Dirt", 5};
["Metal"] = {"Metal", 10};
["Sand"] = {"Sand", 5};
["Plastic"] = {"Tile", 5};
["Marble"] = {"Tile", 5};
["SmoothPlastic"] = {"Tile", 5};
["Wood"] = {"Wood", 5};
["WoodPlanks"] = {"Wood", 5};
["Asphalt"] = {"Asph", 5}
};
local materialAtt = self.allocateMaterials[args[1]] -- args are {floorMaterial}
print(materialAtt) -- this returns the table i want
print(materialAtt[1]) -- however this errors, i have no idea why.
I genuinely have no idea why this isn’t working.