Hi !
Featured games (85)
games approved by the League of Dukes
Games in Showcase (636)
Games in Android Showcase (178)
games submitted by our members
Games in WIP (688)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
   Home   Help   Search   Login   Register   
  Show Posts
Pages: [1]
1  Games Center / Archived Projects / Re: GravityTrap ... first game on: 2002-12-16 15:22:03
Open sourcing it would be cool if you get the time... I'd certainly like to read through the physics code...

See ya,

2  Games Center / Archived Projects / Re: First 2D game - yet another Tetris(tm) clone.. on: 2002-12-16 13:52:03
Hm, you're right, currently it just goes ahead and plants the piece without waiting.  I'll look at it... thanks....

3  Games Center / Archived Projects / Re: First 2D game - yet another Tetris(tm) clone.. on: 2002-12-16 13:30:16
I changed the controls on my version to match yours... whoever suggested it way back when, you're right: the down arrow should simply lower the block, not drop it.

See ya,

4  Games Center / Archived Projects / Re: GravityTrap ... first game on: 2002-12-15 23:35:00
That's a really cool game!  Nice physics.  And still smooth even when there's a slew of bullets on the screen.  Very cool.

5  Games Center / Archived Projects / Re: First 2D game - yet another Tetris(tm) clone.. on: 2002-12-14 16:58:16
Wow dude, that's awesome!   Nice and smooth.  Very cool.

The brickout game is awesome, too... I'm working on one right now and it sure doesn't look as good as that!  Oh well.

See ya,

6  Discussions / Business and Project Management Discussions / Re: Diary on: 2002-12-10 19:38:24
Eggscellent.... consider it bookmarked...


7  Discussions / Business and Project Management Discussions / Re: Diary on: 2002-12-09 22:53:08
Yup, that'd be good stuff.  Especially if you can include some more or less step by step account of implementing a game - problems, successes, stuff that you ended up refactoring into a general purpose library, etc.

I started doing something like that here:

See the "Development notes" at the bottom of the page.  For my next game maybe I can include some more details on blind alleys, refactorings, etc....

Good luck,

8  Games Center / Archived Projects / Re: Tower Games presents Line of Muskets on: 2002-12-05 17:25:53
Pretty cool game... nice smooth animations... fairly intuitive controls.  The game's author is online now so there's some expert guidance available....

9  Games Center / Archived Projects / Re: First 2D game - yet another Tetris(tm) clone.. on: 2002-12-05 16:40:32
Very cool, thanks for the thoughtful response.

FWIW, I was just reading some stuff out there on Othello algorithms.  Seems like some people create an "evaluation thread" while the human player is thinking.  The thread considers each possible human player move and evaluates the best possible response move - so when the player finally does go, the computer has some cached responses.  Cool stuff.  

Thanks again,


10  Games Center / Archived Projects / Re: First 2D game - yet another Tetris(tm) clone.. on: 2002-12-04 12:53:09
Yup, it makes sense to use as few resources as possible.  

I put a Thread.currentThread.sleep(20) in the game loop; that trims CPU usage to about 30% without causing flickering or anything like that.  So that's a little better.  

11  Games Center / Archived Projects / Re: First 2D game - yet another Tetris(tm) clone.. on: 2002-12-04 11:48:55
The more I think about it the more I agree that the "loop as fast as you can" design is not good for some games.  

For example, a Othello game could just sit and wait for user input, and then spend as much cycles as necessary flipping pieces and calculating scores and exploding with light and sound.  Then it could go back to sleep and wait for the next move.  Actually, I guess it would need a background thread to be analyzing possible moves and such... assuming it was a player against computer game.  

What about arcade games though?  Maybe Tetris isn't really an arcade game per se... although when the "lower piece" speed is down to 100 ms it seems fairly arcadish.  Hm.  At the same time though, Herkules' question still seems appropriate - "why should x consume 100% of my CPU?".  Even if it is Asteroids or Space Invaders or some such, gobbling 100% of CPU seems rude.

Re-reading your post again now... the thing that bothers me about "land the piece, then play the animation, then continue the game" is that it seems a bit stilted.  I mean, part of the fun is that a lot of stuff is going on at once - I'm rotating a piece, the animation from the last piece is still going, the animation from the last time I filled up a row is fading away (at least, if there was such an animation).  On the other hand, all that could probably be done using separate threads.  

