XNA Game Studio Beta

    This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

    • XNA Game Studio Beta

      Well, it seems that Microsoft has released the first Beta of XNA Game Studio

      msdn.microsoft.com/directx/xna/

      If you've not heard of it before, it's a .NET environment designed from the ground up for making games. It's got graphics, sound, input and more all in a standardised API; as well as this Microsoft are providing an entire set of tools for the games production pipeline as part of the studio. The best thing is that games you make with XNA will be usable on both the Windows platform and on the XBox360 (support for this is coming with the full release).

      I know this is mainly a C++ forum, but I just thought I'd share.

      I'm really excited by this and I think it'll mean a lot to us hobby coders ;)

      The best thing is; I've been working for the pst couple of weeks on porting the GCC example code to C#. Now that XNA is out, I have a standard platform to aim for too.

      When done, I'll share it with y'all.
    • RE: XNA Game Studio Beta

      Sounds great! I heard about this at GDC but didn't really get a chance to learn much more. I'm interested to see what you discover.

      My concerns with C# or any other .NET language has always been speed, so I'm very interested to see how it runs. Here at work we use .NET for internal tools, but nothing in engine. At one point we were toying with the idea of using C# for our in-game speech tool. I forget why we didn't.

      -Rez
    • RE: XNA Game Studio Beta

      I'm not so sure about the .NET thing myself. but i guess a cheap native code entry into the 360 would be too much to ask. I've been playing with the beta for two nights now and I have to say I love the idea and it does seems easy to use.

      My code load model data is about 3x slower than the C++ i'm porting from. I'll say right though that this is really my first go at C# so I'm positive I'm not using it very well. So far, it's a little slower but still acceptable. when i get a little farther along I'm going to try it on a machine that's about minimum spec for the beta. That'll make for an interesting test

      I'm concerned about performance when I try to do more complex things. Is it true that every time you call an API function (Direct3D or whatever) that it goes through an extra thunking layer to get to native code?

      gb

      The post was edited 1 time, last by garbob ().

    • Rez,
      I was worried about speed as well, but C# is actually amazingly fast despite being a managed gc language. There is some crazy wizardry going on with their memory allocation techniques under the hood, because compared to Java, the speed hit you take in C# is almost negligible. To see what I mean, search the net for games written in C#, and you might find some interesting gems amongst them.

      One could compare the speed debate between C++ and C# to the speed debates between assembly and C. Yes, you give up just a little bit of speed by going C#, but you gain so much more in terms of productivity enhancements such as multithreading and their leak-resistant objects and class library with excellent IDE support.

      I'm guessing that the reason you did not go with C# for the in-game speech tool is one or both of two reasons:
      1. All of those frickin' .NET dependencies you would need to run the game... not worth it if you intend to run the tool on a console (at this time). C# is not exactly a multiplatform-friendly language just yet. They've got some home-brewed solutions out there, but nothing official. As far as I know, using managed C++ in a CLR environment can only be done within the .Net framework
      2. Lack of explicit memory control. Since RAM is a premium on consoles, you would want to be a control freak about what's using it at any one time


      I'm not sure what Microsoft did to solve the variable RAM issue, but I welcome this new development... a lot. I could see this as a crux that pushes C# farther into the mainstream for game development than it currently is. It'll be sad to think of all those programmers out there in five years who don't have a clear picture of what a pointer is and how heap allocations work, but that sort of thing can be learned as needed.... if needed.
    • garbob,
      With reguards to slower rendering... that is definitely a weak point. Are you currently using GDI or Managed DirectX?

      They've actually done some work to make their Managed DirectX more like native C++ DirectX calls, and it's getting better over time.

      GDI on the other hand will be slow as molasses in C#. It seems as if they've decided to leave that as a straight port to managed code, and the use of GDI in C# was never meant for sprite-heavy applications such as 2D games.
    • I'm using Direct X, man i'm glad to hear that about the calling. I was getting discouraged by my model loading performance and justing trying to tell myself that 'm not using C# very well yet. (tricks to work with data collection objects and so forth) Is there any C# books out there that any of you C++ programmer got anything out of or am I better off just do what I'm doing? Right now I've been saying "There must be something for this in the library" and searching the help system
    • I found myself in that situation, too. So far, I've found that I prefer C# cookbooks over general C# reference books.

      As for missing C# functionality for lots of hardware interactions (i.e. sound), I've been forced to make myself familiar with the use of managed C++ so that I could wrap those functions and use them in a C# context.
    • I think we went with C++ because it was easier to integrate into our code-base and because we know C++ much better. The purpose of this tool was to be able to step into our vast dialog trees to test/debug speech problems without having to actually talk to the person and listen to that same dialog over and over. At some point, we'll migrate it into more of a dynamic, real-time speech creator.

      When it comes to C# in games, I'd imagine the same evolution will take place here that did when switching from Assembly to C. Performance-critical components (like rendering) will take place in the lower-level language while game logic and other such events will take place in the higher-level language. Eventually, it won't matter anymore.

      -Rez
    • Originally posted by Kain
      As for missing C# functionality for lots of hardware interactions (i.e. sound), I've been forced to make myself familiar with the use of managed C++ so that I could wrap those functions and use them in a C# context.


      This is exactly what XNA is going to help us with, I think. Seems that it's basically MDX2, so has a low-level sound, graphics and input API that's got a C# interface. Seems good to me.
    • Originally posted by garbob
      I'm using Direct X, man i'm glad to hear that about the calling. I was getting discouraged by my model loading performance and justing trying to tell myself that 'm not using C# very well yet. (tricks to work with data collection objects and so forth) Is there any C# books out there that any of you C++ programmer got anything out of or am I better off just do what I'm doing? Right now I've been saying "There must be something for this in the library" and searching the help system


      I am a C# web developer, and I found the best book for transition from C++ to C# was the Detiel book C# for Programmers, should give you all the knowledge you are looking for. There is a decent book called Beginning C# for Game Programmers, its first 5 or 6 chapters really is a nice introduction to the langue but nothing really that special, and the rest is about DirectX. The Game Programmer book is written for people who dont know C#, but is an easy quick read that will give a good foundation of the langue without reading a textbook.

      I havent done C++ professionally, only in school, only C#, but I love the C# language. I look forward to testing out XNA, it seems like an interesting frame work.
      Hook'em