Skip to content

General

Kopfenheim edited this page Jan 31, 2018 · 4 revisions

Various general functions that do not require the player to be signed in.

Functions

  • init(String instanceIDsStr, boolean useSavedGames)

    Initialize the module

    • Parameters
      • instanceIDsStr: The string with the instance IDs of the various scripts which contain callbacks for different functionalities. Refer to Initialization and Callbacks for more information
      • useSavedGames: Pass in true if you want to use the saved games (snapshots) functionality and false otherwise
    • Returns
      • Nothing
  • clearCache()

    Deletes any images stored on the device which had been saved when loading the player's or multiplayer participant's icon images. It is recommended to call this function when the player exits the app (using the notification for MainLoop.NOTIFICATION_WM_GO_BACK_REQUEST or MainLoop.NOTIFICATION_WM_QUIT_REQUEST).

    • Parameters
      • None
    • Returns
      • Nothing
  • keepScreenOn(boolean keepOn)

    Force the screen to remain on (or not). This is necessary during a real-time match because if the device's screen turns off during a match then the player will be disconnected from the room.

    • Parameters
      • keepOn: if true then the screen will be force to stay on. if false then screen could turn off based on the device settings
    • Returns
      • Nothing
  • getDelimiter()

    The default delimiter used for seperating data contained in a string that is passed to or from the module. For example: This is the character expected by the module for separating the instance IDs in the string passed into init()

    • Parameters
      • None
    • Returns
      • String The delimiting character

Callbacks

None