Skip to content

Commit

Permalink
Update index.md
Browse files Browse the repository at this point in the history
  • Loading branch information
britzl committed Dec 15, 2023
1 parent 15f7c6f commit 3e73102
Showing 1 changed file with 2 additions and 9 deletions.
11 changes: 2 additions & 9 deletions docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ Select `Project->Fetch Libraries` once you have added the version to `game.proje

## Implement the gameplay events

Use the `poki_sdk.gameplay_start()` event to describe when users are playing your game (e.g. level start and unpause).
Use the `poki_sdk.gameplay_start()` event to describe when users are playing your game (e.g. on first user interaction and unpause).

Use the `poki_sdk.gameplay_stop()` event to describe when users aren’t playing your game (e.g. level finish, game over, pause, quit to menu).

Expand All @@ -35,6 +35,7 @@ poki_sdk.gameplay_stop()
```



## Implement commercial breaks

Commercial breaks are used to display video ads and should be triggered on natural breaks in your game. Throughout the rest of your game, we recommend you implement the `poki_sdk.commercial_break()` before every `poki_sdk.gameplay_start()`, i.e. whenever the user has shown an intent to continue playing.
Expand Down Expand Up @@ -87,14 +88,6 @@ Congrats, you’ve successfully implemented the PokiSDK! Now upload your game to
Do not collect Lua errors manually using `sys.set_error_handler()`. The SDK collects Lua errors and the engine's errors and warnings automatically.


## Adding Sitelock
When you get your PokiSDK Sitelock code, just add it to your game as:
```lua
html5.run("Sitelock JS code from Poki")
```
For security reasons, this piece of code is not public, so please request it from your Poki contact.


## Example

[Refer to the example project](https://github.com/defold/extension-poki-sdk/blob/master/main/poki-sdk.gui_script) to see a complete exameple of how the intergation works.
Expand Down

0 comments on commit 3e73102

Please sign in to comment.