Java-Gaming.org    
Featured games (79)
games approved by the League of Dukes
Games in Showcase (475)
Games in Android Showcase (106)
games submitted by our members
Games in WIP (530)
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 ... 37
1  Games Center / WIP games, tools & toy projects / Re: MERCury - 2d Game Library | Experimental release in development; test it out! on: 2014-07-18 01:10:04
Added in 2 more shapes! Polygons, and Stars. They can have any amount of sides. Nothing too special, but felt I should share it.

Trippy demo


-wes  Smiley
2  Games Center / WIP games, tools & toy projects / Re: MERCury - 2d Game Library | Experimental release in development; test it out! on: 2014-07-17 19:41:05
Ok, I just added in more easy rendering of Textures in the Batcher, and linked all of these into the Graphics as well.

1  
2  
3  
4  
5  
6  
7  
8  
9  
    public void drawTexture(Texture texture, float x, float y);
    public void drawTexture(Texture texture, float x, float y, float w, float h);
    public void drawTexture(Texture texture, float x, float y, float w, float h, float rot); // Defaults to the (0,0) corner for the origin.
   public void drawTexture(Texture texture, float x, float y, float w, float h, float rot, float local_origin_x, float local_origin_y);
    public void drawTexture(Texture texture, float sx1, float sy1, float sx2, float sy2, float x, float y);
    public void drawTexture(Texture texture, float sx1, float sy1, float sx2, float sy2, float x, float y, float w, float h);
    public void drawTexture(Texture texture, Rectangle region);
    public void drawTexture(Texture texture, float sx1, float sy1, float sx2, float sy2, Rectangle region);
    public void drawTexture(Texture texture, Rectangle sourceregion, Rectangle region);

Hope this is satisfactory,

-wes
3  Games Center / WIP games, tools & toy projects / Re: MERCury - 2d Game Library | Experimental release in development; test it out! on: 2014-07-15 18:45:05
However I wanted to see how easy it would be to port my particle lib and well...the batcher was kinda bad or more of missing things. I couldn't figure out how to specify rotation, scale, mirroring, etc. So I never made t very far. It took me a few minutes to port to libgdx and I was hoping it wold be the same for this lib but things I guess are still too immature.

I only wrote the Batcher to do low level vertex processing. The Graphics object does most rendering work. Textures are drawn to Rectangles, and so all you need to do to rotate is manipulate the geometric object. Same goes for scaling. If you meant a graphical scaling, then you can, again, go to Graphics.

Is the batcher supposed to handle these things?
4  Games Center / WIP games, tools & toy projects / Re: MERCury - 2d Game Library | Experimental release in development; test it out! on: 2014-07-15 04:19:56
Well, I added in TextFields. I think I like how they turned out (functionally of course, for risk of being beheaded by Jev).



There are a few different modes of input. Here, you see signed integers, which allows numbers, and hyphens. In full, there are strings, signed floating points, unsigned floating points, signed integers, and unsigned integers.
For those unaware, signed means that both negative and positive numbers are allowed, while unsigned means that only positive values are allowed.

The GUI artwork is temporary, and is completely different than how it will look in the end. Ask Jev any questions about that; I am just writing the code Tongue.

-wes Smiley
5  Games Center / WIP games, tools & toy projects / Re: Spam The Spacebar Rouge/rpg/hack&slash [Update!] on: 2014-07-12 20:29:59
Nice looking game!

When I shoot with the spacebar, the hits go the same speed as the player. It looks a tad ugly, so you might want the hit speed to be bigger.

-wes
6  Games Center / WIP games, tools & toy projects / Re: Astrofirm on: 2014-07-11 17:46:02
If it isn't already doing so, your lighting algorithm should react to solid tiles. It would look great.
7  Games Center / WIP games, tools & toy projects / Re: MERCury - 2d Game Library | Experimental release in development; test it out! on: 2014-07-11 09:54:51
There actually wasn't much visual updating (aside from movement-based particle emission) here, but there was a mini-crisis, made worse by insomnia.

