Part removing from model?

For some reason, a part removes itself from a model and when I try and access the part from a script it won’t let me access it. I’ve checked through my scripts and no scripts are removing the part.

1 Like

Not exactly sure what the issue could be with little context.

However, if the part is unanchored with CanCollide off, it’ll fall through the map, removing itself at some point.

1 Like

Yes, at the default “void” depth (Y axis value 500) parts are destroyed, which could be the issue the original poster is facing.

the part is inside the map. so I don’t think that’s why

that’s weird, it loads for me… hmm…


Can I see that line of code which is erroring? Line 14.

sure ill just give you a chunk of it

game.Players.LocalPlayer.CharacterAppearanceLoaded:Connect(function()
	print("Preload Complete")
	wait(10)
	local userInputService = game:GetService("UserInputService")
	userInputService.MouseIconEnabled = true
	
game.workspace:WaitForChild(game.Players.LocalPlayer.Name):SetPrimaryPartCFrame(game.workspace.CharacterRoom.Placer.PrimaryPart.CFrame)
	workspace.CurrentCamera.CameraType = Enum.CameraType.Scriptable
	workspace.CurrentCamera.CameraSubject = nil
	workspace.CurrentCamera.CFrame = workspace.CharacterRoom:FindFirstChild("CamPart").CFrame
-- no end cuz the script ain't done
workspace.CurrentCamera.CFrame = workspace:WaitForChild("CharacterRoom"):WaitForChild("CamPart").CFrame

Alright, try this.

didn’t work

Is CharacterRoom inside another model or inside the workspace directly? Also does it start there or is it cloned/moved there?

it’s inside a model which is inside a workspace. And no, it is not moved or cloned there.

workspace.CurrentCamera.CFrame = workspace:WaitForChild("CharacterRoom"):WaitForChild("CamPart").CFrame

Then this line of code will need changing.

workspace.CurrentCamera.CFrame = workspace:WaitForChild("WHATEVERTHEMODELISNAMED"):WaitForChild("CharacterRoom"):WaitForChild("CamPart").CFrame

image

If CharacterModel is inside the workspace not another model, then the script is fine as it is.

Line 18 is now erroring, can you share that line?

Can you please send us some code? I need to see where the error occurs.

I recommend you share the entire code & a screenshot of everything under workspace, that way we can iron out all the issues at once instead of going through 1 at a time. If you’d rather keep it private feel free to message me.