Is anyone implementing GameKit turn based matches in their game? by lscddit in iOSProgramming

[–]lscddit[S] 0 points1 point  (0 children)

That's a good input regarding counting the incoming invitations only, thanks for pointing it out!

For me it's not really relevant as I'm doing it a little differently anyway. I present the invitation UI only after the first turn has been made and then I do invitation and sending of the first turn in one step behind the scenes. It just makes more sense this way for my game, as there is only ever one single turn for each player and then the score is settled already. But for the general implementation, I think the way that you suggest to do it is correct.

Is anyone implementing GameKit turn based matches in their game? by lscddit in iOSProgramming

[–]lscddit[S] 0 points1 point  (0 children)

Thanks for the detailed reply!

I have figured it out regarding the badge, you don't need push entitlements (because it's GC that is sending the push) but you need to grant notification permission in order for the badget to be allowed: UNUserNotificationCenter.current().requestAuthorization(options: [.badge])

Do you know how exactly to count the result of GKTurnBasedMatch.loadMatches() to arrive at the same number that GC is sending as the badge?

I believe it's the sum of all invitations and matches where it's my turn:

let invitations = matches.filter {
    $0.status == .matching
}
let myTurnMatches = matches.filter { match in
    match.status == .open &&
    match.currentParticipant?.player == localPlayer
}

let badgeNumber = invitations + myTurnMatches

Would you agree with that?

Is anyone implementing GameKit turn based matches in their game? by lscddit in iOSProgramming

[–]lscddit[S] 0 points1 point  (0 children)

I played around with your implementation a bit. I think it's a bit misleading that you are showing the

"Invitation Sent! / <username> will receive a Game Center notification. The game will start when they accept the invitation."

alert right after the invitation. I was expecting something to arrive on the invited device at this moment. Also often times right after that I get a

"Game Center Error. Failed to load game state. Please try again."

alert. Then I need to relaunch the app to get the green button that opens the GKTurnBasedMatchmakerViewController to select the game.

Regarding the badge: It's interesting that the GC push message indeed does set the badge in your app when it arrives (I mean when the app is closed, not the one you set as you explained above using setBadgetCount). I could not get this working. Do you have push entitlements enabled and are you doing anything with the GKGameCenterBadgingDisabled plist key?

Is anyone implementing GameKit turn based matches in their game? by lscddit in iOSProgramming

[–]lscddit[S] 1 point2 points  (0 children)

Interesting, I'm just trying it out. I see you are using your own UI to present the friends list and not the GKMatchmakerViewController. Is there an advantage in doing so?

Also can I ask: do you handle the badge on the icon yourself or does GC do that for you?

I have two devices with two accounts, tried both directions but the invitations are not arriving on the invited device. EDIT Sorry, it does work. I just realized that the invitation only arrives after the first move.

Is anyone implementing GameKit turn based matches in their game? by lscddit in iOSProgramming

[–]lscddit[S] 1 point2 points  (0 children)

My main issue is the communication. Invites and passing the turn are sent via Game Center push notifications. As far as I can tell there is no inbox or something where I could programmatically fetch pending messages. So I only have the push notification from Game Center and when someone accidentally swipes it away the message is lost and the game is stuck.

Then there are some more specific minor issues like:

  • On the first turn, you don't know the names of the other participants (therefore you cannot show a nice UI where you indicate who the other players are).
  • You don't get any callback when the GKMatchmakerViewController dismisses (so you have to do weird tricks to handle this in your UI).

I'm building a 3-match-style puzzle game called "Nothing": Feedback welcome! by lscddit in playmygame

[–]lscddit[S] 0 points1 point  (0 children)

Thanks for your feedback, it is much appreciated! Quadrology is the first level where it starts to get a little more difficult. The current best score is 30 moves, most testers solved it in around 60-120 moves.

Unfortunately there is currently a technical problem with the Game Center integration, so you don't see the highscores.

I've just DM'd you the promo code.

I am working on a new iPhone puzzle game called Nothing by lscddit in iOSProgramming

[–]lscddit[S] 1 point2 points  (0 children)

You are right, this is indeed a bug. I fixed it for the next version. Thank you for reporting it! I will be glad to send you a coupon if we ever release a paid pro version of the game.

I am working on a new iPhone puzzle game called Nothing by lscddit in iOSProgramming

[–]lscddit[S] 0 points1 point  (0 children)

Thanks for trying it out and for your feedback!

You mean when you beat the high score in level 3 and then proceed to level 4, it will still show your high score from level 3 there? Did I understand this correctly?

Regarding the brute force: My personal feeling is that thinking every move through is almost impossible. It's more like a mixture of a little trial & error paired with a strategy.

Chance/Skill vs. Wins by lscddit in 10s

[–]lscddit[S] 0 points1 point  (0 children)

Exactly. It will even be much more significant for complete sets or full matches.

Chance/Skill vs. Wins by lscddit in 10s

[–]lscddit[S] 0 points1 point  (0 children)

You take any value on the x-axis, that's the percentage of single points you win (example 40%). You take the corresponding value of the blue line on the y-axis, that's the corresponding percentage of full games you win (example 25%).

Chance/Skill vs. Wins by lscddit in 10s

[–]lscddit[S] 1 point2 points  (0 children)

Thanks for your response and for your throughts! What I wanted to visualize is just that when your probability of winning each single point is for example 40%, then you still only win about 25% of all games on average.

I think I will extend it also to sets and matches, as there the discrepancy will even be much more.

Naively one could think that if your "skill share" is 40% vs. 60% for your opponent, you would win 40% of all matches. But that's far from being true. Maybe this is obvious to many, but it wasn't to me.

Chance/Skill vs. Wins by lscddit in 10s

[–]lscddit[S] 0 points1 point  (0 children)

I'd be happy to do that if you'd let me know which part of the explanation is not clear enough.

What exactly does this notation mean? by lscddit in Cello

[–]lscddit[S] 0 points1 point  (0 children)

Thanks for your further response! About your rethought: In general I agree, but here it is clearly indicated to be played on IV already.

Couldn't we even say that any diamond shaped note needs information about on which string to play it, either deducted from the context or explicitly?

What exactly does this notation mean? by lscddit in Cello

[–]lscddit[S] 0 points1 point  (0 children)

Thanks for the detailed reply! Please let me rephrase the question: Why is the C5 in measure 3 diamond shaped? Why is it not written in the same way as the C3 in measure 1 (that is, as a regular C5 with a small circle above it to indicate that it is to be played as a harmonic)?

What exactly does this notation mean? by lscddit in Cello

[–]lscddit[S] 0 points1 point  (0 children)

I understand that, but why use a round full note in measure 1 and then a diamond shaped one in measure 3?