Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

how to define is something doent exists in workspace?

if game.Workspace.Soda                  else if
	game.Workspace.Soda:destroy()

how to make if soda doent exist in workspace the script continues and not breaks?

1 answer

✓ Accepted answer

###Use FindFirstChild to check if an object exists.

if game.Workspace:FindFirstChild("Soda") then
    game.Workspace.Soda:Destroy() -- :Destroy not :destroy
end

This discussion is preserved as it was. New answers, comments, and votes are closed.