connection is declared outside of the two connections so that it’s within the scope of those two callback functions. Its purpose is so that if/when the tool is unequipped the humanoid.Running connection is disconnected, this is to prevent memory leaks. If however the connection wasn’t disconnected each time the tool were to be equipped the humanoid.Running connection would be created.