Interfaces
Last updated
Last updated
negdkcc
negdkcc / INEGdk
Defined in:
Represents the interface for the Game Development Kit (GDK). Provides methods for initializing the GDK, logging in, managing game profiles, and interacting with the game server.
buyShopPack(
packId
,amount
,currency
,callback
):void
Defined in:
Purchases a shop pack.
Parameters
packId
number
The ID of the shop pack to purchase.
amount
number
The amount to purchase.
currency
string
The currency to use for the purchase.
callback
NEShopBuyCallback
A callback function to handle the purchase result.
Returns
void
createWallet():
string
Creates a new wallet and returns the seed phrase.
Returns
string
The generated seed phrase.
getAddress():
string
Retrieves the player's address.
Returns
string
The player's address.
getAuthToken():
string
Retrieves the authentication token.
Returns
string
The authentication token.
getGameProfile():
NEGameProfile
Retrieves the player's game profile.
Returns
NEGameProfile
The player's game profile.
getProvider():
string
Retrieves the current provider being used for authentication.
Returns
string
The provider name (e.g., "google", "facebook").
initialize(
config
,callback
):void
Initializes the GDK with the provided configuration.
Parameters
config
NEGdkConfig
The configuration to initialize the GDK with.
callback
NEInitCallback
A callback function that will be invoked after initialization is complete.
Returns
void
isLoggedIn():
boolean
Checks if the player is logged in.
Returns
boolean
true
if the player is logged in, false
otherwise.
isLoginCacheExpired():
boolean
Checks if the login cache is expired
Returns
boolean
true
the login cache has expired or there is no login data in cache, false
otherwise.
loginWithApple(
callback
):void
Logs in using Apple authentication.
Parameters
callback
NELoginCallback
A callback function that will be invoked with the login result.
Returns
void
loginWithEmail(
callback
):void
Logs in using Email authentication.
Parameters
callback
NELoginCallback
A callback function that will be invoked with the login result.
Returns
void
loginWithFacebook(
callback
):void
Logs in using Facebook authentication.
Parameters
callback
NELoginCallback
A callback function that will be invoked with the login result.
Returns
void
loginWithGoogle(
callback
):void
Logs in using Google authentication.
Parameters
callback
NELoginCallback
A callback function that will be invoked with the login result.
Returns
void
loginWithPhrase(
phrase
,callback
):void
Logs in using a phrase (e.g., seed phrase).
Parameters
phrase
string
The login phrase (seed phrase).
callback
NELoginCallback
A callback function that will be invoked with the login result.
Returns
void
loginWithProvider(
provider
,callback
):void
Logs in using a specific provider (e.g., Google, Facebook).
Parameters
provider
string
The provider name (e.g., "google", "facebook").
callback
NELoginCallback
A callback function that will be invoked with the login result.
Returns
void
loginWithTelegram(
callback
):void
Logs in using Telegram authentication.
Parameters
callback
NELoginCallback
A callback function that will be invoked with the login result.
Returns
void
logout():
void
Logs the player out of the system.
Returns
void
requestGameProfile(
callback
):void
Requests the player's game profile.
Parameters
callback
NEGameProfileCallback
A callback function to handle the result.
Returns
void
requestShopInfo(
callback
):void
Requests the available shop information.
Parameters
callback
NEShopInfoCallback
A callback function to handle the result.
Returns
void
requestUserBalances(
callback
):void
Requests the player's balances.
Parameters
callback
NEUserBalanceCallback
A callback function to handle the result.
Returns
void
requestUserPets(
callback
):void
Requests the player's pets.
Parameters
callback
NEUserPetCallback
A callback function to handle the result.
Returns
void
Defined in:
Defined in:
Defined in:
Defined in:
Defined in:
Defined in:
Defined in:
Defined in:
Defined in:
Defined in:
Defined in:
Defined in:
Defined in:
Defined in:
Defined in:
Defined in:
Defined in:
Defined in:
Defined in:
Defined in: