Does really game development on Java suck? Why are we still here?

C++ without boost is masochism.


#include <boost/algorithm/string.hpp>
std::vector<std::string> strs;
boost::split(strs, "string to split", boost::is_any_of("\t "));

Having to use an out param is still annoying, but it does have its advantages other times. See http://stackoverflow.com/questions/236129/how-to-split-a-string-in-c for the horror show that passes for the “elegance” of doing it with pure STL.

Hahaha, sproingie, I was literally just at that link 4 hours ago. Doing it without boost.

I think I will push for boost.

I personally can’t stand boost, I’m never quite sure what it’s doing and the compile errors can be a nightmare to decipher. I’ve found Qt to be an excellent alternative, along with a complete nice cross-platform gui library it also has it’s own stl/boost equivalent. It has a super fast thread-safe shared memory construct used for strings/images etc.

In Qt:


 QString str;
 QStringList list;

 str = "Some  text\n\twith  strange whitespace.";
 list = str.split(QRegExp("\\s+"));
 // list: [ "Some", "text", "with", "strange", "whitespace." ]

Yeah Qt is awesome, it’s really a full-blown platform, not just a GUI library. As for error messages, that’s something that drove me away from C++ in general. Compiler messages I can deal with, but it’s the fact that so many errors, even simple typos, don’t get caught til link time, at which point the very much C+±unaware linker spews mangled symbols at you … blech. It was reading “Effective C++” that really made me aware of how much a minefield the language was.

This is kinda the “air the dirty laundry of major programming languages” thread now, ainnit? Let’s hop on C#'s warts now, it’s feeling neglected. :wink:

C# SUCKS LARGE BALLS AND I HATE IT SO MUCH.

Sorry, I had to get that out of my system. I’m forced to use it in Game Design class in conjunction with XNA, oh which also SUCKS MAJOR BALLS. :slight_smile:

Looking at that boost example I am pleasantly reminded just exactly why Java is so brilliant and why I intend to stick with it - in its pure, natural and unadulterated form - for as long as I possibly can.

Cas :slight_smile:

While I probably agree, could you elaborate on exactly what it is about XNA you don’t like? The API? Distribution? The tools? The data pipeline?

The API is terrible and very complicated. Drawing a quad takes much less code in OpenGL than XNA!

Also Visual Studio sucks compared to Eclipses which makes me dislike C# and XNA even more :slight_smile:

Hmm maybe it does but then maybe not many people doing serious graphics use OpenGL immediate mode any more and suddenly OpenGL takes a fair bit of fiddly setup to do something apparently trivial…

Cas :slight_smile:

The easiest thing you can do with XNA is draw textures using SpriteBatch. I have made many games with it so far, including a side scroller, chess, a remake of Notch’s Metagun, and a very complex and fully programmable text-based interactive fiction engine.

Btw, drawing geometry with it is impossible. I had to copy-paste some code to draw a quad, but could not figure out how to customize it. I had to revert to create a Graphics class that just manipulates a 1x1 image containing 1 white pixel. It has the same methods as Java2D’s Graphics2D like drawLine, drawRect, fillRect, etc… ;D

It’s not hard to use but you will still hate it :stuck_out_tongue:

I totally agree with the linker errors thing. It’s like ready gobblety gook, and a lot of the time they’re caused by weird stuff like circular includes and things. You just have to move code around to fix it. That really reminds me that by far my #1 favorite thing about Java is that the errors are always clear and standard and you get a beautiful stack trace. So many other languages flub this.

I like C# too, but not XNA. I tried to use XNA for a game jam a few years ago and that was hilariously interesting. I spent most of the time trying to get stuff to just go. Then again it really wasn’t so bad as far as I recall.

To be fair, XNA is an abstraction layer on top of a layer on top of a layer - its not designed for you to easily be able to draw something as low level as a quad, its designed for you to be able to do things which you will commonly solve with a toolkit like XNA; high level stuff. In that respect Direct3D is no better; you CAN draw low level geometry using it, but the API is really designed to push large volumes of data.

