Java-Gaming.org Java4K winners: [ by our judges | by the community ]         
Featured games (67)
games approved by the League of Dukes
Games in Showcase (∞)
games submitted by our members



News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
    Home     Help   Search   Login   Register   
Pages: [1]
  Print  
  z4rch 1st playable  (Read 7485 times)
0 Members and 1 Guest are viewing this topic.
Offline SimonH

JGO Strike Force
***

Posts: 896
Medals: 14



« on: 2007-12-12 21:12:34 »

Weighing in at just 4090 bytes, I give you... (ta-da!)... Z4RCH!


You can play (the slightly larger applet version) at http://www.hayles.demon.co.uk/4K/z4rch/z4rch.html

Kinda addictive...

Stickmen Wars 2 is in development.
Meanwhile try Bloodridge
Offline appel

JGO Wizard
****

Posts: 1477
Medals: 23


I always win!


« Reply #1 on: 2007-12-12 22:51:57 »

Cool.

Very hard to control though, wasn't able to destroy one alien  Roll Eyes

Check out the 4K competition @ www.java4k.com
Check out GAMADU (my own site) @ http://gamadu.com/
Offline markush

Jr. Member
**

Posts: 52


Plöp!


« Reply #2 on: 2007-12-13 01:08:04 »

Very Fun!

I even managed to kill some aliens Smiley

On OS X 10.5, ctrl+<arrow> is the combination to change the virtual desktop, so when i wanted to fire and steer at the same time my desktop would switch away, which made the game a bit more complicated.
So for OS X users with spaces enabled some other key kombination would be great. Since you have 6 spare bytes you could probably add an alternative key for fire and lift. Smiley

(but not x and y keys, because than I have to complain about german keyboards where the x and z keys are swapped Smiley )


Games published by our own members! Go get 'em!
Offline Markus_Persson

JGO Kernel
*****

Posts: 2092
Medals: 10


Mojang Specifications


« Reply #3 on: 2007-12-13 02:49:25 »

Weighing in at just 4090 bytes, I give you... (ta-da!)... Z4RCH!

Nice, reminded me a bit of Virus, which is not a bad thing at all.

The controls felt good enough, but I found it really hard to tell if I hit an enemy or not, and sometimes it felt like I was shooting straight at them for a very long time, but no bullets seemed to hit.
I like the trees. =) Polygonal cuteness.

Play Minecraft!
Offline Markus_Persson

JGO Kernel
*****

Posts: 2092
Medals: 10


Mojang Specifications


« Reply #4 on: 2007-12-13 04:04:40 »

Oh

Play Minecraft!
Offline jojoh

JGO Ninja
***

Posts: 554
Medals: 6


games4j.com


« Reply #5 on: 2007-12-13 05:31:03 »

Nice, reminded me a bit of Virus, which is not a bad thing at all.
Yup, very Virus like, only this is slightly easier to ctrl than the original (especially since you can land on water)  Smiley. Very good to squeeze all that into 4K. I found that the only way to kill the virus was to aim dead center on them and then let them hover up into my stream of bullets, since it is very difficult to see if the bullets are above or below the virus. You also seem to lose lift force when shooting and/or moving and/or turning. Guess it would have been nice with some badies moving around, but difficult enough to hit them as it is really.

Noticed that trees that are behind a hill are "lifted up" so that the root is always visible, and they seem to be drawn in front of trees that are closer. Guess you are aware of this and it is just a shortcut to cram it into 4K. Hardly noticeable when you play anyway.

Like the particle effect as well!

Very impressive!

Offline DzzD

JGO Kernel
*****

Posts: 2134
Medals: 16



« Reply #6 on: 2007-12-13 07:56:35 »

very nice!

would be cool to have a smaller applet available as it is a bit slow on my computer  Sad, but that doesn't matter it is an old one... anyways fit that in 4k is really good works.

EDIT:

yea an alien killed  Wink

Offline Hansdampf

Sr. Member
**

Posts: 412
Medals: 2


too offending?


« Reply #7 on: 2007-12-13 08:22:56 »

cool!

I had no problems killing enemies, 2 were left when I lost my last life due to a crash.
It is slow here too on my 3500+

lots of sillystupid games: http://www.emaggame.com
Offline SimonH

JGO Strike Force
***

Posts: 896
Medals: 14



« Reply #8 on: 2007-12-13 12:02:49 »

So for OS X users with spaces enabled some other key kombination would be great.
Thanks for the tip - what would be good keys for OSX?

