I have made a GKMatch and MCSession wrapper for my online games. It was working fine on Swift2 but on Swift3 I have got a weird issue.
When I am running the game with the GKMatch, it works fine, no issue. When I am changing over to the Nearby player mode and start MCSession, my game is running until I reach a scheduledTimer.
The same timer function was perfectly called on GKMatch, but now it is not fired.
All calls are the same as the wrapper is using the same delegates to interact with the rest of the software.
I cannot see any obvious issue with the code.
What is really strange is that the program is not crashing at all, just because the timer function is not fired, it stops at a point the game logic is not running further.
ClearTableTimer=Timer.scheduledTimer(timeInterval: 2.0, target: self, selector: #selector(clearTableCardsTimed), userInfo: nil, repeats: false)
@objc func clearTableCardsTimed(timer: Timer) {