Ha, yeah I had the same problem. XNA really wants you to either use SpriteBatch (which is overly simplistic, and makes annoying assumptions about your data) or to draw full 3d models (which have to be pushed through the entire cumbersome data pipeline). Any form of dynamic geometry is a right bloody pain.

And not just more painful than immediate mode, it’s more painful than vertex array drawing. For a library allegedly aimed at easy of use it does make some odd decisions.

What with all the C# and XNA hate? I found it quite easy to work with and there’s a lot of help available for it. Also Visual Studio is really an excellent IDE and by default better than Eclipse in my experience.

Although I prefer Java, I’ve had no significant difficulties with either of them except that C# properties are annoying.

Eclipse > Visual Studio hands down. If you disagree, you haven’t used either enough.

And yeah properties suck :frowning:

@ra4king -

Have you used the Form & Report creation tools? To tell the truth, it’s been like five or six years since I used the Visual Studio IDE, but I recall there are tools for building Forms and Reports that are like the Microsoft Access tools in the VBA environment that I currently use. Just curious, as I haven’t been able to successfully install any plugins with Eclipse that have these capabilities. (Tried one that failed, about a year ago, and took down my Eclipse with it. Had to reinstall Eclipse.) I know NetBeans is supposed to have this sort of thing, for dragging and dropping objects as a way of building Forms and Reports, but I spent very little time with NetBeans, and I don’t recall it being as handy as the VBA version.

I’m guessing for the .NET world, there would be ways of building HTML pages via drag and drop, also. But as I said, I haven’t used this stuff in a long time, and the question is sincere. I could see where that sort of thing might be less helpful for game programming than for database apps or basic form or report creation.

Even if I am willing to consider the VBA environment (and presumably the Visual Studio IDE as well) handier for building database apps quickly, I still prefer Java and Eclipse overall as being less likely to make me insane and weary of being continually nickel-and-dimed by MS. Thus, I continue towards the goal of making my next contract one that is Java-based instead of Microsoft-based. (Working through the “CattleDrive” as JavaRanch–earned two of four “Moose Badges” so far, and am studying for Java 7 Associate Certification. Hope to take in June.)

Come on dude, you can’t seriously mean that. You’re screaming “My opinion is fact!” here, I can’t believe that you seriously go there.

I’ve used both, extensively. There is no better IDE environment than Visual Studio, not even close. In my opinion.

That’s interesting. I’ve used Visual Studio since the mid 1990’s and I think that Netbeans and Eclipse are both better development environments. Obbviously YMMV

Where you stand on VS seems to vary hugely depending on what you’re doing. VS is great if you work (and think) exactly how MS want you to, using their entire technology stack all the way down. If you don’t want to do that, then most of the more advanced VS features are just useless fluff clogging up the UI. I’ve never wanted to use the server explorer, or the data sources, or the device security manager, etc. etc.

As a vanilla C++ IDE, it’s merely ‘meh’. It’s code navigation is poor, it’s intellisense is slow and often incorrect, it’s syntax highlighting is often flat out wrong. It’s debugger is pretty good at least though.

For Java dev stuff I certainly agree :slight_smile:

This line of discussion is a bit pointless really, I mean humans have evolved to the point where you can have COD VS Battlefield “camps”… emotional attachments to something as silly as a game :confused: The same for programming languages and also development tools.

Perhaps my preference for Visual Studio comes from the fact that it was the first thing I was exposed to when I moved from Dos programming to Windows programming, who knows. But my general experience is that when I use Visual Studio, everything is where it should be. When I use Eclipse, Basic tools I use a lot are hidden away where I don’t expect them to be. Don’t get me wrong, I think Eclipse 3.7 (and specifically that version) is a fine product. But it still has some ways to go GUI-wise.