local parent = script.Parent.Parent.Name
local item_settings = require(game.workspace.Item_Settings)
local values = item_settings[parent]
while wait(values[2]) do
if script.Parent.Parent.Parent.Name == "Purchased" then
local tycoon = script.Parent.Parent.Parent.Parent
local ore_storage = tycoon.Ore_Storage
local ore = script.Parent:Clone()
local cash = Instance.new("IntValue", ore)
ore.Name = "Ore"
ore.CanCollide = true
ore.Anchored = false
ore.Parent = ore_storage
cash.Name = "Cash"
cash.Value = values[1]
game.Debris:AddItem(ore, 20)
end
end
so basicaly the module is in workspace and im trying to make it where i can put the script in any dropper and not have to do anything to it
the error is in line 4 and values is the nil value parent is useing the name of the model and finds that same name in the module script and its a table with settings for the dropper like drop speed and ore value

1 comment
Yo, please use the Code format. Just type "
lua" and end the block of code with "". This is hard to read aha. Also please provide the line in which the error is printed on.