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

Trying to make a variable with an asset that has spaces, how do i fix this?

local BeginnerCharacter = game.Workspace["Hello, welcome to my maze, try to make it to the end, hold Shift to run if needed"] local debounce = false

game.Workspace.Model.FirstPressurePlate.Touched:Connect(function(hit)

if not debounce then
debounce = true
	 game.Workspace.BeginnerCharacter:Destroy()
	game.Workspace.EerieThump:Play()
wait(10)
debounce = false	
end

end) so at the top I tried using a variable because if I did game.workspace["Hello, welcome to my maze, try to make it to the end, hold Shift to run if needed"] instead it would show an error. The variable I made works, or at least it should but it said this 10:23:01.928 - BeginnerCharacter is not a valid member of Workspace please help me thanks <3

1 answer

✓ Accepted answer
while workspace.Model.FirstPressurePlate.Touched:Wait() and not workspace["Hello, welcome to my maze, try to make it to the end, hold Shift to run if needed"]:Destroy() and workspace.EerieThump:Play() do end

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