Here is some example code of what I want to accomplish:
local sky = workspace.Sky:GetChildren()
local repStorage = game.ReplicatedStorage
local severeRisk = repStorage.SeverityRiskValue.Value
local cloudTable = {
repStorage.Cloud1,
repStorage.Cloud2,
repStorage.Cloud3}
while repStorage.EventReady.Value == true do
for i, storm in pairs(sky) do
local stormType = storm.StormType.Value
local growChance = math.random((stormType * 6), 100)
if growChance > severeRisk then
local nextCloud = cloudTable{stormType + 1}
local cloud2 = nextCloud:Clone()
cloud2.Parent = storm.Cloud
end
end
end
This code does not work because cloning models from tables is not possible. Is there any other way I could attempt something like this?