For a while now, there have been SubTextures, and Textures. SubTextures are a type of Texture, and can be rendered in much the same way. They do, however, lack the capability to clamp, and are not PoT Textures. This puts the SubTextures under incapable Textures, while real Textures go under capable textures. The idea here, however, is that SubTextures should be able to be passed in as real Textures, as one may wish to use a sprite-sheet for speed/convenience. The problem rises here, where you need capable Textures for a job, such as a repeating background.

So I now announce a new feature that will help fix these problems in a convenient way:

SubTexture.convertToTexture(): This new method can be used to convert a SubTexture into an actual Texture. This is useful for when you still want one spritesheet image, but you want a repeating Texture pulled from inside of it.

For example, the issue that caused this in the first place: the body of a Panel! It needs to be fully capable, so in order to use a Texture from the spritesheet:
1  
2  
3  
4  
// Just innocently loading a spritesheet
SpriteSheet universal_spritesheet = SpriteSheet.loadSpriteSheet(mytex, allofmysubtextures);
// And just as innocently creating a panel with said spritesheet.
Panel mypanel = new Panel(myboundingrectangle, mybodytex, mybordertex);


1  
2  
// This is bad.
java.lang.IllegalArgumentException: Body Texture has to be fully capable. This requires PoT size, and not being a SubTexture.

1  
2  
// The body texture needs capability! Quick, make it capable!
Panel mypanel = new Panel(myboundingrectangle, mybodytex.convertToTexture(), mybordertex);


And with that, you may get gold like you see here:



Thanks, and sorry if this post made no sense; it is 3:30AM here Tongue.
-wes

And yes, it is on github Wink.
8  Discussions / Miscellaneous Topics / Re: Euclideon's 'infinitely detailed' rendering techniques on: 2014-07-10 08:09:29
They do sell offer an SDK.
9  Discussions / Miscellaneous Topics / Euclideon's 'infinitely detailed' rendering techniques on: 2014-07-10 02:33:40
I don't know if this is old news here or something, but...

<a href="http://www.youtube.com/v/Irf-HJ4fBls?version=3&amp;hl=en_US&amp;start=" target="_blank">http://www.youtube.com/v/Irf-HJ4fBls?version=3&amp;hl=en_US&amp;start=</a>

This is really interesting. These guys are making software that can supposedly render an infinite amount of detail at any size using point cloud search engine indexing. Some pretty clever things are happening here.

Now, I wonder if this will be used in games  Smiley.

-wes
10  Java Game APIs & Engines / OpenGL Development / Re: Somehow using GL_REPEAT on a sub-texture in a sprite-sheet? on: 2014-07-09 23:58:01
But do they support GL_REPEAT?
11  Java Game APIs & Engines / OpenGL Development / Re: Somehow using GL_REPEAT on a sub-texture in a sprite-sheet? on: 2014-07-09 22:42:43
Wait, so the sub-textures still have to be PoT for them to repeat? If so, I think I'll just stick with the shader solution.
12  Java Game APIs & Engines / OpenGL Development / Re: Somehow using GL_REPEAT on a sub-texture in a sprite-sheet? on: 2014-07-09 22:03:15
No, I already upscaled the parental textures to PoT. I was asking if the sub-textures can be nPoT and still repeat?

And what do you mean by 'picking a sampler in my fragment shader?'
13  Java Game APIs & Engines / OpenGL Development / Re: Somehow using GL_REPEAT on a sub-texture in a sprite-sheet? on: 2014-07-09 20:47:46
I have a few questions about Array Textures:
  • Do they still repeat if they are still not PoT?
  • Are they widely supported?
  • Are they less expensive than regular textures when bound in order?
14  Java Game APIs & Engines / OpenGL Development / Somehow using GL_REPEAT on a sub-texture in a sprite-sheet? on: 2014-07-09 18:55:34
Hello.

