Java-Gaming.org    
Featured games (81)
games approved by the League of Dukes
Games in Showcase (494)
Games in Android Showcase (114)
games submitted by our members
Games in WIP (563)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
    Home     Help   Search   Login   Register   
Pages: [1]
  ignore  |  Print  
  TR4KS  (Read 3284 times)
0 Members and 1 Guest are viewing this topic.
Offline davidc

Senior Member


Medals: 5
Projects: 2



« Posted 2009-12-12 03:16:22 »

TR4KS is my first entry into the Java4K competition.
http://www.stimware.com/projects/tr4ks

After looking at the other entries this year (and many from previous years), I'm not happy that mine is up to the same standard. Obviously it lacks a lot in the visual department, but what I'm really concerned about is the actual gameplay and controls. So, what i'm interested in getting some feedback on is:
  • Does it make sense what the player is supposed to do?
  • Is it challenging enough?
  • Is it even remotely fun?

I plan on making some changes to the gameplay and visuals which will involve:
  • random obstacles to lay tracks around
  • replace bitmap images with procedural graphics
  • increase the tile size
  • bigger play area (perhaps an 8x8 grid or even larger)
  • smoother train movement to give a better idea of how far away it is

I'm still completely lost as to how to effectively incorporate sounds into this thing. I've written applets before that have sound effects and music (http://www.stimware.com/projects/pacman), but not sure if it is even worth attempting given the space constraints.

Any ideas or feedback are welcome.
Offline Alan_W

JGO Knight


Medals: 8
Projects: 3


Java tames rock!


« Reply #1 - Posted 2009-12-12 08:27:44 »

It's looking good, particularly for your first 4k game.  Graphics are always a compromise, particularly if you really need bitmaps, as there just isn't space for decent sized sprite bitmaps.  Scaling up and antialiasing might work for a soft focus look, but generally procedural graphics is a better bet.

The best gameplay strategy I found was to keep selecting and dumping sections at the edge, until I got a horizontal section.  I wasn't really getting the best use of the different sections, although that might just be me. There was one freeze up when the train tried to run off the bottom of the screen; probably some null pointer or array bound error.

Sound would be nice, but the calls to set it up eat 100's of valuable bytes.  My best Java1.4 effort is to create an AudioFormat, then a DataLine.Info for a Clip object and then use AudioSystem.getLine(Line.Info) and cast the result to a Clip.  For Java1.5 there is a new AudioSystem.getClip() which gets a clip directly, although strangely that didn't seem to save much space (I need to look at that more).  Once you have a Clip, you can open it, using the AudioFormat and an array of byte data, which you can generate procedurally. Some people use a SourceDataLine rather than a clip and feed data directly into it.  Trouble is, all these library calls use way too many bytes.

The Applet also provides methods to play .au & in recent JREs .wav files directly.  Problem is these are really too big for 4k.  I have tried creating a very small wave (a few milliseconds of sine wave) and looping it.  This actually worked, but only gave me a continuous tone and still used too many bytes.  I briefly wondered whether could generate a .wav procedurally, write it out to a temporary file and then read it back in using Applet's play() method, but this requires signing the Applet, which is a pain.

There is also getToolkit.beep() which plays the default system beep; but you don't know what this sounds like on the target system.  There is also the sun.audio classes, which are still there in JRE1.6 and provided you give them 8000Hz uLaw 8bit data, work Ok in applets.  The problem is they only work in the sun JVM and are not present in some Linux JVMs and including them will cause the applet to fail to load.  Ok one can monkey about with the Classloader at run time, but this rather defeats the objective of saving space.

Time flies like a bird. Fruit flies like a banana.
Offline pjt33
« Reply #2 - Posted 2009-12-12 11:54:50 »

I played it a day or two ago, figured out what to do quite easily, and thought it a fun minigame which I might play again later.
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline davidc

Senior Member


Medals: 5
Projects: 2



« Reply #3 - Posted 2009-12-12 13:42:08 »

I played it a day or two ago, figured out what to do quite easily, and thought it a fun minigame which I might play again later.

Excellent, good to know. I was toying with the idea of showing the next tile to place in a separate area rather than at the cursor, but if this  works I'll just stick with it.

There was one freeze up when the train tried to run off the bottom of the screen; probably some null pointer or array bound error.

Silly me, can't believe I didn't check for that Shocked

Thanks for the comments!
Offline SquashMonster

Senior Member


Medals: 1
Projects: 2



« Reply #4 - Posted 2009-12-12 22:52:43 »

It's pretty fun.  Besides what you listed, the only change I'd really push for is something that makes it more clear what piece is under your cursor.  It's also so risky to try to redo the track with bombs right now that I almost never do it, since you need both the bomb and a replacement; could you show a queue of the next few pieces so we know if it's safe to rearrange?

Not bad at all for a first attempt.  What packing program(s) are you using?
Offline Abuse

JGO Knight


Medals: 12


falling into the abyss of reality


« Reply #5 - Posted 2009-12-13 00:40:20 »

Good concept, though at the moment the outcome seems to be strongly determined by luck of the draw.

Instead of using pure random numbers, perhaps you should randomize the order of a predetermined set.

There's a thread elsewhere on here from a while back (probably a few years ago by now ^^) that went into the topic of 'good randomness'.
I'm sure someone else will remember it, and be able to point you in it's direction.

Make Elite IV:Dangerous happen! Pledge your backing at KICKSTARTER here! https://dl.dropbox.com/u/54785909/EliteIVsmaller.png
Offline Eli Delventhal

JGO Kernel


Medals: 42
Projects: 11
Exp: 10 years


Game Engineer


« Reply #6 - Posted 2009-12-13 02:02:34 »

I'm not sure if it was just me, but the train appeared to randomly crash for no reason, typically because of turns and 4-ways. What are the exact rules for when it is allowed to turn a certain way?

Overall, I think the gameplay is indeed a bit too random. Okay, much too random. I would just place tiles on edges until I got one going left-right. Sometimes I would attempt to do curves and whatnot, but that rarely paid off. The worst was at the very beginning when I would get a curve tile that I literally could not use. Seems dumb.

See my work:
OTC Software
Offline SquashMonster

Senior Member


Medals: 1
Projects: 2



« Reply #7 - Posted 2009-12-13 03:01:20 »

I think the best strategy is to spend your curve pieces making zig-zagged paths one above and one below the straight path, starting near the exits.  You can turn towards one of your curved paths when that meets up with your straight path.  You could also attempt to use a crossover piece with one of them, but that's hard due to the way bombs work.

Davidc, have you ever played Pipe Dream?  It's pretty similar, maybe it'd give you ideas.
Offline davidc

Senior Member


Medals: 5
Projects: 2



« Reply #8 - Posted 2009-12-13 05:59:36 »

It's also so risky to try to redo the track with bombs right now that I almost never do it, since you need both the bomb and a replacement

The bomb only clears the piece underneath the tile. Most of the time I don't use it either, except if I have been forced to put a bend where I don't want it.

Not bad at all for a first attempt.  What packing program(s) are you using?

Just ProGuard at the moment, haven't both using Pack or other utils. I might give them a go if it gets a bit tight adding new features.

Instead of using pure random numbers, perhaps you should randomize the order of a predetermined set.

I did think about weighting the pieces a bit more, so the straight ones appear less often and the cross-roads very rarely. This however makes it harder on such a small board.

I'm not sure if it was just me, but the train appeared to randomly crash for no reason, typically because of turns and 4-ways. What are the exact rules for when it is allowed to turn a certain way?

If the train approaches a four way intersection it should always go straight ahead. I had some other ideas for intersections but they don't really work in such a small format.

The worst was at the very beginning when I would get a curve tile that I literally could not use. Seems dumb.

I agree, you really need to get a good tile early or you can run out of time very fast.

Davidc, have you ever played Pipe Dream?  It's pretty similar, maybe it'd give you ideas.

No, but will check it out.

Thanks again for all the comments folks. I have fixed the bug raised earlier by Alan_W, if I get time I might see about making the grid bigger as this may make it a lot easier to play. I'm still looking at some rudimentary sound ideas given the feedback from Alan, a simple toot-toot as the train approaches would be satisfactory.

Offline Mike

JGO Wizard


Medals: 76
Projects: 1
Exp: 6 years


Java guru wanabee


« Reply #9 - Posted 2009-12-14 16:05:16 »

Bigger grid, ability to turn tiles and it'll be really fun. Managed to get to level 4 now but at the moment it is almost only luck, some skill would be fun Smiley

My current game, Minecraft meets Farmville and goes online Smiley
State of Fortune | Discussion thread @ JGO
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline davidc

Senior Member


Medals: 5
Projects: 2



« Reply #10 - Posted 2009-12-14 16:24:41 »

ability to turn tiles

That's a good idea for making it more of a game of skill, I would probably limit it to a set number of rotations per level.
Offline me

Senior Member


Projects: 4


Java games rock!


« Reply #11 - Posted 2009-12-14 19:26:24 »

Hi DavidC,

Good start. There was a sort of tube-game in the past
4k-years that looks similar.

I'm in favor of more skill-based instead of random based
levels. Maybe have some fixed tiles that can't be altered?!

Looking forward for next iterations ...

Best regards from

M.E.

M.E.
--------
Offline davidc

Senior Member


Medals: 5
Projects: 2



« Reply #12 - Posted 2009-12-15 01:06:59 »

Maybe have some fixed tiles that can't be altered?!

That was something I considered, some random trees/boulders/ponds which could force the player to lay the track around them. It might even make the final cut.
Offline soothsayer

Senior Newbie


Projects: 1



« Reply #13 - Posted 2009-12-16 11:21:21 »

I like this train game. Maybe the mouse control will be better choice than keyboard control because the train is moved fast enough. The animation is not so smooth, pixel movement of train would be humane for eyes.
Offline davidc

Senior Member


Medals: 5
Projects: 2



« Reply #14 - Posted 2009-12-16 13:39:21 »

I have released an update to the applet which hopefully addresses some of the very useful suggestions given already:
  • Bigger grid size (7x7)
  • Complete removal of all bitmap images, replacing them with line drawings that make good use of the Java2D API. This has allowed for bigger tiles at a smaller cost. It also gves me more scope for creating an animated train that actually points in the correct direction along the track.
  • Tiles can now be rotated, which introduces more of a skill element and reduces the reliance on luck. It is just a bit too easy at the moment though.
  • A random tree is placed on the map. Adding more per level might provide for a much needed increase in difficulty.

The animation is not so smooth, pixel movement of train would be humane for eyes.

Thanks for the feedback, I was wondering if anyone found it annoying or not. Sadly, the inhumane treatment will continue for now. I might try to implement smooth transitions between grid squares, which shouldn't be too hard given the way the train is drawn.
Offline tom
« Reply #15 - Posted 2009-12-16 17:08:07 »

Nice game. I found it a bit stressful. Maybe give some more time before the train start on the first level. I did not mind that the train was not animated. Was focused on placing the tracks instead.

If you have any space left you might have a look at this game for idees:
http://www.eyeone.com/games/overflow.jsp

It has tiles that you have to pass threw. It is possible to replace tracks, but you loose time. It has rocks you can't pass threw or destroy.

Offline davidc

Senior Member


Medals: 5
Projects: 2



« Reply #16 - Posted 2009-12-17 00:34:42 »

It has tiles that you have to pass threw.

That's not a bad idea. Perhaps some passengers that need to be picked up for extra points.
Offline tom
« Reply #17 - Posted 2009-12-17 16:26:09 »

You could also add points for going threw a corner tile and crossing tile.

Offline davidc

Senior Member


Medals: 5
Projects: 2



« Reply #18 - Posted 2009-12-17 16:43:17 »

You could also add points for going threw a corner tile and crossing tile.

I think that would add some much needed motivation to make interesting tracks, rather than just go for a straight line to finish the level. That Pipe Dream game gave extra points for crossing over an already used pipe, so that would work well. There were also pipes that would slow the flow down, which i could achieve by adding stations where the train has to stop and pause.

Quite a few good ideas and I've got nearly 200 bytes left to work with.
Pages: [1]
  ignore  |  Print  
 
 
You cannot reply to this message, because it is very, very old.

 

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

The first screenshot will be displayed as a thumbnail.

Dwinin (19 views)
2014-09-12 09:08:26

Norakomi (54 views)
2014-09-10 13:57:51

TehJavaDev (63 views)
2014-09-10 06:39:09

Tekkerue (31 views)
2014-09-09 02:24:56

mitcheeb (53 views)
2014-09-08 06:06:29

BurntPizza (37 views)
2014-09-07 01:13:42

Longarmx (23 views)
2014-09-07 01:12:14

Longarmx (27 views)
2014-09-07 01:11:22

Longarmx (26 views)
2014-09-07 01:10:19

mitcheeb (34 views)
2014-09-04 23:08:59
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

Resources for WIP games
by CogWheelz
2014-08-01 16:19:50

List of Learning Resources
by SilverTiger
2014-07-31 16:29:50

List of Learning Resources
by SilverTiger
2014-07-31 16:26:06

List of Learning Resources
by SilverTiger
2014-07-31 11:54:12

HotSpot Options
by dleskov
2014-07-08 01:59:08
java-gaming.org 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‑gaming.org
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!