We need a friendly ENGINE, not a dysfunction EDITOR

5+ years ago when we started, C++ was the only way to develop cross platform games and apps, JavaScript is now another option.

You can choose cocos2dx or some other framework, but I would strongly recommend giving a second thought to JavaScript.

(Or TypeScript, which I find to be a better JS as it gives better auto-complete while coding and better compile time error checking. For JavaScript I will recommend using WebStorm, and for TypeScript you should use Visual Studio Code).

Languages are just tools. I have moved between C++, Java, ObjC, Swift, JavaScript, Python, PHP, C# over the years and differences arenā€™t much. Javascript is only becoming special because there are now JS frameworks that can do everything from server (NodeJS) to mobile apps (Cordova) to desktop apps (Electron) to games (WebGL) to WebVR and IOT etcā€¦ Making it possible to not work with multiple languages for a single project. Or in case of companies, not hire people with different language skills.

If you are happy with current C++ cocos2dx why not just stay with the current cocos2dx releases? Why migrate to another similar framework? I think the Cocos2dx team is doing a good job of giving more options for developers who want to use an Editor for development, or for developers who prefer JS. They havenā€™t stopped development of the core C++ engine that we all love.

We are doing the extra work of moving to JS because it gives some advantages in development/maintenance time/cost. And makes it possible to target more platforms that need html/css/js apps. Where this is not the case, we are continuing with cocos2dx C++. Moving to another framework is just too much work with no benefits.

I love C++ and Cocos2dx, but I am not biased against other languages or frameworks. Some of our projects are using ThreeJS while others are going to stay Cocos2dx C++. Most of them are now Cocos2d-JS, and we are ā€˜tryingā€™ Cocos Creator for one. It really depends on the project and its needs.

exactly that. on your last sentence is the truth. Iā€™m currently evaluating a use case where I probably have to use libnoise, voro++, ozz-animation, and some. so no cocos, because i cannot change the (now lower) c++ chain.
Cannot modify update cycle; itā€™s trapped into unreadable bindings, let alone possible performance problems.
Cannot use components; they only work up the chain(creator), not down (cocos2dx).
Clearly using cocos for such an use case is an errorā€¦ moreover, I donā€™t even know if itā€™s going to be done, just evaluatingā€¦
I will use cocos chain when i see fit. I like sdkbox idea. Iā€™m probably use it even outside of cocos, if itā€™s possible.
Iā€™m evaluating other engines because they have what i need without me having to ā€œrebuild the wheelā€ about componentization, factories, and so on. just that. saving time.
About js: because everyone is doing a thing, doesnā€™t mean is to be taken without the right consideration.
At the moment, if I take a c++ code base, I can port to emscripten. Unity and Unreal do this, if iā€™m not mistaken. Itā€™s the inverse path. Not that I like it particularly; itā€™s just saved time. As I said in many other places, doubling your code base because thereā€™s a new kid on the block itā€™s not a sound business behaviour. The same reasons who moved cocos to the choice of html-first (which I approve, considering the challenges of chinese market) applies for meā€¦
Until someone convinces me that emscripten is not a viable solution for whatever the reason, i will not port. That doesnā€™t mean i wonā€™t uses cocos; i will probably use on something new, which needs fast execution, 2d only kind of games, widespread diffusion. Facebook channel? Hope so, If we find a way to monetize/gain audience. Apple just launched its message channel, and already appears to be deadā€¦:confused: Soā€¦

1 Like

I wanted to port my game to JavaScript but thereā€™s almost no documentation for it, or itā€™s all in Chinese. The JS-Bindings scripts are very buggy and undocumented. Thereā€™s no smooth migration path other than just using the new tools (that sometimes do things in a much different way), and just rewriting the whole game.

I was just trying to test out cocos2d-jsā€¦ Do i need to install something on xcode because Iā€™m getting no intellisense and jump to definition etc.

Yes, documentation is a problem with entire cocos2dx family, both C++ and JS. But Cocos2d JS not very different from cocos2d C++ once you figure out the build process, config files and folder structure. Actual code follows exactly the same API and parameters etcā€¦

I am also not a huge fan of Creator. Both because its new for me and because it is itself new. And porting existing apps and games to creator will mean almost a rewrite from scratch. For new projects its a good option.

I would suggest using webstorm and running js version in chrome. You will get all the autocomplete and go-to-definition etc. For some of our other JS projects using Cordova/Ionic/ThreeJS etc we prefer using VisualStudioCode and TypeScript but Cocos2dJS does not provide TypeScript definitions due to which autocomplete etc does not work with VisualStudioCode. Debugging works just fine.

And the entire run/debug sequence with webstorm+chrome is 100x faster than xcode/android-studio/device/simulator etcā€¦ Just refresh the page to see all your changes. A lot more productive. Google has been trying to give the same for native android apps with Instant Run but it still doesnā€™t work and its been out since 2 years now.

Good to know.
And, moreover, istant run only works on java code. No way with ndk and c++.

They did plan to add ndk support for instant run too, of course it might happen tomorrow or not happen for 6 months.

