So, i've just recently made a Respawn script for a game i'm making ("Marble Fall"). I would destroy the walls and the "Marbles" fall. And, then i respawn them which works. It just deletes the walls again? I only want the whole dropper to respawn not just the Marbles
Here is the respawn script. This below is inside of a button called "Spawn Walls"
script.Parent.MouseButton1Click:Connect(function()
local dropper = game.Workspace.Dropper
local dropperc = dropper:Clone()
dropperc.Parent = game.ReplicatedStorage
dropper:Destroy()
print("Respawning Dropper")
wait(5)
dropperc.Parent = game.Workspace
end)
The dropper respawns but then the walls get destroyed too.
Wall Destroy Script
game.ReplicatedStorage.Destoryw.OnServerEvent:Connect(function()
game.Workspace.Dropper.Walls:Destroy()
end)
Then the button to launch that event is
script.Parent.MouseButton1Click:Connect(function()
game.ReplicatedStorage.Destoryw:FireServer()
end)
I am not sure what i did wrong. And there is no errors either ("http://prntscr.com/l4k7zr") If anyone could help, that would be awesome! :D Thanks in advance
Game LInk to test for yourself "https://www.roblox.com/games/2440463201/Marble-Fall-ALPHA"

3 comments
are the two buttons mentioned the same button, or different buttons?
and you can't destroy stuff or clone stuff on the client and expect other people to see that, those are local parts and can only be seen by the local player
The 2 buttons are 2 different ones. And, there mentioned desperately. I'm not sure what happened. Plus, this does work with FE I've tested with a friend.