Java-Gaming.org Hi !
 Featured games (91) games approved by the League of Dukes Games in Showcase (804) Games in Android Showcase (239) games submitted by our members Games in WIP (868) games currently in development
 News: Read the Java Gaming Resources, or peek at the official Java tutorials
 Show Posts Pages: [1] 2 3 ... 5
 1 Game Development / Game Play & Game Design / Re: Shooting a Fireball on: 2012-03-23 02:29:06 Why is your name DeafTV?
 2 Game Development / Newbie & Debugging Questions / Re: Finding a path to nearest walkable tile, of a nonwalkable tile on: 2012-03-21 02:51:30 After the A* calculations are done you have a closed list.  This is the list of all the tiles that you can reach.  cycle through those and find the one that is closest to the destination (aka: your tree).  You can use a simple calculation to figure out how close it is to the destination like Math.abs(nX - dX) + Math.abs(nY - dY);
 4 Game Development / Newbie & Debugging Questions / Re: Finding a path to nearest walkable tile, of a nonwalkable tile on: 2012-03-20 04:40:17 If you can't reach the tree, it shouldn't be in your open list.
 5 Game Development / Newbie & Debugging Questions / Re: Finding a path to nearest walkable tile, of a nonwalkable tile on: 2012-03-20 04:00:40 Examine the tiles in the closed list, calculate the distance to the destination and pick the one that has the least.
 6 Game Development / Game Play & Game Design / Re: smoother x/y-axis increments on: 2012-03-18 03:03:19 If you're using any sort of timer that updates (or allows updating) of the sprite position when time's up, then you can just use the speed of the sprite to calculate the new timer time.  Each sprite would need it's own timer, but that's normal.
 7 Game Development / Game Play & Game Design / Re: game balance, costs & benefits on: 2012-03-18 02:59:02 I completely understand what 65k is saying.  I thought about this in a Street Fighter scenario.  Maybe your custom character starts out with flat speed, strength, etc...  As you progress you can better fit your character to your style of game play, Increasing one aspect at the penalty of another (each level up, allows you to move x aspect points).  Some prefer fast players with combo moves, others the big brutes, and then there's the lamers who prefer sitting in a corner throwing shuriken the whole time.I think it's a good idea, as long as it doesn't become a game of rock-paper-scissors (strength beats speed, speed beats stamina, stamina beats strength).
 8 Discussions / General Discussions / Re: Anyone want to help test my Voxel Editor? on: 2012-03-16 05:33:45 Works fine here with Ubuntu 10.10, however you failed to mention that arrow keys moves and rotates the camera.
 9 Game Development / Newbie & Debugging Questions / Re: Could someone explain this line of code? on: 2012-03-13 17:59:32 >> 8 gives you green, because green starts at the 8th bit (it's address, if you will).  >> shifts in bits,  so to get red it's >> 16 (3rd byte) and so on.
 10 Discussions / Miscellaneous Topics / Re: Statistics project: Please take a few seconds to answer! :) on: 2012-03-13 13:32:22 33, Caucasian, Male, heavy metal & techno.
 11 Game Development / Newbie & Debugging Questions / Re: Override what? on: 2012-03-12 00:54:09 This whole time I was passing 'this' to it, saving it as 'that'.  I never knew I could use that.createImage().  Thank you for the pointer.
 12 Discussions / General Discussions / Re: ZOVE is [seeking volunteer] java programmers! on: 2012-03-06 20:18:20 Quote from: RylandAlmanza on 2012-03-05 20:26:21Yeah, the website could use a lot of work. Reminds me of my first website. I was so silly. Edit: Was about to post the link to my old website from 2007 from the way back machine, but I looked it over and it was too embarrassing, lol.Oh My.  I didn't know this existed...  Time to usurp Zove's post:http://web.archive.org/web/20041206233914/http://gbeebe.com/index.php?date=2004-08-11 When I aspired to do a web comic.http://web.archive.org/web/20030803062838/http://www.gbeebe.com/ Hey, my old logo!
 13 Discussions / Miscellaneous Topics / Re: Single atom transistors! on: 2012-03-06 19:29:26 That was meant as a joke, actually, I think everyone understood that.  I was going to reference Microsoft in the joke, but figured not everyone has the hatred that I do towards them.Quote from: RylandAlmanza on 2012-03-06 19:15:02Quote from: ReBirth on 2012-03-06 14:34:06Yeah, it's not like you split atoms when you break a glass.I'm going to go break glass over and over until I split an atom. Just to prove you wrong!The look on your face when you actually do it... oh, wait...
 14 Game Development / Game Play & Game Design / Re: What makes a Good RPG? Your thoughts/opinion. on: 2012-03-06 16:11:50 Story line/Plot, Mini/side quests, Rare Items with cool powers.  I've played some decent RPGs that didn't have great sound or music.I also think that if you can keep the player involved, for say 50 total hours, until the game is won, you've done a good job.
 15 Discussions / Miscellaneous Topics / Re: Single atom transistors! on: 2012-03-05 05:07:07 And what happens when you get some Read/Write access error, due to some bad multi-thread programming.  Could you accidentally split the atom?
 16 Java Game APIs & Engines / Java 2D / Re: Getting rid of trails? on: 2012-03-05 01:22:42 where is g.clearRect(0, 0, width, height); ?
 17 Discussions / General Discussions / Re: The nD on: 2012-03-04 04:02:28 ... As long as it's not another Phantom Console.
 18 Game Development / Newbie & Debugging Questions / Re: Using JScrollPane as the camera for a top-down shooter on: 2012-03-01 03:55:19 but it's working fine... maybe it's an OpenJVM thing.  I have to try it on a windows machine.
 19 Game Development / Newbie & Debugging Questions / Re: Using JScrollPane as the camera for a top-down shooter on: 2012-03-01 03:35:21 I had setIgnoreRepaint(true); then called repaint(); in the main loop each frame.  Kinda' the same thing, I guess.
