Games in ionic


can you please tell me if it is possible to develop games with Ionic ?

I am worrying about the video capabilities, etc.


What you like to ask yourself is rather is HTML5+JavaScript responsive enough for the kind of game you like to create.

For graphics, you probably want to make a fullscreen div and use one of many possibilities like HTML5 2D canvas, SVG, WebGL, Leaflet, OpenLayers or just plain DOM and CSS to render the game. They all have their pros and cons. And you can even mix it up by using eg 2D canvas for the background and place DOM objects on top.

For the Ludum Dare 48h game challenge, I have created two different games in Ionic. One of them is a turn based game using SVG as drawing canvas. The other one is using Leaflet as drawing canvas and use geolocation as the only way to control the player.

Thanks a lot for your answer @Leffe108. Are there example of Ionic games i could try out ?

you should dig into phaser.js if you want to build a game with javascript and html5

there is also cocoon js with its own webview for faster rendering. But i tried this a year ago and working with this was terrible.

But i think it is worth a try

1 Like

Here you can find my two Ionic games with source code. Both are made in 48 hours for the Ludum Dare rules which are liberal in the use of code libraries, but art has to be created by yourself in 48 hours (though fonts, materials, sound generators etc. is allowed)
Navennni - My first try on a turn based game in Ionic for Ludum Dare.
Shapes Outdoor - My most recent LD entry.

They may contain things that are not best practice. So look on other tutorials etc. to learn that. Especially the first one clearly does something wrong as the intro scene often get screwed up if you return to it after having started the game. In Ludum Dare you have to be a bit lose on best practices and get things done within the time limit.