I have been researching for a bit on how to make a section of a texture render in GL_REPEAT. Is there any way to do this other than just manually repeating the sub-texture by drawing the sub-texture multiple times? The farthest I have gotten is Array Textures, but I can't make out if they are good for sprite-sheets, or compatible enough. Then people keep referring to using shaders to map correctly, but I can't really work out what I am supposed to do in said shader.

Are there any options I am missing here, or is manual repeating the only logical/compatible way?

Thanks,
-wes
15  Games Center / WIP games, tools & toy projects / Re: 3D Randomly Generated World on: 2014-07-09 04:51:40
Looking good! This has gone a long way from where you started!
16  Games Center / WIP games, tools & toy projects / Re: MERCury - 2d Game Library | Experimental release in development; test it out! on: 2014-07-08 02:50:36
Windows!

Sorry for the crappy scaling on this.


It is a Panel that is draggable, and closeable. Not much else to say!

-wes

EDIT:
Sorry, none of this is up to github. Too buggy and unstable as of now.
17  Discussions / General Discussions / Re: Rock Simulator 2014 funded on IndieGoGo on: 2014-07-05 23:30:15
Things just got drama.
18  Games Center / WIP games, tools & toy projects / Re: MERCury - 2d Game Library | Experimental release in development; test it out! on: 2014-07-05 08:33:44
Oh, sorry! I probably should have emphasized that those actually are RadioButtons. Probably should have some different sprite. But I guess we will get to that when Jeviny can work on the default theme.
19  Games Center / WIP games, tools & toy projects / Re: MERCury - 2d Game Library | Experimental release in development; test it out! on: 2014-07-05 08:22:21
I worked on floating elements in panels today (although the changes are not pushed, as they are untested/buggy). Lots of fun/confusing maths that should be simple but continue to be a pain. Also, panels. Basically, these are invisible Rectangles that contain a bunch of Components, and organize them based on their respective FLOATS. There currently are

FLOAT_LEFT
FLOAT_CENTER
FLOAT_RIGHT

Here is a modified demo to demonstrate (I have drawn a Texture in the back to symbolize where the Panel will be).



Here is the code. Fairly simple.

1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
14  
15  
        panel = new Panel(new Rectangle(30, 30, Runner.getInstance().getWidth()/1.5f, Runner.getInstance().getHeight()/2.8f), 20);
        // Add checkboxes (or any component really) to the panel
       panel.addChild(foocheck, barcheck);
        // Sort them into neat lines.
       panel.sortChildren();

        ...

        // Updates all children
       panel.update(delta);

        ...

        // Renders all children
       panel.update(delta);


Window system in the future (maybe) so stay tuned.

Happy 'Murica day.
-wes
20  Games Center / WIP games, tools & toy projects / Re: AWTEngine2D WIP | A 2D Engine using only AWT Canvas on: 2014-07-04 16:53:21
Very good work so far; everything is wrapped around AWT so nicely!

I found some issues by surfing the source and posted them to the Github Issue Tracker.

-wes
21  Games Center / WIP games, tools & toy projects / Re: MERCury - 2d Game Library | Experimental release in development; test it out! on: 2014-07-04 05:03:00
Worked on a new component today, to celebrate being back from my 8 day absence.

Meet the checkbox! EDIT: Now with radiobuttons!



-wes
22  Game Development / Game Play & Game Design / Re: Upgrade Ideas on: 2014-07-03 17:38:28
Well, we will need a tad bit more information about your game. Is it a sidescroller? A top-down shooter? A racing game?
23  Game Development / Newbie & Debugging Questions / Re: How to delay somthing without stopping the gameloop? on: 2014-07-03 17:30:22
See: Timers. It works by creating a separate thread for timing things. You can start the timer, and it will not pause your loop.

EDIT:
As PandaMoniumHUN pointed out, multithreading actually isn't too optimal unless you need extreme accuracy. I would recommend his approach before you use threads.
24  Game Development / Newbie & Debugging Questions / Re: Transparency in LWJGL on: 2014-06-24 21:35:22
Well, for the benefit of future peoples, let me share how I would go about solving this issue:

1) Render the top texture to an FBO at said transparency
2) Render other texture to world
3) Render the top texture FBO to the world