20  Game Development / Newbie & Debugging Questions / Re: Using JScrollPane as the camera for a top-down shooter on: 2012-02-29 05:58:45
My Paint method looks, like this:
 1  2  3  4  5  6  7  8  9  10 `public void paint(Graphics g) {            Graphics2D b = (Graphics2D) bufferStrategy.getDrawGraphics();       //b.clearRect(0, 0, WIDTH, HEIGHT);       b.drawImage(imgDbl, 0, 0, screenWidth, screenHeight, null);       //b.drawImage(imgAll, 0, 0, null);       b.dispose();       bufferStrategy.show();         }`

Note:  My main class extends Frame, and a canvas is added to it.
 21 Game Development / Newbie & Debugging Questions / Re: Using JScrollPane as the camera for a top-down shooter on: 2012-02-29 04:53:47 Well, IMHO, I think they're wrong.
22  Game Development / Newbie & Debugging Questions / Re: Using JScrollPane as the camera for a top-down shooter on: 2012-02-29 04:42:35
To center a player (or any "Followable") in the middle of the screen:

 1 `g2.translate(-following.getX() + screenWidth/2, -following.getY() + screenHeight/2);`

Yea, I was just being cheap.
23  Game Development / Newbie & Debugging Questions / Re: Using JScrollPane as the camera for a top-down shooter on: 2012-02-29 04:37:30
I would do something to what ra4king is saying, but I would make a Followable interface with .getX() and .getY().  Have any class that you want to be able to follow implement the interface.  You then could do something like this:

 1  2  3  4  5  6  7  8  9  10  11  12 `//Your variableFollowable following;//Somewhere else:following = player1;public void paint(Graphics g) {    Graphics2D g2d = (Graphics2D) g;        g2d.translate(following.getX(), following.getY());        //draw stuff`

You could then have fancy stuff, like a Camera class that can be followed.  It could move over to where something is going on, and then move back to Player1.  etc...

