What's the Best Programming Language for Wargames?

Gamers can also use this forum to chat about any game related subject, news, rumours etc.

Moderator: maddog986

GaryChildress
Posts: 6746
Joined: Sun Jul 17, 2005 3:41 pm
Location: The Divided Nations of Earth

What's the Best Programming Language for Wargames?

Post by GaryChildress »

If I were going to learn a programming language with which to create a war game what would be the best language to use? What programming language are the majority of wargames created with? What programming language works best with wargames?

Thanks. [:)]
User avatar
JudgeDredd
Posts: 8356
Joined: Fri Nov 14, 2003 7:28 pm
Location: Scotland

RE: What's the Best Programming Language for Wargames?

Post by JudgeDredd »

I think C is the language of choice. Although there are quite a few languages you can use.
 
As far as I know C# can be used, as can Visual Basic (didn't I read somewhere Advanced Tactics written in VB??).
Alba gu' brath
User avatar
sterckxe
Posts: 1897
Joined: Tue Mar 30, 2004 8:09 am
Location: Flanders
Contact:

RE: What's the Best Programming Language for Wargames?

Post by sterckxe »

ORIGINAL: Gary Childress
If I were going to learn a programming language with which to create a war game what would be the best language to use?

The one which you are most familiar with [;)]
ORIGINAL: Gary Childress
What programming language are the majority of wargames created with?

C++, but a significant minority is using Delphi (AGEod, a couple of Matrix games, ...) with the remainder going for Visual Basic, Eiffel, C#, ...
ORIGINAL: Gary Childress
What programming language works best with wargames?

All of them, even Java - today's hardware has no problem running 2D apps at all.

That said, if you're new to programming and don't mind the M$ tie-in : there's a free edition of the C# RAD platform which is pretty good and has everything you need.

Greetz,

Eddy Sterckx
GaryChildress
Posts: 6746
Joined: Sun Jul 17, 2005 3:41 pm
Location: The Divided Nations of Earth

RE: What's the Best Programming Language for Wargames?

Post by GaryChildress »

OK. So let's say I want to learn C++. Are there any inexpensive online colleges which others here can recommend which offer classes over the Internet?

Also whats the cheapest LEGAL way of getting C++?

Thanks.
GaryChildress
Posts: 6746
Joined: Sun Jul 17, 2005 3:41 pm
Location: The Divided Nations of Earth

RE: What's the Best Programming Language for Wargames?

Post by GaryChildress »

Also, what is Visual C++? Is that the same as C++?

Thanks.
User avatar
sterckxe
Posts: 1897
Joined: Tue Mar 30, 2004 8:09 am
Location: Flanders
Contact:

RE: What's the Best Programming Language for Wargames?

Post by sterckxe »

ORIGINAL: Gary Childress
Also, what is Visual C++? Is that the same as C++?
Thanks.

Underneath : yes

Visual C++ however is the M$ RAD platform where a lot of stuff/widgets have already been precoded for you to use and allows you to do the "visual" layout of your forms.

Cheapest way to get it : depends on where you live and what you do (student editions, ...) - check the M$ website.

But you're really better of going for C# these days - just my two (euro)cents.

Greetz,

Eddy Sterckx
GaryChildress
Posts: 6746
Joined: Sun Jul 17, 2005 3:41 pm
Location: The Divided Nations of Earth

RE: What's the Best Programming Language for Wargames?

Post by GaryChildress »

I'm actually downloading Visual C++ Express from Microsoft now. It appears to be free, although I'm sure it's a lot more restricted in its abilities than the full Visual C++.
User avatar
Terl
Posts: 601
Joined: Wed Jun 01, 2005 10:47 am
Location: Charleston, WV

RE: What's the Best Programming Language for Wargames?

Post by Terl »

Hi Gary, I am using the same program to learn C ++ (I am trying to learn it as well). There are some differences between the free (express editions) and the full Visual Studio but you will not miss them in the learning stages (some of the debugging tools and the express will not let you easily connect to SQL server databases, it does sql express though). For C and C++ you could also use Code Blocks (Free [:)] Get it here Get the version that comes with the gcc compiler). Another resource is NetBeans from Sun. It is mainly for Java but it does have C and C++ modules (though you would need a compiler I believe for C/C++)

Microsoft has some good beginning tutorials available and the MSDN library is great as well. I actually purchased a C++ book through Amazon to get me started, How to Program C++ , which is helping a great deal. It is pricey but I got it through one of the vendors for 1/2 the price. There are also lots and lots of web sites that can help get you started. I find the best way is to read my book and just program. The only way you get better at it is by doing it.
GaryChildress
Posts: 6746
Joined: Sun Jul 17, 2005 3:41 pm
Location: The Divided Nations of Earth

RE: What's the Best Programming Language for Wargames?

Post by GaryChildress »

I'm trying a tutorial for Visual C++. It appears that the Express version doesn't have a setup and deployment feature. Is it not possible to create setup files for programs created in Express? [&:]
User avatar
JudgeDredd
Posts: 8356
Joined: Fri Nov 14, 2003 7:28 pm
Location: Scotland