An excellent tutorial on FBOs again here by mattdesl, to get you started.

EDIT:
Or you could mess with blending. This is a bit more good a tutorial to get you started on that.

-wes
25  Discussions / Miscellaneous Topics / Re: What I did today on: 2014-06-24 19:28:17
I changed my avatar to something I doodled during school (way earlier in the year).
26  Game Development / Newbie & Debugging Questions / Re: Transparency in LWJGL on: 2014-06-24 19:26:18
So you want to render one texture transparently as if the other does not exist?

Maybe frame buffer objects, but I am sure there are better built-in solutions out there.
27  Games Center / WIP games, tools & toy projects / Re: MERCury - 2d Game Library | Experimental release in development; test it out! on: 2014-06-21 03:54:56
@trollwarrior
No, it means that they could render 71K moving quads. ~400K vertices though.

@kingroka123
That, chances are, is the Texture of a font that is being loaded. I think I'll add an option to ignore that warning.

-wes
28  Games Center / WIP games, tools & toy projects / Re: MERCury - 2d Game Library | Experimental release in development; test it out! on: 2014-06-19 22:49:26
Texture is just data. You can rotate it while it loads, but that is not how you primarily rotate. You render the Texture to a Rectangle to rotate it. Here is how:

1  
2  
3  
4  
5  
6  
7  
8  
9  
Rectangle bounds = new Rectangle(0,0,10,10);

@Override
public void render(Graphics g) {
    // Rotate by 1 degree every frame.
   bounds.rotate(1);
    // Render the texture to a rectangle.
   g.drawTexture(texture, bounds);
}

-wes

EDIT:
That shouldn't be happening. Are you loading any other Textures with it?
29  Games Center / Showcase / Re: [game][3.2+] Lub vs Dub for android on: 2014-06-19 00:29:27
Great job!

When flipping, though, don't just teleport the texture. Maybe make a smooth transition from one side to the other?
30  Games Center / WIP games, tools & toy projects / Re: MERCury - 2d Game Library | Experimental release in development; test it out! on: 2014-06-19 00:11:29
Played around more with the particles, and found that they were kind of difficult to work with. I decided to make them a tad more easy to use, and added in both Textured Particles and Rotating Particles.

The result is more than satisfactory:



Along with that, there is a nice little feature I added in. You'll notice there is a little bit of debug text at the top-left. It will stay there, no matter how you scaled the graphics. FPS and Vertices are default, but if you want to add in more debug information, call this every frame:

1  
Runner.getInstance().addDebugData("Name", value);


And it works like a charm Smiley.

EDIT:
And in case you want to disable the debug, all you must do is this:
1  
Runner.getInstance().showDebug(false);


-wes
Pages: [1] 2 3 ... 37
 

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

The first screenshot will be displayed as a thumbnail.

Riven (4 views)
2014-07-23 21:16:32

Riven (6 views)
2014-07-23 21:07:15

Riven (5 views)
2014-07-23 20:56:16

ctomni231 (40 views)
2014-07-18 06:55:21

Zero Volt (36 views)
2014-07-17 23:47:54

danieldean (30 views)
2014-07-17 23:41:23

MustardPeter (32 views)
2014-07-16 23:30:00

Cero (47 views)
2014-07-16 00:42:17

Riven (48 views)
2014-07-14 18:02:53

OpenGLShaders (38 views)
2014-07-14 16:23:47
HotSpot Options
by dleskov
2014-07-08 03:59:08

Java and Game Development Tutorials
by SwordsMiner
2014-06-14 00:58:24

Java and Game Development Tutorials
by SwordsMiner
2014-06-14 00:47:22

How do I start Java Game Development?
by ra4king
2014-05-17 11:13:37

HotSpot Options
by Roquen
2014-05-15 09:59:54

HotSpot Options
by Roquen
2014-05-06 15:03:10

Escape Analysis
by Roquen
2014-04-29 22:16:43

Experimental Toys
by Roquen
2014-04-28 13:24:22
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!