Cocos Creator API

1.3.0

Cocos Creator is a highly customizable game development tool that utilizes the power of cocos2d-x.

ProtocolSocial

social protocol

signIn ( )

sign in

signOut ( )

sign out

submitScore
(
  • leadboardID
  • score
)

submit score

leadboardID String
score Number

Type: long

showLeaderboard
(
  • leaderboardID
)

show the id of Leaderboard page

leaderboardID String

showAchievements ( )

show the page of achievements

share
(
  • info
)

unlock achievement

info Object

Type: map

setListener
(
  • listener
  • target
)

set listener

listener Function
target Object

getListener ( ) Function

get listener

:

: Function

listener

pauseRecording ( )

get friends info Before to invoke, you need to verdict whether this properties existed

interact ( )

interact Before to invoke, you need to verdict whether this properties existed

subscribe ( )

subscribe Before to invoke, you need to verdict whether this properties existed

isFunctionSupported
(
  • functionName
)
boolean

Check whether the function is supported

functionName String

:

getPluginName ( ) String

get plugin name

:

: String

getPluginVersion ( ) String

get plugin version

:

: String

getSDKVersion ( ) String

get SDK version

:

: String

callFuncWithParam
(
  • funName
  • [args ]
)

void methods for reflections with parameter

funName String
args optional Object | anysdk.PluginParam

optional arguments

callStringFuncWithParam
(
  • funName
  • [args ]
)
String

String methods for reflections with parameter

funName String
args optional Object | anysdk.PluginParam

optional arguments

:

: String

callIntFuncWithParam
(
  • funName
  • [args ]
)
Number

int methods for reflections with parameter

funName String
args optional Object | anysdk.PluginParam

optional arguments

:

: Number

Type:int

callBoolFuncWithParam
(
  • funName
  • [args ]
)
boolean

boolean methods for reflections with parameter

funName String
args optional Object | anysdk.PluginParam

optional arguments

:

callFloatFuncWithParam
(
  • funName
  • [args ]
)
Number

float methods for reflections with parameter

funName String
args optional Object | anysdk.PluginParam

optional arguments

:

: Number

Type:float

There are no methods that match your current filter settings. You can change your filter settings in the index section on this page. index