I would like to send NSData
from a GKPlayer
to another in a match. Therefore, the method sendDataToAllPlayers(_:withDataMode:error:)
would be the most ideal.
func sendDataToAllPlayers(data: Int,
withDataMode Reliable: GKMatchSendDataMode,
error: NSErrorPointer) -> Bool {
return true
}
Though, how can I use the method above to send an Int
variable?
var score:Int = 0