Page 1 of 1

BZFLAG in html

Posted: Sun Oct 14, 2007 8:05 pm
by Benji
I think it would be cool if the bzflag client could also be written in an html code so people could post the game onto their website. Is this possible?

Posted: Sun Oct 14, 2007 8:33 pm
by A Meteorite
Um, no.

But patches are welcome.

EDIT: In case you weren't aware, this is not even technically feasible. HTML is a mark-up language for presentation. That's it. BZFlag is such a complex game, it couldn't even be programmed in JavaScript (well, you could, but no one would want to, and it'd be thousands of times as slow as the real compiled C++ client). The only feasible port would be Java for inside a browser, but even then it would not be a particularly fun to program (or play) port. Of course, if you really want it, patches are always welcome. :)

Posted: Sun Oct 14, 2007 9:53 pm
by Winny
HTML is, as A Meteorite said, is only code for presenting something... there is no logic involved.

This is an example of basic HTML

Code: Select all

    <div>
      <ul>Catagories
      <li>Photoshop Tutorials</li>
      <li>Tech News</li>
      <li>Wordpress Templates</li>
      <li>Misc.</li>
      </ul>
   </div>  
Note how there is no "logic", nothing saying "If A is equal to B, then Run C", or something like that, anyways...

Now, here is an example of a language with Logic (In this case, PHP)

[ Darn... PHPBB won't let me insert PHP... find it here: http://home.kyleve.net/phpexample.txt ]

Although they may appear similar (in the basic structure, anyways), they do two very different things.

Posted: Sun Oct 14, 2007 10:00 pm
by Benji
Thanks guys. I was wondering this because you see some Miniclip and other websites games written in html for the public to post that game to their website. I know BZflag is more complex then these games so it would be harder to do. I also know it would never be as great as playing in the real client but for people who just want to try BZflag with out downloading anything this might be helpful. Thanks again for your help.

Posted: Sun Oct 14, 2007 10:02 pm
by macsforme
A JavaScript client wouldn't be too bad for a 2D client, I think... but again, what's the point? It would be an awful lot of work.

Posted: Sun Oct 14, 2007 10:02 pm
by Winny
Benji
That is _not_ written in HTML....

You simply imbed the game into the webpage with HTML. Once again, as Met said, the game itself is written in either Flash, or Javascript.

Posted: Sun Oct 14, 2007 10:06 pm
by Benji
O I see.

Posted: Sun Oct 14, 2007 11:23 pm
by L4m3r
A cheesy pseudo-3D Flash client could be fun... still not worth the effort though. :p

Posted: Sun Oct 14, 2007 11:42 pm
by F687/s
Better yet, you could make a web client that sends exactly would you type in to the server, and you receive what it says. Think of it as BZAssembly.

Of course, we all know that this is never going to happen. I'm fine with the client, and I am anti-Flash (in today's world, we call it pro-Desktop). I've endured a ton of flash crap, so I wouldn't really expect much from the game.

Unless it was written in Perl. Then it would be a different matter.

Posted: Mon Oct 15, 2007 12:17 am
by Tanner
F687/s wrote:Better yet, you could make a web client that sends exactly would you type in to the server, and you receive what it says. Think of it as BZAssembly.

Of course, we all know that this is never going to happen. I'm fine with the client, and I am anti-Flash (in today's world, we call it pro-Desktop). I've endured a ton of flash crap, so I wouldn't really expect much from the game.

Unless it was written in Perl. Then it would be a different matter.
If you're speaking of a web BZAdmin, AAA has already created something like that in his server management software using his BZFlag_Info and AJAX.

-Tanner

Posted: Mon Oct 15, 2007 1:23 am
by Joe-Schmoe
I guess the point would be that you don't have to download anything to run the game.

That's useful for people like me who are paranoid about security/safety issues, or if you're using the game on a public computer such as in a library.

Also, since it's embedded into a webpage, you could have stats, buddylists, and all sorts of other stuff around the edges, though this can probably be done anyway by opening a browser and playing the game windowed. Or maybe certain servers only serve to clients in a browser on their site. That way they can sell ad space.

Posted: Mon Oct 15, 2007 4:14 am
by blast
As far as I know, Flash does not have TCP/IP socket support... and, what is the point? Copy a recent (ex: 2.0.10RC3) BZFlag onto a USB stick and use a portable launcher application to pass it the proper -confdir location. BAM! Portable BZFlag...

Posted: Mon Oct 15, 2007 7:23 pm
by F687/s
> If you're speaking of a web BZAdmin, AAA has already created something like
> that in his server management software using his BZFlag_Info and AJAX.


That was kind of a joke. I meant something along the lines of netcat.

The one thing that perplexes me is...why are we even talking about this if we all know it's not going to happen?