Gideros Unite Framework

From GiderosMobile
Revision as of 06:50, 14 December 2023 by MoKaLux (talk | contribs)


Gideros Unite Framework

ar2rsawseen 2012/07/25 Gideros Mobile, updated 2023/12/13 (V2)

Gideros Unite framework provides a way to implement Multiplayer games:

  • using LuaSocket to establish socket connections and create server/client instances
  • device discovery over Local Area Network
  • call methods on devices through the network
  • protocols: tcp, udp or both (binding some method to tcp if reliability is needed, and others to udp for faster data processing)

You can download the Gideros Unite Framework: Unite.zip

And an application project: DrawTogetherV2.zip

Standard scenario

This is a standard scenario that can be created using Gideros Unite framework:

  1. Server starts broadcasting or skip to step 5, if all clients know server IP address
  2. Client's start listening to servers
  3. Client receives broadcast message from server, newServer event is initiated
  4. Client autoconnects to server or user manually (by pushing button) connects to specific server
  5. Server receives newClient event
  6. Server accepts client automatically or user manually (by pushing button) accepts specific client
  7. Client receives onAccept event
  8. Implement your game logic here, where both clients and server can call methods on all devices or on one specific device in the network
  9. When one of the clients becomes unreachable, all clients and server get onClientClose event
  10. When server becomes unreachable, all clients get onServerClose event
  11. When you are finished, close client or server using close method, which stops all timers, closes all connections and destroys instance

Framework