I have come across an issue whereby the weapons occasionally stop firing.
I’ve done a little digging and found that when I switch away from a weapon before the wait time between shots has elapsed, this appears to immediately stop the coroutine, and ultimately prevents the canShoot boolean from being changed back to true. This effectively disables the weapon until the scene is loaded again.
I have temporarily added an OnEnable method to set the canShoot boolean to true when each weapon is enabled. This stops the weapons from becoming unusable, but then introduces another issue where the user can bypass the wait time between shots by quickly switching weapons and switching back.
Has anyone else come across this or is this just me? Also, if anyone came across it, did anyone find a solution?