Thursday, September 07, 2006


OK, this is how the deal goes ... I will be creating a new entry in my blog from time to time "after hours" (when my eyes want to pop out of my head) ... So with the exception of today, you will find no more that one entry per day (and I promise I won't add a new entry every day, I have a life, you know) ... And yes! I'm not an English-native speaker so please forget any grammar and spell errors "I certainlywill make" (I know, I know, just kidding: "I will certainly make").

Having said that, we can now move onto the first topic.

If you read my previous entry you will see that I claim that sometimes resources (in any form of documentation, white-paper, book, source code, etc.) in some way assumes that you already know certain concepts, techniques, programming languages ...

Thus, if my blog will mainly deal with game development/programming with C#, what should you know first to properly follow and understand those resources? Think! Think! ... Tic-tac, tic-tac, ... Yes, you're right ... C# (pronounced "C-sharp" ).

1) What is this so-called "C-Sharp" language? In short, it's Microsoft's flagship language.

The long answer, it is a high-level language based on MS framework that deals for you with, among other things:
  • Memory management (say 'goodbye' to pointers and function pointers and say 'hello' to the garbage collector delegates and so on, but of course, you can still use pointers with C# if you want, not to mention with C++.NET).
  • Translation of source code to MS Intermediate Language or "MSIL" (now, executables and dlls are no longer machine code after "compilation" and no matter which .NET language you choose, you can reference and use assemblies created with other .NET languages with ease).
  • Proper execution of assemblies on clients' machines (this will make sure that an MSIL assembly is "natively" compiled to machine code on the machine that executes/calls it in order to avoid the problems of running programs pre-compiled on third-parties' machines).
Regarding the language structure, talking in a dirty way (you are over 18, right?!), C# is a sort of mixture of aheem ... va! (sorry for that but my flu is killing me) and C++. Let's say that it lays between those two. Sort of ...

2) Being C# developed by MS, does this mean that C#-based assemblies will only run on PC computers with Windows OS? No, there is an open-source project called "Mono" which provides the necessary software that let you develop and run .NET applications on a multi-platform environment (Linux, Solaris, Mac OS X, Unix and even Windows).

You can use the "Mono-Develop IDE" to compile and run any assemblies you create for .NET through Mono's framework.

Off course, you can use Visual Studio 2005 to develop on Windows platforms, either on the commercial flavors or the free ones (called "Express Editions"). You can also use an open-source, and yet powerful, IDE called "Sharp Develop".

3) What makes this C# language a value asset for programming? Glad you ask.

Friendly, portable, powerful, fast, with lots of features that help you program ... And as you will see, as long as approach to game-related topics, that it not only a language suitable for applications (for which it is mostly used nowadays) but also for games.

Coming from Java? Not a problem. You will quickly find your-self programming with ease.

Coming from C++? Not a problem either. You will feel a great amount of relief when you notice that you can stop dealing with pointers. Speed? Almost the same under certain circumstances and growing (it will eventually match C++). Differences? Heritage is only allowed on a single basis. Delegates replace function pointers. "Generics" resembles "Templates". Etc., etc.

Coming from any other sort of basic and non-basic language? You will find that it is not hard to learn, even if it is the first time that you get your hands on Object Oriented Programming ("OOP").

4) Which versions of the MS framework are currently out there? Good question.

You have three main versions:
  1. .NET Framework 1.x: the one that started everything. Many applications still use it.
  2. .NET Framework 2.x: it has introduced one of the greatest features you will find: "Generics" (some friend!).
  3. .NET Framework 3.x: formerly called "WinFX". Currently, it's under a beta stage and will ship within "Windows Vista" next year. It will change the way you use the components that form the Framework it-self (from now on referred as "Foundations") . For instance, the "Window Presentation Foundation" will replace GDI (everything will be based on DirectX), and will introduce "XML for Applications" or XAML (pronnounced "Zamel") as a way to create GUI's.
Please take due note that from .NET Framework 2.x and on, you will also find installation versions for x86, x64 and IA64 machines (i.e.: if you have a x64 Win OS and an AMD 64-bit processor, go ahead and install the version for x64 computers).

5) Where can I find books, tutorials and any other resources to get my hands on C# programming? Interested, uh?

For books, always visit vendors like "Amazon" and "Barnes and Noble", so to speak. Use the search for references like C#, .NET Framework, and so on.

And for tutorials, you can visit places like "The Code Project", "C# Corner" and "GotDotNet".

But always visit the main source: "MS Developers Network" and "MS Forums".

Well, to finish off today's entry (... yes, please ...) I could spend a lot of weeks and even months to talk about C#, but it is not the point here since you can see you shall find plenty of resources out there. I just wanted to give you a brief explanation of its main characteristics as well as to point you the right places to find resources.

If you aren't a newbie then it's most likely that you already knew all of the above-mentioned information, but if you are a newbie I hope it helps ... :)

Just remember, the use of C# is growing faster and faster among "indies" (we will talk about this in later posts) and I believe it's a matter of time until the game industry adopts it as a standard. And believe me, it will ... ;)


Wow! This is my first post on my own blog ... I'm really excited !!!

For those of you who happen to find this blog, let me tell you what I will be talking about ... Mainly, game development and programming with C#, from the viewpoint of an "newbie-indie" (please repeat).

I consider my-self a "rookie" in what game development and programming relates, even though I have an advanced knowledge in general programming. But, let's face it! One thing is programming an "app" -no matter how difficult the task, and other very different is entering the game-programming world.

If you want to become a "pro", the first thing that you have to notice is that everything that you have learned in your life as an application programmer/designer/architect/etc., is just the lower base and no more than the lower base of knowledge that may help you start dealing with the new challenges ahead in the game industry.

Unfortunately, this is something that you learn by "trying an error" since on one hand you find that every game-engine developer says "Use our SDK, game development was never easier before!" and on the other hand, no one warns you about the risks of following a light that shines so hard that if you don't take it slowly you could end up trapped in a dead-end alley.

Don't you feel that every book, forum, or blog about games development/programming out there assumes that you already have a certain amount of experience in whatever topic they cover? And at the same time they don't say where to find information for newbies? Take shaders for instance, now we are approaching to the 4th model. But, what is a shader? Where can one find info from the grounds up? Or take techniques on lighting/shadowing: are light-maps and shadow-maps the same?

Don't panic! There are a lot of places that offer very good examples and articles on how to get started -which sometimes are very difficult to find even by doing a [place here the name of the first search engine that you think now] search.

So, where to start? I will be soon providing information regarding every topic related to game development -links to pages, articles, other blogs and why not? my own comments- so that you can get on the right track, right away!

Enough for my fist post and remember, do as I say but not as I do ...

Watch this space!