Matrix Games Forums

Forums  Register  Login  Photo Gallery  Member List  Search  Calendars  FAQ 

My Profile  Inbox  Address Book  My Subscription  My Forums  Log Out

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

 
View related threads: (in this forum | in all forums)

Logged in as: Guest
Users viewing this topic: none
  Printable Version
All Forums >> [General] >> General Discussion >> RE: What's the Best Programming Language for Wargames? Page: <<   < prev  1 2 [3]
Login
Message << Older Topic   Newer Topic >>
RE: What's the Best Programming Language for Wargames? - 7/23/2008 1:11:33 AM   
Nemo121


Posts: 5821
Joined: 2/6/2004
Status: offline
Is there any reason why, if you decided to go for C++, you couldn't go for Visual C++ ( which seems a little more accessible ).

It is always interesting to get a glimpse into programming. It is SOOO different than what I am used to dealing with for work.

(in reply to Perturabo)
Post #: 61
RE: What's the Best Programming Language for Wargames? - 7/23/2008 1:33:45 AM   
Veldor


Posts: 1531
Joined: 12/29/2002
From: King's Landing
Status: offline

quote:

ORIGINAL: Nemo121

Is there any reason why, if you decided to go for C++, you couldn't go for Visual C++ ( which seems a little more accessible ).

It is always interesting to get a glimpse into programming. It is SOOO different than what I am used to dealing with for work.


Microsoft h8ers don't like Visual C++..

But towards another previous comment C# isn't really going to stay a MS only thing long. There are non-MS compilers and what-not that are well on thier way. Open Source versions and all that.

And why? Because at first everyone had to hate C# because MS invented it (Well some people working for MS anyway).. But in the end most gave in because it just is simply that much better. From a development perspective its not only about the power of the language, its about how fast you can code in it and how easily you can debug errors with it. Thats why the C# Developers are the smart ones. We all want better wargames and its about keeping up with the jones's. Less coding and debugging time means more time and money spent on the things we care more about.

Anyway why go with a half-baked non MS product just to save a couple bucks?

No real good reason unless your a MS h8er.

Well Billy G. finally quit Microsoft anyway so now is as good a time as any to love Microsoft...

Please, for me, cuz my MS stock needs a boost. TIA...

_____________________________


(in reply to Nemo121)
Post #: 62
RE: What's the Best Programming Language for Wargames? - 7/23/2008 2:17:46 AM   
Perturabo


Posts: 2614
Joined: 11/17/2007
Status: offline
quote:

ORIGINAL: Nemo121

Is there any reason why, if you decided to go for C++, you couldn't go for Visual C++ ( which seems a little more accessible ).

Well, it won't run on my computer.

As for MS...
I stopped buying their products after I had to activate Win XP by phone on my mother's computer by phone.

_____________________________

People shouldn't ask themselves why schools get shoot up.
They should ask themselves why people who finish schools burned out due to mobbing aren't receiving high enough compensations to not seek vengeance.

(in reply to Nemo121)
Post #: 63
RE: What's the Best Programming Language for Wargames? - 7/23/2008 1:58:38 PM   
Peter Fisla


Posts: 2503
Joined: 10/5/2001
From: Canada
Status: offline

quote:

ORIGINAL: Nemo121

Is there any reason why, if you decided to go for C++, you couldn't go for Visual C++ ( which seems a little more accessible ).

It is always interesting to get a glimpse into programming. It is SOOO different than what I am used to dealing with for work.


Well Microsoft tries to follow C++ standards but of course there will always be some differences but not that big that really need to seriously think about it - if we are talking about purely C++ language. If you decide to use MFC (Microsoft Foundation Classes) then you will need to do some work port your app to linux but it will not be a complete rewrite. I have been using Visual C++ since 1996 and I like it, I'm currently using Visual Studio Standard 2005 (you can still find out around for about ($150 or less). You don't need Visual Studio 2008 as the focus of the 2008 was for .NET development...

(in reply to Nemo121)
Post #: 64
RE: What's the Best Programming Language for Wargames? - 7/23/2008 6:03:17 PM   
pad152

 

Posts: 2871
Joined: 4/23/2000
Status: offline
Wikipedia is a great source for info

C
http://en.wikipedia.org/wiki/C

C++
http://en.wikipedia.org/wiki/C%2B%2B

C# (C sharp)
http://en.wikipedia.org/wiki/C#

Object-oriented programing
http://en.wikipedia.org/wiki/Object-oriented_programming

(in reply to Perturabo)
Post #: 65
RE: What's the Best Programming Language for Wargames? - 7/24/2008 1:05:34 AM   
Veldor


