Skip to content
Egretia is a brand new open mobile game and application engine which allows you to quickly build blockchain games on Android,iOS and Windows
JavaScript TypeScript Other
Branch: master
Clone or download
Latest commit 5472dbd Dec 10, 2018
Type Name Latest commit message Commit time
Failed to load latest commit information.
build commit egretia engine code Dec 10, 2018
docs commit egretia engine code Dec 10, 2018
src commit egretia engine code Dec 10, 2018
tools commit egretia engine code Dec 10, 2018 desc change Dec 10, 2018
package_en.json commit egretia engine code Dec 10, 2018


Egretia Engine

The Egretia Engine is a HTML5 game engine. It provides modules to handle common game development tasks such as 2D and 3D rendering, GUI systems, and audio and resource management. The Egretia engine is flexible and suitable for 2D or 3D projects. It allows developers to work without worrying about low-level browser impelementation, HTML5 performance, or fragmentation issues.

Platform Coverage




To Install the Egretia Engine:

Once installation is complete, Egret's engine and tools are easy to manage.

Getting Started


Egret projects are developed using TypeScript, which is a superset of JavaScript. Please refer to the TypeScript manual for more information. The Egretia API and ActionScript3 (AS3) are very similar. It will be easy to get started with Egretia if you are familiar with AS3.

Create a project by command line

Use following command to create a default game object:

egret create HelloWorld

You may also add parameters if required: Use empty | game | gui | eui to specify different projects.

After running this command, you should now see a folder called 'HelloWorld'.

Write your first line of code

By default, the entry point for an Egretia game projects is src / Main.ts. To make write the first line of code for your project, find the createGameScene () function, and add console.log ("Hello World");

After making your changes, the code should now look like this:

private createGameScene():void {
        // log
        console.log("Hello World");
        var sky:egret.Bitmap = this.createBitmapByName("bgImage");
        var stageW:number = this.stage.stageWidth;
        var stageH:number = this.stage.stageHeight;
        sky.width = stageW;
        sky.height = stageH;

Here, we've called console.log("log content that we'd like to display"). This will display our log message in the browser's developer tool.

We recommend using Chrome to debug the Egretia project.

Use the following command to build Egretia projects:

egret build

Use the following command to run Egretia projects:

egret startserver

For more information, please refer to the Learning Module documentation.


Tower Defence Demo Click here for online experience.

Click here for more 2D/3D demos.

Show Case

Click here to see Show Case


  • Access Doc to get Engine document
  • Access Example to learn demo source code
  • Access API to get API document
  • Access Video to get videos
  • Access Community to communicate with other developers


Third Party Library

  • Use base64texture to convert base64 String to egert Texture
  • Use dcagent DataEye SDK for Egret
  • Use ecs component system
  • Use euiextension EUI extension
  • Use gesture Gesture library
  • Use keyboard Keyboard event listener
  • Use Greensock Greensock animation library
  • Use jszip jszip Compression library
  • Use md5 A simple MD5 Library
  • Use mouse PC mouse support library
  • Use particle particle system
  • Use physics p2Physics engine,current version 0.7.0
  • Use socket
  • Use tiled tiledmap support library
  • Use weixinapi WeChat API
  • More third party libraries please visit here


Asking a question is the first step to participating in an open-source community. You can report Egretia issues here. It is recommended that issues be discussed in the official community portal, as it can help with solving problems efficiently.


This content is released under the ( BSD License.

You can’t perform that action at this time.