Hi !
Featured games (91)
games approved by the League of Dukes
Games in Showcase (757)
Games in Android Showcase (229)
games submitted by our members
Games in WIP (843)
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 ... 7
1  Game Development / Newbie & Debugging Questions / Laying out images with equal spacing on: 2013-10-13 05:20:07
Hey Everyone, this question is not necessarily language specific.

I am trying to create a "picture frame" style application. I have my images added to a panel and the panel itself has a background image. This background image is used as the border. When the user increases the border I want to shrink all of the images by the border size. The issue with this is that with adjacent images the border looks "double" the size of the outer border.

I am trying to think of an algorithm that will be able to resize all of the images and position them with equal space. My application reads in the data (strings) for the different frames available which can have a wide array of different grids (4 x 4, 2 on top, one wide on the bottom, etc). I am thinking that I need to some how add some information to tell the grid if it has a neighbor or not and move the image only half the border width.

I know this is kind of confusing or jumbled but basically am asking for a way to shrink these images with equal spacing between them.
2  Game Development / Newbie & Debugging Questions / Re: Creating an application with multiple panels on: 2012-12-04 22:34:51
Right, I kind of realized i was mixing these a bit too much just a bit ago and decided I would essentially create a model which I can manipulate values for and then the panels can use the model to display what they need to.

My only issue with that is, lets say I have a model which has a customer. The person using the software  searches the phone number "555-5555" and when he hits search it sets the Model's customer objects phone number to "555-5555" and takes him to the SearchResult screen, this screen will use that customer objects phone number to perform the search and display it. All is good, and lets say he goes back to the main screen and searches again, the customers phone number will change and therefore the search will still work.

I think?

Any problem with this idea?
3  Game Development / Newbie & Debugging Questions / Creating an application with multiple panels on: 2012-12-04 22:03:39
Hey Everyone, this isnt really game related but I am having some problems creating a Java Swing application with multiple jpanels.

I am using the CardLayout which works great for switching between screens however my issue is with passing data. For example I have a MainPanel with a MenuScreen and SearchScreen, on my MenuScreen I have a textbox which one enters a phone number and hits search. This should then switch the screen to the SearchResult screen which will display the results of a SQL Query using the number provided on the MenuScreen.

I am wondering, if I am using a cardlayout on the MainPanel which I call in order to switch screens, how do I pass the new screen the phone number value?

4  Game Development / Newbie & Debugging Questions / Re: I can't make an arraylist of integers?! on: 2012-07-11 02:33:29
You need to have an ArrayList of Integer not int, int is a primitive data type not an object.
5  Games Center / Featured Games / Re: Daedalus on: 2012-03-21 06:04:14
If it is the same laptop as before ( same video card ) maybe it is just a problem with the drivers ? Can you still run call of duty with your current setup ?

Oh no its a different one, looks like the upgraded my processor and memory but shook me a bit on the graphics card
6  Games Center / Featured Games / Re: Daedalus on: 2012-03-20 09:38:37
Damn, I had a laptop which played Call of duty world at war on high settings perfectly fine, but it broke and the warranty sent me a new one (this one) and now it cant play this 2D Java game  Cranky Clueless
7  Games Center / Featured Games / Re: Daedalus on: 2012-03-20 09:14:38
Ahh ok I got the error log this time, here it is.

