Sign in to follow this  
fikers

New User! Some questions!

Recommended Posts

Hi everyone!

I'm a first time poster on this forum after having just come across it after a google search - just what I was looking for.

I have a finance background but have been learning how to program (JavaScript) the past few months. I have an idea for a simple game that I really want to build. However, instead of learning Swift, I was thinking of building a native iOS app using something like PhoneGap or CoCoon. I don't even know if that's actually possible since I don't know what exactly they are but from what I've gathered, these programs will let you build a game in JavaScript and compile it into a native iOS app - which would be pretty cool!

Can someone guide me to some resources on where I can get introduced to the world of making games using JavaScript for iOS (where I think the market for games really is)?

Thank you - looking forward to contributing to this community!

Share this post


Link to post
Share on other sites

Cordova have a number of getting started guides on their homepage, Phonegap is just a wrapper around cordova (I think) and I'm not sure about Cocoon but I'd expect all of them have detailed getting started guides.

These wrappers work by creating a basic skeleton native project, inserting a webview and loading that webview up with your HTML, which then loads your JS, CSS and whatever else you need. They normally also contain some mechanism for allowing JS to talk to the native app, or, at least, trigger some native actions to take place (such as save data locally which you can't really do on the web), this communication normally requires installing and managing a load of plugins, some of these plugins also contain configuration which allows the platforms to scaffold a native app (such as changing the status bar look or some other stuff like requesting permissions).

All of these platforms require a fairly hefty build process and part of the process is making running that build process as easy for you as a developer as possible (note that you'll need a hefty amount of dependencies for each platform, for example if you want to target iOS you need a Mac to get xcode which is required to build the project).

If you're new to JS then trying to throw it into a native wrapper is going to significantly decrease your chance of finishing any sort of project, even without dealing with the myriad of subtle bugs from trying to access and control native features you're upping the difficulty significantly by adding a chunky build chain, if you're writing your code in ES6 then that comes with it own build chain to get runnable JS on all platforms so you might need that (note that actually, if you're only targeting newer OS's and therefore newer browsers, many ES6 features are already implemented so you may be able to forgo transpiling back to regular JS, if you don't know what any of this means then this is part of your learning curve!).

I'd strongly suggest finishing some 'regular' JS projects, getting them to run correctly in the browser then creating a public url and shipping to a server so you have a finished project before tackling something like web-in-native. If you do go the web-in-native route then good luck! It's an exciting field and one that is growing, there are a number of complex 'native' apps on the various app stores that are running web tech so its a good avenue to pursue, but, know your language first, JS is quirky and whilst it is, in theory, a very permissive and 'easy' language there are so many gotchas that it can be a tricky language to really master.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.