Java-Gaming.org    
Featured games (81)
games approved by the League of Dukes
Games in Showcase (491)
Games in Android Showcase (112)
games submitted by our members
Games in WIP (556)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
    Home     Help   Search   Login   Register   
Pages: [1] 2 3
  ignore  |  Print  
  Battle tank 2 - a bird eye view shooter (completed!)  (Read 14710 times)
0 Members and 1 Guest are viewing this topic.
Offline phu004

JGO Coder


Medals: 4
Projects: 9
Exp: 10 years


NoSuchPersonException


« Posted 2008-11-11 03:37:39 »

It is a typical shoot them up type of game,  I borrowed some of the game element
from both Quake series and C&C, so you will definitely find something familar there.

Here is a shot:


You can  try it here:
http://www.freewebs.com/phu004/BT2/play.htm

If you are interested in the source code feel free to grab it
http://www.freewebs.com/phu004/battletank2.zip

(the total content need to be download is less than 0.5 mb, so the game should start fairly quickly)

controls:
W,S = move forward/backword
A,D = turn left/right
mouse = move turret around
left click = shoot
1 = normal cannon
2 = rocket launcher
3 = railgun
4 = nuke cannon

"q"  = toggle between weapons


It would be nice if you can give me some feedback and suggestion about  the game.


Cheers

Pan




Offline SimonH
« Reply #1 - Posted 2008-11-11 04:47:02 »