java.lang.IllegalStateException: Function is not supported
   at org.lwjgl.BufferChecks.checkFunctionAddress(
   at org.lwjgl.opengl.GL30.glGenFramebuffers(
   at com.deathpat.shoot.engine.LightingEngine.init(
   at com.deathpat.shoot.engine.Engine.init(
   at com.deathpat.shoot.Shoot.main(
8  Games Center / Archived Projects / Re: Never Snuggle With Zombies on: 2012-03-20 08:49:57
Aside from the hiccups of getting it started the game is actually presented really well! Someone up there said "even if its flash style" but thats actually a good thing compared to most java games, good job!
9  Games Center / Featured Games / Re: Daedalus on: 2012-03-20 07:29:05
Window opens up and then it crashes before I can see anything, I opened the .shoot/1.3/ folder but there was only the config file, no error logs.

Wish it would work though because it looks amazing, especially for 4/5 months!
10  Game Development / Newbie & Debugging Questions / Re: Real Time Combat Collision on: 2012-01-16 00:39:56
Yea I figure instead of using the two systems might as well use the more flexible one which would allow for bullet, "boomerang" style weapons and even stationary melee attacks, also the method with separate "hitboxes" will allow for timed attacks such as "magic" or "iced" attacks that would linger for a while afterward by giving them a time limit until they are removed from the list of "hitboxes" in the game world.

I am not really new to this stuff just looking for different methods and styles people may implement but appreciate your comments!
11  Game Development / Newbie & Debugging Questions / Re: Real Time Combat Collision on: 2012-01-14 09:39:09
Yea that was one of the methods suggested above.

and basically what I mean is a weapon which attacks out a certain distance and then comes back, like throwing a boomerang or something like that which would need to be completely separate from the player.
12  Game Development / Newbie & Debugging Questions / Re: Real Time Combat Collision on: 2012-01-14 09:16:42
Yea that is true also, there are many solutions to this as you can see but the reason I havent chosen that route is a method with a separate hitbox would allow for attacks to shift out and come back in like a grappling hook type of attack etc.

Also one issue I would see with having the player hitbox expanding to fit the weapon attack area would cause movement collision to be off wouldnt it? Since the same hitbox is used for collision.
13  Game Development / Newbie & Debugging Questions / Re: Real Time Combat Collision on: 2012-01-14 02:18:41
Yea that would work much easier but the problem with that is it will only allow attacks when the enemy and player are intersecting, which doesn't give much room for different types of attacks such as longer swords, or things like that since you dont necessarily have to be "intersecting" the enemy to attack it. But thanks for the example and suggestion, these are all good and would work all just depends on what you are looking for and the more ideas the better!
14  Game Development / Newbie & Debugging Questions / Re: Real Time Combat Collision on: 2012-01-09 22:55:57
@GabrielBailey74 Thanks, I mean how to handle the collision of the attack, like if the attack is button is hit, do you just add a "hitbox" to a list in the game world and then test it against enemies in range as Mads stated?

Or do you just have one "attack hitbox" in the player class, that gets manipulated based on the current weapon and when cycling through the game world entities, check if player is attacking and if it is, test that hitbox against nearby enemies.
15  Game Development / Newbie & Debugging Questions / Re: Real Time Combat Collision on: 2012-01-09 22:38:53
Thanks for the response, but this question is more of designing "melee" combat and comparing melee attacks to all entities in a game as opposed to basic collision detection, but either way thanks Smiley
16  Game Development / Newbie & Debugging Questions / Real Time Combat Collision on: 2012-01-09 08:50:36
Hey everyone, I was just curious as to how you all would implement real time combat in a 2D "action game." Such as a game where a character walks around and swings a sword or punches enemies.

I have heard of having hitboxes, however am not sure how to implement such a thing. One idea I have had is for example, if the player has a long sword in hand, and the sword has a "use" function, when this use function is called it adds a "hitbox" to the game world, similar to adding bullets to a game world which has bounds and is tested against all entities in the world, however this hit box just stays still and disappears after a designated time (if the sword swing lasts 1 second then it will last one second and then be removed). But this seems kind of limiting, and also requires all Weapons to have an instance of the game to be able to add the hitboxes to it.

Or I was thinking the player will just get the bounds for the weapons attack hitbox and just add it to the world, but anyways.

What are some ideas you have, I am sure better than this one haha.
17  Game Development / Game Mechanics / Re: Random Map Generation on: 2012-01-04 07:07:09
I see how you are storing the values into the 2D array of "values" but what exactly do you do with those values? How do you render the map?

Anyway, the map looks really nice, good work and thanks!
18  Game Development / Newbie & Debugging Questions / Re: I have lost my mind - Snake Game Design on: 2011-12-24 21:16:16
My first ever snake game, I used an ArrayList of Points. Every time the snake moves, I add a new Point for the new head and remove the last Point. However I don't remove the last point when capturing the apple Smiley
Also the easiest way is to not think about pixels when doing this, just think about your data. You only convert to screen coordinates when rendering. So if you have a grid of 20x20, each point would have an x and y between 0 and 19.

Good luck Smiley

Haha much cleaner than the chain reaction idea, I knew there was a simpler way, thanks! Its always nice to see what other people think to clear your brain a bit haha
19  Game Development / Newbie & Debugging Questions / I have lost my mind - Snake Game Design on: 2011-12-24 09:00:52
Recently I have been working on a bunch of random projects, havent completed anything and they have ranged from top down shooters, asteroids style games, match 3 games etc. So I decided to screw all the complicated designs and just make a complete snake game real quick, however I then realized I HAVE NO IDEA how to properly design a snake game.

I know there is no "right" way to design it but I cant even figure out any way to do it. The way I have been trying to do it is without a grid just using bounding boxes for collisions and having the snake move at a fixed distance every couple of frames or so. Why would I need a grid?

My current design is working, but it seems like its stupid. It is basically a Snake which is made up of a list of Body parts, each update I save the head's old position, update the head, and then loop through each of the Body parts from the end of the list to the front and set each body part to the location of the one next to it, and if its the first element in the array I set it to the "old head" position. It works but seems sloppy or hacked together.

But anyways, how would you guys design this seemingly simple game?
20  Games Center / Showcase / Re: Village Bastard [Ludum Dare 22] on: 2011-12-22 08:27:41
haha I really like the name!

I have a quick question though, how do you get the buildings to not display the roof when the player is inside of it?

Do you just have each building check and see if the player is within its bounds every update and not draw the roof if it is? Or does the player check if it is inside of the building? (really random specific question lol sorry but just sparked my curiosity).
21  Games Center / Featured Games / Re: Minecraft on: 2011-11-26 21:26:47
Yea seriously, has he not contributed anything to LWJGL or anything like that? Does he even acknowledge...anything to do with it?
He has donated to LWJGL in the past and the library is credited on the credit page.

Its likely he's way too busy to have time to spend or think about JGO, especially now that he has to run a company.

Ahh thats good to hear! Of course I figured he has way too many things on his mind at the moment to really detract from anything other than his company and minecraft, it just sounded like he didnt do anything in the post but its good to know he has!
22  Games Center / Featured Games / Re: Minecraft on: 2011-11-26 07:20:52
Markus has stuck with a pretty old version of LWJGL because it works on more systems than the later versions. It might have been helpful if he'd contributed some coders and / or some of that giant pile money he's made off the back of it to getting that stuff fixed and providing testing. Hm.

Cas Smiley

Yea seriously, has he not contributed anything to LWJGL or anything like that? Does he even acknowledge...anything to do with it? I remember when he posted Minecraft here for people to try it out before it became big, and now hes gone.. Clueless

*edit* lol he mentioned tigsource but not javagaming, that would have been awesome.
23  Discussions / General Discussions / Re: Brainstorming the future on: 2011-08-25 22:06:55
Nobody responded to having a place to put all the featured game as some sort of "java portal" (since this site already has a lot more traffic then most java portals ever get) could help get java games exposure, featured games feedback and maybe even some money for developers and the site? Are my posts invisible or is this just a bad idea  Huh lol
24  Discussions / General Discussions / Re: Brainstorming the future on: 2011-08-23 01:10:53
I'm trying to think of some cunning post that will turn the tables on the joke and make me look like a total genius but unfortunately I can't figure out something witty to say Cheesy

Cas Smiley

*woops read that wrong, Cas you should have just left it, I assumed you were just going along with it lol
25  Discussions / General Discussions / Re: Brainstorming the future on: 2011-08-22 08:15:33
Wow guys I never realized I had such a great impact on this community, always thought I was more of just a random person but glad that a lot of you have taken note of me, appreciate it!

As for a suggestion, I dont think I have any that will live up to the expectations you all seem to have for me, but maybe have a page for where the Featured games can be displayed in a "portal" type fashion. Which could eventually lead to some money for the site if gamers catch on to it and place some ads, or even some money for the developers and start a portal for java games right here. Although that's definitely a lot harder to do than it is to suggest.
26  Games Center / WIP games, tools & toy projects / Re: Fruit Maze on: 2011-08-12 21:11:07
Great game! An undo button would definitely be helpful though.
27  Discussions / Miscellaneous Topics / Re: Simple Server Project Help on: 2011-08-10 06:39:31
I cant help all the way at the moment but as for the styling of the text box, the problem with using a JTextArea you can not stylize individual lines of text, if you want the text to be bold all of the text will be bold. I believe you can use a JEditorPane to stylize text in a better way though.
28  Discussions / Business and Project Management Discussions / Re: DRM for Level Packs on: 2011-08-05 09:53:06
This is not really what you were asking for but maybe sell a Level/Quest editor which people can use to make their
own levels and quests that they can share which will help you add content for people whom just want to play the game, but also for people whom want to create content for the game and you would not have to worry about people
sharing levels because it would be a good thing.

Just an idea off the top of my head. Also if it is an applet or something could you just "enable" the level on their account if they pay for it?
29  Game Development / Game Mechanics / Re: Understanding Active Rendering game loops on: 2011-08-04 22:49:05
Thanks for the code and example, although I seem to see stuttering in your example also...I guess this is just something that will happen no matter what, and in a game setting I doubt it will be noticeable
30  Game Development / Game Mechanics / Re: Understanding Active Rendering game loops on: 2011-08-04 12:26:36
OK I notice the stutter, isn't the app small enough to just post the code here?

I linked to the source code, although Idk what happened to my link to the app...did you really see the app or did the link disappear? also the code is extremely basic, but I made it using my "library" but it is really only 4 files, 2 of them are significant, GameScreen (where the block is moved and drawn) and Game (the loop)
Pages: [1] 2 3 ... 7
EgonOlsen (38 views)
2018-06-10 19:43:48

EgonOlsen (20 views)
2018-06-10 19:43:44

EgonOlsen (40 views)
2018-06-10 19:43:20

DesertCoockie (187 views)
2018-05-13 18:23:11

nelsongames (122 views)
2018-04-24 18:15:36

nelsongames (121 views)
2018-04-24 18:14:32

ivj94 (861 views)
2018-03-24 14:47:39

ivj94 (122 views)
2018-03-24 14:46:31

ivj94 (758 views)
2018-03-24 14:43:53

Solater (139 views)
2018-03-17 05:04:08
Java Gaming Resources
by philfrei
2017-12-05 19:38:37

Java Gaming Resources
by philfrei
2017-12-05 19:37:39

Java Gaming Resources
by philfrei
2017-12-05 19:36:10

Java Gaming Resources
by philfrei
2017-12-05 19:33:10

List of Learning Resources
by elect
2017-03-13 14:05:44

List of Learning Resources
by elect
2017-03-13 14:04:45

SF/X Libraries
by philfrei
2017-03-02 08:45:19

SF/X Libraries
by philfrei
2017-03-02 08:44:05 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!