Publish to Alipay Mini Games

    Cocos Creator officially supports the release of games to the Alipay Mini Games.

    • Download Alipay and install it on your phone.

    • The minimum supported version of Alipay on Android is 10.1.75, on iOS is 10.1.78.

    First, use Cocos Creator 3.0 to open the project that needs to be released. Select Alipay Mini Game in the Platform dropdown of the Build panel, and then click Build.

    The specific filling rules for the relevant parameter configuration are as follows:

    • Polyfills - Polyfills are optional. If this option is checked at build time, the resulting release package will have the corresponding polyfills in it, and will also increase the size of the package. Developers can choose polyfills on demand, but only are currently available.

    • Remote URL - Remote URL is optional. For details, please refer to the Resource Management for Alipay Mini Game Environment section below.

    Second, after the build is completed, click the folder icon button below the alipay-mini-game build task to open the build release path. If the Build Task Name is , you can see that the Alipay Mini Game’s project folder alipay-mini-game is generated in the directory, which has included Alipay Mini Game environment configuration file game.json.

    preview

    Alipay Mini Game is similar to WeChat Mini Game. There are restrictions on the package size. Assets more than 4MB must be downloaded via a network request.

    It is recommended to only save script files in the mini-game packages, while other assets are uploaded to the remote server, and downloaded from the remote server as needed. The download, cache, and version management of remote assets, Cocos Creator has already done it for you. The specific implementation logic is similar to the WeChat Mini Game. Please refer to the documentation for details.

    Specifically, developers need to:

    1. When the build is complete, upload the folder to the server.
    2. Delete the res folder under the local release package directory.

    Currently, our adaptation of Alipay Mini Games has not been completely completed, and the following modules are still not supported:

    • WebView
    • VideoPlayer
    • Custom Font