Posts: 1531
Joined: 12/29/2002
From: King's Landing
Status: offline

quote:

ORIGINAL: Peter Fisla
Well Microsoft tries to follow C++ standards but of course there will always be some differences but not that big that really need to seriously think about it - if we are talking about purely C++ language. If you decide to use MFC (Microsoft Foundation Classes) then you will need to do some work port your app to linux but it will not be a complete rewrite. I have been using Visual C++ since 1996 and I like it, I'm currently using Visual Studio Standard 2005 (you can still find out around for about ($150 or less). You don't need Visual Studio 2008 as the focus of the 2008 was for .NET development...


I liked MFC at the time but now that they've done away with it in favor of Windows Forms and the like... Id probably avoid MFC altogether if I didn't already know it. Even knowing it I now really really dislike it compared to the new stuff.

I don't know why portability is such an issue especially for wargaming. Anyone out there is gonna have had to find a way to run windows games if they are even a half-serious gamer. Certainly no one else worries about it (Matrix or whomever) so why keep citing it as an issue with MS Dev Products? Thats really a rhetorical question though since I'm sure I'm in the silent minority on this particular issue.

_____________________________


(in reply to Peter Fisla)
Post #: 66
RE: What's the Best Programming Language for Wargames? - 7/24/2008 1:27:40 AM   
Nemo121


Posts: 5821
Joined: 2/6/2004
Status: offline
Unless there's something massive I'm missing I'd agree with veldor. I know people who use emulators to run Windows wargames on their computers. It mightn't be ideal but for a turn-based, 2d game the overhead of the emulator is hardly crippling.

(in reply to Veldor)
Post #: 67
RE: What's the Best Programming Language for Wargames? - 7/28/2008 3:04:20 AM   
mbatch729


Posts: 537
Joined: 5/23/2001
From: North Carolina
Status: offline
Figured I'd add a few comments too. Skip C++. The dangers of unmanaged code isn't worth the small, and decreasing, FPS (frames per second) you can get compared to C#. I'd encourage you to explore C#, but Python can be useful for various scripting tasks too.

_____________________________

Later,
FC3(SW) Batch
USS Iowa

(in reply to Nemo121)
Post #: 68
RE: What's the Best Programming Language for Wargames? - 7/28/2008 8:29:40 PM   
Jeffrey H.


Posts: 3154
Joined: 4/13/2007
From: San Diego, Ca.
Status: offline

quote:

ORIGINAL: pad152

Wikipedia is a great source for info

C
http://en.wikipedia.org/wiki/C

C++
http://en.wikipedia.org/wiki/C%2B%2B

C# (C sharp)
http://en.wikipedia.org/wiki/C#

Object-oriented programing
http://en.wikipedia.org/wiki/Object-oriented_programming



C# link was incorrect, this is a correct one:

http://en.wikipedia.org/wiki/C_Sharp_%28programming_language%29




_____________________________

History began July 4th, 1776. Anything before that was a mistake.

Ron Swanson

(in reply to pad152)
Post #: 69
RE: What's the Best Programming Language for Wargames? - 10/29/2019 8:12:46 PM   
RyanCrierie


Posts: 1461
Joined: 10/14/2005
Status: offline
It's been ten years so let's revisit this with some information gleaned from looking at the EXE files:

Operational Art of War III: Microsoft Visual C++ (based upon text saying "Microsoft Visual C++ Runtime Library")

War in the Pacific Admiral's Edition: Microsoft Visual C++ (based upon text saying "Microsoft Visual C++ Runtime Library")

Forge of Freedom: A Microsoft Visual Studio language (based upon C:\Projects\ACWPlato\ForgeOfFreedom.pdb in the EXE)

Advanced Tactics Gold and the Decisive Campaigns games: Microsoft Visual Basic (based upon text that says "Microsoft.VisualBasic")

Panzer Corps: Microsoft Visual C++ (based upon text saying "Microsoft Visual C++ Runtime Library")

Strategic Command: European Theater (2002) -- Microsoft Visual C++ (based upon text saying "Microsoft Visual C++ Runtime Library")

Strategic Command: World at War -- Pascal with Simple DirectMedia Layer (SDL) library (based upon seeing SDL.dlls in folder, and mention of "Pascal" in EXE)

SP Camo's Steel Panthers WW2 and Steel Panthers Main Battle Tank: Borland Delphi.

As for what was used and why:

Eddy Sterckx's comment about the best programming language for wargames being "The one which you are most familiar with," explains I think some of the choices -- the programmers used what they knew best.

As for this comment by Deride:

I highly recommend XNA Studio from Microsoft.

