1. Home
  2. Knowledge Base
  3. Mobile Built Services
  4. CocoonIO
  5. Tutorials
  6. Cordova Dialog – Make an exit message in Construct 2

Cordova Dialog – Make an exit message in Construct 2

Exit Message

If you’re using CocoonIO, you can switch to this Tutorial. But you also can use the additional plugin Cordova Dialog by Cranberrygame.

[creativ_button url=”https://shatter-box.com/knowledgebase/cocoonio-make-a-on-exit-message-in-construct-2/” icon=”book” label=”CocoonIO – Make an on exit message in Construct 2″ colour=”blue” colour_custom=”” size=”medium” edge=”straight” target=”_blank”]

Install the plugin

For this tutorial you need the Cordova Dialog plugin by Cranberrygame. You get them in the scirra store.


Cranberrygame - Cordova Plugins 150 MB 4920 downloads

Download the awesome Cordova Plugin Package provided by Cranberrygame. The package...


Download the package and drag & drop the



file into Construct 2.


Then restart Construct 2.


Then start coding the dialog function. An easy example is shown below.


The result will look like that then.


Demo (Android file)

You can try the demo android application file to see it in action. Just download it here.


Cocoon - On Exit Dialog 6 MB 1196 downloads

Download our demo application for the Cocoon On Exit Dialog game template. ...

Source file

Moreover you can download the capx example over here. But remember to install the plugins “CocoonCanvas+” & “CordovaDialogs” first.


Cocoon - Exit Message (CordovaDialog) 0.2 MB 1521 downloads

Download our free game template Cocoon Exit Message. This template uses the plugin...

Additionally you can use the CocoonCanvasPlus plugin to make an exit dialog.


Cocoon - On Exit Message 0.2 MB 1416 downloads

Download our free game template Cocoon On Exit Message. This template shows you how...

File is for learning purposes only!


For this example you must also install the core plugin “Dialogs” in CocoonIO and Intel XDK.


Go to cocoon.io and select your project. Then click on the “Plugin” tab and select “Core“.


Find “Dialogs” and click install. Don’t forget to save your settings then.

Intel XDK

If you use Intel XDK there are no further steps required. In this case the plugin is included in the config.xml file.

Updated on May 6, 2018
Was this article helpful?

Related Articles

Not the solution you were looking for?
Click the link below to submit a support ticket
Visist our Forum!

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.