Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

own node.js modules / C++ bindings #38

Open
MKelm opened this issue Aug 1, 2013 · 4 comments
Open

own node.js modules / C++ bindings #38

MKelm opened this issue Aug 1, 2013 · 4 comments

Comments

@MKelm
Copy link
Owner

MKelm commented Aug 1, 2013

I have some topics that might need own node.js modules, because that makes it possible to use faster C++ bindings.

So in the later stages it might be needed if we have some performance concerns and have to transfer some game modules to C++ bindings.

Here is a article about addons: http://nodejs.org/docs/latest/api/addons.html#addons_addons

Here are some examples:
Example hello-world-ish programs:

Examples:

Something offtopic, my last bigger C project ;) http://repo.or.cz/w/jimb.git

@MKelm
Copy link
Owner Author

MKelm commented Aug 1, 2013

I placed the issue to final 1, but the final 1 has no requirement for performance issues, so it might be useful to add at least one milestone for performance patches for final versions.

@MKelm
Copy link
Owner Author

MKelm commented Aug 2, 2013

A binding library for complex calculation functions might be useful, but I do not know the potential of speed enhancement in detail, C++ is definitely faster, but the JS V8 engine is very fast too.

@jackery4444
Copy link
Contributor

C++ is much faster than pretty much every other language, with the only exception being assembly as far as I am aware. However this extra speed that C++ provides really isn't needed due to the lightweight nature of the game. We should never use C++ if performance is the only reason because the extra effort and added complexity to the project outweighs the practically un-noticeable speed difference.

@MKelm
Copy link
Owner Author

MKelm commented Aug 3, 2013

Yes, it is more for a worse case scenario if something occurs which needs this, but you are right the game looks lightweight, till now ...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants