Hi !
Featured games (84)
games approved by the League of Dukes
Games in Showcase (549)
Games in Android Showcase (139)
games submitted by our members
Games in WIP (593)
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] 2 3 4
1  Games Center / 4K Game Competition - 2010 / Re: Javak4K 2010 is now open for submissions!! on: 2009-12-02 03:48:37
Problems with the page layout, scrolling down screws up the display of the applet on my machine (vista, firefox w/adblock plus).
2  Games Center / 4K Game Competition - 2010 / Re: Falcon4k on: 2009-12-02 03:46:01
very nice, my biggest problem was that once you crash, you HAVE to go to the side to "un-crash", you can't go up.
3  Games Center / 4K Game Competition - 2010 / Re: Preliminaries (tentative) on: 2009-11-27 19:35:10
Just to clarify, I assume the total size of the entire project (including server parts) must not exceed 4KB, the only exception being jnlp files or applet tags on the condition that those don't inject any data or logic into the game.

Last year I submitted a single 4K jar that contained both client and server, but the apparent consensus on the forum was that passing the server's address as a start-up parameter violated the unspoken rule against inserting data via the command line.

My intention this year would be to submit a 4K jar, only modified to not use the command line for the server address.
4  Games Center / 4K Game Competition - 2010 / Re: Preliminaries (tentative) on: 2009-11-21 19:11:26
Applets only (required), webstart optional (applets can be launched as Webstart).

Isn't this a bit overly restrictive? I was planning on resubmitting my poker server/client this year, modified to not use the command line for the server address input, but I'm not sure an Applet can act as a server, or even connect to a server?
5  Games Center / 4K Game Competition - 2009 / Re: Flash 4K on: 2009-03-24 02:06:11
Why wouldn't it? Applets and webstart support more or less the same stuff. Even the parameter input you used for switching modes is supported...
Could the server run as an applet and accept connections from other clients? Don't the security restrictions for applets prevent them from connecting to anything other than the web server from which they were launched? Maybe not, I'm obviously not very experienced with applets.

but you shouldn't do that anyway, in my opinion. Even if the parameter size + JAR file is less than 4096 kb, it breaks the idea that "everything should be contained in the JAR file". A JOptionPane dialog is really not very expensive, and can produce pretty much the same result in one line.
Well, if you notice my game didn't get officially submitted, so the command line point is moot. I personally think my reasons for doing it the command line way are valid and don't take away from the accomplishment of getting the game into 4k. And since I did it for myself - the contest would have been a side benefit - then I can be happy with it the way it is Smiley  I did try to retrofit the JOptionPane prompt into the game, but I was never able to get it back under 4k  Undecided   But that's another issue Smiley

I've never done flash development. Is there a free development environment or anything?
6  Games Center / 4K Game Competition - 2009 / Re: Flash 4K on: 2009-03-24 01:40:38
At least this has convinced me to have the next Java4K entirely Applet based.

And by that I mean embedded on, like how it should be! Smiley
I don't think my poker server would have been possible as an applet? While I probably won't try the poker server thing again, I think the competition should be left open to ANY type of game that can fit into 4k.
7  Games Center / 4K Game Competition - 2009 / Re: Online No Limit Texas Hold'Em 4K on: 2009-03-07 03:07:22
I know for a fact that the ruling every year has been that you cannot provide arguments with the JNLP. It has been clearly stated before; if was not this year, this is simply a mistake on behalf of the organizers.

How does one go about hosting or joining a server? I'm confused. Smiley

In defense of my choice to use arguments on the command line - it is 4 bytes of data, and my jar file is more than 4 bytes lower than the 4k limit. It is also not sound data, art data, game logic, etc, it is configuration only - and I know other games have used the command line for configuration options before, such as whether to run windowed or full screen. That being said, this solution makes it the easiest for those wishing to host a server to do so with the least amount of trouble, and allows players to connect with the least amount of trouble.

That being said, all one has to do to host is a) have an http server up and running, and configured correctly (to host the jnlp file and jar), b) edit the client jnlp file to include your server's address, and c) either start the server from the server jnlp file or from the command line with java -jar Poker4k.jar. Point prospective players to the client jnlp file, and play on.

Also: You might need to make sure any firewalls and/or port forwarding are configured correctly.. the game connects on port 0x4096 (or 16534, for you hex challenged individuals - do we have any of those here?)
8  Games Center / 4K Game Competition - 2009 / Re: Invalid jar files after compression on: 2009-02-25 00:06:03
How do I compress a jar file with a manifest file and keep it executable? For example I was trying to use the following to create an executable jar:

bjwflate -s 513 A.class META-INF\MANIFEST.MF

Whenever I try to run it it tells me the jar file is corrupt. This happens a lot after using certain optimizers as well. I also verified that I can create a jar file with the jar command and 7zip that runs ok.


