HTML vs C++

HTML vs C++
0.0 0


Building an app in html vs in C++ What is the difference if I was to open the same game essentially on an iphone. Just one of them was built usign cocos html and one in cocos c++? Im still new to the app game haha


From a user’s perspective, they are the same


@teohzhiliang Thanks for the help! So it doesnt mean they need internet to play the game? Just the style of coding between the two?


@teohzhiliang Also would you say its easier to develop games using html?


Hi, @Acerz

Of course it’s much easier to develop your game using javascript than using C++, the simplicity shows in two aspects

  1. Efficience of coding
  2. Simplicity of debug: you can firstly develop your game using cocos2d-html5, and debug your game logic on Chrome which is also easier than debug with C++.

Other advantage of using javascript is that you can directly have web version and native version in the same time.
But there is also disadvantage of javascript binding, it do use the native cocos2d-x API, however, the performance is not on the same level.

So all depend on your need, if you develop a simple game and want a quick development, then cocos2d-html5 with JSB is perfect for you, but if your game is more complexe and using many features like particle system, OpenGL effects, armature animations, etc… then may be you’d like to test the performance first.



@pandamicro Thanks a lot man. But I noticed that Java script is executed by web browsers. That doesnt necessarily mean that the app will need an internet connection to play does it?



The javascript binding is using Mozilla spider monkey which is simply a javascript engine, it doesn’t require a internet connection