It wonā€™t be too fast as they will still need to do the ndk-build and then copy over the new .so file(s). But it will at least skip the apk packaging step which does take a lot of time.

@walzer Actually itā€™s all that simple - ideal language for cross-platform development of 2d games itā€™s that is supported by ā€œnativeā€ IDEā€™s, so for iOS & android itā€™s Xcode & Android Studio respectively.

That why I will not use any other language for development 2d games for major platforms iOS & android. Moreover, Iā€™m developing game in Xcode by 95% and then adopt it to android in studio. Who also thinks and doing this same way?

p.s. another fun option currently maybe a SWIFT, but itā€™s not supported by android, however who knowsā€¦ itā€™s so popular and so pushed by Apple, so even google will support it soon :smiley:
p.s.2: https://news.realm.io/news/swift-on-android/

1 Like

ā€œThat why I will not use any other language for development 2d games for major platforms iOS & android. Moreover, Iā€™m developing game in Xcode by 95% and then adopt it to android in studio. Who also thinks and doing this same way?ā€
I do exactly the same, xcode + eclipse for android.
I will never choose another language then c++. Because of portability, and to extend with functionality.

4 Likes

same here c++ ftw!

1 Like

@walzer I also want to mention once again that for the open source engine written in C++ - switching(or mostly targeting) to javascript is very bad ideaā€¦ And creating closed-source editor too which again targeting to js.
Overall that means of losing developers. Also you have already practical results about closed-source editors beforeā€¦ abandoned.

But Iā€™m thinking, you just want to monetize it in future? Thats why this editor is closed-source. But you better also make closed-source cocos2d-x, with that monetization will be better. Just give a rock solid editor-engine and I will payā€¦ and not js ofc. But what you trying to do currently looks strangeā€¦ but definitely moving in a wrong direction.

3 Likes

I love JS, to me Cocos Creator is great, this seams to be the right direction.

I was using cocos2d-x, then i try cocos creator and look over samples in github. I think cocos creator is good for me, well, changed c++ to js is a lil bit strange first. but then, i just want to make a game. and performance is quite good too.

Iā€™m not a big fan of JS as a language but I love how Chukong has finally added TS support!!

Cocos Creator is pretty nice so far, and while I doubt Iā€™d ever release a game written in JS/TS, Iā€™m so much faster creating/prototyping with Cocos Creator. Once I get my current game mostly fleshed out in Cocos Creator/TS, I plan to rewrite it in C++.

Also, Iā€™m both impressed and confused at how long this particular thread has been active.

1 Like

Totally, absolutely agree with @anon98020523 .:slight_smile:

I totally agree with @anon98020523

@anon98020523 agreed

@anon98020523 agreed

Dear @walzer, as a founder of Cocos2d-x, some important things maybe you should know.

First of all, your 1st principle is great, but we should refocusing our target users:

They are experienced game developers, most of them are software engineers.

I thought we should admit some truths:

  1. The simplest game making tool is the sort of Game Maker. No scripts at all !
  2. Unity is the most widely game or multimedia developing engine, it is also very friendly to users.
  3. Unreal is the most professional game engine, most of us will agree with that.
  4. Other game engines, what ever it is open sourced or not, has editors or not, they are ā€˜Othersā€™.
  5. Cocos2d-x is the most distinctive, and the most successful one of that ā€˜Othersā€™.

If you think Cocos Creator can make the game development easier, that is absolutely wrong way.
When you sort the info from Stack Overflow or GitHub, pick the most popular language for Cocos Creator, the fact is the easiest tool of game development doesnā€™t even need to code anything at all !

Unity and Unreal are both great game engines are very friendly to developers. What is very friendly ? They accept(include auto conversion) the most industrial standards resources - images, sounds, video, etc. They have lots of editors for whole game developing process - authoring 2D/3D animations, actions, lighting, colliders, etc. They invest much resources building the tutorials, documents, and videos.

Cocos2d-x canā€™t be matched with them at all. And the biggest flaw is absolutely NOT the editors.
But why Cocos2d-x so successful ? Everything is because it opens sources.

If I just want game developing process easier and more flexible, donā€™t care it open sourced or not, I can just use Unity, it cost nothing by subscription policy, and has more features, more learning resources, more supported platforms, more latest technology, and more. Your 3 principles - easier, cheaper, more advanced ? All failed.

So, return the most import question, what is the most important factor for target users ?
In my humble opinion, keep its role, focus what it should do, welcome more industrial resources, build more tutorial and documents, should be the answers. Because main target users use it as the main engine just because itā€™s open source engine, we can tune, debug our game by ourselves, everything is native, we know what we want and what we are doing.

I relief because the new version 3.15 were released, and it fixes bugs, imports new implementations and features as usual. Dear @walzer , as a 10 years+ experienced game developer, I experienced OpenGL, Ogre, Flash, Unityā€¦ lots game developing engines, I love editors of course, I built them before. So I can realize how much important Cocos Studio or Cocos Creator to you. But if you donā€™t supposed to open its source, it will just be another dysfunction editor, it will never be matched with Unity. The core spirit of Cocos2d-x is open source, open the freedom of game developers, I hope you can realize that.

11 Likes