Putting the 'role' back in role-playing games since 2002.
Donate to Codex
Good Old Games
  • Welcome to rpgcodex.net, a site dedicated to discussing computer based role-playing games in a free and open fashion. We're less strict than other forums, but please refer to the rules.

    "This message is awaiting moderator approval": All new users must pass through our moderation queue before they will be able to post normally. Until your account has "passed" your posts will only be visible to yourself (and moderators) until they are approved. Give us a week to get around to approving / deleting / ignoring your mundane opinion on crap before hassling us about it. Once you have passed the moderation period (think of it as a test), you will be able to post normally, just like all the other retards.

Which programming language did you choose and why?

Destroid

Arcane
Joined
May 9, 2007
Messages
16,628
Location
Australia
Just a general question to the people here programming original projects. If you are using an existing engine but the programming language was a major part of your decision to use that engine, it's worth mentioning that too.
 
Self-Ejected

Ulminati

Kamelåså!
Patron
Joined
Jun 18, 2010
Messages
20,317
Location
DiNMRK
I don't do games development but I am a programmer by trade. I find myself using a mish-mash of various languages depending on the project in question. I usually have to work with existing architectures, so an average month in my life usually sees me dabbling in C, C++, Java, Perl, Python and PHP.

If I were to do a project from scratch, it'd depend very much on what SDK I went for for the GUI elements. In a 2D game I'd probably end up using C++ with Qt. If it was 3D, I'd go with whatever language was natively supported by whatever engine I rolled with. I don't see myself ever coding a 3D engine from scratch.
 

crojipjip

Developer
Übermensch
Joined
Jan 11, 2012
Messages
4,253
C++. Games and game hacking. i was especially big on mmo exploits being utilized in software
 

DakaSha

Arcane
Joined
Dec 4, 2010
Messages
4,792
C#/XNA, Unity3D (Uses C#/Mono), HaXe (For Flash and AIR)

Also is prosper answering a post normally or am I dreaming
 

20 Eyes

Liturgist
Joined
Nov 23, 2010
Messages
1,395
C# with XNA. It's free, powerful, and (from what I've been told) easier to learn than C++. The last point was what made me chose it, as I have zero background in programming.
 

crojipjip

Developer
Übermensch
Joined
Jan 11, 2012
Messages
4,253
There are four rivers. Each river is a flood of hexagons. Inside each hexagon is a web. Just like our INTERNET a web is the connection of many computers. The web is changing all the time. The connection between one computer and another depends on the logical context. What I mean by this is a web becomes a collection of circuits. The goal of the many is the object for our design. People will be dropped and added depending on a particular need. When our sequences are finished for a program, a new goal is created. There is no longer a job crisis or inequality.
 

crojipjip

Developer
Übermensch
Joined
Jan 11, 2012
Messages
4,253
because our web is built on software, we can change our circuit boards . synthesize all the advantages , even of those hardwares you don't fancy, and you can always be with sameness.
 

J1M

Arcane
Joined
May 14, 2008
Messages
14,616
C# with XNA.

Reasons:
I care about PC, not phones or consoles.
XNA makes so many things easier, like content pipeline, spritefonts, etc.
C# is easy like Java, but more useful and made by smarter people.

The only thing I think Java does better than C# is enums. C++ can certainly do the job, but I find it leads to lower productivity.

If you are just looking to play around with modding, I suggest the Unreal engine. UnrealScript is quite powerful and if you mod an existing game instead of pulling down the UDK you have access to a lot of existing art and a large codebase to learn from.
 

TheDeveloperDude

MagicScreen Games
Developer
Joined
Jan 9, 2012
Messages
389
Java and LWJGL for game programming. By LWJGL I can use OpenGL/OpenAL.
Earlier I was using C++/DirectX and C# but in recent years I have had a Java programmer job and one language is enough for me.
 

Destroid

Arcane
Joined
May 9, 2007
Messages
16,628
Location
Australia
Honestly I'm a little shocked at the overwhelming use of C# and XNA. No-one cares about cross platform?
 

DakaSha

Arcane
Joined
Dec 4, 2010
Messages
4,792
Well that's why i stoppped using it.
Having said that there is Mono and Monogame (Which unity3d uses btw)
 
