Next language for game development?
(Mods: not sure this is the right forum for this, but it doesn't seem to fit any better anywhere else...)
At this point in time, I feel that I am extremely fluent in both C++ and Python, fluent in plain-old-C, Java and PHP, and have a passing familiarity with Scheme and D.
Lately I have been doing most of my development in Python, but the performance is a definite bottleneck, so I am forced to implement a fair amount of the functionality in C++ (via ctypes and/or boost::python), which kills many of the advantages of using Python in the first place.
That has caused me to fallback to my default of C++, but truth be told, I am tired of using C++ on a daily basis, and want to move on to something a little higher-level, and more productive. While I am at it, I would like to find something that makes a number of my requirements a little easier, and it wouldn't hurt to learn/tackle some new programming concepts at the same time.
I am looking to develop both clients and servers in the same language, and at the moment the target is fast-paced, multiplayer (not MMO), 3D games.
Absolute requirements: high-level (i.e. functional aspects, introspection, etc.), cross-platform (Windows, Mac and Linux), access to OpenGL/DirectX, close-to-native performance.
Bonus points: existing libraries for various game-development-related tasks (networking, physics/math, GUI), strong concurrency support.
I not particularly worried about the marketability/popularity of the chosen language - I have solid C++, Python and Java skills to fall back on when it comes time to job hunt, and I don't have immediate plans to collaborate with other programmers on my own projects.
There are a few languages that have caught my attention/interest lately:
• C# - Large game development community, plenty of gamedev tools/libraries, solid track record, high-level. On the flip-side, somewhat dodgy cross-platform support (particularly Mac/OpenGL), not that many new concepts after C++ and Java.
• Scala - Excellent concurrency and networking support, huge amount of software available on the JVM, excellent cross-platform support, new concepts. Unfortunately, language is relatively new and still developing rapidly, java support for OpenGL not as solid as I would like, no game development community.
• D - Already somewhat familiar, strong concurrency, access to C libraries. Cons: language in flux, perennially a 'dead end' language, limited amount of software to date, very little game development, few new concepts, still suffering from a forked standard library.
• And lastly (though completely out there in left field), Google go - Excellent concurrency, access to C libraries, looks like a python/C crossover, many new concepts. Cons: brand new, no support for Windows yet, no software, no game development community, not quiet 'high-level' in the way I was thinking about.
I am *not* looking to start a language war here, rather I would like to gain insight from anyone who may have used/attempted to use one of these languages in a game development setting, about benefits/pitfalls they have encountered. I welcome any general (as long as insightful/thoughtful) comments you may have on the use of these languages for game development, and I am also open to adding other languages to the list, if you know of an interesting choice that I have failed to consider.
And (just in case [smile]) to forestall the cries of 'just use engine X' (where X is one of Unity3D, UDK, Ogre, etc.), I am not considering an existing engine because: a) I am not planning to go to market in the near future, and b) I am working on areas these are not explicitly designed to handle (universe scale rendering, voxel terrain, etc.).
I think your critiques of your options are pretty accurate.
If you've not looked at C# after 2.0, there's some things (extension methods, co/contra variance generics, proper closures to name a few) that are "new" compared to the C++/Java world. And functional style programming has gotten a boost recently even if functions are still second class citizens. But if cross-platform is a dead-on show-stopper, that might be a problem. I've not looked at mono recently, so you'll probably need to do that evaluation yourself. That said, C# is still the language that I find provides me the least impediments to getting stuff done.
From what I've seen of Scala, it's not developing that rapidly, and should have fairly stable IDE support. I like a number of its features, but not necessarily how they're implemented syntactically (ymmv). I'm also skeptical that you'll get close to native performance due to the smallish Java open source gamedev community. If cross platform is a showstopper, I'd consider this strongly.
Though I might also throw Python into the mix (again). If performance is your only concern, some research into some of the alternative compilers might help. Perhaps even doing some development on high performance libs to replace poor performers?
If you've not looked at C# after 2.0, there's some things (extension methods, co/contra variance generics, proper closures to name a few) that are "new" compared to the C++/Java world. And functional style programming has gotten a boost recently even if functions are still second class citizens. But if cross-platform is a dead-on show-stopper, that might be a problem. I've not looked at mono recently, so you'll probably need to do that evaluation yourself. That said, C# is still the language that I find provides me the least impediments to getting stuff done.
From what I've seen of Scala, it's not developing that rapidly, and should have fairly stable IDE support. I like a number of its features, but not necessarily how they're implemented syntactically (ymmv). I'm also skeptical that you'll get close to native performance due to the smallish Java open source gamedev community. If cross platform is a showstopper, I'd consider this strongly.
Though I might also throw Python into the mix (again). If performance is your only concern, some research into some of the alternative compilers might help. Perhaps even doing some development on high performance libs to replace poor performers?
Quote:Original post by TelastynMono itself seems to work pretty fantastically, but libraries are another matter. After 8 hours I had a sort-of-working openTK, and no luck at all with Tao.* on my Mac. Cross-platform GUI toolkits (particularly with OpenGL embedding) also seemed to be an issue.
But if cross-platform is a dead-on show-stopper, that might be a problem. I've not looked at mono recently, so you'll probably need to do that evaluation yourself.
Quote:I'm also skeptical that you'll get close to native performance due to the smallish Java open source gamedev community.More on this under python, but basically it isn't the game-development specific portions that are slowing me down, and raw Scala performance seems solidly above Python.
Quote:If cross platform is a showstopper, I'd consider this strongly.Yes, and this is the reason that Scala is currently near the top of my list. I don't particularly like the syntax of scala, but the JVM still sports the best portability around, and with the recent Java2D/JoGL/Swing integration, the best GUI options as well.
Quote:Though I might also throw Python into the mix (again). If performance is your only concern, some research into some of the alternative compilers might help.This might help, and I haven't really looked into them. As I understand it, the primary contenders are the (very beta, last I looked) compiler from google, or the (ever unfinished) compiler based on LLVM?
Quote:Perhaps even doing some development on high performance libs to replace poor performers?Would that this were the problem - unfortunately, it is my experience that it isn't the libs that cause the performance issues. My rendering code is GPU-bound anyway, and all the other computationally-heavy stuff has already been bridged to C++.
Now I have things like list traversal and dictionary lookups showing up at the top of my profiler output, which is a royal pain. For instance, my scene-graph traversal (without the math and rendering, which is implemented in C++), and my entity update loop (i.e. message dispatch) are both at the top of my profiler output. I have had to employ a number of completely stupid tricks (like replacing my component/entity classes with ctypes structs) to get around basic language overhead, and it is starting to make python feel as painful as the C++.
Quote:Original post by swiftcoder
• And lastly (though completely out there in left field), Google go - Excellent concurrency, access to C libraries, looks like a python/C crossover, many new concepts. Cons: brand new, no support for Windows yet, no software, no game development community, not quiet 'high-level' in the way I was thinking about.
I would very much hesitate to say google go has many new concepts (welcome to 1968?). Two new at best.
Anyways I thought OpenTk was good. maybe just linux. That leaves the JVM having enough tool support to be worth its cost. Whose only two usable modern languages with good concurrency support are Scala and Clojure. Since static typing seems to be implicit in your requirements, That leaves just scala. you could try ocaml i guess, although comparatively it is lacking in tooling but has multiplatform gl support.
Quote:Original post by DaeraxFair enough, but some of them are definitely new to me (the lightweight-fiber concurrency model, for instance).
I would very much hesitate to say google go has many new concepts (welcome to 1968?). Two new at best.
Quote:Since static typing seems to be implicit in your requirements, That leaves just scala.Static typing is not a requirement (especially coming from a python background), however, I have played around enough with Scheme/LISP to doubt my productivity with Clojure.
I agree with all of your assessments and general inclinations. I don't really do any python development (can't stand the syntax) so I don't have enough experience to recommend compilers beyond knowing there's a (relative) bunch. And that they tend to be more varied than other languages with fairly different performance characteristics. IIRC Eve has an odd python setup that allows for good performance and scalability.
Perhaps some prototyping in scala to see how well it suits your needs then?
Perhaps some prototyping in scala to see how well it suits your needs then?
Quote:Original post by TelastynYes, this is the way I am leaning. The toolset is certainly a dream - excellent NetBeans integration.
Perhaps some prototyping in scala to see how well it suits your needs then?
I don't know about the *next* game development language, but I think that certain aspects of games will soon be written in purely functional languages. A lot of research is currently being put into automatic parallelization of functional languages, particularly Haskell. Furthermore, Haskell has a fiercely loyal community and is being funded by Microsoft, who has lots of money to throw at things. It's a difficult language, but I feel it has potential to be very useful in the right hands in the years to come.
Quote:Original post by swiftcoder
• Scala - Excellent concurrency and networking support, huge amount of software available on the JVM, excellent cross-platform support, new concepts. Unfortunately, language is relatively new and still developing rapidly, java support for OpenGL not as solid as I would like, no game development community.
Can't Scala seamlessly call regular Java classes? In which case what's wrong with LWJGL?
Quote:Original post by DaeraxOCaml comes up on a regular basis, and it probably should be on my list. I don't know that much about it, but the opengl support looks solid, and the performance looks solid. On the flip side, the syntax quite frankly scares me, and the game development resources are not huge.
you could try ocaml i guess, although comparatively it is lacking in tooling but has multiplatform gl support.
Quote:Original post by cache_hitI appreciate this sentiment, but I have my doubts. Pure-functional languages have been the 'next big thing' since god knows when, and they just keep missing the mark by a little. They are great for writing parsers/compilers, transactional servers, etc. but game development I am not sure on.
A lot of research is currently being put into automatic parallelization of functional languages, particularly Haskell.
Quote:Original post by OrangyTangGood question, and I had pretty much tossed out LWJGL after the last time I looked at gamedev in Java. At the time it felt like a dead-end option compared to 'official' opengl support, and with the recent JoGL/Java2D/SWT/JavaFX integration, that opinion is only reinforced.
Can't Scala seamlessly call regular Java classes? In which case what's wrong with LWJGL?
Quote:Original post by TelastynStackless Python, ja. As I understand it, basically Python with lightweight fibers, and some related libraries. However, most of the client seems to be written in C++ - quite possibly for the same reasons I cited.
IIRC Eve has an odd python setup that allows for good performance and scalability.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement