Can OutSystems P10 be used to build games?

Can OutSystems P10 be used to build games?


Short answer is, yes. I've been in my spare time, building some simple, yet funny games. ( at least in my opinion  ).

Currently I've around 10 ongoing projects (some already in Production) in my Personal Environment and 4 of them are games.

While trying to build games using P10, I came across some limitations, or we can call them as not yet optimized features! But we need to take into consideration that P10 was released not so long ago.

Some of them I've already shared with the team, but we need to know that I'm reporting stuff that's not directly related with Enterprise Applications, and I know before hand that they might not get implemented, but it's worth the sharing.

Since P10 we can build heavily based JavaScript applications with the ease that we're used to do it in the past. So why not benefit from that and enter the hype of minimal, simplistic yet funny HTML5 games, that once build can be deployed across different platforms without so much effort?

Let's breakdown some of the limitations that I've identified and that I would love to see them tackled down in future releases of the platform.

  • WebGL and Canvas support.

As we all might know, P10 uses Cordova (previously known as PhoneGap), and by looking to a Scirra benchmark we will know that:

"PhoneGap unfortunately appears on the whole to be unsuitable for publishing HTML5 games. This is mainly because it is stuck with the system default browser which is usually too slow. On iOS the system browser is Safari which actually performs very well, but when you wrap it up in PhoneGap it drops three times slower on iPad 2, ten times slower (!!) on iPad 3 (using the retina display), and bizarrely for reasons I really struggle to comprehend, is only marginally slower on the iPhone 4S. So the only utility for PhoneGap appears to be for targeting the iPhone. Windows Phone 7 also seemed to take a performance hit from using PhoneGap, so perhaps there are difficult technical issues around putting a browser in a native app."

Nevertheless I gave it a try, and by building simple and not heavy animated games, the platform can do the job. But if you're aiming to rich eye candy games, unfortunately is a big no go ...

With this in mind I created Tappy Colors. It's a fully HTML5 + Javascript game, no canvas or webgl was used. On new phones, with newer versions of Android it runs really well, but for older phones with old Android versions it can gets a bit sloppy.

But I also want to give canvas another try, because in the first game, a platformer, I was adding to much stuff on the screen, from animations, to particles, the world, and so on. While testing in the desktop browser I was getting a nice, smooth and stable 60fps, but when I moved the first version to native I got it to an average of 7fps...

On the second try, the game was a simply clone of the iOS version Perfect Square. Where we need to fit one square onto the platform so that it’s aligned perfectly. Touch it to grow and release to let it fall! It may sound simple, but this one touch game will take super precision and timing to master it!

In my version of Perfect Square, since it is really simple and minimalist I've no issues at all on modern phones, while using canvas! And just some minor issues on older phones.

  • Plugin Variables

This one is a minor issue, and easily overcome. But there are some plugins which we're required to add up some variables. Due to the fact of platform re-usability, we always try to create once, use it in every application that needs it. But in this case we cannot do that.

For example, I created the OutSystems version of Google Play Services plugin. This Cordova plugin needs to know which game (in the playstore) are we going to attach. In P10 this is done at the plugin level, so in order to have the same plugin for multiple games, you need to have one plugin replica for each game.

  • WebRTC

This is also a limitation of the default Cordova webview. There's no support for native WebRTC, useful for real-time messages for example, and I came across this when building a real-time multiplayer game, that I'll release soon. To overcome this limitation I easily integrated P10 with Pusher and now I can have real-time communications for my games and apps. But would be nice to see this natively in a next version of the platform.

These are the biggest limitations (in my opinion) to develop games using the platform, but we need to keep in mind that the platform is aimed for enterprise grade applications and to games  . And I've described limitations that are more related with Cordova and not directly with the platform.

With this projects I've created some useful plugins that I'll share with the community soon, from Ads, to Native Audio, Google Play Services for leaderboards... It's been a funny and interesting way to spend some of my spare time!

Have any of you gone through the same pains? Do you have any game to share with us? How about to create a showcase of OutSystems games?


That's pretty cool! Thanks for the informative post!

Very cool, awesome work!

This is cool! Good job!

bullet force

Good one....!