Page 1 of 1

Dungeon Master Javascript

Posted: Tue Apr 06, 2010 1:25 pm
by Taghor
Hi there!

been a few years since i posted...

I wrote a DM/EOB clone a few years ago though never got around to polishing it...

An earlier post gave me an idea to do this...

I spent a few nights fiddling around with Java script here's what i came up with ...

http://joesblog.me.uk/v/DungeonMasterJa ... /Main.html

As far as i am aware it works in all modern browsers.. even somewhat on the iPhone...

Current Features:Basic traversing of the dungeon, Wall text, Events and some basic form of lighting..however that's a bit giggery pokery..

Any comments / thoughts would be appreciated.. p.s. sorry for not really commenting the code :P I'm quite lazy at that..

Thanks!

Joe.

Re: Dungeon Master Javascript... My version

Posted: Fri Apr 09, 2010 12:44 pm
by Erik Bauer
Looks and plays very pretty. I like the colour gradients you used for darkness.
Keep on!

Re: Dungeon Master Javascript... My version

Posted: Tue Apr 13, 2010 1:34 am
by Taghor
Hi Again..

Thanks Erik for the kind comments :)

Just a recent update for anyone that is interested.. i kind of have doors working, not as generically as i would like, the logic just needs to be finished its just finding the time to do it.. though one night this week I mite give it a go..

After i have the doors working im not sure what to do next, possibly items as that would be something worth while..

I do intend to in the end have either a dungeon community sharing map ideas and such...
Possibly a multiplayer aspect, that all depends on how fast or rather how effeciently i can create and handle JSON requests..something i have not even looked at yet.

A side note, things may look a bit messy now on the HUD/GUI as i have had to accomidate for Internet Explorer's lack of CSS Compliance...although the game plays fine in IE its visuall better in Firefox/Chrome.

once again any comments, thoughts or oppinions are allways appreciated :P

Thanks again,

Joe.

Re: Dungeon Master Javascript... My version

Posted: Tue Apr 13, 2010 1:44 am
by Gambit37
Impressive stuff! Runs very well in Chrome. Do you think you'll turn it into a complete game, or is this a proof of concept?

Re: Dungeon Master Javascript... My version

Posted: Tue Apr 13, 2010 11:50 am
by Taghor
Thank u!

I do intend to make it into a complete game, the development of it has happened far faster than I expected...

My big evil main problem i can see at the moment will be the sound engine.. how to make noise using a web browser.. i thought along the lines of using an embedded HTML object or something.. i really want to avoid using flash at all costs as this would reduce the compatibility of the game somewhat..

The first real test when i *touch-wood* get everything working to an alpha stage will be to attempt to recreate the first few levels of DM1

Re: Dungeon Master Javascript... My version

Posted: Tue Apr 13, 2010 2:29 pm
by Gambit37
Yep, sound will be a big problem unless you use Flash. Another option is HTML5 though I'm not up-to-speed yet on the sound support for it -- and you'd also have to insist on players having a decent browser (that is, HTML5 doesn't work in Internet Explorer yet.)

Re: Dungeon Master Javascript... My version

Posted: Tue Apr 13, 2010 2:38 pm
by Hajo
Some people made a Quake clone with Javascript and HTML 5, and it ran fairly decent in Chrome and Safari. With sound, multiplayer support and all that. I have lost the link, but it should be googleable. I'd assume in a few years every browser will be able to do this.

Re: Dungeon Master Javascript... My version

Posted: Tue Apr 13, 2010 3:05 pm
by ian_scho
I was about to say HTML 5 as well... Honestly, it's corporate websites that worry about backward compatibility while you, Taghor, should be more worried about getting a physics engine in there :)

Re: Dungeon Master Javascript... My version

Posted: Tue Apr 13, 2010 3:10 pm
by Hajo
Found a link to the "Quake in browser" thing. It's Quake II actually:
http://www.engadget.com/2010/04/02/quak ... for-video/

Re: Dungeon Master Javascript... My version

Posted: Tue Apr 13, 2010 3:27 pm
by Roquen

Re: Dungeon Master Javascript... My version

Posted: Tue Apr 13, 2010 9:16 pm
by Gambit37
Here's some code snippets for doing sound in HTML5:

http://www.storiesinflight.com/html5/audio.html

Re: Dungeon Master Javascript... My version

Posted: Tue Apr 13, 2010 9:41 pm
by Taghor
Indeed the WebGL library looks quite interesting i may be able to use it at least in some part for some decent visual effects..the graphics at the moment admitidly are a rip from a sample package in RTC..and bits from swoosh..

Though i could imagine the spell effects and lighting would be made pretty nice with the features in WebGL ..

According to what i understand of WebGL its not installed by default(untill firefox 3.7 that is)?

I did play around with HTML5 tonight and the sound support does look pretty promising, and the ability to create an audio object in javascript means it can be called whenever needed, this being said cross browser compatility is lacking in regards to file formats that can be played; currently firefox can play wav's and not mp3's... however Chrome can play mp3's and not wav's. Im sure this will be resolved pretty soon by mozilla/google. Both can play OGG's but this rules out Safari and Chrome.. :roll:

My only option would be to supply both and disregard IE of richer features such as sound..

I Wouldnt object to using flash for users of IE alone.. but it'd really be going backwards on the idea to not really overly on 3rd party libraries..

Once again thank you for all your comments and thoughts!

I shall keep the topic upto date on any updates i do,

Thanks!

Joe. :)

Re: Dungeon Master Javascript... My version

Posted: Wed Apr 14, 2010 7:16 am
by Roquen
My understanding is that it's pretty much Chrome for the moment. The preview version of IE with HTML5 support is currently publically available (have no idea of what the current support state is though).

Re: Dungeon Master Javascript... My version

Posted: Wed Apr 14, 2010 10:38 am
by ian_scho
Thanks for the heads up Mister Gambit!

Re: Dungeon Master Javascript... My version

Posted: Wed Apr 14, 2010 5:50 pm
by Sophia
Most fancy HTML5 stuff also works on a mac if you download the latest version of WebKit (which is what Chrome is based around anyway)

Re: Dungeon Master Javascript... My version

Posted: Tue Apr 20, 2010 1:57 am
by Taghor
Just posting a quick update on whats been going on..

Finally got the door system to 95% of functionality...bound to be some tweeks and refactoring but its quite effecient i think.

New things added that are obvious are Custom doors, and door viewing at a distance..

also done a bit of refactoring and formatting of code....

Thanks again for all your constructive comments!!

Joe...