Publish to Cocos Play
Cocos Creator officially supports the release of games to the Cocos Play.
- Download and install the Cocos Play Self-test Tools on your Android device (recommended Android Phone 6.0 or above).
Use Cocos Creator 3.0 to open a project. Select Cocos Play in the Platform dropdown of the Build panel, and then click Build.
The specific filling rules for the relevant parameter configuration are as follows:
After the build is completed, click the folder icon button below the cocos-play build task to open the
build
release path. If the Build Task Name iscocos-play
, you can see that acocos-play
folder is generated in thebuild
directory. This folder is the exported Cocos Play game project and cpk, the cpk package is in thebuild/cocos-play
directory.
The Self-test Tools can launch the game and provide features such as game login, payment, etc. By reading the game configuration parameters, you can determine the type of game to start and how the game will start.
For details, please refer to the documentation.
Open the previously installed Self-test Tools, then click the Configure Game button at the top left of the Self-test Tools to enter the game configuration page. Configure parameters as required and click Save.
Properties
There are two ways to start the game through the Self-test Tools.
Load the game package as a file from the specified location (The game lodeType is File).
- Copy the
.cpk
file generated after the build to the device directory, if it is copied to the internal storage directory of device, create a new folder (named cocosplay) in the internal storage directory and copy the.cpk
to the cocosplay folder. - Select File in the lodeType of the game configuration page.
- Fill in the path to the cocosplay folder where the
.cpk
file is placed in thepath
option. Such as/cocosplay/game.cpk
.
- Copy the
Open the game as a web page from the specified URL (The game lodeType is Url).
- Upload the
.cpk
file to the server. - Select Url in the lodeType of the game configuration page.
- Fill in path, such as: .
- Click on Save after the configuration is complete, then click on Start Game to open the game.
- Upload the