Starting programming simple simulators

pesgores

Deus Vult!
Joined
Sep 20, 2008
Messages
1,087
Location
Portugal
So I've kind of chosen what to do about my life and I've decided to be a videogame developper. All my life I've been creating games of all sorts to amuse myself, with videogame inspired mechanics (i.e.: Football Simulation, Civilization, among others), and what drove me off from continuing playing them was the time it took me to make the necessary calculations between results and final data (all of this done on paper).

I haven't tried making something like this before, but from what I know, I can write a few basic simulations in MS Excell. I'd like to start hearing tips from those with more experience in this area, apart from reading tutorials to get me started.

My first objective is to create a Football simulator that can, only by introducing quantitative stats for teams, give a report of a match using a simple formula I've invented among many others. How should I start?
 
learn Lua and find a good API
 
Perl, Python or C would be much better than doing this in MS Excel. YOu'll learn a useful language and get to make something you want to.

EDIT -- In fact, a little console app in C wouldnt be difficult to bang out.
 
Yeah do it in Python or C or Java.

Best game development site is here:

www.gamedev.net
 
I also throw in my vote for Python. While it is often criticized for being slower than C/C++ it is fast *enough* for many things. It is faster to learn and also faster to code in.

Link if you are new to programming: http://www.greenteapress.com/thinkpython/html/index.html
Or some background: http://diveintopython.org/

I would avoid perl, some swear by it but to me the code looks like someone was banging their head on the keyboard. Traditionally it was used to code the support programs in many linux distributions, but now python is the new favorite for that.

If you are interested in 3d game programming then I suggest Panda3D which offers both python and C++ for game making: http://www.panda3d.org/
 
Are you a programmer?

If you're not, take a couple years to learn the finer points of the craft, before you dive into game development.

I know 2 people who went into game development - the first couple years in the industry (if you manage to get your foot in the door) are not very fun.. You're basically going to be a coding monkey - writing tools and such for senior programmers. You might actually never even get to do anything 'fun'.. at least until you work your way up to a more senior position.
 
Man, I wish I could find a proper coding monkey job. :sad: It's all coding professor jobs where you have to know all kinds of framework and tools and scrum and whatnot. Of course, the skills required is not taught in university at all, you will only learn it by being lucky enough to get a job where it's used but you're still somehow accepted despite not knowing it. /rant

I've never done anything in Excel but I hear the script language can be quite powerful for what it is. It's some kind of Basic-inspired language, right? I've heard it's quite easy to ramp up screens in Visual Basic. If you don't know any other programming language then maybe least effort/fun would be to learn something similar and "convert" your old stuff into individual software.

I doubt VB is used in game industry though, I think that would be mostly C/C++ and perhaps Java if it's on mobile platforms.

here's a job ad looking for a game developer: http://www.massive.se/jobs/47/15/
 
Are you a programmer?

If you're not, take a couple years to learn the finer points of the craft, before you dive into game development.

I know 2 people who went into game development - the first couple years in the industry (if you manage to get your foot in the door) are not very fun.. You're basically going to be a coding monkey - writing tools and such for senior programmers. You might actually never even get to do anything 'fun'.. at least until you work your way up to a more senior position.

My first objective here wasn't creating a game to be honest, but more of a "input data, receive results" simulator with a randomness factor.
 
A formula in Excel may work fine for that, but if in the future you want to expand it, it would probably be better if it was in an actual programming language (No, VB is not...)
 
I wouldnt consider it to be. Its got its uses, but if I were writing an actual program, C/Cpp, Python or Java would be my choices.
 
Well that PacMan game is pretty good. He did a space invaders one too.

But yeah, as I said, Python, C/C++ or Java/C# would be my choice.
 
To be anal for a moment - there's no such language as "C/C++". C++ shares some common syntax with C, but they're two separate and different languages. If you want to learn C, learn C. If you want to learn C++, learn C++. Just don't be one of those people who writes bastardized "C with classes" type code.

Yeah do it in Python or C or Java.

I would second recommending Python or Java for a beginner. Even Ruby if you're just looking to dabble in basics.

If you want to learn a "real" language though and aren't interested in one of those, I'd recommend C++ over C. It gets much more complex, yes, but you don't have to learn the more difficult stuff until you're ready for it, and the C++ standard library makes life much, much easier for a beginner. C++ will also be more useful in the long run - I know of very few people still doing game development in C.
 
My first objective here wasn't creating a game to be honest, but more of a "input data, receive results" simulator with a randomness factor.

Looking at the primary objective, I'm sure you could do that perfectly well in Excel with VBA. I've done a few "input data, receive results" formulaic type programs in regular Visual Basic (version 4, from way back when), and it is a pretty easy language to pick up the essentials, and set up a basic GUI. Visual Studio Express 2010 (including Visual Basic, Visual C++, etc.) is free, and while it's not the same Visual Basic as what I used, it should still be comparitively easy to use, and Visual Basic 2010 will probably get you what you want without too much extra effort required to get up and running.

Visual Basic tends to have a bad reputation because a lot of Visual Basic programmers have bad programming habits. It probably doesn't help that it's a Microsoft language (which a lot of people have a problem with, some with reason, a lot without reason), or that it either is limited/clunky in several ways (early versions) or not really backwards compatible with older versions (newer versions). But it is used in an awful lot of business applications, although likely a decreasing amount. And I'm sure there are some games (think mid-90's era) that do use Visual Basic. It's possible to do a full-fledged game in Visual Basic if you are determined and willing to put up with some inconveniences. But it's certainly not a good bet for full-fledged games.

Long-term, Python, C#, Java, and most of the other languages here are all good ones to consider learning. Java should also be fairly friendly to beginners - C++ or C have a lot more trap doors for the inexperienced C++ or C programmer to fall into. I'd suggest Groovy as a language that is similar to Java, but protects you from many of the pitfalls and inconveniences that Java will still make you put up with from time to time, and is also likely to grow in popularity. It isn't particularly fast, but how fast the code runs shouldn't be a primary concern when you are starting out. Save fast languages, which often also are the ones that let you shoot yourself in the foot easily, for later, once you're comfortable with the basics.

If you want to be a career programmer (video game developer/etc.), you should definitely move beyond Excel/VBA/Visual Basic at some point - but I wouldn't say that doesn't mean it's bad to start with them.
 
You can also get Visual Studio C# express.

The language is powerfull, but not extreamly complicated if you want to do some simple stuff. You have a good set of pre defined classes, and it's easy to make simple interfaces, mostly WYSIWYG.

Then, you can do more advanced stuff as well. Going for instance to XNA if you want to make fast graphics.
 
Yeah C# is a nice language to learn. It's what Java should have been like.

Shame I can't find any decent tutorials on the web though, the MSDN doesn't do a good job of teaching you stuff whereas there is loads of C++ stuff about.

Personally I tend to just use C++ for everything except GUIs since that's what I know best. C# really is much easier for GUI stuff, MFC sucks.

I wouldn't recommend Visual Basic.NET, it's basically identical to C# these days but with crap syntax.

The express editions are great and free. The IDE is a little slow.
 
My first objective here wasn't creating a game to be honest, but more of a "input data, receive results" simulator with a randomness factor.

I really wouldn't use Excel for this, as eventually you'd want to program in a GUI, AI, other game logic, etc. and Excel isn't very well suited for that.

Writing a program that processes data might actually be a good way to learn a language (C++, C, Java, whatever), so that might not be a bad starting point..
 
Back
Top Bottom