RE: What's the Best Programming Language for Wargames?

Post by JudgeDredd »

I was going to say...I think the express versions are purely for development and "learning". You are not allowed to make money from any applications you make with the express versions and I'm pretty sure that's why the deployment aspect isn't there.
Alba gu' brath
User avatar
Terl
Posts: 601
Joined: Wed Jun 01, 2005 10:47 am
Location: Charleston, WV

RE: What's the Best Programming Language for Wargames?

Post by Terl »

Sorry Gary, I forgot to list the deployment piece as one that is not in the express versions. They are good for learning programming and the development end though. I used my "stimulus check" to get a copy of Visual Studio - fun to convince the wife of that one... [:)]

Anyway, the express versions will make an exe file which you can distribute through other means. As for what Judge says about the licensing, I am not certain. I did not read it that closely as I used it just to learn and then got the full version.

Here's a free program to create setup files: Inno Setup
GaryChildress
Posts: 6746
Joined: Sun Jul 17, 2005 3:41 pm
Location: The Divided Nations of Earth

RE: What's the Best Programming Language for Wargames?

Post by GaryChildress »

How much does a full copy of Visual Studio run?

What is a compiler? I've seen "free compilers" for C++ but I take it that there is more to C++ than a compiler?

EDIT: So it sounds like I can learn programming with the express edition but I will need to get the full edition if I ever get to the point where I want to share or market programs?
User avatar
Terl
Posts: 601
Joined: Wed Jun 01, 2005 10:47 am
Location: Charleston, WV

RE: What's the Best Programming Language for Wargames?

Post by Terl »

If you do not want to spend money, I would use code blocks (links above) with the gcc compiler. It costs nothing and works very well. It is a free download and free to use.

The MS express programs have the compiler with them, you need get nothing else. As for the full copy, mine was just under $700 (I got the pro version). There are some places on the net that advertise the educational licensed verson for ~ $160. They (most anyway) will ask for proof like a student id to sell it to you. If you have such, you could go for that BUT NOTE per the license at MS the license on the educational version is invalid after you are done with school. If you are serious about it and wish to use it commercially, it may be worth it to invest in the pro version. That is why I bought mine; I use it at work (already made a couple utility programs using VB) and at home while learning C++.

I edited a post above with a link to a program that would create setup files for you to use with your projects. The Express editions will make .exe files and all for you, it is just that it won't deploy them as you found in your tutorial.
EDIT: So it sounds like I can learn programming with the express edition but I will need to get the full edition if I ever get to the point where I want to share or market programs?

I believe so. Again, I am not certain of MS license on the Express, but Judge is in the software field so I think he may be correct in his guess. It tracks with what one would think of MS; that they would never give you something for free if you could make $ off it [:)]. Anyway, there are other avenues to save a buck and still develop and deploy your work.
User avatar
TonyE
Posts: 1570
Joined: Mon May 22, 2006 9:50 pm
Location: MN, USA
Contact:

RE: What's the Best Programming Language for Wargames?

Post by TonyE »

A mllion programmers, a million opinions [:)]
 
My two cents are that C++ is a good adventure but go open source if you can stand it.  Something like GCC (compiler) + Eclipse (IDE) + wxWidgets (buttons, lists, etc.) allows you to develop in pretty much the same code across Windows, Linux, and OS X.  The flexibility of being able to jump from the MS ship is nice, and the cross platform is really handy as well.  If your game runs natively on a Mac you instantly gain quite a few friends, and in this low volume business of wargames that might make a big difference in sales!
 
The sad thing is that the above configuration isn't easy to set up and there are few people to turn to for kind help.  So that's where one says, "learn the language essentials with the free MS tools, when you get the hang of it, go to a more advanced solution like the one above." 
 
What route do I take?  Well, I'm one of those wacky Delphi programmers at heart and I love the speed at which I can develop a program thanks to the work of component (add-ins, want a GIS system, grab www.tglobe.com, want any pretty control, go to www.tmssoftware.com, etc.).  Delphi for years was the only programming tool to really get RAD right (imho of course); now the MS .NET platforms do a good job but the components are much more expensive than the Delphi equivalents.  There is a slow moving but working open source port of Delphi called Lazarus (and a free limited version of Delphi called TurboDelphi) again allowing Linux and OS X development with one codebase.
 
