Author Topic: Java RL tutorial!  (Read 15959 times)

XLambda

  • Rogueliker
  • ***
  • Posts: 208
  • Karma: +0/-0
    • MSN Messenger - tau_iota@live.de
    • View Profile
    • The Weird Rogue
Re: Java RL tutorial!
« Reply #15 on: March 12, 2012, 09:21:16 PM »
Could you stop the hating, please? ::) I know that you C++ folks think your language is better, and I'd be happy to argue with you as I speak both. But this is a tutorial, and a newb is not interested in whether Java is better or C++. And he sure as hell won't care about low-level programming. For tutorial purposes, Java has a few big advantages over C++, it's portable (one toolchain and one exec for all platforms), it has a huge class library and it abstracts from some of the more mind-boggling aspects of C++ (Pointers? Really, Stroustrup?).

Also, the only other tutorial at roguebasin is in Python, and I know what you C++ folks think of THAT language... ;D

This discussion makes me wonder if a better tutorial might be one that is entirely pseudocode based.  Give someone the gist of what type of problems/solutions exist for roguelike programming, and show off the basics.  Maybe provide an implementation in a few languages at the end of each section so that the viewer can decide for themselves which language looks best for them.  Of course, your tutorial is exactly what it is supposed to be: a "Java" rl tutorial.  So I think the debate over which language is better is kind of irrelevant to this thread.  Although, in terms of "newb" friendliness I would have picked a language that already has everything you need, rather than something that requires importing libraries, not that there's anything wrong with that in the global sense.

And which language would that be? ??? Using libraries for displaying stuff and handling keys has been done ever since Rogue, I'm not aware of a language that doesn't need something like it. If you know one, please do tell me more.

kraflab

  • Rogueliker
  • ***
  • Posts: 454
  • Karma: +0/-0
    • View Profile
    • kraflab.com
Re: Java RL tutorial!
« Reply #16 on: March 12, 2012, 11:00:10 PM »
Could you stop the hating, please? ::) I know that you C++ folks think your language is better, and I'd be happy to argue with you as I speak both. But this is a tutorial, and a newb is not interested in whether Java is better or C++. And he sure as hell won't care about low-level programming. For tutorial purposes, Java has a few big advantages over C++, it's portable (one toolchain and one exec for all platforms), it has a huge class library and it abstracts from some of the more mind-boggling aspects of C++ (Pointers? Really, Stroustrup?).

Also, the only other tutorial at roguebasin is in Python, and I know what you C++ folks think of THAT language... ;D

This discussion makes me wonder if a better tutorial might be one that is entirely pseudocode based.  Give someone the gist of what type of problems/solutions exist for roguelike programming, and show off the basics.  Maybe provide an implementation in a few languages at the end of each section so that the viewer can decide for themselves which language looks best for them.  Of course, your tutorial is exactly what it is supposed to be: a "Java" rl tutorial.  So I think the debate over which language is better is kind of irrelevant to this thread.  Although, in terms of "newb" friendliness I would have picked a language that already has everything you need, rather than something that requires importing libraries, not that there's anything wrong with that in the global sense.

And which language would that be? ??? Using libraries for displaying stuff and handling keys has been done ever since Rogue, I'm not aware of a language that doesn't need something like it. If you know one, please do tell me more.

I use Blitzmax.  It's a really professional grade language, in terms of functionality, but it is tailored directly at making games (which is not to say that anything is over-simplified: you can still do things like function pointers, inheritance/polymorphism, pass by reference, etc).  It is cross-platform compilable from the same source code, with a bunch of graphics commands built in (i.e. you can call "drawimage image" without needing headers etc).  Of course, people still make external libraries for it, but I've never really had a need to use them.  Actually, you can even import code from other languages, such as C++.  The main downside is that it is not free, although you can use all functionality except creating an executable from the demo - so it's fine for the sake of a tutorial.  I've programmed everything from video games to monte carlo simulations in it, and I can't think of any specific functionality it does not have that other languages do.  People say that it is less efficient than c++ in general, but I've never really had any problems myself.

It's kind of like taking python's simplicity and development speed, but slapped onto a c++ style system and without the need to have python installed ;)

edit: I just remembered the one thing I wish it had: operator overloading.  But that's not really a deal breaker for me  :P
« Last Edit: March 12, 2012, 11:02:34 PM by kraflab »