This is the current function that i use to place my maps. How do i make it more secure? Sometimes it does not even load parts (walls) anything more secure? Or just plain efficient?
function AddField() Fields = Game.ServerStorage.Fields Chosen = Game.Workspace.Chosen Randomize = Fields:GetChildren() Picking = Randomize[math.random(1,#Randomize)] Chosen.Value = Picking.Name FieldAdd = Game.ServerStorage.Fields:FindFirstChild(Chosen.Value) FieldAdd:Clone().Parent = Game.Workspace FieldAdd:MakeJoints() end
function AddField() Fields = Game.ServerStorage.Fields Chosen = Game.Workspace.Chosen Randomize = Fields:GetChildren() Picking = Randomize[math.random(1,#Randomize)] Chosen.Value = Picking.Name FieldAdd = Game.ServerStorage.Fields:FindFirstChild(Chosen.Value):Clone() FieldAdd.Parent = Game.Workspace FieldAdd:MakeJoints() end
Try this...
It makes it connect to the original model so try parenting it to something like so:
function AddField() Fields = Game.ServerStorage.Fields Chosen = Game.Workspace.Chosen Randomize = Fields:GetChildren() Picking = Randomize[math.random(1,#Randomize)] Chosen.Value = Picking.Name FieldAdd = Game.ServerStorage.Fields:FindFirstChild(Chosen.Value):Clone() FieldAdd.Parent = Game.Workspace FieldAdd:MakeJoints() end
No I did not take other dude's I just have same answer because there isn't much more I know to clone