Stories
Slash Boxes
Comments

News for nerds, stuff that matters

Slashdot Log In

Log In

Create Account  |  Retrieve Password

Quake2 Ported to Java, Play Via the Web

Posted by Hemos on Mon Nov 28, 2005 01:55 AM
from the keepin-it-old-school dept.
casemon writes "Quake2 fans unite! Thanks to German software developer ByTonic software, you can now play Quake2 via the web with Jake2 a java port of ID Softwares seminal Quake2. ByTonic claims performance is similar to original C version. From the Jake2 website; "Jake2 is a Java 3D game engine. It is a port of the GPL'd Quake2 game engine from idSoftware. To use the Jake2 engine you need either the data files from the original game or from the demo version available for download from ftp://ftp.idsoftware.com." You actually don't need to get the data files, they've set it up to automatically download the 38Mb demo assets using WebStart. Just click the Play Now button and away you go. Most features supported, even multiplayer server!"
+ -
story
This discussion has been archived. No new comments can be posted.
The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
 Full
 Abbreviated
 Hidden
More
Loading... please wait.
  • Erm, link: (Score:5, Informative)

    by medgooroo (884060) on Monday November 28 2005, @07:48AM (#14127851)
    http://www.bytonic.de/html/jake2.html [bytonic.de] just thought it might be, you know, handy?
    • Too sad that the idSoftware server is slashdotted and I could not download the data from the webstart program =o(
    • Re:Erm, link: (Score:3, Informative)

      It is awesome what they have did!

      I have a real good computer (memory, processor and video card) but I must tell you, the game runs really fast, you dont have the feeling of running a java application with all those 3 dimensional objects flying around you. You cant tell thats a program being interpreted.

      Great job folks! The Java community has only to earn with this proof of concepts works :)

      I have been there [livejournal.com]
      • Re:Erm, link: (Score:3, Insightful)

        by bentcd (690786)
        You cant tell thats a program being interpreted.
        Java programs don't get interpreted on modern VMs, they get JITed. In some cases, this can result in more effecient code than a precompiled binary such as one created by a C compiler.
          • La, la, la, I can't hear you...

            Bob
          • Re:Erm, link: (Score:5, Insightful)

            by MartinG (52587) on Monday November 28 2005, @08:40AM (#14128160) Homepage Journal
            This is a bullshit argument that generally presumes a substandard optimization by the binary compiler.

            No it assumes that the compiler cannot know the most common runtime code paths (which is true). A JIT engine can of course.

            Even with compilers that read seperately collected profiler data (such as recent gcc which can take gprof output) can only work on that one profiler measurement. Lots of software is highly dependent on usage patterns and so different paths will be run depending on how the user uses the software. Only runtime optimisation can take this into account.

            • Re:Erm, link: (Score:4, Interesting)

              by tedgyz (515156) * on Monday November 28 2005, @09:22AM (#14128461) Homepage
              Right on, brother! The C/C++ bigots just can't accept that a Java program might run as fast as, or (gasp!) faster then a C/C++ program.

              I worked in a compiler group for 10+ years. Profiling was definitely the best way to optimize a program. The challenge was that the compile-profile-compile loop was cumbersome and was hard to account for all use cases. JIT profiling deals with YOUR use case. If it's really good, it will even adapt and re-profile as your use pattern changes.
              • How is it bigotry? (Score:3, Insightful)

                by chaboud (231590)
                The only reason that this posting is news is that, up to now, Java programs haven't been as fast as C++ programs in the general case. Given the overwhelming experiential evidence, it would seem that the Java bigots are the ones who need to make more of a case than "it is faster because I say so." Quake 2 running on Java is a start. Quake 4 having shipped as full Java would have been a big win. That this post isn't being brushed off as non-news bears out my point.

                This is really the conflation of two orth
          • Re:Erm, link: (Score:3, Interesting)

            >>In some cases, this can result in more effecient code than a precompiled binary such as one created by a C compiler. This is a bullshit argument that generally presumes a substandard optimization by the binary compiler. I believe the theory is that the compiler can optimise for, say, Athlon XP, but cannot assume that anything above a 386 (or a Pentium, depending on settings) is being used, so it can't use XP-only instructions/tricks. Whereas the JIT compiler can optimise for the exact processor
          • >>>In some cases, this can result in more effecient code than a precompiled binary such as one created by a C compiler.

            >This is a bullshit argument that generally presumes a substandard optimization by the binary compiler.

            Like it or not, in 10+ years from now most (if not all) applications will be written in either Java, .NET or a similar Framework/Language. C/C++ will only be used where bit-banging stuff is needed AND NO ONE will care about except a few grumpy old man...
            • by CowboyBob500 (580695) on Monday November 28 2005, @08:48AM (#14128216) Homepage
              Exactly. In real life I found that there are 3 types of people who perpetuate the myth that Java is slow:-

              1) .NET developers
              2) People who's last experience of Java was rollover applets in 1996 and who have refused to install a JVM since
              3) Crusty old Unix hackers with beards and rainbow jumpers for whom Window Managers are eye candy and whose idea of a IDE is vi

              Bob
              • by Lagged2Death (31596) on Monday November 28 2005, @09:29AM (#14128518)
                Even with 512MB of RAM, Azureus (the hugely popular Java-based BitTorrent client) takes forever to start up, responds sluggishly to user input, and sucks down so much RAM that the Windows PC it's running on is nearly useless for any other task. This isn't simply the nature of BitTorrent - other clients run far more smoothly.

                Maybe there are reasons for this that aren't directly related to Java. Maybe Azureus just isn't very well-written, or maybe it's just feature-bloated. Maybe the Windows JVM just stinks.

                But in any case, the common perception of Java applications as being slow and ponderous is one that Java applications have earned - there are actual reasons, based on real-world experiences, that cause people to feel this way. That has nothing to do with some pig-headed resistance to change.

                Rather than railing against the Java-haters, why not point out some useful, slick, fast Java-based applications? I'd love to see some. Every one that I've tried so far has been a disaster in one way or another. I honestly want to like Java. I like the language, I love the concept - it's the real-world experience with it that I have a problem with.
                • by FatherOfONe (515801) on Monday November 28 2005, @09:39AM (#14128624)
                  "Rather than railing against the Java-haters, why not point out some useful, slick, fast Java-based applications? I'd love to see some."

                  Um, you did see what the article is about didn't you? Perhaps you should try it out.

                  I have used quite a few Java programs and most perform well.
                  • by Anonymous Coward on Monday November 28 2005, @10:04AM (#14128859)
                    A port of Quake 2 that is slower and uses more memory than the native client that was released seven years ago?
                    • by Anonymous Coward
                      The benchmarks [bytonic.de] clearly show that the java version is as fast as the original C version.
                    • by Alban (86010)
                      You sound like an armchair general talking about how it is in the trenches (posting as an AC, no less).

                      John Carmack is not the greatest programmer, but he is a damn fine programmer. He has shipped tons of games, and shipping games is an incredibly difficult thing. You also have to keep in mind that until quake2 included, he handled almost all major programming tasks (rendering, networking, architecture). Doom is one of the first games I've seen to cleverly use the same client/server architecture whether you
                • Rather than railing against the Java-haters, why not point out some useful, slick, fast Java-based applications?

                  I've had a pretty good experience with jEdit [jedit.org], a Java-based programmer's editor on both Linux and OS X. It's mostly replaced emacs for me now. Although I've only tinkered with Eclipse so far, it's been pretty responsive for everything I've tried. On the Mac, NeoOffice/J (the OS X port of OpenOffice.org, which relies on Java for access to the Cocoa API) seesm to run pretty well. Granted, these ar

              • Re:Erm, link: (Score:3, Interesting)

                by LWATCDR (28044)
                I have developed code in java for a few years now and you are over simplifying the case.
                Where Java has been or still is slow.
                1. Start up. It takes a good bit of time to start a java program because it takes a good amount of time to load the JVM. Not an issue on a sever where the JVM is probably in use all the time but a pain on the desktop. It also makes small utilities a pain in java. The latest version of java seems to start quicker.
                2. Swing. Swing has been slow. The latest version of java seems much bett
              • Re:Erm, link: (Score:4, Insightful)

                by laffer1 (701823) <luke AT foolishgames DOT com> on Monday November 28 2005, @10:22AM (#14129061) Homepage
                I fit category 1 and 3 above and I still think java runs very fast for server based code. Running a java servlet container is very fast. A few applications like jedit, intellij idea and limewire seem fast on the graphical front. Someone can write a slow .NET, C++, or objective c app too.

                Java's benefit is its age and portability. Its fairly mature and very fast when running under the server vm for some time. Quick command line apps are best served with C code. Compile C code with g++ instead of gcc sometime. Not only will your code run slower, but it will be larger as well. Likewise time a Visual C++ app vs a .NET gui app starting up. The advantage of Java and .NET is the massive amount of libraries that are guaranteed to be there. The STL in C++ is not implemented consistently across compilers or platforms. My big complaint with java isn't speed, but organization. I find the namespaces cluttered and confusing compared to .NET. Think about it. They have io and nio. Try to write XML code sometime! Oh god. Java is more portable than .NET though. The price is a consistant namespace layout. Maybe someday if Mono matured to a point it was portable and at least .NET 1.0 compatible we'd see a real shift in software development. I'd use c# in bsd for example. Its great for web development compared to the servlet api.

                If your vision of java is applets think again. No one uses java for applets anymore. If you do, you missed DHTML and its recent variants. Client side code is ignorant anyway. Browsers aren't standarized enough for that yet. Java is good for server side code and if written properly, desktop gui applications.
              • by Keebler71 (520908) on Monday November 28 2005, @12:32PM (#14130296) Journal
                Exactly. In real life I found that there are 3 types of people who perpetuate the myth that Java is slow:-

                Don't you mean that there are 11 types of people?

            • I'd actually think that there is still a good future for native code.
              However, not C or C++. But perhaps something like ocaml, which can compile to bytecode or native code, but has all the niceties of garbage collection and so on. This would be nice, as ocaml is actually type safe (Java's type system has holes in it, but at least it has generics now...)
  • Works pretty well (Score:5, Informative)

    by Anonymous Coward on Monday November 28 2005, @07:52AM (#14127865)
    I saw it at swing sightings. I tried it with the original game files and didn't notice any difference in speed with the original binaries.
    And this with a not so fast computer: PIII 800, TNT 2, 384 MB RAM.
    Anyway if you wanna see benchmarks with older computers look at their web.
  • by should_be_linear (779431) on Monday November 28 2005, @07:59AM (#14127901)
    ... I would give this guy research lab and resources to create java-based DirectX library. For game developers, it would be just great to write once and sell on Windows on Linux on Mac on Playstation (don't know about XBox). Even without Sun's support, it would be great fot 3rd party to sell such engine/framework.
    • ... I would give this guy research lab and resources to create java-based DirectX library. For game developers, it would be just great to write once and sell on Windows on Linux on Mac on Playstation (don't know about XBox). Even without Sun's support, it would be great fot 3rd party to sell such engine/framework.

      You'd have to give it away for free to make *anyone* throw away their well-tested-and-working C++ engines for a Java Version. No matter how fast it is, the java=slow paradigm is burned to deep into
    • by TheRaven64 (641858) on Monday November 28 2005, @08:21AM (#14128047) Homepage Journal
      Java already has an OpenGL interface (presumably what this is using). I don't know what this guy is using for sound (although the Java Media Framework might work), or input, but presumably all of the pieces are already there. What Sun really needs to do is market Java better as a game development platform. Add some code for loading models as OpenGL display lists, and a few other convenience methods and start plugging the platform better. Oh, and relax the licensing so I can run Java on my FreeBSD box without jumping through hoops.
      • Java already has an OpenGL interface (presumably what this is using). I don't know what this guy is using for sound (although the Java Media Framework might work), or input, but presumably all of the pieces are already there.

        Yes, probably JOGL [java.net] for the OpenGL. For sound, core Java can handle raw PCM, and JOAL [java.net] (Java Bindings for OpenAL) can sit on top of that. Java Media Framework is useless and effectively dead. Input can be handled by JInput [java.net].

      • Still, there are things that needs to be addressed:
        - Multiplayer should allow voice and webcam communication.
        - There should be Servers and bandwidth available for Multiplayer games.
        - All parts of this library must be able to run on Windows/Linux/Mac/Playstation (including JRE and SPU support on PS3)
        - There should be new graphic instructions in Java JRE (based on OpenGL API) that directly maps to OpenGL driver and don't need RMI layer.
        - There could be "iTunes for games" service that provides all game
  • Yes, but does in run (Score:2, Interesting)

    by Kj0n (245572)
    in Firefox [slashdot.org]?
  • works on a mac (Score:2, Informative)

    by Anonymous Coward
    Runs great on my 1.2 GHz G4 with 640 MB of RAM in OS X 10.4.3. Running the web start version downloads a file which starts up as a separate java program.

    This is the coolest use of Java I've ever seen.
  • Quake 2 seminal? (Score:3, Insightful)

    by Malc (1751) on Monday November 28 2005, @08:20AM (#14128040)
    No, I don't think so. Perhaps if you were born after 1985. Wolf 3D and Doom were the seminal games, or perhaps even Ultima Underworld, although nobody seems to remember that one. There were many games in the genre making it appear tired and unoriginal long before Quake 2 came along with a bit more of the same.

    I've played Quake 2 than all the rest put together, but that doesn't make it seminal.
    • by Antonymous Flower (848759) on Monday November 28 2005, @08:32AM (#14128116) Homepage
      Quake 2 was the first game designed for and supporting 3d acceleration out of the box. In this way it is certainly seminal. So much so, in fact, that 3d acceleration is no longer a part of the collective consumer consciousness :)
      • I think what you've described, and the features described by others in their replies are just part of the natural evolution of the same concept. I was bored and fed-up with FPS games before Q2 came along. It sucked me back in for many more years. But that didn't make it seminal as a game. It was more of the same, just with better graphics and more refined controls.

        The advances made at ID Software in computer graphics are impressive. Unfortunately a lot of games are afflicted by an obsession with the gr
    • Re:Quake 2 seminal? (Score:3, Interesting)

      by Chrontius (654879)
      If you consider Quake2 as the first game to really make it while introducing proper mouselook to the masses, yes it is. Duke3D had it, but it was wonkky enough to make me seasick so it never got used. Quake2 gave you the ability to do much more with it than anything prior, even Quake, where it was not really needed and played by the best gamers I know with pure keyboard.
    • Wolfenstein 3D and Doom aren't seminal. Marathon was seminal. It was the first one that actually had a story and puzzles to figure out. Wolfenstein and Doom aren't even in Marathon's league when it comes to gameplay.
    • Perhaps he meant Quake 2 was seminal towards id's use of more than brown and green in the color palette.
  • dupe (Score:2, Informative)

    by tduff (904905)
    dupe [slashdot.org]
  • Performance myth. (Score:3, Informative)

    by adolfojp (730818) on Monday November 28 2005, @08:44AM (#14128188) Homepage
    Jvm apps can be faster than their compiled counterparts, specially when compared to those made with non specialized compilers like GCC. The "virtual machine = slow" myth is no longer true.

    The real issue is startup time and initial memory consumption. Java is not suitable for applets that run in the background because your basic app will require about 20 megs of RAM minimum to start. Another issue is swing. You can disagree with me, but please wake me up when it gets clear type fonts on windows.

    Cheers,
    Adolfo
    • by Anonymous Coward
      Mustang (Java 6) which is under Open development (not quite open source license) already has wider support for clear type than Microsoft... So you are right its a bit late but people have invested work into that.
      Swing is not slow or bloated, it just can't be compared to the native OS size since it duplicates its functionality so its memory usage seems high in the task manager. Startup time and cold start is improving with every release and building serious client side Java applications is becoming a very re
  • by Numen (244707) on Monday November 28 2005, @09:03AM (#14128324)
    Can we get a comparison of the Java and .NET ports of this?

    The .NET port can be found at http://www.vertigosoftware.com/Quake2.htm [vertigosoftware.com]
  • by Anonymous Coward
    Most users that played Quake2 did not have hardware with builtin 3D acceleration. So the folks at idsoftware improved their already outstanding software rasterizer for Quake2, which provided almost identical rasterizing performance on then-highend machines compared to modern 3d cards at that time.
    If the Java version would do the same, then I would take my java performance prejudices and dump them.
  • by FerretFrottage (714136) on Monday November 28 2005, @09:30AM (#14128536)
    Q2Java [planetquake.com] was a port of the Q2 game logic and used JNI IIRC to interface with the game engine since 3D graphics support and serious sound support for Java was still nascent if existing at all. I wonder how hard it will be to port my "grapple the head mod" over to this version?

  • by bored (40072) on Monday November 28 2005, @10:40AM (#14129253)

    I have two points.


    Comparing a static C binary, with a JIT is sort of silly. Logically comparing a JIT with a C binary compiled with profile based feedback optimization is probably more legitimate.

    Secondly, the released Quake engine had a couple of assembly routines. Proving that C wasn't always the best choice, even back then. My understanding is that the versions of quake with assembly loops are roughtly 30% faster than the C only version they are comparing this with.

    In the end these sound like good results, I'm continually amazed at how fast java has gotten. The fundamental arch is pretty much broken for generating fast binaries, and it speaks volumes about the quality of the coders writing the JIT engines that they can make a stack based compilation target run fast on modern processors.



    Oh, one final thing, did anyone see what C compiler they used for those numbers? I'm currious if it was the same compiler ID originally used, or one of the more modern intel compilers?

    • by Anonymous Coward
      Actually, it runs pretty quickly, although not quite as quickly as the original. Something like 85-90%. That's mostly because of the overhead of calling into the OpenGL libraries from Java, and because Quake 2 was written at a time when 3D games were fillrate limited, not CPU limited. Back then, the extra overhead of sending models one vertex at a time was essentially zero, because you were still sending the data faster than the graphics card could render it. With modern graphics cards, Quake 2 becomes CPU
    • There is no way to write and read from lots of memory quickly in java is there?

      Yes, Java came out with Native I/O API (NIO).

      All benchmarks that I have looked into that show that Java runs faster then C/C++ are extremly heavily biased towards making Java look good.

      I've read similar reports of .NET being better than Java. Even newer reports show that Ruby is better than .NET. I guess Ruby is the best there is. Expect a Ruby port of Quake that runs faster than the original C version ;)

      Correct me if I am wro