I like this! Good atmosphere.
Handling needs a bit of a tweak (ie momentum on the tank; it shouldn't just 'stop' when forward is released)
'S' to fire??? Make it space or ctrl.
Needs some ambience (darken the background) and instructions (keys? and what are those boxes when enemies die?) on the same page as the app.
Maybe slow the firing rate a little? Seems a bit fast for tanks...?
Otherwise; handles well, looks good - love the water & barriers - I think you're onto something here!

BTW You can use requestFocus() at the start of the run() method to grab the keyboard without the user having to click on the app to play.

Keep it up!

People make games and games make people
Offline phu004

JGO Coder


Medals: 4
Projects: 9
Exp: 10 years


NoSuchPersonException


« Reply #2 - Posted 2008-11-11 07:37:52 »

Thanks for the suggestion SimonH.

If I ever manage to finish the game, the tank won't shoot/move near as fast as now.
I configured this for the purpose of  testing. But I should really take away its godlike
power next time I update.

"s" to fire, because I have made "a,d" for performing dodging moves (similar to FPS game).
 I think this setup is more convie.nce for the player. I will let ppl configure their own settings
eventually.

I am sure making the background darker is a good idea, but technically I don't know how
to do this efficiently.  The player tank will always stay in the centre bottom  of the screen,
maybe i could apply a precalculated ambient map after I finish drawing everthing.

I guess you don't played Quake 3 arena much  Grin, if you do you will immiditely realise
that these boxes droped by enemy are ammunitions. At this stage the player has
infitite ammo, so they won't do anything.

Nice hint for the keyboard focusing, I will implement this in my next update.

Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline mh114

Junior Member





« Reply #3 - Posted 2008-11-11 07:49:33 »

Looks nice, I like the shadows and the water is nifty looking! Smiley One suggestion, you should use (at least) bilinear filtering and more importantly mipmaps on the textures. I suspect that pixel flickering / artefacts will get tiresome to look at after a while, IMHO of course.

Otherwise it feels very solid start, keep it up!  Cool

Offline phu004

JGO Coder


Medals: 4
Projects: 9
Exp: 10 years


NoSuchPersonException


« Reply #4 - Posted 2008-11-11 08:47:03 »

Yeah, the flickering is annoying. It is definitly a good idea to apply mini maps,  and it shouldn't be too hard to implement.
Thanks for pointing out.
Offline zammbi

JGO Coder


Medals: 4



« Reply #5 - Posted 2008-11-11 08:48:31 »

Very nice start, can't wait to see what it becomes.

Current project - Rename and Sort
Offline atomhamster

Senior Newbie





« Reply #6 - Posted 2008-11-11 09:23:36 »

Yes, a nice start! Some other suggestions:

- the auto-align is nice, but also counter intuitive. whenever i move, the turret tends to face forward
- maybe use the mouse to aim? this would make it easier to drive away from enemies and still fire in their direction
- fire rate is too high and bullets are too fast. you can't see very far and it leaves no option to evade enemy fire

nevertheless, this is just tweaking. nice work!
Offline phu004

JGO Coder


Medals: 4
Projects: 9
Exp: 10 years


NoSuchPersonException


« Reply #7 - Posted 2008-11-11 10:59:29 »

thx for the suggestions

Quote
the auto-align is nice, but also counter intuitive. whenever i move, the turret tends to face forward

Yeah it feels a little weird from a bird eye point of view, maybe I could make the turret rotation slightly lagging behind the camera rotation.


Quote
maybe use the mouse to aim? this would make it easier to drive away from enemies and still fire in their direction

Using a mouse might be a good idea, but I personally don't like using mouse in an applet,  the user could lose focus by moving the
cursor outside of the applet window. 
You can press "a" or "d" to move side ways, while keep your turret facing towards the enemy position. (like circle strafing)
Offline SimonH
« Reply #8 - Posted 2008-11-11 15:15:17 »

I am sure making the background darker is a good idea, but technically I don't know how
to do this efficiently.

I only really meant the background of the webpage containing the applet  Smiley
1  
<body bgcolor="#000000">


People make games and games make people
Offline EgonOlsen
« Reply #9 - Posted 2008-11-11 16:24:20 »

Yeah, the flickering is annoying. It is definitly a good idea to apply mini maps,  and it shouldn't be too hard to implement.
Thanks for pointing out.
Using a lower frequency texture as ground texture may help to improve the visual outcome in the short run.

Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline princec

JGO Kernel


Medals: 369
Projects: 3
Exp: 16 years


Eh? Who? What? ... Me?


« Reply #10 - Posted 2008-11-11 19:29:51 »

Extra impressive.

Cas Smiley

Offline mgianota

Senior Newbie





« Reply #11 - Posted 2008-11-11 19:42:25 »

Excellent start. Keep going and let's see the finished game.

--Mario
Offline ChrisM

JGO Coder


Medals: 1
Projects: 1


END OF LINE.


« Reply #12 - Posted 2008-11-11 20:42:51 »

Excellent!  And a Java app in a browser that seems to work for all who tried it...Hmmmm.....Wink

Offline kevglass

JGO Kernel


Medals: 159
Projects: 23
Exp: 18 years


Coder, Trainee Pixel Artist, Game Reviewer


« Reply #13 - Posted 2008-11-11 20:50:19 »

Oh pppppuuuurrrrrrlllleeeaase..... Tongue

Great fun game btw.

Kev

Offline phu004

JGO Coder


Medals: 4
Projects: 9
Exp: 10 years


NoSuchPersonException


« Reply #14 - Posted 2008-11-11 21:00:18 »

Thanks for the positive comments guys.

I just made a few changes to the applet, the tank movement and shooting has have been tweaked,
the applet now have the control of the keyboard when it starts up, and I also enabled collision detection.

Quote
Using a lower frequency texture as ground texture may help to improve the visual outcome in the short run.


That was what I was thinking when I chose the textures. It is not easy to find a perfect one though. I think mini map will be
the ultimate solution.




Offline DzzD
« Reply #15 - Posted 2008-11-12 12:23:54 »

Quote
That was what I was thinking when I chose the textures. It is not easy to find a perfect one though. I think mini map will be
the ultimate solution.

just apply a blur filter on your image

Offline Markus_Persson

JGO Wizard


Medals: 14
Projects: 19


Mojang Specifications


« Reply #16 - Posted 2008-11-12 13:58:31 »

Very neat. =D


Might I suggest a different movement scheme, though?

W accelerates, S decelerates.
A and D turn the tank but not the turret (ie the camera doesn't rotate when pressing A or D)
Left/Right arrow keys rotate the turret but not the tank.
Space fires.

Right now you move the tank with both the right hand (forwards/backwards) and the left (strafe left and right), which feels kinda odd. Not to mention shooting with 's' is just weird. Wink

Play Minecraft!
Offline phu004

JGO Coder


Medals: 4
Projects: 9
Exp: 10 years


NoSuchPersonException


« Reply #17 - Posted 2008-11-12 23:23:49 »

Quote
W accelerates, S decelerates.
A and D turn the tank but not the turret (ie the camera doesn't rotate when pressing A or D)
Left/Right arrow keys rotate the turret but not the tank.
Space fires.

Right now you move the tank with both the right hand (forwards/backwards) and the left (strafe left and right), which feels kinda odd. Not to mention shooting with 's' is just weird.

Thx for the comment.  Damn why nobody like the key setting that I invented Sad .
Anyway I have update the controls to excatly what you have suggested.
Offline noblemaster

JGO Ninja


Medals: 20
Projects: 10


Age of Conquest makes your day!


« Reply #18 - Posted 2008-11-13 00:00:15 »

Quote
Damn why nobody like the key setting that I invented Sad
It's very nice otherwise! At least we found something to complain about  Grin

Offline Eli Delventhal

JGO Kernel


Medals: 42
Projects: 11
Exp: 10 years


Game Engineer


« Reply #19 - Posted 2008-11-13 03:44:01 »

Fun! I would have liked to change the upwards angle of my cannon.

See my work:
OTC Software
Offline Markus_Persson

JGO Wizard


Medals: 14
Projects: 19


Mojang Specifications


« Reply #20 - Posted 2008-11-13 09:45:44 »

Anyway I have update the controls to excatly what you have suggested.

Awesome, that was fast! It feels a lot more fluid now, imo. I can't wait for you to finish this =D

I love the distortion effect on the waves, force fields and cloaked rail gun enemies.  Smiley

Play Minecraft!
Offline markus.borbely

Junior Member





« Reply #21 - Posted 2008-11-13 11:00:55 »

Very nice. Works perfect on my Mac.
Controls are much better now.
Offline Hansdampf

Senior Member


Projects: 3


too offending?


« Reply #22 - Posted 2008-11-13 12:34:14 »

Very nice!
I imagine it could evolve into something like the good old 'Firepower' on Amiga.

Excellent!  And a Java app in a browser that seems to work for all who tried it...Hmmmm.....Wink
... until I hit browser reload  Tongue

edit:
1  
2  
3  
4  
5  
6  
7  
8  
9  
Exception in thread "Thread-10" java.lang.NullPointerException
   at rasterizer.renderTerrain(rasterizer.java:315)
   at rasterizer.rasterize(rasterizer.java:95)
   at polygon3D.draw(polygon3D.java:268)
   at terrain.draw(terrain.java:798)
   at main.actionPerformed(main.java:193)
   at Ticker.fireActionPerformed(Ticker.java:59)
   at Ticker.run(Ticker.java:66)
   at java.lang.Thread.run(Unknown Source)

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

JGO Coder


Medals: 4
Projects: 9
Exp: 10 years


NoSuchPersonException


« Reply #23 - Posted 2008-11-13 18:46:05 »

Quote
Very nice!
I imagine it could evolve into something like the good old 'Firepower' on Amiga.

... until I hit browser reload 

When you click the refresh button, the destory() method is invoked  in the
middle of the rendering piple line (I extend this method to delete the look up table, etc),   
It is a bit annoying when it happens, but did it crash your browser as well?
Offline Hansdampf

Senior Member


Projects: 3


too offending?


« Reply #24 - Posted 2008-11-13 19:35:04 »

but did it crash your browser as well?
No, and I'm sure you can fix it because leaving/re-entering the page works fine  Smiley

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

JGO Coder


Medals: 4
Projects: 9
Exp: 10 years


NoSuchPersonException


« Reply #25 - Posted 2008-11-14 02:22:25 »

Quote
No, and I'm sure you can fix it because leaving/re-entering the page works fine 

fixed Smiley

By the Way can any of you guys try to  keep refreshing the applet for a couple of time, see if it gives a
java out of memory exception?
Offline mgianota

Senior Newbie





« Reply #26 - Posted 2008-11-14 02:35:35 »

You're not gonna believe what just happened. I was reloading the Applet over and over again. On about the twentieth reload the applet left the window and reappeared in the top left hand corner of the screen! Cheesy BTW I saw no memory issues in task manager.

This Applet stuff is getting hysterical, it really is.

--Mario
Offline phu004

JGO Coder


Medals: 4
Projects: 9
Exp: 10 years


NoSuchPersonException


« Reply #27 - Posted 2008-11-14 02:56:08 »

Quote
On about the twentieth reload the applet left the window and reappeared in the top left hand corner of the screen!

LoL  that was unexpected.  But after trying it out myself I saw the same thing.

It might be a glitch from running the java script  in the back ground.
Let me have a look .
Offline CommanderKeith
« Reply #28 - Posted 2008-11-14 06:38:59 »

This is a radical game, nice job, especially with the graphics.

May I ask, how did you do the 3d graphics? And where did you get all the trees, tanks, terrain etc

I read that you don't like to use the mouse in an applet, but I think it would be much more fun if you could fire and direct the turret with the mouse, but still steer with the keys. If the player loses focus, you can just tell him so in the applet.

cool game!  Cool






Offline phu004

JGO Coder


Medals: 4
Projects: 9
Exp: 10 years


NoSuchPersonException


« Reply #29 - Posted 2008-11-14 08:24:58 »

Quote
May I ask, how did you do the 3d graphics? And where did you get all the trees, tanks, terrain etc.

Thanks for the postive comment.

There is nothing special about the graphic,  I lernt most of the rendering stuff from David Brackeen's
eBook, Developing game in Java.  Perhaps the only new thing i have tried is the distortion effect.


Modeling those tanks,  trees is actually a pain in the ass. You see I hard coded them in a very primitive way.
They are also very simple such that the polygons will get drawn correctly without sorting.   
I got all the textures through a little bit google searching.
And all the shadows are the result of hand drawing Grin


Quote
I think it would be much more fun if you could fire and direct the turret with the mouse, but still steer with the keys. If the player loses focus, you can just tell him so in the applet

I can think of 3 possible way to do this:

1. have the mosue direct the turret only, but it will be hard for the other hand to move the tank and the camera at the same time.
You will need to press at least  6 differnt keys i.e move forward, move backword, turn tank body left, turn tank bodyright, turn camera left, turn camera right.

2 have the mouse direct tank turret and the camera at the same time, then you will need to find a good way to rotate camera within the applet area.

3 click a point on the screen, and have the camera automatically turning to that direction.  I am not sure how well this will work in practice.

Anyway I will keep working on this while adding more game elements.


Pages: [1] 2 3
  ignore  |  Print  
 
 

 
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!