I just had a small problem and am new to scripting. I’m not sure why this is not working properly and don’t know what I’m doing wrong. I’m trying to make it where when you interact with the proximity prompt, a part will move to a new location.
Here I have a part with proximity prompt and a script.
This is what is inside the script:
local Button = game.Workspace.Button
local ProximityPrompt = script.Parent
ProximityPrompt.Triggered:connect(function(Player)
Button.CFrame = CFrame.new(-18.274, 11.065, -38.124)
end)
I also just have the part I want to move named Button in workspace. I looked through a few videos on proximity prompt but didn’t really get the sense of why my script isn’t working. Its most likely very obvious but I’m very new to scripting. Thanks.