Basically, bjwflate flattens the contents of the file when you do it that way - in other words, the manifest is no longer under meta-inf, and thus the jar is invalid.

Doing it Hsaka's way should maintain the folder structure, and it should end up being valid.
9  Games Center / 4K Game Competition - 2009 / Re: Online No Limit Texas Hold'Em 4K on: 2009-02-25 00:04:34
Do you plan to develop this further?

As in: Beyond the 4K barrier, to add some user-friendliness, some rules, maybe a bit 'o eye candy?

If so, I'll continue to host it and link it as a game on our board.  Wink

If there's interest, I wouldn't mind doing so... without the 4K limit, there's lots of functionality that can be added Smiley
10  Games Center / 4K Game Competition - 2009 / Re: Ultimate Tic-Tac-Toe on: 2009-02-09 11:09:37

It's possible to win, but it's a tad difficult.  Also see my book:

Holy crap, I just won by accident.

I got into the pattern that had resulted in a tie about 5 times already, so I just started clicking randomly to get the game over with, and what do you know... 

Taking another look, now I see the difference - it wasn't quite the same pattern, it's almost like the computer made a wrong move o.O

Good game.
11  Games Center / 4K Game Competition - 2009 / Re: Online No Limit Texas Hold'Em 4K on: 2009-02-07 15:44:42
Just played against myself. Ok not that much fun, but at least it worked  Grin
And working is half the battle Smiley  There's a lot of features I wanted to include to make it more fun (like chat), but the multiplayer code doesn't leave much room for anything else.

Just an inconsistency i found:
When ther is Fold, Call, Raise and All In  you can click "B" as for Bet.  Wink
Yep. There's really only four actions - Fold, Call/Check, Bet/Raise, and All In - and I didn't think it worth the bytes to make sure you hit the right letter for the Bet/Raise action, since it does the right thing either way.

Edit: I think it's just as a matter of size that you had no chance to implement it, but if multiple players going all in, there is only one pot
Yep. The side pot implementation was very costly, and I couldn't find a cheaper way of doing it, so instead it's tournament-style.
12  Games Center / 4K Game Competition - 2009 / Re: Online No Limit Texas Hold'Em 4K on: 2009-02-07 04:55:20
Hehe, it was me.. was hoping one more person would join  Grin

Edit: ..maybe you could allow the game to start with a minimum of 2 people?

The problem is that the rules for advancing the dealer button and who posts the small and large blinds are different for 2 players than they are for 3 or more. I can take another look at it, and see if I can make it fit.
13  Games Center / 4K Game Competition - 2009 / Re: Online No Limit Texas Hold'Em 4K on: 2009-02-07 03:10:31
No, I guess not.

I saw that someone was on-line here at least once today, so a remote connection works...

Yep, it works! Now to get people on all at the same time Smiley

Edit: now I wish I'd been able to fit even a crude chat interface... someone else is on, but there's no telling who Smiley
14  Games Center / 4K Game Competition - 2009 / Re: Online No Limit Texas Hold'Em 4K on: 2009-02-07 03:10:07
I guess i'm connected... not a whole lot of feedback from the interface Smiley

Yeah, that's the problem with the multiplayer code... not much room left at all for user interface stuff. I tried to leave in as much as I could, but it's a really, really tight fit.

Basically, if the client runs, you're connected. Period. You'll see a red box with your starting cash (2000), and a blue box with your current bet (0). If there are others connected, you'll see their red boxes with their cash, and their blue boxes with their current bets. If there is a game in progress, you should also see the cards (face down, unless they are in the showdown) and pot values.

