Sign in to follow this  
iBeMonkayy

What language does what?

Recommended Posts

iBeMonkayy    127
Hello,
I am very new to game programming and am still deciding what language to chose. I was wondering if someone could tell me the basic languages and what they are used for/best suited to. All I know is that Minecraft uses Java and Perl is for advanced webpages.
Thanks, Owen

Share this post


Link to post
Share on other sites
For someone who is just starting out, I would suggest a modern, high-level language, with a sizable community, and a wealth of resources.

More specifically, I would suggest Python, and my video tutorial series: http://www.youtube.com/playlist?list=PLDFB7FFF90EE6F0C1

That said: You really don't need to worry about "picking the right language" - As long as you start somewhere, you'll learn the basics of programming no matter what language you start with, and that should be your initial goal.

Share this post


Link to post
Share on other sites
ultramailman    1720
This is what I think:

C: general purpose language, has some nice libraries for game developement, like SDL and Allegro
C++: seems to be very popular for game development, provides OOP features to allow easier OOP than in C, and other features that C doesn't have
Objective-C: a superset of C, also provides OOP features, I've never used it though
C#: never used it

Java: has OOP features, and runs on any machine that can run a Java virtual machine. I usually see it used for non game programs, but thats just me. It has a built in library called swing that allows you to make GUI for your programs.

python: interpreted language, a lot less typing compared to C or Java. There is a SDL wrapper called pygame. Great for actually writing a game, instead of braces and semicolons.

This is what I think I know, might be wrong though. I suggest python + pygame as a starting point.

Share this post


Link to post
Share on other sites
pharaoh357    132
Hello there friend I'd would recomen Lua ([url="http://lua.org"]http://lua.org[/url]) which is a very simple and clean Language and Love ([url="http://love2d.org"]http://love2d.org[/url]) which is a framework writen by Rudy, It is very easy to learn, with Love and Lua you will be writing games in no time.

Share this post