This is the new toolset from Microsoft that they are hoping to push for new developers. You can use these tools to write programs that run on PCs or XBox. If you build a nice enough game, you can buy the professional version that allows you to post your games to XBox Live - and even make money.


That didn't age well. as Microsoft killed XNA back in 2013.

_____________________________


(in reply to GaryChildress)
Post #: 70
RE: What's the Best Programming Language for Wargames? - 10/29/2019 8:24:39 PM   
ncc1701e


Posts: 7380
Joined: 10/29/2013
From: Utopia Planitia Fleet Yards
Status: offline
Let's complete your list.

Unity of Command: Python
Unity of Command 2: Python
Warplan: C# and Unity3d


_____________________________

Chancellor Gorkon to Captain James T. Kirk:
You don't trust me, do you? I don't blame you. If there is to be a brave new world, our generation is going to have the hardest time living in it.

(in reply to RyanCrierie)
Post #: 71
RE: What's the Best Programming Language for Wargames? - 10/29/2019 8:28:36 PM   
RyanCrierie


Posts: 1461
Joined: 10/14/2005
Status: offline
A lot of things have changed in the last ten years.

IN 2014; Microsoft made Visual Studio free for hobbyists with the Community Edition, and this has:

Visual C++
Visual C#
Visual Basic

_____________________________


(in reply to RyanCrierie)
Post #: 72
RE: What's the Best Programming Language for Wargames? - 10/29/2019 8:35:10 PM   
RyanCrierie


Posts: 1461
Joined: 10/14/2005
Status: offline
quote:

ORIGINAL: ncc1701e

Let's complete your list.

Unity of Command: Python
Unity of Command 2: Python


I had to check it and well, there it is:

https://unityofcommand.net/forums/viewtopic.php?t=607

quote:

the game is entirely written in Python (http://python.org/). We use a few external libraries to put our platform together: cairo (http://cairographics.org/), pygame (pygame.org), etc.

Doing it in python means we were able to make it sweet and bug free (it's only 50k lines of code, including the editors) but at the same time there is some pain when we move it to a new OS as we need to compile our platform ourselves first - Mac was a bit of a headache for example.


quote:

Flatwater wrote:
Would you be willing to share which program you used to create the standalone Windows exe from your Python scripts?

Hi! No secrets there, we used py2exe on windows and pyinstaller on linux.


quote:

here's what we're doing. We use Python 2.7 and Pygame 1.7 (I think, not 100% sure, but whatever is on the build machine since ~2yrs ago).

We set up a a software surface using pygame, but do not use pygame for rendering, just for input. Instead we both blit and draw onto the pygame surface using cairo. This involves some ctypes magic to set up - email me and I'll send you the code if you want. To get the performance, we use a "dirty rect" type algorithm. This doesn't really help with full screen redraws (i.e. scrolling) but we don't do a lot of those anyway.

My "head in this direction" advice is: use SDL2 (via pySDL) and do your blitting on an OpenGL context. I don't think you need to make any OpenGL calls for that, just use the SDL2 primitives (Sprite etc). Don't be put off by the work-in-progress feel of SDL2/pySDL - e.g. you may need to get the latest version from their repos and compile everything yourself.


quote:

For the next game, we will be using cx-freeze, because unlike the other exe-builders, such as those used by UOC, it supports Python 3.3 (UoC actually uses Python 2.6) and builds for all three platforms nicely!


_____________________________


(in reply to ncc1701e)
Post #: 73
RE: What's the Best Programming Language for Wargames? - 10/29/2019 10:39:26 PM   
RyanCrierie


Posts: 1461
Joined: 10/14/2005
Status: offline
Been searching around; and apparently for C#; since Microsoft killed XNA:

quote:

Unity is generally considered the XNA replacement for most as MonoGame is heavily bug-laden when trying to do some of the more advanced XNA stuff (Object instancing for example)


_____________________________


(in reply to RyanCrierie)
Post #: 74
RE: What's the Best Programming Language for Wargames? - 10/30/2019 9:03:59 AM   
altipueri

 

Posts: 869
Joined: 11/14/2009
Status: offline
Presumably the Peter Fisla who posted ten posts up - was the Peter Fisla that programmed "Tigers on the Hunt" ?

:)

And does Perturabo who posted above that, still avoid Microsoft products?


Blimey, time flies

(in reply to RyanCrierie)
Post #: 75
RE: What's the Best Programming Language for Wargames? - 10/30/2019 7:35:14 PM   
ncc1701e


Posts: 7380
Joined: 10/29/2013
From: Utopia Planitia Fleet Yards
Status: offline
The problem is not only the programming language. This is the 2D or 3D engine that you want to use for graphics. The choice of your graphical engine may dictate your language.
Except if you want to develop your own engine of course...


_____________________________

Chancellor Gorkon to Captain James T. Kirk:
You don't trust me, do you? I don't blame you. If there is to be a brave new world, our generation is going to have the hardest time living in it.

(in reply to altipueri)
Post #: 76
RE: What's the Best Programming Language for Wargames? - 10/30/2019 8:13:21 PM   
RyanCrierie


Posts: 1461
Joined: 10/14/2005
Status: offline
I've been thinking things over and I think the choices are:

Visual C++ with SDL: If you want to be sure that the core technologies behind your engine don't get abandoned. SDL saw a release (2.0.10) just a few months ago; and Visual C++ is kept up to date by Microsoft.

Downside is that C++ is tougher to learn and you spend more time dealing with memory allocation bugs than usual; since C++ doesn't have garbage handling.

Visual C# with Unity: If you want to develop a game in the next 2-3 years. Unity can be used for 2D or 3D games, and Unity itself is kept somewhat up to date. Plus, C# has garbage handling for memory, so you don't have to deal with that.

Downside is that the Developers of Unity can and have depreciated things (in 2005, Boo, C# and JavaScript were supported languages for Unity. They've depreciated support for Boo and JavaScript, leaving only C# by 2019.) So if you're planning on using it to make games 10 years down the road, YMMV.

_____________________________


(in reply to ncc1701e)
Post #: 77
RE: What's the Best Programming Language for Wargames? - 10/30/2019 8:48:21 PM   
RyanCrierie


Posts: 1461
Joined: 10/14/2005
Status: offline
To elaborate further on this:

Eddy Sterckx's comment about the best programming language for wargames being "The one which you are most familiar with," explains I think some of the choices -- the programmers used what they knew best.

Look at WITP:AE and TOAW III.

The game engines used by both go have a lot of heritage:

WITP:AE's engine goes back to the original WITP (2004) which in turn goes back to Uncommon Valor (2002), and in turn all the way back to 1999's Talonsoft's 12 O'Clock High: Bombing the Reich and Battle of Britain -- the last of which ran on a Pentium and recommended 64MB RAM, of which 16-20 MB were used for Win95/98.

Plus, Grigsby's experience in programming before the above games was:

Steel Panthers (1995) which ran on a 486DX and 8 MB
War in Russia (1993) which was a 386 and 640 KB
Pacific War (1992), which was a 286 and 640 kb.
Panzer Strike (1988), on Apple II or Commodore 64

Likewise, for TOAW III; the basic engine goes all the way back to 1998, when it was just Windows 95/96 and 16 MB of RAM required.

Norm Koger before that worked on:

Age of Rifles (1996), 486 DX2, 8 MB
Tanks (1994), 386, 2MB
Conflict: Korea (1992), 286 and 640KB.

Conflict Korea, if you look at the screenshots on Mobygames is VERY much the prehistoric "TOAW"; due to the similarity of game concepts you see show up later in TOAW.

You can see how when you started out doing a complex simulation of either Korea, the ENTIRE Pacific War or Russian Front on just 640 KB RAM, you'll be used to working "close to the metal" to get as much performance from the hardware at the time; and as you move forward in your career, you'll stick with the languages you know and trust the best.

_____________________________


(in reply to RyanCrierie)
Post #: 78
RE: What's the Best Programming Language for Wargames? - 10/31/2019 7:56:34 AM   
ncc1701e


Posts: 7380
Joined: 10/29/2013
From: Utopia Planitia Fleet Yards
Status: offline
I have forgotten:
Commander Europe At War: Java and I think they are just using AWT for creating the graphical interface


_____________________________

Chancellor Gorkon to Captain James T. Kirk:
You don't trust me, do you? I don't blame you. If there is to be a brave new world, our generation is going to have the hardest time living in it.

(in reply to RyanCrierie)
Post #: 79
RE: What's the Best Programming Language for Wargames? - 10/31/2019 8:05:57 AM   
ncc1701e


Posts: 7380
Joined: 10/29/2013
From: Utopia Planitia Fleet Yards
Status: offline
Something also to consider is portability. Do you plan your game for Windows / Linux / MacOS or just for Windows?


_____________________________

Chancellor Gorkon to Captain James T. Kirk:
You don't trust me, do you? I don't blame you. If there is to be a brave new world, our generation is going to have the hardest time living in it.

(in reply to ncc1701e)
Post #: 80
Page:   <<   < prev  1 2 [3]
All Forums >> [General] >> General Discussion >> RE: What's the Best Programming Language for Wargames? Page: <<   < prev  1 2 [3]
Jump to:





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts


Forum Software © ASPPlayground.NET Advanced Edition 2.4.5 ANSI

1.221