local part = game.Workspace.Partius
local function onModelTouched(HitPart)
script.Parent.Position = script.Parent.Part1.Position
end
part.Touched:Connect(onModelTouched)
print("Online")
local part = game.Workspace.Partius
local function onModelTouched(HitPart)
print("Touched/Fired")
script.Parent.Position = script.Parent.Part1.Position
end
part.Touched:Connect(onModelTouched)
print("Online")
local part = game.Workspace.Partius
local function onModelTouched()
print("Touched/Fired")
script.Parent.Position = script.Parent.Part1.Position
end
part.Touched:Connect(function()
onModelTouched()
end)
You didn’t mention HitPart in the function so I erased it
What its touching the part is another part or a model? If so, use the function SetPrimaryPartCFrame(script.Parent.Part1.CFrame). Remember if that the model does not have a primary part, it must be set!
You could also use MoveTo(), but the first one is better
local part = game.Workspace.Partius
local connection -- just for a debounce
local function onModelTouched(part)
print('Old Position', script.Parent.Position)
script.Parent.Position = script.Parent.Part1.Position
print('New Position:', script.Parent.Position)
connection:Disconnect()
end
connection = script.Parent.Touched:Connect(onModelTouched)