Link to post
Share on other sites
iBeMonkayy    127
Python seems like a god one but it seems that it is more web development rather than games. My ultimate goal with programming is to create a game like Civilisation (a simpler version and a game like Minecraft. Java sound good? One of my friends knows Java so that is a bonus for it as I can get help from him.

Share this post


Link to post
Share on other sites
jbadams    25676
[quote name='Monkayy' timestamp='1350813559' post='4992398']
Python seems like a god one but it seems that it is more web development rather than games.
[/quote]
Python is just fine for games. You have access to many libraries such as [url="http://www.pygame.org/"]PyGame[/url], [url="http://www.panda3d.org/"]Panda3d[/url], and [url="http://www.pyglet.org/"]Pyglet[/url] as well as bindings to libraries originally written in many other languages such as [url="http://pysfml2-cython.readthedocs.org/en/latest/"]PySFML[/url], [url="http://www.ogre3d.org/tikiwiki/PyOgre"]PyOgre[/url] and many others. You can also use the [url="http://ironpython.net/"]IronPython[/url] implementation to access any .NET libraries or bindings.

Examples of games using Python include [url="http://www.eveonline.com/"]EVE Online[/url], [url="http://toontown.go.com/"]Toontown Online[/url], and [url="http://piratesonline.go.com/"]Pirates of the Caribbean Online[/url]. It can also be used as a scripting language, as was the case in [url="http://www.civ4.com/"]Civilization IV[/url].

Python would be more than capable of creating a game similar to Civilization or Minecraft.


That being said, if you really prefer Java it's also a perfectly viable option that's quite capable of your goals.

Share this post


Link to post
Share on other sites
iBeMonkayy    127
I think I will end up going with Java and maybe learn Python at a later point. One last question, would it be possible to make a game like Civ in Java? (That is worded wrong, I know I could but I suppose my question is, is it relitivly easy?)

Share this post


Link to post
Share on other sites
kunos    2254
[quote name='Monkayy' timestamp='1350815341' post='4992400']
I think I will end up going with Java
[/quote]

funny how you choose the only language that nobody suggested [img]http://public.gamedev.net//public/style_emoticons/default/tongue.png[/img]
Why post a question in the first place if you've already made up your mind about it?

To answer your question, ya, you can do a game like Civ in pretty much every language on the planet, and that, by definition, includes Java.
The biggest bottleneck is always the programmer, not the language. Edited by kunos

Share this post


Link to post
Share on other sites
iBeMonkayy    127
[quote name='kunos' timestamp='1350815798' post='4992401']
[quote name='Monkayy' timestamp='1350815341' post='4992400']
I think I will end up going with Java
[/quote]

funny how you choose the only language that nobody suggested [img]http://public.gamedev.net//public/style_emoticons/default/tongue.png[/img]
Why post a question in the first place if you've already made up your mind about it?

To answer your question, ya, you can do a game like Civ in pretty much every language on the planet, and that, by definition, includes Java.
The biggest bottleneck is always the programmer, not the language.
[/quote]
I had not made up my mind on Java but I knew in my head that at some point I would want to do it. I left it out of my original question to try and get un-biased knowledge of all of the languages to see if I changed my mind. But good spot anyway :P

Share this post


Link to post
Share on other sites
Anri    971
Ten years ago, I would have said plain C, but only to learn the basics of programming. Its a great stepping stone to C++ and Java; first learn procedural programming and then move on to OOP(object-orientated programming).

Today...I would recommend Java. Reason being its very popular in many fields other than gaming and has great educational support.

If anyone is thinking of learning Java, and looking at a University to learn it from scratch then I would recommend the Open University's M250 module. I took its predecessor M255 and it begins with an example with croaking frogs - of all things - to illustrate OOP, and it was a pretty good way to explain it even to a complete beginner. Just a recommendation, of course.

Share this post


Link to post
Share on other sites
RLS0812    3043
To learn how to program a game, I would recommend a high level program. Python, C#, Visual Basic, Lua ... to name a few.
Once you are familiar with game design, and can write decent games, I would recommend switching to a lower end language for better performance, and portability. The most populate one would be C++ .

It is all up to you, and what you feel comfortable programming with. Just be aware that some folks who posted in this topic may be misinformed as to what certain languages are capable of. Always do your research to see what a language is actually capable of doing ....
[quote]
Python is just fine for games. You have access to many libraries such as ... [url="http://www.panda3d.org/"]Panda3d[/url], and ...[/quote]
Panda 3D is not a Python library. It's a game engine written in C, which utilizes scripts written with it's own version of Python 2.6 [url="http://www.panda3d.org/manual/index.php/Main_Page"]HERE[/url] is the manual.
[quote]
Examples of games using Python include [url="http://www.eveonline.com/"]EVE Online[/url], [url="http://toontown.go.com/"]Toontown Online[/url], and [url="http://piratesonline.go.com/"]Pirates of the Caribbean Online[/url]. It can also be used as a scripting language, as was the case in [url="http://www.civ4.com/"]Civilization IV[/url].[/quote]
All of those games use an engine written in C, that utilize scripts written in Python. None of them are Python based .
[quote]
Python would be more than capable of creating a game similar to Civilization or Minecraft.[/quote]
It has been shown that Python has a difficult time rendering voxel worlds ( Minecraft ). It can be done, however you will suffer incredible frame rate problems. Edited by Shippou

Share this post


Link to post
Share on other sites
Eelco    301
Seems you have already made up your mind, but anyway:
[list]
[*]The Java community and its libraries are centered around enterprisy stuff. Id say the java gamedev community is small. That sort of thing matters a lot. (then again, I believe python does not have a very large gamedev community either)
[*]Java is probably one of the least expressive languages around. In terms of learning a wide variety of well thought out language concepts, I wouldnt touch it with a ten foot pole. If you use windows yourself (and dont bother worrying about your users just yet), id urge you to give C# a look; which is basically java done right. In general, id say .NET is a great learning platform.
[/list]

Share this post


Link to post
Share on other sites
Eelco    301
[quote name='Shippou' timestamp='1350841055' post='4992493']
[quote]
Python would be more than capable of creating a game similar to Civilization or Minecraft.[/quote]
It has been shown that Python has a difficult time rendering voxel worlds ( Minecraft ). It can be done, however you will suffer incredible frame rate problems.
[/quote]
One of pythons great strengths is interoperability with C and its libraries. You write it in python, and if it isnt fast enough, and you have the skill to take it to a lower level, that option is always wide open to you.

As opposed to, say, java, which makes this a royal pain in the ass.

Share this post


Link to post
Share on other sites
Bacterius    13165
[quote name='Shippou' timestamp='1350841055' post='4992493']
It has been shown that Python has a difficult time rendering voxel worlds ( Minecraft ). It can be done, however you will suffer incredible frame rate problems.
[/quote]
[citation needed]

Python can do well, although obviously you can't use "pythonic" lists and dictionaries to store your voxels, because that's just not going to work. But using C arrays instead, there is no reason at all Python cannot manage voxels.

Share this post


Link to post
Share on other sites
RLS0812    3043
[quote name='Bacterius' timestamp='1350845101' post='4992514']
[citation needed]
Python can do well, although obviously you can't use "pythonic" lists and dictionaries to store your voxels, because that's just not going to work. But using C arrays instead, there is no reason at all Python cannot manage voxels.
[/quote]
It can handle voxels, however it is SLOW when it comes to handling them. A good practical example would be [url="https://github.com/mcedit/mcedit"]MC-Edit[/url] which is a Minecraft world editing tool written in Python. It works, however on my duel core 2.6Ghz computer, it takes forever for it to render surface areas.
I do agree that using C / C++ arrays are a much more efferent way to go.

Share this post


Link to post
Share on other sites
rip-off    10976
@OP I think Java is a decent choice as a first language, but has suffered (at least in the past) from a rather weak community support for writing games. Maybe my information is out of date, due to the popularity of a flagship produce like Minecraft might speak of a more active community I am unaware of.

[quote]
It has been shown that Python has a difficult time rendering voxel worlds ( Minecraft ). It can be done, however you will suffer incredible frame rate problems.

...

It can handle voxels, however it is SLOW when it comes to handling them. A good practical example would be MC-Edit which is a Minecraft world editing tool written in Python. It works, however on my duel core 2.6Ghz computer, it takes forever for it to render surface areas.
[/quote]
Careful now. That a given program doesn't handle something well is not something one can draw conclusions about the technologies involved from. There is also the skill and determination of the programmers to be taken into account. For example, maybe they aren't particularly good at or interested in optimisation, or perhaps optimisation is less of a priority than building the map editing features.

Likewise, that Minecraft manages to have a decent voxel renderer doesn't say much about Java. I don't know the details, but perhaps the Minecraft team are adept at getting the graphics hardware to do a lot of the sweating.

I could write a terrible Voxel renderer in assembly, does it prove anything?

Share this post


Link to post
Share on other sites
TheDespite    104
I would not suggest starting with Java. This is mostly because of the lack of community.

I suggest you start playing around with XNA (C#). I know (and you should as well) that XNA is not so good option for actual game development anymore(if it was in the first place), but is still a great platform to learn with! This is because the game loop(s) and content management are already handled for you so you can just drop in a couple of sprites and start moving them on the screen.

Share this post


Link to post
Share on other sites
jbadams    25676
[quote name='Shippou' timestamp='1350841055' post='4992493']
[quote]
Python is just fine for games. You have access to many libraries such as ... [url="http://www.panda3d.org/"]Panda3d[/url], and ...[/quote]
Panda 3D is not a Python library. It's a game engine written in C, which utilizes scripts written with it's own version of Python 2.6 [url="http://www.panda3d.org/manual/index.php/Main_Page"]HERE[/url] is the manual.[/quote]
I believe it's mostly C++ actually, and I was perfectly aware of that when I posted it. It's intended to be used by Python [i]or[/i] C++ programmers however, and made my list because you can develop a game using by [i]writing only Python code[/i] and no C or C++. The fact that the underlying engine isn't also Python isn't particularly relevant to a would-be Python programmer who is considering using the engine, except perhaps for the comfort that there is some lower-level optimization already done for them.

[quote][quote]
Examples of games using Python include [url="http://www.eveonline.com/"]EVE Online[/url], [url="http://toontown.go.com/"]Toontown Online[/url], and [url="http://piratesonline.go.com/"]Pirates of the Caribbean Online[/url]. It can also be used as a scripting language, as was the case in [url="http://www.civ4.com/"]Civilization IV[/url].[/quote]
All of those games use an engine written in C, that utilize scripts written in Python. None of them are Python based .[/quote]
I didn't say they were written exclusively in Python, I said they used Python, and further up in the topic said it was "used extensively" in them. EVE Online also uses a variation of the language known as Stackless Python. It's one of the great strengths of Python that it's relatively easy to extend the language with lower-level code if performance is becoming a problem, and personally I think the fact that these great games have done so is a point in favour of the language rather than some black mark against it.


Given the OPs decision to use Java we're getting off topic though...



Java is just fine for games. As mentioned, the major drawback is probably that there are less people doing so, and a bit less in the way of documentation and tutorials available, but I don't think this is a show-stopping problem that should turn you off from the language -- particularly if you want to work with or get help from your friend who already knows the language.

Share this post


Link to post
Share on other sites
Hey there, Monkayy, I had the same problem as you when I started looking for a programming language to learn a few months ago. I started with C++ and that seemed to get me along just fine. I spent like thirty dollars on a beginners guide for dummies to c++ and it displayed all of the basics with variables, functions, and some OOP (Object Oriented Programming) that got me started with my current major. I'm studying for a Bachelors (Possibly Masters or Doctorate), depending on my career path in the future, and have taken up classes in basic C. Learning C++ was a great choice since they're the same language, just more advanced features in c++, and am doing fine as is. I would definitely suggest learning something that's most comfortable for you with the syntax. I'd add more but I gotta go to work! I'll add more when I get back home if this post still has a pulse.

- Jarret

Share this post


Link to post
Share on other sites
runnerjm87    177
Java is a great language to begin learning the core concepts of OOP, given that the JVM handles a lot of the low-level processes that tend to cause headaches. I would suggest that if you're going to get into game development that you learn C++ simply because it gives you a higher level of access to the memory that your program is using which will give you more flexibility when it comes to fine-tuning performance.

The Unreal Engine, for example, is written in C++, gives you the ability to write and utilize your own C headers (with the licensed version, not UDK) and its native UnrealScript language uses many of the conventions common to Java.

Share this post


Link to post
Share on other sites
teccubus    307
If I were you, I would not bother with languages like Python, Ruby, Java, C#, because programs written in them are slow as hell.
Instead, I would recommend C, C++, Ada or - which I think is the best option - D.

Share this post


Link to post
Share on other sites
kunos    2254
[quote name='teccubus' timestamp='1350925445' post='4992816']
If I were you, I would not bother with languages like Python, Ruby, Java, C#, because programs written in them are slow as hell.
[/quote]

i cant' say much about Phyton, Ruby and Java.. but if your C# programs are "slow as hell" (or even slow), you are doing it wrong.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this