it is very difficult to see if the bullets are above or below the virus. You also seem to lose lift force when shooting and/or moving and/or turning
Yeah, no Z-ordering so bullets are always drawn last... Sad
Lift is inverse square, so the nearer the ground you are, the greater the lift. Above a certain height all you're doing is slowing your descent!

I've made it (much) easier to hit enemies and tried to sqeeze a tiny bit more speed out of it...

Click here to try the game

EDIT: Just found a way to increase speed by 5-10% & save 21 bytes! (...don't use Math.round())

Stickmen Wars 2 is in development.
Meanwhile try Bloodridge
Offline Abuse

JGO Kernel
*****

Posts: 1866
Medals: 5


falling into the abyss of reality


« Reply #9 on: 2007-12-13 14:12:21 »

That is a game crying out for a 2nd input device, using the mouse for aiming!

Just squeeze it down another ~200bytes and you should be sorted!  Grin
Games published by our own members! Go get 'em!
Offline Abuse

JGO Kernel
*****

Posts: 1866
Medals: 5


falling into the abyss of reality


« Reply #10 on: 2007-12-13 14:34:15 »

There's still alot you can do on the optimisation front!

Just a few :-

1) get rid of the Listener

Replace it with enableEvents(InputEvent.XXXX_MASK), and override processEvent(....) (or processXXXEvent if you are only interested in one type of event)
This will remove 2 methods, saving ~50 bytes each.

2) get rid of getWidth/getHeight - as you are making an applet, the size is hardcoded anyhow.

3) stick with using just 1 Color constructor, and don't reference the static final instances.
e.g. as you are already using the Color(int.int.int) constructor, you will reduce your constants pool size by replacing "Color.black" with "new Color(0,0,0)". (store in a local if you are worried about extra garbage)

4) Don't use String concatenation - it pulls in loads of rather large constants pool entries, and the bytecode for performing the concatentation is rather large.

5) If convenient - use drawChars instead of drawString, it has a smaller method signature resulting in a smaller constants pool entry.

6) Use the default Font!



btw, as far as I am aware Component#createImage(width,height) does not create a VolatileImage back buffer, meaning all of your fillPolygon operations are not being hardware accelerated.
If you switched to using BufferStrategy (or a Volatile backbuffer) I'd expect an enormous fps boost. (probably a solid 60fps on most machines)
Offline SimonH

JGO Strike Force
***

Posts: 896
Medals: 14



« Reply #11 on: 2007-12-13 15:21:31 »

1) get rid of the Listener
2) get rid of getWidth/getHeight - as you are making an applet, the size is hardcoded anyhow.
3) stick with using just 1 Color constructor, and don't reference the static final instances.
4) Don't use String concatenation - it pulls in loads of rather large constants pool entries, and the bytecode for performing the concatentation is rather large.
5) If convenient - use drawChars instead of drawString, it has a smaller method signature resulting in a smaller constants pool entry.
6) Use the default Font!
7) If you switched to using BufferStrategy (or a Volatile backbuffer) I'd expect an enormous fps boost. (probably a solid 60fps on most machines)

1,2) They're just thrown in there to make an applet version - the submitted entry will be a JFrame.
3) Good call!
4,5) Hmmm... Will I save enough space to warrant it? If I was gonna get 200+ bytes I'd do it, but I don't think I will!
6) No way! It could be anything!
7) I changed to VolatileImage and noticed only a small (but significant) speed increase, but that may just be my rubbish graphics card. I've updated the applet also - is it faster for you now? (even with the Color()s sorted using this has got me back up to 4087 bytes  Undecided)

Thanks for the tips!

Click here to try the game


Stickmen Wars 2 is in development.
Meanwhile try Bloodridge
Offline markush

Jr. Member
**

Posts: 52


Plöp!


« Reply #12 on: 2007-12-13 16:02:17 »

7) I changed to VolatileImage and noticed only a small (but significant) speed increase, but that may just be my rubbish graphics card. I've updated the applet also - is it faster for you now? (even with the Color()s sorted using this has got me back up to 4087 bytes  Undecided)

Its much smother now on OS X Smiley

And an alternative key for CTRL could be ALT I think.
Offline SimonH

JGO Strike Force
***

Posts: 896
Medals: 14



« Reply #13 on: 2007-12-13 16:57:19 »

Its much smother now on OS X Smiley

And an alternative key for CTRL could be ALT I think.

Nice one!

ALT key now added for fire...

Click here to try the game


Stickmen Wars 2 is in development.
Meanwhile try Bloodridge
Offline Morre

JGO Ninja
***