Here's a question - how could that animation be accomplished without redrawing the underlying board every time the circles get bigger?   Hm, I guess I could draw a clipped region of the board, then do the animation.... and the clipped area could be dependent on the largest circle size... hm.  Or maybe there's some Java 2D ImageFilter thing for that....

Thanks for the ideas and feedback,

12  Games Center / Archived Projects / Re: First 2D game - yet another Tetris(tm) clone.. on: 2002-12-03 16:33:58
Hm, that's well said.  Let's see.... 

Note that any explanation I give for doing this as an FPS-based thing will be purely post-action rationalization on my part since I just kind of wrote this the only way I could think of doing it.  It's more of a lack of knowledge on my part than an attempt to do things a particular way. :-)

Anyhow, yup, let's see, how to do this without a busy-wait game loop?  OK, there could be a timer that fires once a second that kicks off a "piece lower" event that erases and redraws that piece.  And the KeyListeners could do a similar thing for rotation and left/right movement.  

The animation thing would be interesting.  

[much typing]

OK, it was interesting enough that I cobbled together an little "animation" that, in addition to be disconcertingly ugly, gives us something to work with.   I've uploaded a new version to the web site -

So, how could I do something like that without a FPS thing?  Maybe run the animation in another thread?  And then interrupt the thread if the animation needed to be restarted?  Maybe that's a way to do it...

13  Games Center / Archived Projects / Re: First 2D game - yet another Tetris(tm) clone.. on: 2002-12-03 11:55:23
Right, it could just sleep inside the game loop... but wouldn't that preclude a "row filled" animation or a "piece landed" animation?   Because those would need to, you know, fly away in little pieces or something nice and smooth.  

On the other hand, I haven't implemented any animations like that yet, so that's not a very strong argument :-)

14  Games Center / Archived Projects / Re: First 2D game - yet another Tetris(tm) clone.. on: 2002-12-03 10:14:53
Right... it'll take everything it can get... the game loop is pretty much this:


So it'll loop as fast as it can.  

I put a Thread.yield() inside the game loop, and a Thread.currentThread().setPriority(Thread.MIN_PRIORITY) right as the program starts to try up make it a bit less greedy....


15  Games Center / Archived Projects / Re: Teranoid (The best java breakout) on: 2002-12-02 18:11:20
Beautiful graphics, great variety in blocks, nice physics.  The only problem I saw was that the screen would occasionally lock up - GC pauses I presume - but other than that, really really nice.

16  Games Center / Archived Projects / First 2D game - yet another Tetris(tm) clone... on: 2002-12-02 18:02:39
...can be found here:

This is a very simple implementation of Tetris - no sound, blocks are drawn using Graphics2D.drawRoundRect(), and so on.  Everything should work though - the pause function, the "top 5 high scores", the demo mode, etc.  FWIW,  I get about 65 FPS on my little Pentium III 1.1GHz laptop.

Thanks for any feedback - this is my first effort in this field so pls be gentle :-)



P.S.  First I posted this over in the Java 2D section... thanks to zparticle for noticing that it should have been over here to begin with.
Pages: [1]
Dwinin (73 views)
2015-11-07 13:29:08

Rems19 (81 views)
2015-10-31 01:36:56

Rems19 (78 views)
2015-10-31 01:32:37

williamwoles (107 views)
2015-10-23 10:42:59

williamwoles (93 views)
2015-10-23 10:42:45

Jervac_ (111 views)
2015-10-18 23:29:12

DarkCart (135 views)
2015-10-16 00:58:11

KaiHH (118 views)
2015-10-11 14:10:14

KaiHH (157 views)
2015-10-11 13:26:18

BurntPizza (172 views)
2015-10-08 03:11:46
Rendering resources
by Roquen
2015-11-13 14:37:59

Rendering resources
by Roquen
2015-11-13 14:36:58

Math: Resources
by Roquen
2015-10-22 07:46:10

Networking Resources
by Roquen
2015-10-16 07:12:30

Rendering resources
by Roquen
2015-10-15 07:40:48

Math: Inequality properties
by Roquen
2015-10-01 13:30:46

Math: Inequality properties
by Roquen
2015-09-30 16:06:05

HotSpot Options
by Roquen
2015-08-29 11:33:11 is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!