Beginner: Build Runtime Quick Game using Cocos Creator — Part 3

Basavaraj Navi
Nov 8, 2021 · 5 min read
Huawei Quick Game

Introduction

Are you new to Quick game?

If yes, follow my previous articles understand basics about Quick Game.

In this article, we will learn how to build the Runtime Quick using Cocos Creator.

What is runtime quick game?

After runtime quick games based on RPKs developed by different development tools (Like Cocos Creator, LayaAir, Egret) are released on AppGallery, they can be loaded and run on Quick App Center.

Creating Quick Game

Step 1: Register as a Huawei developer and pass identity verification on HUAWEI Developers.

Step 2: Set up the development environment, including installing development tools on the PC and Quick App Loader (for mobile phones and tablets) on the test device.

Step 3: Sign in to AppGallery Connect and click My apps.

Step 4: Click New App.

Step 5: Add all required information, then click OK.

Parameters information.

Step 6: Navigate to Project settings > General information add package details.

Step 7: Add Default data processing location.

Generating and configuring a certificate fingerprint.

Create certificate

Step 1: Open Quick App IDE and open an existing project or create new project.

Step 2: Choose Tools > Certificate

Step 3: If signature is not yet created, select Create else if already exist select Import.

Step 4: Add necessary information and click Create.

Step 5: Copy SHA-256 certificate fingerprint from output.

Configure the Certificate fingerprint in AppGallery

Step 1: Sign in to AppGallery and click My project.

Step 2: Select the project which you want to configure the certificate fingerprint.

Step 3: Navigate to Project Settings > General information in the App information and enter the copied SHA-256 certificate.

Enable Game service.

Step 1: Sign in to AppGallery and click My project.

Step 2: Select the project which you want to enable Game service and Account kit.

Step 3: Navigate to Project settings > Manage APIs and enable Account Kit and Game Service.

Install Runtime Quick Game development tool

Cocos Creator

To use Cocos Creator to develop a quick game, visit the Cocos official website to obtain Cocos Creator 2.0.7 or later and install it.

LayaAir IDE

To use LayaAir IDE to develop a quick game, visit the Laya official website, obtain the installation package of the required version, and install it.

Egret Engine

To use Egret Engine to develop a quick game, visit the Egret official website, obtain the EgretLauncher and Egret Wing installation packages of the required versions, and install them.

Building Application in Cocos Creator.

Step 1: Open Cocos Dashboard. Choose Project and click New.

Step 2: You can select type of project and Click on Create and open.

  • Empty(2D)

In this article, I will choose Example Taxi Game

Step 3: Navigate to Project > Build.

Step 4: Set the parameters by referring to the following figure. The values of the parameters must be the same as those in the manifest.json file.

Step 5: Select Huawei Quick Game for Platform. After configuring all relevant items, click Build. The RPK is generated in the build/huawei/dist directory of the project.

Enter the required details. Select Build and make.

Step 5: Connect your phone to a computer using a USB cable and enable the developer mode.

For details, please refer to Enabling the Developer Options on a Huawei Phone.

Step 6: Click Play on the Build page.

On the displayed QuickGame DevTools page, click the run icon to run the game on the mobile phone.

Step 7: If you do not have devices, you can also run on the browser.

Result

Tips and Tricks

  • Understand About Quick Game.

Conclusion

In this article, we have learnt about creating Quick Game using Cocos Creator, generating and configuring the SHA-256 fingerprint certificate, Enabling game service and account kit and building Runtime Quick Game application.

Reference

Quick Game official document

Download tools from here

Beginner: Find the Explanation of Quick Game Part 1

Beginner: Tic Tac Toe Game using HTML5 Quick Game — Part 2

Huawei Developers

Huawei Developers