My 2 cents

My 2 cents
0.0 0



I am not a pro game developer and I haven’t used cocos2dx for real. I like to browse your sources occasionally though.
Since you are in the process of a refactor I thought to drop my comments:

  1. The project structure, in general, is to a certain extend ugly. It includes everything and the kitchen sink. Some examples:

/ cocos2dx / <— Android makefile among the sources. Not pretty.
/ cocos2dx / <- Makefiles in sources. Not pretty.
/ cocos2d_libs.xcodeproj <— IDE trash.
/ cocos2d / plugin / plugin-x_ios.xcworkspace <— IDE trash.
/ samples / samples.xcodeproj <— More IDE trash, I use Eclipse btw.
/rpm <— Distribution package descriptor. Not pretty.

On the other hand sample projects are mostly done right.

/ samples / Cpp / TestCpp / Classes <— Clean sources. Beautifull.
/ samples / Cpp / TestCpp / Resources <— Clean resources. Beautifull.
/ samples / Cpp / TestCpp / <— At project root, not in sources. Beautifull.

/ samples / Cpp / TestCpp / .externalToolBuilders <— Ah, at last some Eclipse trash too!
/ samples / Cpp / TestCpp / .cproject <— More Eclipse trash!
/ samples / Cpp / TestCpp / <— At project root. Not cool.

  1. Source code uniformity. Really guys, you need to use an automated source formatting tool. And you could also use rules about class layout, order and consistency.

Compare this:

With this: <— Simply great! and the whole project structure is neat too.

  1. Modularity. User projects shouldn’t have to live inside the cocos2d project structure.

In conclusion, I realize that I may be talking nonsense, since I haven’t used cocos2d professionally. Please don’t take my criticisms personally :slight_smile: I appreciate your hard efforts.