Joined
Jan 9, 2011
Messages
2,727
Codex 2012 Codex 2013 Codex 2014 PC RPG Website of the Year, 2015 Codex 2016 - The Age of Grimoire Make the Codex Great Again! Grab the Codex by the pussy Insert Title Here RPG Wokedex Strap Yourselves In Codex Year of the Donut Codex+ Now Streaming! Serpent in the Staglands Dead State Divinity: Original Sin Project: Eternity Torment: Tides of Numenera Wasteland 2 Codex USB, 2014 Shadorwun: Hong Kong Divinity: Original Sin 2 BattleTech Bubbles In Memoria A Beautifully Desolate Campaign Pillars of Eternity 2: Deadfire Pathfinder: Kingmaker Steve gets a Kidney but I don't even get a tag. My team has the sexiest and deadliest waifus you can recruit. Pathfinder: Wrath I'm very into cock and ball torture I helped put crap in Monomyth
I'm not developing any games but I write C++ for a living. While it is not as "productive" as more dynamic languages, I find that proper use of type system (hard, but not impossible, to do) saves you many headaches with stupid bugs. A good IDE (Visual Studio, Eclipse, Qt Creator) helps a lot.
Thinking about your architecture, class dependencies, etc., before you start coding also helps. And for fuck sake, don't stick blindly to "patterns", "recepies", "frameworks" or the like - good stuff is what works for you and your team, so use your head.

Bad thing about C and C++ is that there is no standard build system for projects in them. You have the old make+friends, cmake, qmake, scons and others. They all suck.

Another difficult point about C++ (but not C) is debugging. Visual Studio has an excellent debugger, but it's not free. If you are stuck on GCC be prepared to learn some really arcane stuff about how C++ types are represented. No idea about clang/LLVM beyond the fact that it has much, much better compile-time error messages, especially when templates are involved, than GCC and VS.

One thing you should keep in mind is that limiting your project just to one language may be counterproductive. I personally like to use python for rapid prototyping. Python can easily interface with C++ code, so you can work on performance-critical parts in C++ and just slap them together with python glue.

Python does suck for large projects IMO - no IDE with something like IntelliSense (Aptana Studio is OK for general work though), not knowing the exact type of the object can lead to some strange bugs (although it might be just me coming from years of C++). Of course EVE online is written mostly in Python (Stackless to be precise), so it probably doesn't suck as much as it seems initially.

For in-game scripting I would go with either javascript (with SpiderMonkey or V8) or Lua.