Once a game starts, the active player will be shown with a yellow background. If it's your turn, you will also see an action bar with your choices. Type the first letter of your choice, and the game will continue. At the end of the hand, the winner's (or winners') blue box will turn gold with red lettering showing the amount won.

A note about the showdown - if a player raised during the last round, the last player to raise will be the first to show their cards. Otherwise the player at the dealer's left will be the first. Progressing around the table to the left, if a player's hand is equal to or better than the previously shown hands, then their hand will be shown, otherwise it will be automatically mucked.

There is a hidden 1 minute (approximately) timeout for user action. If the server does not receive your input within that minute, your hand will be automatically folded.

Never fear that the person running the server will have an unfair advantage - they cannot see anyone's cards unless the cards are face up for the whole table to see.

Last but not least, the game will start when 3 people or more join. Switching from heads-up (2 people) to normal play and back was a bit more than I could fit into the game.
15  Games Center / 4K Game Competition - 2009 / Re: Online No Limit Texas Hold'Em 4K on: 2009-02-06 11:36:38
I just want an instant hit...
I hear ya...  maybe after I convince someone to set up a server, you'll give it a try Smiley Or maybe not, it's all good Smiley
16  Games Center / 4K Game Competition - 2009 / Re: Online No Limit Texas Hold'Em 4K on: 2009-02-05 23:24:29
Do the rules permit network access?
Yes. What the rules do not allow is downloading of content (resource files, sound files, images, etc) from an external site.

This game is 100% self-contained. All logic, artwork, etc is contained within the one jarfile, which is less than 4K.
17  Games Center / 4K Game Competition - 2009 / Re: Online No Limit Texas Hold'Em 4K on: 2009-02-05 23:22:37
Seems kinda a lot of work to just start playing - I'd prefer some AI rather than the multiplayer code...  Undecided
The "lot of work" should disappear once hosting is arranged.

I considered AI vs multiplayer, and decided that multiplayer was a greater challenge, and was what I wanted to try. I may create an AI version, we'll see how my schedule looks in the next few weeks.
18  Games Center / 4K Game Competition - 2009 / Re: Online No Limit Texas Hold'Em 4K on: 2009-02-05 23:20:50
I don't want to ruin the fun, but do the rules not stipulate the game needs to be playable without supplying any arguments (either from the jnlp or command-line).
If they don't, they need to (and used to), otherwise you can completely bypass the 4kb size limitation by passing in as much data as you like.
No, they don't. I understand the reason to include such a rule, but the rules as posted at do not stipulate such a restriction. However - in the interests of fairness, if it is deemed necessary I will be happy to  attempt to modify the game to take input in a manner similar to your recommendation.

Incidentally, are you aware neither of the jnlp files you've linked to work?
Yes. Without hosting, the codebase would prevent the files from running on all systems no matter what I put there. I am in the process of arranging hosting, and it should be up later tonight or early tomorrow.

Additionally, I realized while reviewing the rules that I did make an error with this submission - it is not compiled for 1.5. I will recompile and repost.
19  Games Center / 4K Game Competition - 2009 / Online No Limit Texas Hold'Em 4K on: 2009-02-05 03:52:41
networking is not on the cards.
Funny you should say that...  Cool

Online No-Limit Texas Hold'Em Poker in 4K!

I'll need hosting before people can play this, but I'm working on arranging that now. As it is, there are 2 jnlp files, one for running the server and one for running the client. Those wishing to run their own server will need to modify the client jnlp file to provide the appropriate IP address, and then make that jnlp file available to their players.

The jar file is not signed - when testing this on my local machine (both server and clients running locally) I was able to run it without signing. If the lack of signature causes problems with connections over the wider internet, I will be happy to sign it and repost.

Notes about the game:

The game will start when 3 or more people have connected.
There are no side pots. When one player goes all-in, no further raises are allowed.
To play, type the first letter of your desired action when prompted - F for Fold, C for Call or Check, B for Bet, R for Raise, or A for All In.

20  Games Center / 4K Game Competition - 2009 / Re: Need Help Compressing on: 2009-01-31 04:58:18
Remove whatever feature it is that requires functionality protected by the security model?

Not an option, it's kinda the whole core of the game Sad
21  Games Center / 4K Game Competition - 2009 / Re: Need Help Compressing on: 2009-01-31 01:32:06
The executable jar must have a manifest, or it is not executable.

I was afraid of that. Oh well, guess I need to find another way to drop 133+ bytes Smiley
22  Games Center / 4K Game Competition - 2009 / Re: Need Help Compressing on: 2009-01-30 00:22:41
The rules of the contest say you have to supply a JNLP file. If you have one of those, you don't need a manifest.

True, but it also says

Quote from:
# If your JAR is below 4K until you sign it, you must provide a runnable unsigned JAR to demonstrate the game meets the competition rules.

Since my jar will definitely be over 4K when signed, I will need to provide a runnable unsigned jar that is 4k or less to prove that my game qualifies. Since java will not accept any jar file that does not have a manifest, the manifest must be present for the jar file to be runnable. As such, you cannot use an unsigned manifest-less jar file as your final determination of size - you must use either the signed jar file with no manifest, or an unsigned jar file with a manifest.

I don't like this conclusion, as it means I haven't gotten it as small as I thought I had, but them's the rules until a judge says otherwise.
23  Games Center / 4K Game Competition - 2009 / Re: Need Help Compressing on: 2009-01-29 13:16:27
I knew you didn't technically NEED one, but I've been stubbornly including one because I thought you were SUPPOSED to have it for this contest...
Ok, I've been thinking this through all morning, and I think the rules of the contest might not let us (me) take advantage of this.


Quote from:
# If your JAR is below 4K until you sign it, you must provide a runnable unsigned JAR to demonstrate the game meets the competition rules.

Although, now that I read it again, it does say "runnable" not "executable" - so maybe it can be removed after all, as you can still run the game from the command line, you just have to specify the main class.

Judges, can we get a ruling? Smiley
24  Games Center / 4K Game Competition - 2009 / Re: Need Help Compressing on: 2009-01-29 11:21:00
Also did not know this. Would save 17+ bytes!
I knew you didn't techincally NEED one, but I've been stubbornly including one because I thought you were SUPPOSED to have it for this contest...

A quick test using my nowhere-near-4k-yet project shows that, including headers, removing the 17 byte manifest saves a whopping 133 bytes. I guess this is due to the path and file name as well as the file contents.

Guess I'll be removing that manifest Smiley
25  Games Center / 4K Game Competition - 2009 / Re: Keggle on: 2009-01-05 15:58:37
Great game, I like it, but it runs painfully slowly on this PC.

P4@2.66GHz, 1GB RAM, WinXP Pro SP2, JRE 1.6.0_03, 35% CPU utilization, 60% memory utilization, running via webstart.
26  Games Center / 4K Game Competition - 2009 / Re: Desert Bus on: 2008-12-30 03:12:07
I suspect you could get away with a few less score digits Smiley 

Hilarious. well done.
27  Games Center / 4K Game Competition - 2009 / Re: 4x4k on: 2008-12-23 14:19:31
Happens all the time to me... wanna have some fun? hold down for a few sec, then jump. For me, at least, I hit the ground and go flying, about half the time the truck does that inverted trick.
28  Games Center / 4K Game Competition - 2009 / Re: Links, tips and goodies on: 2008-12-12 17:42:43
Hmm, that's interesting - I wonder if that is a quirk of a particular implementation, or is a documented piece of functionality.
What is your main Container subclassing? Applet, Frame or JFrame?
To date, it's always been JFrame, and it's Sun's JRE 1.6.0_03.

Edit: I just did a test with the game I'm currently implementing. It extends JFrame, and calls enableEvents(0x30) - that's AWTEvent.MOUSE_EVENT_MASK | AWTEvent.MOUSE_MOTION_EVENT_MASK, for those not familiar. I added an override for processKeyEvent, and sure enough I'm receiving key events even though they were not explicitly enabled,
29  Games Center / 4K Game Competition - 2009 / Re: Links, tips and goodies on: 2008-12-10 23:58:58
The template also says:  t.enableEvents(AWTEvent.KEY_EVENT_MASK);  However, aren't key events on by default?
I know when I override processKeyEvent(KeyEvent event) I do not have to enable key events. You might still need to enable them if you override processEvent(AWTEvent event) instead. Going with processKeyEvent will also save you the cast from AWTEvent to KeyEvent.
30  Games Center / 4K Game Competition - 2009 / Re: Help? on: 2008-12-08 19:19:57
Your game logic seems very complex with many conditions and states... with out simplifying the logic or abusing some behavior of java or math to represent your game logic I do not think you will be able to fit it with in 4k Sad
I'm starting to think the same... I've gotten it down to 6037 bytes by inlining the network code instead of using DataInput/OutputStreams, and by removing a few unnecessary states and combining a few others, but I'm not sure what else I'll be able to remove without making it simply unplayable.

Edit: now 5750 bytes... a few more trouble spots to attack before I switch from Omaha to Hold'Em to save another chunk. I'd rather stay with Omaha if I can - limit hold'em is somewhat boring IMO.
Pages: [1] 2 3 4

Add your game by posting it in the WIP section,
or publish it in Showcase.

The first screenshot will be displayed as a thumbnail.

Archive (23 views)
2015-01-29 04:26:08

theagentd (22 views)
2015-01-28 15:33:52

GamerIDGoesHere (31 views)
2015-01-27 01:23:23

GamerIDGoesHere (33 views)
2015-01-27 01:22:15

CopyableCougar4 (39 views)
2015-01-27 00:34:41

CopyableCougar4 (26 views)
2015-01-26 04:47:56

Olo (19 views)
2015-01-25 21:26:00

Olo (24 views)
2015-01-25 18:44:22

Robo11 (42 views)
2015-01-25 06:14:26

basil_ (34 views)
2015-01-17 22:29:32
2D Dynamic Lighting
by ThePixelPony
2015-01-01 20:25:42

How do I start Java Game Development?
by gouessej
2014-12-27 19:41:21

Resources for WIP games
by kpars
2014-12-18 10:26:14

Understanding relations between setOrigin, setScale and setPosition in libGdx
by mbabuskov
2014-10-09 22:35:00

Definite guide to supporting multiple device resolutions on Android (2014)
by mbabuskov
2014-10-02 22:36:02

List of Learning Resources
by Longor1996
2014-08-16 10:40:00

List of Learning Resources
by SilverTiger
2014-08-05 19:33:27

Resources for WIP games
by CogWheelz
2014-08-01 16:20:17 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!