replicatedStorage.Events.SpawnBoat.OnServerEvent:Connect(function(player, boat, spawnPos)
print(spawnPos.Position)
if boat == "Dinghy" then
if player:WaitForChild("Inventory").Boats.Dinghy.Value == true then
if game.Workspace.Boats:FindFirstChild(player.Name.. "'s boat") then
game.Workspace.Boats:FindFirstChild(player.Name.. "'s boat"):Destroy()
end
local dinghy = serverStorage.Boats.Dinghy:Clone()
dinghy.Parent = workspace.Boats
print(spawnPos.Position)
-- dinghy.OwnerValue.Value = player.Name
dinghy:MoveTo(Vector3.new(-247.714, 67, -110.623))
print(dinghy.PrimaryPart.Position)
dinghy.Name = player.Name.. "'s boat"
end
end
end)
So right now this code above functions, the model moves to the position, but if i change the line to this
dinghy:MoveTo(Vector3.new(spawnPos.Position))
then the model prints as being at 0, 0, 0, which is incorrect and it isn’t at the correct position in the game, not sure why this happens as spawnPos.Position prints as the correct position, not 0, 0, 0, what should I do?