Now, engines I've tried:
  • Unity3D - it has very nice editor, you can write scripts for it in something like javascript or C# like. C# is easier for me to get into. This engine also has a very big community and assets library, most of it require you fork over some cash. It has one giant flaw though, so big that I can't actually work with it - source control. You can't reasonably version an Unity project with its assets and code in git, SVN, or whatever you use (tar.gz snapshots will work, if you are a sick and perverted individual living in stone age). So to have a decent source control you actually have to fork over for Pro licence ($1k) so that you can connect to their asset server, which is free but useless without pro licence. Of course you can find a copy of it that fell of the truck, or maybe Siara will give you one, but you can't publish anything you made with such tools.
  • SDL - it's not much of a game engine, more of tools you can use to build a simple game or an actual game engine. I did my bachelor thesis using it. Easy to use but not very abstract and you have to do a lot of stuff yourself.
  • Panda3D - initially it looked like shit engine, but I've grown to like it very much. The engine itself is written in C++, and you can write your games in C++ if you wish. Main mode of working with it is using Python. I actually find it very nice, being able to easily throw something together I want to do in py and then if I like how it works move it to C++. The whole project is open source, Carnagie Mellon University and Disney being big contributors to it. There is a pretty active community, tons of addons for the engine and lots of tutorials. It doesn't have a nice scene editor like unity but there are some 3rd party addons (free) that help you build your own world editor inside your game. To get the full feature set of unity you need to combine it with a good python/c++ editor, 3D design program (I use blender, being a cheap bastard), 2D editor for textures (I use KDE stuff on Linux and Paint.NET on windows), and a good shell (you've got it if you work under linux, good luck on windows), 3rd party stuff for pathfinding etc. It does support several physics libs.
For all the stuff I currently play around with I use Panda3D. Unlike Unity3D it supports render to texture for free, so you can combine it with Qt for interface. I personally find that quickly written py code is better than quickly written c++ code, while carefully designed c++ is much better in long term than carefully written python. Due to this I really like p3d.
 

J1M

Arcane
Joined
May 14, 2008
Messages
14,616
Honestly I'm a little shocked at the overwhelming use of C# and XNA. No-one cares about cross platform?
XNA is Windows, Xbox, and Windows Phone. You can use all the same source code and (optionally) change the art assets.

Do you really think there is a large number of PS3 owners that actively purchase from the PSN who don't also own an Xbox? And why would you want to release on Android/iPad initially? That would slash the price you can charge.

More importantly, if you are just doing this for money you probably have investors telling you what to do. You should be working on a project that you want to do, not chasing some mythical windfall that will suddenly materialize if you choose the right platform.
 

Destroid

Arcane
Joined
May 9, 2007
Messages
16,628
Location
Australia
I was more thinking so the linux bros could play, I don't imagine many of the people posting about their projects in codex workshop care much about consoles.
 

crojipjip

Developer
Übermensch
Joined
Jan 11, 2012
Messages
4,253
I was more thinking so the linux bros could play, I don't imagine many of the people posting about their projects in codex workshop care much about consoles.
i am programming the matrix right now. it will change the whole world once people play it.
 

tiagocc0

Arcane
Joined
Jun 29, 2007
Messages
2,056
Location
Brazil
C++ because it's easy and Qt because it's works nicely in windows, max os x and linux (don't know exactly which) and makes C++ even easier.
 

Alex

Arcane
Joined
Jun 14, 2007
Messages
8,750
Location
São Paulo - Brasil
I too am not making any games right now. My favorite language, however is Smalltalk. I really like that everything about the language is open to the developer, yet it is so well written.

Lately, I've also been looking into functional programming lately, like Scheme and Haskell.
 

SCO

Arcane
In My Safe Space
Joined
Feb 3, 2009
Messages
16,320
Shadorwun: Hong Kong
The only language that impressed me as a alternative paradigm to modern typed imperative vm ones was PROLOG. The underlying inference engine idea is frigging brilliant (pity it's slow).
 

SCO

Arcane
In My Safe Space
Joined
Feb 3, 2009
Messages
16,320
Shadorwun: Hong Kong
Oh, right imperative as opposed to O.O. No, i'm thinking of the opposition to functional languages.

Functional language can compress a program so much (due to fetishists i suspect), that it turns unreadable. They appear to purposefully choose the worst names possible, and since there are no need for infunction variables and you can do most things by using a well applied fold or map (very general methods, that get very general argument names), things quickly get out of hand.
All structure, meaning implicit.
 

Alex

Arcane
Joined
Jun 14, 2007
Messages
8,750
Location
São Paulo - Brasil
Oh, I should have realized you meant that in the broader sense, not the more strict one. Sorry about that.

I don't know. Functional programming can get pretty weird if the programmer doesn't take care to make his meaning explicit (even if the method is implicit). And not having control as to how the program is processed, requiring to read the documentation to know what the processor will try first, sounds like a bad deal to me. But I can't help but think it could help make much more orthogonal the meaning of the program and the process it uses to get there.

Also, have you ever heard of Cola? It is a language developed by the Viewpoints Research Institute. It is very interesting in that it is implemented in itself... in runtime! That is, the basic parts of the language (like what is a vtable or how it deals with integers) are themselves objects running in the language itself. Of course, there is a cheat there that bootstraps the working language using a static version of it first. But once it is running, you can change or add objects that change hoe the language behaves without needing to recompile it all.
 

SCO

Arcane
In My Safe Space
Joined
Feb 3, 2009
Messages
16,320
Shadorwun: Hong Kong
Also, have you ever heard of Cola? It is a language developed by the Viewpoints Research Institute. It is very interesting in that it is implemented in itself... in runtime! That is, the basic parts of the language (like what is a vtable or how it deals with integers) are themselves objects running in the language itself. Of course, there is a cheat there that bootstraps the working language using a static version of it first. But once it is running, you can change or add objects that change hoe the language behaves without needing to recompile it all.

the-horror--thumb.jpg


And i though that duck typing was bad...
you aren't that kind of person that competes in the "underhanded C contest" are you?
 

As an Amazon Associate, rpgcodex.net earns from qualifying purchases.
Back
Top Bottom