Google Gets Quake II Running In HTML5 258
Dr Herbert West writes "A trio of Google engineers have ported id Software's gib-filled first-person shooter Quake II to browsers — you know, for kicks — as a way to show just what HTML5-compatible web browsers are capable of. According to the developers, 'We started with the existing Jake2 Java port of the Quake II engine, then used the Google Web Toolkit (along with WebGL, WebSockets, and a lot of refactoring) to cross-compile it into JavaScript.' More details are available on one developer's blog, and installation instructions have been posted as well."
Installation Instructions? (Score:2)
Now it's time to go RTFA.
Art is not redistributable. (Score:5, Informative)
From the project FAQ [google.com]:
We are as yet unable to provide a public demo link. The Quake II code is GPL licensed, but the demo resources (textures, models, sounds, et al) are not, so we cannot simply upload them to a server. We are pursuing legitimate avenues to do so, though -- stay tuned.
Make a new level! (Score:2)
There's GOT to be some good levels, characters, weapons available under Creative Commons. How about stealing some from OpenArena?
Re: (Score:2)
I think you'll have a hard time finding a level that doesn't use even a single of the original game assets.
Re: (Score:2)
Not hard, if you're willing to go to Quake3 games -- Nexuiz, OpenArena, Tremulous, World of Padman...
The question is whether those can be backported to Quake2.
Re: (Score:2)
Well, a better plan would actually be porting ioquake3, and including the latest speex and OpenAL 3d positioned VOIP. But I'm sure you could down sample the openarena stuff quite easily to a q2 format if you weren't willing to instead bolster the engine.
Re:Installation Instructions? (Score:5, Interesting)
Re: (Score:2)
It's one of those hacks that is cool because it's deeply wrong, not something that is in any way sensible.
You apparently don't fully understand the bane on existence that flash is. The POC is as a flash replacement, not as a platform for replacing your xbox/ps3/wii.
Re:Installation Instructions? (Score:5, Interesting)
Re: (Score:2)
Still, OpenGL/WebGL is pretty well suited for pixel-based 2D stuff too.
Re: (Score:2)
Re: (Score:2)
Flash sucks, no doubt. But the development tools are great. That's where Flash really shines--any idiot can build a flash game.
When there are tools to easily build JS+Canvas+Websockets+audio+HTML5, then you may see the beginning of the end of Flash.
Re:Installation Instructions? (Score:5, Informative)
Also, it presently needs a dev version of chrome started with a command line parameter that disables some sandboxing features.
Interesting (Score:2)
The most recent Jake2 release was comparable and faster in some situations than the native C version.
I wonder how the javascript version stacks up to the Java and C versions.
Re: (Score:3, Informative)
Oh, Jake2 benchmarks: http://bytonic.de/html/benchmarks.html [bytonic.de]
Re: (Score:2)
That graph compares "original C code" to a Java version using jogl. Does the original C version of Quake use OpenGL or software rendering? If they are comparing software-rendered C to OpenGL accelerated Java, that's a silly comparison. Or am I mistaken about the original C version?
Re: (Score:2)
The benchmarks are against the hardware accelerated OpenGL path of Quake2.
I agree, benchmarking the C software renderer against a hardware accelerated Java renderer would be a joke. :)
Re: (Score:2)
I just didn't want some douche bag crying about how I lacked a reference. ;)
How about Urban Terror? (Score:2, Informative)
How about OpenQuartz? (Score:4, Insightful)
No you can't. QuakeLive requires a "browser plugin" which defeats the whole point of playing in a browser. You don't get any of the advantages, like sandboxing, cross-platform, or no installation required.
This article is about running Quake in a browser, which is pretty dang cool, if not really practical. Also, it's not really about Quake or FPS so much as HTML5.
Urban Terror was a good suggestion. They probably could have gotten permission to distribute it if they asked. I would have suggested OpenQuartz, which is GPL. It's only half a level, but that's plenty for a demo.
Re: (Score:2)
Also, it's not really about Quake or FPS so much as HTML5.
No, in fact this is almost ANTI HTML5.
The only HTML5 here is the final rendering is occuring in an HTML5 Canvas. This is NOT HTML5 and this is not truly running the game in a browser as you suggest as it is relying on WebGL and other libraries to produce a final render to the HTML5 Canvas.
If this was an HTML5 demonstration, it would be using PNGs, SVG, and CSS to create the game not just rendering to a square HTML5 canvas element.
On Windows Vista or Windows7, I could write code in a couple of minutes using
Re:How about OpenQuartz? (Score:5, Informative)
WebGL and other libraries
WebGL isn't a library, it's a binding. It does bind to native OpenGL (if the browser supports that), and while it may not be strictly HTML5, it is in line with the HTML5 goals -- to make the browser itself the platform, without relying on plugins.
If this was an HTML5 demonstration, it would be using PNGs, SVG, and CSS to create the game
Fair enough, though that would be much slower.
Wow, almost as impressive as using activex rendering DirectX content that we first saw in the freaking 1990s.
Yes, because ActiveX is a nice, cross-platform standard with multiple open source implementations... Oh wait.
Read that again until it sinks in, by the way.
Cross-platform -- WebGL runs on Windows, Linux, and OS X, at the very least, and likely on the iPhone. Your attempt to pretend this is a Google-vs-the-world thing falls flat.
Standard -- WebGL is managed by Khronos, who maintains OpenGL itself -- the working group includes Apple, Google, Mozilla, and Opera.
Multiple open-source implementations -- Firefox and Chromium both support it in some dev build or other. That also means Gecko and Webkit, which means dozens of other browsers.
WebGL embedded in a browser or used as a plug-in is NOT the browser's rendering engine doing the work.
So what?
And for what it's worth, it is useful that it ends up on a Canvas. Unless I'm mistaken, that means it is composited with the rest of the document, meaning you could (for example) draw your HUD using standard HTML and only use the GL for the 3D. Please explain why this is a bad thing.
Quake Live (Score:2)
Re: (Score:3, Funny)
This is what Quake Live should have been!
It should have been turn-based? ~
It doesn't count if it can't play Doom (Score:2, Funny)
It doesn't count if it can't play Doom
Re: (Score:2)
DOOM FTW. It is my favorite id Software game (Wolfenstein 3D is second) and one of my favorite computer games.
Benchmarks (Score:2)
Die Flash games! (Score:2)
The thing that is killing my old iBook G4 are the bloody Flash games that my wife wants to run on it. The thing is still perfectly capable of doing most stuff but Flash is such a resource hog and the OS X version of Flash so poorly optimised, especially since they released Flash 10 for Mac which made the PPC performance much worse. I'm tempted to get an iPad but the lack of Flash would upset her indoors but I think lack of Flash is a bonus. Anyway, if all these Flash game writers started porting over to
Re: (Score:3, Insightful)
Simply isn't going to happen until someone writes a development environment on par with Flash's, which doesn't seem to be happening any time soon. Chicken and egg problem. There's no interest in moving off Flash until the tools are there and nobody wants to write tools until there's interest in them.
Re: (Score:2)
Well the lack of tools is certainly a gap in the market that some party could cash in on right now with a pretty big payoff long-run.
This makes it look like GWT is becoming a candidate. Also based on some of the assertions made recently by Adobe in the vein of "we're in the creative tools business, not the technologies business" I think they may jump on board the HTML5 train soon as well.
Re: (Score:2)
Saved Page For Offline... (Score:2)
I wonder if a browser game like this would work if you saved the page for offline access.
Re: (Score:2)
I'm not sure about android and chrome, but in the iPhone + Safari, there is away to make your web apps downloadable and useable offline.
Javascript is becoming an assembly language (Score:5, Interesting)
It may be hard to understand the significance of this if you are not immersed in the hell that is web front-end engineering. Javascript in isolation is not as bad a language as people make it out to be, but supporting common browsers and fixing all bugs as you're writing it is terrible. It is an incredibly hostile development environment.
The dream, from a developer's perspective, is this: In 3-5 years (this is the dream part given how fast the web changes), Javascript is an assembly language. You don't write it unless you really need to dig down to the "bare metal" of the browser itself. You compile to it from your language of choice. Your compiler spits out Javascript and any HTML/CSS containers required to skin your app and allow it to render in the browser. Your application can be linked to and run directly in the browser with no Flash, no Unity3d, no JavaFX, no plugins or installation required.
That no plugins are required is incredibly significant from the perspective of a company trying to distribute a product to as many people as they can, as cheaply as they can. Losing 20% of potential users because you required an installation of them is unacceptable--this increases your marketing costs by at least 25% and dampens the spread of your application via word of mouth, email, Facebook sharing, or whatever viral channels you happen to be using. This is why new 3D browser plugins are not succeeding. Unless it's Flash, no one has the plugin you need and you can't get them to install it reliably enough.
As someone who is frequently made miserable by having to support stupid browser oddities, I would kill to be able to write an application in Python, C#, or Java and know that I can compile to a package supported by >90% of people on the web. Yes, running complex stuff in Javascript is slow. But as seen in Chrome and Firefox, it's getting faster. Much like writing in assembly versus higher-level languages, writing Javascript directly will always be faster than compiling from another language. But at what cost to your time and sanity?
In 2010, my real options for rich content on the web are (1) Javascript/Browser Support Hell and (2) write a Flash application instead. That #1 is so miserable is one of many reasons for Flash's continuing success. The dream shown by this demo and others is that we will get a real Option 3.
Re: (Score:2)
Let me guess: you're John Dvorak... ?
Re: (Score:3, Interesting)
Tried Pyjamas [pyjs.org]?
Re: (Score:2)
This is exactly how ZK Framework and GWT work, you just write you programs in Java and they generate Javascript for you while taking into account browsers incompatiblities and indeed I believe it's the future if Web development.
Re: (Score:3, Interesting)
I agree that Javascript is quickly becoming an assembly language. GWT (the tooling Google used to get Quake running in Javascript) is exactly that. Java code is compiled to "native" Javascript.
Although, what you say about browser oddities is largely irrelevant with the usage of toolkits like jQuery, Prototype, Dojo, etc. Instead of targeting the Javascript DOM API, you target your toolkit's API. The DOM API is the part that differs between browsers, except for a few very rare cases. Targeting a toolkit
Re: (Score:2)
No Flash and no Java (Score:2)
I don't know why some knee-jerks tagged this article as "Java". It's not running on Java. It uses JavaScript. It doesn't use Flash either. It's pure browser code.
Also read this part of the developers' blog post:
What this means for the Web
For years, people have assumed the browser was a poor platform for this kind of thing, and that you'd need something like Flash, Silverlight, JavaFX, or native code. While it is true that you should not expect the browser to rival triple-A titles like Far Cry or Call of Du
Re: (Score:3, Interesting)
``In other words, goodbye Flash and Java applets. And die already.''
Personally, I'd much rather have had a good, efficient, open-source plugin for interactive multimedia, based on open standards.
Yes, it's nice that we can emulate that with existing web standards, but, really, why has nobody actually built a good platform specifically tailored for the things we're now using JavaScript, HTML, and HTTP for? Java was close, but too bulky. Flash was great, but proprietary. AJAX is open, but horrible from a techn
Re: (Score:2)
What part of the linked articles mentioning Google Web Toolkit did you miss?
GWT translates source code in Java to html and js. In this case Jake2 is written in Java, and has been massaged into GWT friendly code.
Hence the 'Java' tag.
Apps in a browser (Score:2)
And this, my friends, is why something like the iPad is going to take off ... big time.
Google is really pushing this "browser as a platform" concept to the limit. Now imagine a "GooglePad" or a "ChomePad" or something which does nothing but browse the web. You click on a link and within seconds you're gaming at 60fps. Control-scheme aside, I think this concept will be succesful.
MMORPG in a browser, anyone?
Y
HOWTO for Mandriva 2010 (Score:2)
I hate how people who should know better assume that everybody runs the same Linux distro that they do and fail to write HOWTO instructions intended for a wide audience in a generic manner.
At http://maximumhoyt.blogspot.com/2010/04/quake2-in-browser-in-mandriva-2010.html [blogspot.com] there are Mandriva-ized abbreviated instructions which are useful if you use Mandriva (or a Mandriva derivative) and want to try this out as well.
But I do have an error and Quake2 won't display (I get an Aw, Snap! in Chrome), so any feedbac
But can it run Linux? (Score:2)
Has anyone invoked this meme yet? I don't see it. It's relevant in this case because we really are seeing stuff that used to be native code done in the browser. If there's not a C->Javascript translator already then soon there will be. Google's native client can run compiled code. It's starting to look like we can expect a Linux kernel running in a web browser in the next few years. Not obviously that useful but would be cool and you can bet that people will find things to use it for ...
Better Idea. (Score:2)
I like a good fps as much as the next guy. I really do, I'm an Urban Terror junkie. It's quake 3 tech, but very similar gameplay. However, it seems like we could have better uses for this technology:
http://slashdot.org/comments.pl?sid=1588910&cid=31546834&art_pos=5&art_pos=5 [slashdot.org]
Standard Benchmark ? (Score:2)
So now, we can use Quake to benchmark browsers, instead of Acid2 or some Javascript libraries. Yay !
Seems pretty iffy. (Score:2)
Looking at their web page, you can't run it in a browser from the web, or by downloading it. You have to download it and build it, and people are reporting all kinds of problems getting it to work.
What's actually going on behind the curtain?
Re:OMGLOLWTF (Score:5, Funny)
wan't
I think that's the popular contraction of "wang" and "not." Am I correct? If so, your sentence doesn't make sense.
Re: (Score:3, Informative)
Re: (Score:3, Funny)
Re:OMGLOLWTF (Score:5, Insightful)
Because you can.
Re: (Score:2)
Re: (Score:2)
It's exactly this type of cross-platform thinking that kills PC games and makes consoles attractive. Hey, why use DirectX when you can just up the hardware reqs and run it in the browser?
And on the other end, are you seriously planning to run a 3D game in a browser on a phone?
Re: (Score:2)
Re: (Score:2)
Hey, why use DirectX when you can just up the hardware reqs and run it in the browser?
*facepalm*
Not that it wouldn't up the hardware reqs, especially with the current state...
But Google is working on a standard for native code in the browser, which would make the browser a safe sandbox for entirely native, full-performance games.
And it is OpenGL. Are you seriously implying DirectX is faster than OpenGL?
And on the other end, are you seriously planning to run a 3D game in a browser on a phone?
Not only am I planning on it, I'm planning for it to work well.
Re: (Score:2)
"It's exactly this type of cross-platform thinking that kills PC games and makes consoles attractive."
Yep, you're going to enjoy playing your web-browser FPS on that controller while I beat you down with a dedicated keypad and laser mouse.
Re: (Score:2)
why wouldn't you?
netbook + small SSD + browser-based full PC game = fun times
Re: (Score:2)
For now, you may have a point...but eventually, full games will be natively coded to be browser-based without any extra plugins.
That was what I was referring to, not this version of Quake II specifically. For what it's worth, the "original" Quake II runs quite well on just about any decent netbook out there.
Re: (Score:2)
I sincerely doubt it. Javascript is, as the name implies, a scripting language. It has the same problem as with other scripting languages: it's easy to hack something together, but as the size of the project grows, that same feature makes it harder and harder to keep the whole thing from collapsing into a rats nest lined with spaghetti.
The awful fact is that most programmers are m
Re: (Score:3, Insightful)
Javascript is, as the name implies, a scripting language.
At the time, that distinction was relevant. It isn't anymore.
it's easy to hack something together, but as the size of the project grows, that same feature makes it harder and harder to keep the whole thing from collapsing into a rats nest lined with spaghetti.
Here we go...
You can write COBOL in any language, and you can write good code in any language. If you don't have the discipline for Javascript, you could always write a preprocessor that forces it on you, but I think you'll find that knowledgeable programmers using it on real projects don't tend to have these problems.
The awful fact is that most programmers are mediocre and need handholding from the language to produce good or even okay code.
Another fact is that this same handholding slows down good programmers until you only have mediocrity everywhere. I don't think it
Proof of Concept (Score:5, Insightful)
The purpose of something like this is to push the boundaries of what can be done in web development as a means of determining where it falls short, and what needs to be done to allow efficient practical applications in the future.
Re:Proof of Concept (Score:5, Insightful)
So does this mean the folks whining about "flash is needed for cheap space invader games" can go away now?
Re:Proof of Concept (Score:5, Funny)
For the love of God, I hope so.
Re: (Score:2)
that's a proof of concept, a technical demo... but I agree with you, I don't need it in my webbrowser.
Re: (Score:2)
This is really cool and awesome, but why would I wan't to run this on my browser?
From your implied lack of interest in things technical and nerdy, I would venture a guess that you (you personally) would NOT want to run this in your browser.
Re: (Score:2, Informative)
Re: (Score:2, Offtopic)
Or an applet version: http://download.java.net/javadesktop/plugin2/jake2/ [java.net]
Re: (Score:2)
Javascript != Java. That link if for the Java version, not the HTML5 version which is the current topic.
Re: (Score:2)
yeah but the Java version is basically the same thing according TFA and it works now in 95%+ of peoples browsers AND its an order of magnitude faster.
Re: (Score:3, Insightful)
Re:Demostration of what? (Score:5, Informative)
The Java version of Jake2 runs at around the same speed as the native C version (sometimes a little slower, sometimes a little faster):
http://download.java.net/javadesktop/plugin2/jake2/ [java.net]
Re: (Score:2)
Yes, considerably: http://en.wikipedia.org/wiki/Java_version_history [wikipedia.org]
Re: (Score:2)
The vast majority of the items apply just as much today.
Mono does this for one.
Not really. A nice chunk of the .NET platform isn't implemented yet in Mono (unimplemented exceptions) and a sizeable part of that will never be implemented due to manpower and patent reasons. In addition, Microsoft's .NET platform is not open source and Mono is not the same thing (see last sentence).
I think Mono is a good thing but it's not even close to supporting the type of WORA support that Java enjoys today. Write Once, Debug Everywhere used to b
Re: (Score:2)
Unfortunately, now that Oracle has acquired Sun, I'm pretty sure Java will be perverted and tied into Oracle's database products. Oh well, it's about time to learn LISP anyway...
Well, it would if developers stopped using look and feel changer to emulate the host system. At least the GTK versi
Re: (Score:2)
Yeah hopefully Oracle maintains the status quo but Ellison definitely has the Blofeld vibe to him.
I prefer SWT myself. I don't like Swing much in any of it's forms.
Re: (Score:2)
If ORACLE tries to tie Java to their database as you suggest it would kill Java. Java is one of their more valuable properties, it was probably THE reason to buy Sun. ORACLE is not stupid they won't do that.
To much of the Java ecosystem is on IBM iron and talking to DB2. ORACLE would much rather have thriving Java community then pick up a tiny number of database sales.
Re: (Score:2)
(Primarily a .NET developer myself)
No nullable primitive types.
They have them for primitive types, actually, and had for ages - java.lang.Integer for int etc.
Since Java, unlike .NET, doesn't have user-defined value types, they didn't need to come up with an extensible scheme to derive a nullable type from any random value type. And for a fixed set of primitive types, it's easier to just hardcode the reference type wrappers.
Not sure if you can use a string for a switch statement
You can't. There are some plans for Java 7, apparently.
Do you have attributes? Instead of the ugly getters and setters?
If you mean "properties", then no, they don't have them.
If
Re: (Score:2)
No, that's not the same thing. Integer (and Long, etc) are objects, not primitives. The GP's point was that in Java you can't say e.g.
int i = null;
I've not tried that (and don't have a JDK installed on this machine) but I would expect a compile-time error. (I've not tried it in C# either for that matter)
Re:Innovation (Score:5, Interesting)
Re: (Score:2)
you mean we are reaching the performances we had 15 years ago instead of 20 ?
Re: (Score:3, Informative)
Re: (Score:2)
This is probably why Duke Nukem 3D was my friends and my FPS of choice (it had to compete with Warcraft 2 for multiplayer playtime, though).
Re: (Score:2)
I had a friend who played quite a lot of Quake on a DX2 with (IIRC 8MB RAM, may have been 12 or 16 though, but I think it was 8). It ran at about 15fps - playable for him, at least. Caveat: he unloaded almost everything (custom "Quake only" cmd.com and the like) and ran the game in the "postage stamp" size "window". It was hilarious to watch: he would sit about 3" from the screen.
Re: (Score:2)
Re: (Score:2)
Quake was listed as officially unsupported on anything less than a Pentium, and they recommended that it be run on a Pentium 75. That was the only way to be sure that the infamous Pentium FDIV bug didn't rear its misshapen head. It's hard to believe Quake would be in high school by now if it were a person.
Duke3D definitely ran faster - on a system meeting Quake's minimum specifications you could get away with running in 640x480, or other lower resolutions if your graphics card supported VESA 2.0 and were
Re: (Score:2)
Re: (Score:2)
Keep in mind Duke3D wasn't actually 3D. It was based off the doom ID engines (heretic and such). Quake II was, you know, actual 3D.
Re: (Score:2)
Re: (Score:2)
Even Quake one would barely run on a 486.
Re: (Score:3, Funny)
I hear you. But wait until someone ported Chrome to Chrome! They may ask Xzibit on how to do it. ^^
Sup dawg, I herd u liek innr platformz, so we put a browser in yo browser, so yo can waste resources, while wasting resources!
Re: (Score:2)
Re: (Score:2)
The iPad doesn't support Flash, but it does support HTML5 , so we can totally Quake II on the iPad... because you know we can... and have lots of money and free time.
I am rich
I deserv it
I am good,
healthy &
successful
Re: (Score:2)
Can anyone confirm that this would work on the iPad? I mean, any HTML5 compliant browser should be able to run this shouldn't it? The iPhone/ITouch? (Granted a slide show) .. Just curious.
Re: (Score:2)
Yes, the original blog post was, in fact, posted on April 1.
Re:Why do I have to install something for a browse (Score:3, Interesting)
Uh, those are the instructions for running the server. You don't need any plugin for the web browser.
I guess they don't want to handle the bandwidth required for letting thousands play Quake 2 over their link (legal questions aside).
Re: (Score:2)
See here [wikipedia.org].
Re: (Score:2)
protip: fragging used to be called getting gibbed. It's the internal name they used for Quake 1 when body parts flew all over the place.
Re: (Score:2)
Er, it's for chromium. Learn to read, please.
Re: (Score:2)
yeah because they wouldn't have wanted to show off their GWT stuff...
Although, this was more of a, this sounds like a neat hack, let's do it, than anything else.