Roblox keeps giving me the error that SkinPrice is not a valid member of a certain skin while it obviously is. We are using a package to load the UnitSkin folder but that shouldnt be the issue.
Might just be me missing something very obviously but I honestly have no clue what
this is the script, its in serverscriptservice
local RS = game:GetService("ReplicatedStorage")
local Modules = RS:WaitForChild("Modules")
local Folder = RS:WaitForChild("DailyShopHandler")
local DailyMod = require(Folder.CurrentShop)
local PossibleSkins = {}
local function CreateSkinTable ()
local unitSkins = RS:WaitForChild("UnitSkins")
task.wait(3)
for _, tower in pairs(unitSkins:GetChildren()) do
if tower:IsA("Folder") then
for _, skin in pairs(tower:GetChildren()) do
if skin:IsA("Folder") then
if #skin:GetChildren() >= 7 then
print("Skin found")
local skinPrice = skin["SkinPrice"].Value
table.insert(PossibleSkins, {tower = tower.Name, skin = skin.Name, price = skinPrice})
print(tower.Name.." inserted")
end
end
end
end
end
print("PossibleSkins:")
for _, skinData in ipairs(PossibleSkins) do
print(skinData.tower, skinData.skin, skinData.price)
end
end
