So I am making a game where I want parts to go back to their starting position. I dont have any code because I dont know how to make it. Could you help?
This is not helping there are 2 dice in the model
So I am making a game where I want parts to go back to their starting position. I dont have any code because I dont know how to make it. Could you help?
This is not helping there are 2 dice in the model
local Pos = game.Workspace.Model.PrimaryPart.Position
game.Workspace.Model:MoveTo(Vector3.new(10,10,10))
game.Workspace.Model.PrimaryPart:GetPropertyChangedSignal("Anchored"):Connect(function()
game.Workspace.Model:MoveTo(Vector3.new(Pos))
end)
Wait but I want this script to run after the cubes unanchor
now try
model.PrimaryPart:GetPropertyChangedSignal("Anchored"):Connect(funcion()
if model.PrimaryPart.Anchored == false then
--code
end
end)
K ill try it
the if is an error
This discussion is preserved as it was. New answers, comments, and votes are closed.
1 comment
Ok lets see if it works