For the record I detest .NET as Microsoft centric (yes mono exists but it doesn't keep up) but the idea of including so many useful libraries in the core language is impressive.
 
Eddy probably has it right for most, "The one which you are most familiar with [;)] ".
 
 
 
 
Sincerely,
Tony Eischens
Harpoon (HC, HCE, HUCE, Classic) programmer
HarpGamer.com Co-Owner
User avatar
IronManBeta
Posts: 3313
Joined: Mon Feb 25, 2002 10:00 am
Location: Brantford, Ontario

RE: What's the Best Programming Language for Wargames?

Post by IronManBeta »

I use and recommend Delphi 2007 for game development. 

I'm not sure that any one platform is intrinsically better than any other any more - so whatever you are already best at is probably your best choice.  I like Delphi because I can get results so fast with it.  There are a ton of third party libraries out there so you don't have to reinvent the wheel for low level items.  You can focus pretty much on what makes your project a game and not get bogged down with the less fun stuff.
User avatar
jwilkerson
Posts: 7900
Joined: Sun Sep 15, 2002 4:02 am
Location: Kansas
Contact:

RE: What's the Best Programming Language for Wargames?

Post by jwilkerson »

ORIGINAL: sterckxe

Underneath : yes

Visual C++ however is the M$ RAD platform where a lot of stuff/widgets have already been precoded for you to use and allows you to do the "visual" layout of your forms.

Cheapest way to get it : depends on where you live and what you do (student editions, ...) - check the M$ website.

But you're really better of going for C# these days - just my two (euro)cents.

Greetz,

Eddy Sterckx

I agree with Eddy's comments. I do not think there is a "wrong" choice for a programming language. In the modern world, there are two main choices, c# (Microsoft) and java (not-a-microsoft). If you ever plan on doing anything with your programming skills other than writing your own game, then I would suggest one of these two as they are the most marketable. The syntaxtical differences between c++, c# and java are minumal, the main differences are in the "vendor supplied classes" which is one set of routines for the dotnet world and another for the java world. But the same basic capabilities exist in both worlds.

AE Project Lead
New Game Project Lead
User avatar
bobogoboom
Posts: 3799
Joined: Mon Feb 13, 2006 7:02 pm
Location: Dallas

RE: What's the Best Programming Language for Wargames?

Post by bobogoboom »

there is always a wrong choice. i mean what if someone tried to program a game in php that would be a wrong choice or pascal that would also be a wrong choing.[:'(]
I feel like I'm Han Solo, and you're Chewie, and she's Ben Kenobi, and we're in that bar.
Member Texas Thread Mafia.
Image
Sig art by rogueusmc
User avatar
TonyE
Posts: 1570
Joined: Mon May 22, 2006 9:50 pm
Location: MN, USA
Contact:

RE: What's the Best Programming Language for Wargames?

Post by TonyE »

ORIGINAL: bobogoboom

there is always a wrong choice. i mean what if someone tried to program a game in php that would be a wrong choice or pascal that would also be a wrong choing.[:'(]

I beg to differ. PHP can do some amazing things, including games (http://php.resourceindex.com/Complete_Scripts/Games/ has a few examples). There are some pretty solid PHP graphics libraries out there and in development. I'd rarely call it the best choice but wrong might be too strong of a characterization. Pascal is even less of a wrong choice when combined with DirectX and even better, Open GL (see http://www.pascalgamedevelopment.com/). I've done OpenGL with Lazarus (Delphi clone) but all of what I did and more can be done with FreePascal.

Sincerely,
Tony Eischens
Harpoon (HC, HCE, HUCE, Classic) programmer
HarpGamer.com Co-Owner
GaryChildress
Posts: 6746
Joined: Sun Jul 17, 2005 3:41 pm
Location: The Divided Nations of Earth

RE: What's the Best Programming Language for Wargames?

Post by GaryChildress »

OK. Here's my first game using Visual C# Express. Just send me $50.00 and I'll package it in a program and send it to you. [:D][:D][:D]
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace ConsoleApplication1
{
class Program
{
static void Main(string[] args)
{
int number;
Console.WriteLine("Pick a number.");
number = int.Parse(Console.ReadLine());
if ((number < 8) && (number > 6))
Console.WriteLine("You win!");
else
if ((number > 7) || (number < 7))
Console.WriteLine("You lose!");


Console.ReadLine();

}
}
}

EDIT: Yes! I came up with this almost entirely on my own using a few sample lines of code! [8D]
User avatar
bobogoboom
Posts: 3799
Joined: Mon Feb 13, 2006 7:02 pm
Location: Dallas

RE: What's the Best Programming Language for Wargames?

Post by bobogoboom »

ORIGINAL: TonyE

ORIGINAL: bobogoboom

there is always a wrong choice. i mean what if someone tried to program a game in php that would be a wrong choice or pascal that would also be a wrong choing.[:'(]

I beg to differ. PHP can do some amazing things, including games (http://php.resourceindex.com/Complete_Scripts/Games/ has a few examples). There are some pretty solid PHP graphics libraries out there and in development. I'd rarely call it the best choice but wrong might be too strong of a characterization. Pascal is even less of a wrong choice when combined with DirectX and even better, Open GL (see http://www.pascalgamedevelopment.com/). I've done OpenGL with Lazarus (Delphi clone) but all of what I did and more can be done with FreePascal.

php is horrible as a programming languege. most programming langueges at least understand the concept of name space.
I feel like I'm Han Solo, and you're Chewie, and she's Ben Kenobi, and we're in that bar.
Member Texas Thread Mafia.
Image
Sig art by rogueusmc
Post Reply

Return to “General Discussion”