ppgee / cocos-pnp

Cocos Playable Ads in Multi-Network(facebook, google, unity, tiktok etc.)
MIT License
93 stars 47 forks source link

How Can I Send Events On Platforms #12

Open xwbash opened 5 months ago

xwbash commented 5 months ago

How can I trigger events like starting a level, ending it, or opening the market? I have a ".adapterrc" file like the one below, but I don't know how to run events through TypeScript.

{
  "buildPlatform": "web-mobile",
  "orientation": "portrait",
  "enableSplash": true,
  "injectOptions": {
    "AppLovin": {
      "head": ""
    }
  }
}
ppgee commented 5 months ago

If you are only calling relevant methods within the business scenario, you just need to add them to the business code. If it requires platform audit verification, inject similar global methods in the relevant networks. image