Engines overview
Engines overview
Every engine page documents the same SDK. The wrappers are thin: they load the JavaScript SDK in the web export and translate calls, so behaviour, limits and error codes are identical to the JavaScript reference.
| Engine | Distribution | Status |
|---|---|---|
| Unity | Unity package com.zokogames.sdk (WebGL) |
Available |
| Phaser | Global plugin (ZokoPlugin) around the JavaScript SDK |
Available |
| Godot | Addon zokogames (Godot 4, HTML5 export) |
Available |
| Construct 3 | Addon (actions, conditions, expressions) | Available |
| GameMaker | Extension (zokogames.js) |
Available |
| Cocos | TypeScript module ZokoSDK |
Available |
| Defold | Lua library zokogames |
Available |
Status of the wrappers. The wrappers are written against each engine's documented API and share one bridge, but they have not yet been compiled and run in every engine's editor. Expect small fixes on first import, and send them to support with the engine version. The JavaScript SDK underneath is the tested part.
Every wrapper mirrors the JavaScript SDK method list. The naming rules below are the mechanical mapping; each engine page lists the exact calls.
Naming rules#
The JavaScript API is the source of truth. Other languages follow a mechanical mapping.
| JavaScript | C# (Unity) | GDScript (Godot) | GML (GameMaker) |
|---|---|---|---|
SDK.init() |
ZokoSDK.Init(cb) |
ZokoGames.init_async() |
zoko_init() |
SDK.ad.requestAd(type, cb) |
ZokoSDK.Ad.RequestAd(type, ...) |
ZokoGames.request_ad_async(type) |
zoko_ad_request_ad(type) |
SDK.game.gameplayStart() |
ZokoSDK.Game.GameplayStart() |
ZokoGames.gameplay_start() |
zoko_game_gameplay_start() |
SDK.user.getUserToken() |
ZokoSDK.User.GetUserToken(cb) |
ZokoGames.get_user_token_async() |
zoko_user_get_user_token() |
SDK.data.setItem(k, v) |
ZokoSDK.Data.SetItem(k, v) |
ZokoGames.data_set_item(k, v) |
zoko_data_set_item(k, v) |
- Modules become
Ad,Banner,Game,User,Data,Analyticsin C# andad,banner,game,user,data,analyticsin Lua. GDScript and GML flatten the modules into the method name (ZokoGames.gameplay_start(),zoko_game_gameplay_start()). - Promises become callbacks (Unity, GameMaker async events) or awaitable calls (Godot, Unity
...Asyncmethods). - Error objects keep
codeandmessage; C# exposes them asCodeandMessage.
Properties of all wrappers#
- Editor simulator. In the editor and in non-web players a simulator answers instead of the browser, so you can run the game without uploading it. It mimics ads, users, friends and cloud save, and has settings to force an ad failure or an adblocker.
- Disabled is normal. If the SDK is disabled the wrapper reports
disabledand your game must still run. - Single core. The browser side of each wrapper is generated from one shared bridge, so a fix applies everywhere.
Web export checklist (all engines)#
- Export for the web (WebGL, HTML5), not as a desktop or mobile app.
- The page that hosts the engine must load
https://sdk.zokogames.com/zokogames-sdk-v1.jsbefore the engine boots. Engine templates provided by the wrappers already do this. - Keep the initial download small, see first frame fast.
- Use relative paths and Brotli or Gzip compression only if your export tool also configures the response headers; the portal's hosting handles pre-compressed Unity files.
- Test in the Preview tool.