There is a problem that the script can't disconnect an event


image
what’s its problem?
I can’t fix it :frowning:

I don’t what the problem is exactly, but trying chucking in a small wait() before your disconnect.

I think the block is not successful in assigning the value of the connection before end.

https://developer.roblox.com/en-us/recipes/How-to-disconnect-an-event-connection

Read this article again and apparently you have to declare the function before assigning the event connection to it.