Posts: 507


I'm Dragonene on IRC.


« Reply #14 on: 2007-12-13 17:28:06 »

Right. This game is awesomely cool Cheesy

Too tricky for me, though... I can barely kill more than 1 enemy.

Superb graphics :>

Offline SimonH

JGO Strike Force
***

Posts: 896
Medals: 14



« Reply #15 on: 2007-12-15 12:32:13 »

A few little tweaks;

  • More realistic explosions
  • Improved steering
  • Enemies more aggressive
  • Improved shadows for bullets

Also got it down to 4075 bytes  Grin

Click here to play


Stickmen Wars 2 is in development.
Meanwhile try Bloodridge
Offline DzzD

JGO Kernel
*****

Posts: 2134
Medals: 16



« Reply #16 on: 2007-12-15 12:37:52 »

still cool but please provide another link with a smaller applet.... plz...

Offline SimonH

JGO Strike Force
***

Posts: 896
Medals: 14



« Reply #17 on: 2007-12-15 12:50:16 »

still cool but please provide another link with a smaller applet.... plz...

Here's a half-size version - but it's not much faster than the normal sized one...


Stickmen Wars 2 is in development.
Meanwhile try Bloodridge
Offline DzzD

JGO Kernel
*****

Posts: 2134
Medals: 16



« Reply #18 on: 2007-12-15 13:05:44 »

thanks, this is not as faster as i was expected but it is a little more fast, was able to kill 6 aliens this times  Smiley

Offline Abuse

JGO Kernel
*****

Posts: 1866
Medals: 5


falling into the abyss of reality


« Reply #19 on: 2007-12-15 15:49:35 »

Given that your particles are so small, could you change them to fillRect rather than fillOval? it should give a performance boost (though maybe not measurable given the small number of particles)
Offline nva225

Sr. Member
**

Posts: 298



« Reply #20 on: 2007-12-18 12:55:37 »

A very technologically impressive entry, as I'm sure most people would agree. First time I played the game I got a little confused with the controls (sometimes spacebar wouldn't register for vertical thrust if I was hitting too many other keys I think?) and had issues shooting some of the aliens down, but pretty soon I managed to figure it out. It's actually pretty fun once you know how to kill things, since usually the enemy ends up hitting you once or twice, esp if you're attacking 2 enemies, and there's a real sense of "oh crap I might die", which is important to have.

But I eventually got it down so I could reliably destroy the guys, and actually got through the first wave, only to my disappointment to find there was no second wave! I went back to the main base and healed my ship, but "Wave 1" just sat there... taunting me. And yes it said 0 enemies left.

Perhaps would be more fun if the engine was more efficient/rendered faster, but a very excellent entry overall.
Offline SimonH

JGO Strike Force
***

Posts: 896
Medals: 14



« Reply #21 on: 2007-12-18 13:06:16 »

there was no second wave! I went back to the main base and healed my ship, but "Wave 1" just sat there... taunting me. And yes it said 0 enemies left.

There's 10 different waves in all (hit 'Enter' to continue to the next wave - I should make that clearer...) I can't get past wave 3; 60 enemies!

Edit - 'Tis done - it now says 'Press ENTER to continue' under 'Wave Complete'. NB I've also added a cheat (applet only!): Press 'A' to kill all the enemies and finish the wave.
One other thing - your score now goes down the more the land is polluted - so there's an incentive to clear the ground as fast as possible!


Stickmen Wars 2 is in development.
Meanwhile try Bloodridge
Offline nva225

Sr. Member
**

Posts: 298



« Reply #22 on: 2007-12-18 15:25:47 »

Ahh ok, I should've random key spam'ed and found that. Thanks.
Offline SimonH

JGO Strike Force
***

Posts: 896
Medals: 14



« Reply #23 on: 2007-12-19 19:57:06 »

One last little tweak: as the waves increase the enemies notice you from further away, so the hover-and-shoot strategy becomes a bit trickier...

Click here to play z4rch


Stickmen Wars 2 is in development.
Meanwhile try Bloodridge
Offline erikd

JGO Kernel
*****

Posts: 2561
Medals: 7


Maximumisness


« Reply #24 on: 2007-12-28 18:55:40 »

Very impressive, but very slow on my machine. I'm sure a 2GHz machine should be able to outperform virus on an Atari ST? Smiley
Impressive nonetheless for just 4k!

Pages: [1]
  Print  
 
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.16 | SMF © 2011, Simple Machines Valid XHTML 1.0! Valid CSS!
Page created in 0.414 seconds with 22 queries.