~/talk

Bridging Apps with iOS Multipeer Connectivity

Talkat Swift Craft 2024 · 2024-05-21..05-24· [ios, web-platform]
slides:none on file

A basic Tic‑Tac‑Toe app connects two iOS devices using MultipeerConnectivity: it uses MCSession, MCNearbyServiceAdvertiser and MCNearbyServiceBrowser, encodes game moves as Codable JSON and persists MCPeerID stored with NSKeyedArchiver so identities remain consistent. The session model limits direct peers to 8-device session limit; the demo works reliably for two phones, supports sendResource for images, but streaming is unimplemented and backgrounding disconnects sessions requiring manual re‑establishment and lots of delegate debugging.

AI-written summary · about

  1. 0:00Introduction to speaker
  2. 1:04Why use Multipeer Connectivity
  3. 3:11Use cases for Multipeer
  4. 3:55Key framework concepts
  5. 5:46Setting up the app
  6. 7:14Player model and session
  7. 9:19Delegates and setup
  8. 10:50App states and UI
  9. 11:34Finding peers with browser
  10. 12:15Inviting peers to session
  11. 12:59Session delegate and connection
  12. 13:21Transferring data between peers
  13. 14:46Sending and receiving messages
  14. 17:17Game logic and Tic Tac Toe
  15. 19:04Sending game state updates
  16. 19:46Live demo of Tic Tac Toe
  17. 20:49Challenges with Multipeer
  18. 21:30Debugging difficulties
  19. 22:13Future improvements
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.