It's java, so it's all up to your imagination.
 24 Discussions / General Discussions / Re: This ever happen to you? on: 2012-02-24 04:39:46 Quote from: UprightPath on 2012-02-24 04:29:37Hmm, I'd add in something about not aging while in the bubble.Yea, I've thought about that too, but then I get into the physics behind it and deem it all impossible with the electricity outside being paused in time and not being able to reach the computer to make it work.
 25 Discussions / General Discussions / Re: This ever happen to you? on: 2012-02-24 04:17:54 I love it when the alarm clock goes off waking me up early, walk towards the bathroom to take a shower, pause for a sec... run back to the bedroom, grab my cellphone, pull up the calendar...  Today is my day off!   And I'm up before the kids are.  Time to get in some decent programming hours.  I love that feeling.  But then the wife comes down stairs shortly after and asks "Have you been on that thing all night long?"  I do the whole laying in bed, plotting the next couple of procedures and coming up with solutions to problems, I've even coded in my sleep.  I remember waking up in the middle of the night thinking "that would totally work", but I never get up to type the code... If only I could type in my sleep.When I was younger, I used to gauge what day it was based on the amount of code that I had.  I remember the feeling of sadness when a 3 day weekend was over and it seemed that I had accomplished squat.  Getting home from school and opening my math book to pull out a quiz that I had jotted pseudo code on the back of, to implement it.  A lot of my coding is done this way now.   I'll bring home, from work, drawings, diagrams, formulas, pseudo code, game maps, etc on blank paper swiped from the fax machine.  When the wife and kids are in bed it's code time.  Sometimes it'll be midnight and I tell myself "I can wrap this last bit up in a couple of minutes before bed" then when I get it done it's like 3:00.I assume that I'm not alone, when deciding on a super power, I'd pick the ability to create a bubble around me with about a 6 foot radius.  Everything on the inside would work as normal, everything on the outside would be paused in time.  I could code forever and sleep as much as I want, and still have time to do the things that I must do.
 26 Game Development / Performance Tuning / Re: Fast Collision Detection on: 2012-02-22 03:58:09 If you already know how to tell if 2 images at given coordinates overlap, then scan the overlapping pixels in each image in that box, using Image.GetRGB().  If both overlapping pixels contain a solid color then the images have collided.  You could speed this up by making an array of 1's and 0's for each image prior to playing and checking those for collision.  I haven't done this in Java, but from my experiences in other languages, pixel perfect collision is very costly, especially if you have lots of blank pixels in your image, and many on screen images to check.  There are other shortcuts that that aren't as costly, such as bounding vectors (an array of points that outline your shape).  Do you necessarily need pixel perfect collision?
 27 Games Center / Featured Games / Re: Pixel Towers - Android / Desktop Game on: 2012-02-21 16:00:14 It's an onboard video card in my linux machine     I installed in on my Acer A500 tablet, it works great on it.  My 5yo son likes it.  A few questions though:  When the people move, the appear to be "animated" so they aren't 1x3 pixel sprites are they?  What does it mean when it says "slow down"?  Did I manage to get a power up, or is it telling me I'm going too fast?
 28 Games Center / Featured Games / Re: Pixel Towers - Android / Desktop Game on: 2012-02-21 01:24:05 meh, new error:QuoteNot a directory: ../pixeltower-android/assets/gfxException in thread "LWJGL Application" java.lang.NullPointerException   at com.thegreystudios.pixeltower.screen.SplashScreen.present(SplashScreen.java:86)   at com.thegreystudios.pixeltower.Game.render(Game.java:38)   at com.thegreystudios.pixeltower.PixelTower.render(PixelTower.java:26)   at com.badlogic.gdx.backends.lwjgl.LwjglApplication.mainLoop(LwjglApplication.java:163)   at com.badlogic.gdx.backends.lwjgl.LwjglApplication\$1.run(LwjglApplication.java:113)