I have tried to remove a message from workspace using:

workspace.Message:remove()

and this:

workspace.Message.destroy()

It works when I play from the studio, but when I click play, the Message just stays. What am I doing wrong?

3 comments

2

Methods are canonically uppercase, not lowercase (though this is only a warning and not an error). In addition, Destroy is a method, not a property, and is also indexed with :Destroy() and not .Destroy().

1

You should also make sure that Message actually exists as a child of workspace.

0

@Blue; it is a member, otherwise it couldn't be a method. You just have to invoke it with (:) as a method, or provide the 'self' parameter when calling it as a member