Catch up on stories from the past week (and beyond) at the Slashdot story archive

 



Forgot your password?
typodupeerror
×
First Person Shooters (Games) Quake Entertainment Games

.NET Version of Quake II 59

MSwanson writes "It seems that Vertigo Software has ported the Quake II source code to Microsoft's .NET platform. Not only did they add a heads-up display in the .NET managed version, but they also say that the managed version initially ran faster than the native version. After changing some optimization settings, the native version now runs 15% faster than managed .NET code. Still pretty impressive. Download the ported version along with source code at the Vertigo site."
This discussion has been archived. No new comments can be posted.

.NET Version of Quake II

Comments Filter:
  • by Dr. Bent ( 533421 ) <ben&int,com> on Monday July 14, 2003 @10:56AM (#6433949) Homepage
    So they're still using some native C++ code? Big deal. Sounds like they just put a .NET wrapper around the QuakeII Engine, and they're still using native code to do all the heavy lifting. So you're still tied to Windows, and it runs 15% slower....fantastic.

    Now, when they have a version written purely in managed code than can run on any .NET implementation (and runs only 15% slower), then I'll be impressed.
    • Quake II, if I am not mistaken, was written in C (not C++). So it looks like they ported the code to C++ and used .NET so that you can run the engine as a managed app. Should make it pretty easy to add new features.
      • looks like they ported the code to C++

        Getting C code to compile with a C++ compiler is hardly a difficult task. QuakeII compiles with Visual C++ out of the box for starters.

        Should make it pretty easy to add new features.

        I'm sorry, but I don't see how getting this to compile under the bastardized piece of crud that is "managed C++" would make it easier to add new features.

        All this does is show you can port a C app to C++ on .NET. Yay. What are their supposed advantages to having Quake II run unde

      • by z01d ( 602442 ) on Monday July 14, 2003 @12:42PM (#6434837)
        Quake II, if I am not mistaken, was written in C (not C++).

        that's right. and although we don't have quake3 engine source code, but it's safe to say that all id games so far are using C (or QuakeC for mod making of Q1). but not any more, here is a quote from JC about D3:

        I did most of the early development work with a gutted version of Quake 3, which let me write a brand new renderer without having to rewrite file access code, console code, and all the other subsystems that make up a game. After the renderer was functional and the other programmers came off of TA and Wolf, the rest of the codebase got rewritten. Especially after our move to C++, there is very little code remaining from the Q3 codebase at this point

        http://www.gamespy.com/e32002/pc/carmack/
    • by thing12 ( 45050 ) on Monday July 14, 2003 @12:03PM (#6434485) Homepage
      Sounds like they just put a .NET wrapper around the QuakeII Engine, and they're still using native code to do all the heavy lifting.

      Not quite -- if you download it and run the code through a .net disassembler you'll see that it can be converted to msil or higher up to C#. I haven't done a detailed analysis of it, but on the surface it looks like a complete conversion. Of course that doesn't count calls to COM objects and any 3rd party DLL's that are called via platform invoke's. But it looks like the "heavy lifting" is being done inside the confines of the .NET Framework.

      • by irix ( 22687 ) on Monday July 14, 2003 @01:05PM (#6435097) Journal

        it looks like a complete conversion

        They converted the code to compile in Visual C++ .NET. If you run with managed extensions on, they hook in a class that does the radar using .NET APIs (Windows forms and such). By the way - look at their code for the radar - it is hideous. Everything in the .h file in true "lets make the users of our class import all sorts of useless dependencies" style. Ugh.

        If you diff through the code, you'll notice about 800 lines in their radar implementation and only minor differences elsewhere (don't name variables after C++ reserved words, etc.).

        It is a proof of concept, but a none too impressive one. It is made even less impressive by the MicroSoft cheerleading found all over their description of the port.

  • What is the port? (Score:5, Interesting)

    by molo ( 94384 ) on Monday July 14, 2003 @10:57AM (#6433958) Journal
    Quake II .NET is a version of the popular Quake II game, ported to native and managed C++ using Microsoft® Visual Studio® .NET(TM) 2003

    Can someone fill me in here? What is the big deal? Id has always used the MS compilers for that platform. So they just updated it to work with the latest release of the compiler. Wow, fancy shit.

    -molo
    • Re:What is the port? (Score:5, Informative)

      by erasmus_ ( 119185 ) on Monday July 14, 2003 @12:14PM (#6434551)
      The big deal is that this new version is now using managed code instead of just native C++. This company did it to illustrate how this can be done, even for large C++ projects. Managed code is run by the Common Language Runtime, allowing for a ton of useful features, which can now be used by Quake 2, or another ported project. A good overview can be found here [microsoft.com], but here are a few from that page to get you started:

      The common language runtime manages memory, thread execution, code execution, code safety verification, compilation, and other system services. These features are intrinsic to the managed code that runs on the common language runtime.

      The runtime also enforces code robustness by implementing a strict type-and-code-verification infrastructure called the common type system (CTS). The CTS ensures that all managed code is self-describing. The various Microsoft and third-party language compilers generate managed code that conforms to the CTS. This means that managed code can consume other managed types and instances, while strictly enforcing type fidelity and type safety. ...

      In addition, the managed environment of the runtime eliminates many common software issues. For example, the runtime automatically handles object layout and manages references to objects, releasing them when they are no longer being used. This automatic memory management resolves the two most common application errors, memory leaks and invalid memory references.


      That last one means your program no longer crashes or takes over all memory resources because of bad resource management.
      • So basically, it's still native Windows-only code, but the .NET features make it 15% slower?
      • by OeLeWaPpErKe ( 412765 ) on Monday July 14, 2003 @12:40PM (#6434811) Homepage
        Quake is a C project. C, not C++, as many have said. This invalidates all of the points you make. Now try again.

        A C framebuffer (that means 2D, and yes quake II is an app that doesn't use any 3D api, it's all in the engine itself the magic happens) app can be ported to everything with minimal effort ( download a few demos and port them to QT, Allegro, SDL, and DirectX), it won't take you very long.

        Also, as the fill rate is the limiting factor, there will not be a very big performance difference in any of the versions.
        • Quake is a C project. C, not C++, as many have said. This invalidates all of the points you make. Now try again.

          Quake2.NET is a C++ project. Not C. That invalidates your point and thus revalidates the original point, that this is a project that can be pointed to as proof that .NET can handle large managed C++ projects.

          A C framebuffer (that means 2D, and yes quake II is an app that doesn't use any 3D api, it's all in the engine itself the magic happens) app can be ported to everything with minimal effort
          • I would like to offer anecdotal support of your point about fill rate. I'm always running out of fill rate before I run out of the ability to compute polys. I always run the low-end nVidia card, though, because they're cheap and they work. (I don't run Linux on the desktop, mind you. I'm actually thinking of making "the switch" in any case.)
      • I read my previous post and decided it may need some clarification.

        The common language runtime manages memory, thread execution, code execution, code safety verification, compilation, and other system services. These features are intrinsic to the managed code that runs on the common language runtime.

        Which of these is missing from C itself ? Okay maybe code safety is not "intrinsic" to the code itself (ie, you'll need a debugging tool like valgrind).

        For the other points ... what exactly is the differ

    • IIRC, Quake I was compiled using DJGPP, or at least that was claimed on the DJGPP web site [delorie.com].
  • by dtfarmer ( 548183 ) on Monday July 14, 2003 @12:04PM (#6434488) Homepage
    but they also say that the managed version initially ran faster than the native version. After changing some optimization settings, the native version now runs 15% faster than managed .NET code

    Anyone else misread that at first to mean they changed optimization settings on the managed code, and now it runs slower than the native version....
  • so where's a bittorrent link to get the Quake 2 demo? ID is slashdotted.

    ftp://ftp.idsoftware.com/idstuff/quake2/q2-314-dem o-x86.exe [idsoftware.com]

    arg.
  • In looking at the linked site I noticed that their port includes a "Quake 2 Radar". This is actually constitutes a new cheat. There was a cheat w/ a radar called the "Z-bot" as well as the ZR-Bot. If you have a radar and no one else does then you can frag them right as they turn a corner befor they know what hit them. The radar is a huge advantage.

    If you play halflife and you have played against wall hackers then this would be the equivalent done in a different manner but with the same end result.
    • In looking at the linked site I noticed that their port includes a "Quake 2 Radar". This is actually constitutes a new cheat. Unfortunately "Cheating" with a GPLd client game is not new nor has to be considered as an issue. Eric S. Raymond has a really nice essay [catb.org] about what happened the day that ID released the Quake 1 sources to the world, and what happens constantly to every damn online game out there. Anyway, someone even thinks as going far as making you voluntarily install spyware on your pc [evenbalance.com] in orde
      • I play BF1942 for the most part now and the cheating is at the bare minimum if any at all. There is the superman cheat but it's relatively lame and you can still kill the person. Counterstrike is the single most frustrating online game ever because of the massive amount of cheating involved. I doubt I'll ever play C.S. again because of the amount of cheating and the lack of anti-cheating options implemented by Valve.
        • I play BF1942 for the most part now and the cheating is at the bare minimum if any at all. There is the superman cheat but it's relatively lame and you can still kill the person. Counterstrike is the single most frustrating online game ever because of the massive amount of cheating involved. I doubt I'll ever play C.S. again because of the amount of cheating and the lack of anti-cheating options implemented by Valve.

          I think Valve was waiting to release his Steam [steampowered.com] platform before stopping cheaters. We will

      • Me thinks you protest too much. I freaking LOVE
        punkbuster. Without it, I wouldn't bother playing
        online at all. It's so pleasing when some moron
        shows up with an ogc bot and gets kicked off. :)
        It just makes me giddy. Granted, not all of us are
        as good as Haku and can DESTROY A BOT [dangpow.com]
        with nothing more than talent and skill. You'll need
        the a recent quake3 to view that demo. It's some
        of the slickest playing I've ever seen.
        • Me thinks you protest too much. I freaking LOVE punkbuster. Without it, I wouldn't bother playing online at all. It's so pleasing when some moron shows up with an ogc bot and gets kicked off. :)

          Hey man! I'm not protesting! ^__^;
          I was only saying that I don't like some spyware-like software being installed on my computer only because there are the usual morons ruining the game for all the others...

          Maybe I am just lucky to have many friends that can bring the PCs to my house and that the Italian community

    • It's not a cheat if everyone has it. In the very
      least, they should make sure that this 15 percent
      slower version of quake2 that everyone will be
      RUSHING to install, is only compatible with itself
      and not prior clients.
      • It's not a cheat if everyone has it. In the very least, they should make sure that this 15 percent slower version of quake2 that everyone will be RUSHING to install, is only compatible with itself and not prior clients.

        Yes, but consider this: How can you keep the 2% of people that can recompile the beast to play with the prior client/servers, since it is all GPLd code? And to share the compiled client with the others? :/

    1. This is a proof of concept that Microsoft's "Managed C++" stuff may be an interesting technology.

      If really Managed C++ isn't too much slower than C given the standard optimizations Managed C++ may become a viable platform for development in the end. We will see what will happen as Microsoft's JIT compiler matures.

    2. If it is viable for Quake 2, it might be viable for any future game coming to PC, XBOX or even Phantom. Remember that having .NET (or Java with JNI as well, see this nice soviet Sturmovik simulat [il2sturmovik.com]
    • don't expect this to be ported on Mono asap, Mono still lacks a Managed C++ compiler

      But the compiled MSIL should run on Mono -- at least if Mono has developed all the class libraries Quake II depends on. So while Mono may not be able to compile it, it should, some day, be able to run it.

  • When they refer to native and managed versions, they are still referring to their .NET build of the project. Although they don't provide any details, these are still both slower than the "original" version. This is from the faq on their page:

    How is the performance of the managed version?
    Initially, the managed version was faster than the native version when the default processor optimization setting /G5 (Pentium) was used. Changing the optimization setting to /G7 (Pentium 4 and Above) created a native v

  • My Question... (Score:2, Interesting)

    by evil-osm ( 203438 )
    Where can I get a copy or at least the list of updated optimizations to the native version? I'd love to get it to run 15% faster on my P200 that I have for Q2.
  • Don't tell me this is a .NET 1.1 port!
    I don't give a crap about that C/C++ conversion/rip, I just want it to run on the _compatable_ version of .NET!
  • So does .Net solve the Multi player problem with allowing ping floods to ruin connections to game servers?

    I think not.

    Dolemite
    _________________

He has not acquired a fortune; the fortune has acquired him. -- Bion

Working...