Dark Bit Factory & Gravity

ARCHIVE => Archive => Java,JS & Flash => Topic started by: mike_g on March 27, 2007

Title: Znax Clone In Javascript
Post by: mike_g on March 27, 2007
Heres (http://mike_g.sitesled.com/Game/Game.htm) another game I made in javascript so far its a working clone of Znax, one of my favorite games in the arcade. I'm also working on a set of special tiles and a different time system that will hopefully add some depth and make this a bit more original. If anyone has any cool ideas then let us know. Cheers.
Title: Re: Znax Clone In Javascript
Post by: Shockwave on March 27, 2007
That's really good! You got the tiles dissapearing nice too :) My only suggestion at the moment would be that the tiles are a bit dark, but maybe you wanted to go for a dark look so I'll stfu if you like :)
Title: Re: Znax Clone In Javascript
Post by: mike_g on March 27, 2007
Thanks Shockwave. I wernt sure if i liked the tiles dissapearing all that much as when you remove large areas of them is gets a bit slow. And yeah my friend said that the tiles were a bit dark. Originally I was going to have them bright then shade them when you select em but that looked a bit  too in your face so i reversed it. Still lightening them up a bit is easy to do.
Title: Re: Znax Clone In Javascript
Post by: benny! on March 28, 2007
Awesome. Just awesome. Holding the highscore of the arcarde znax, I do really
love this game. Your conversion is just great. Really cool ...

Karma ++
Title: Re: Znax Clone In Javascript
Post by: Clyde on March 28, 2007
Welldone MikeG :)
Title: Re: Znax Clone In Javascript
Post by: mike_g on March 28, 2007
Cheers :)
Title: Re: Znax Clone In Javascript
Post by: rdc on March 28, 2007
Looks cool. I can't really tell the different colors apart though.
Title: Re: Znax Clone In Javascript
Post by: mike_g on March 30, 2007
I finished the game off. It now has special tiles which hopefully make the game a bit more interesting. I made the tiles lighter too.

Play it here (http://mike_g.sitesled.com/ZC/ZnaxClone.htm)
Title: Re: Znax Clone In Javascript
Post by: rdc on March 31, 2007
Nice job on this.
Title: Re: Znax Clone In Javascript
Post by: mike_g on March 31, 2007
Thanks.
Title: Re: Znax Clone In Javascript
Post by: Jim on March 31, 2007
Good stuff!  I thought Javascript was just for popping up windows :)

Jim
Title: Re: Znax Clone In Javascript
Post by: p01 on April 01, 2007
How the hell does the game work ? I never played Znax and can't figure the game logic. :-[ I can not click the same tiles twice, even if it was not part of a 'removed' rectangle. And there's no indication of which tile I can click or not.

Jim: Luckily JavaScript can do much more. Have a look at the JavaScript demo scene prods (http://www.pouet.net/prodlist.php?platf%5B%5D=JavaScript&order=release&page=1&order=release&x=27&y=5).
Title: Re: Znax Clone In Javascript
Post by: mike_g on April 01, 2007
@ jim: Glad you like it dude :)

@p01: Yeah maybe the instructions arent clear enough. You can find the original flash game here (http://dbfinteractive.com/index.php?action=arcade;sa=play;game=16) in the arcade which has a demo of how to play. Maybe I ought to code a little example like that that runs before you start the game.
Title: Re: Znax Clone In Javascript
Post by: p01 on April 01, 2007
thanks. I can click the same tiles several times in the Flash version ???
FYI I'm using Opera 9.1

I don't know if you want to be true to the original, but it'd be really nice to only have to click the tiles of the opposite corners of the rectangle, and have some sort of overlay showing the rectangle ( with an indication saying if it is a valid rectangle or not ) when you look for the second tile.
Title: Re: Znax Clone In Javascript
Post by: mike_g on April 01, 2007
Hmm.. I only tested it in firefox and IE. There may be some issues with opera as I dont have any problems clicking the same tiles more than once. Click on one once it goes on click again it goes off.

As for an overlay and automatically removing valid diagonal tiles, it sounds good. I suppose that would make things a little quicker.   
Title: Re: Znax Clone In Javascript
Post by: p01 on April 01, 2007
[wild_guess] using innerHTML pbly nukes some event handlers [/wild_guess]
Title: Re: Znax Clone In Javascript
Post by: p01 on April 01, 2007
I've implemented a proof of concept of Znax with a 2 clicks selection w. highlight (http://poi.ribbon.free.fr/tmp/znafu/).

It works like a charm in Opera, but for some reason it doesn't work in FF although FireBug doesn't bite me in the face.  ???
Title: Re: Znax Clone In Javascript
Post by: mike_g on April 01, 2007
I cant seem to select any of the tiles in your version using firefox. In IE I can only make selections by dragging the mouse, and it comes out looking wrong. Example Here (http://i92.photobucket.com/albums/l15/mikegrundel/EG.png).

Dunno maybe I should get Opera to test some stuff on. Browser incompatibilities are a pain in the arse  :-\
Title: Re: Znax Clone In Javascript
Post by: p01 on April 01, 2007
Sorry for the incovenience. But that do you expect from a quick done at 3am :p

Opera's GUI is 'different'. First thing I do on a build I'll use a few times is to change the skin to 'Tango cl', and remove that annoying start bar and move the useful buttons it has ( fit to width, zoom, image toggles, css toggles ) in the address toolbar ... and place my tabs toolbar and personnal toolbar on the right hand side.
Title: Re: Znax Clone In Javascript
Post by: mike_g on April 01, 2007
Just tried your example out in opera and I like it :) It cuts out a lot of clicking, and having to see if the tiles line up. If I find the time I'll change my version to something like that.

I also tried my version in Opera and yeah now I see what you meant. Its all screwed up. Guess I'll just put a message on there for the time being saying it wont work in Opera. 

Cheers.
Title: Re: Znax Clone In Javascript
Post by: Shockwave on April 04, 2007
Heh, cool late night code :) Have some good Karma! Click and drag is a great idea for this game :)