Featured games (79)
games approved by the League of Dukes
Games in Showcase (477)
Games in Android Showcase (107)
games submitted by our members
Games in WIP (536)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
    Home     Help   Search   Login   Register   
Pages: 1 ... 8 9 [10]
 on: 2014-07-28 21:36:11 
Started by Ecumene - Last post by Ecumene
Okay, I drew up an image of what's happening:

 on: 2014-07-28 21:20:20 
Started by tommohawkaction - Last post by tkausl
Why dont you use google:

 on: 2014-07-28 21:19:28 
Started by joaogl - Last post by joaogl
Thank's guys, I have a question on the fragments, how can I compare two vec4?

I want to only change the result if the calculated color(its in a vec4) is darker then the existent color(its a vec4 too)

 on: 2014-07-28 21:19:08 
Started by tommohawkaction - Last post by tommohawkaction
Hello, I am making a 2d game like minicraft (2d) it is using 2d arrays to make the map, I want to make a nice random generation system but I have no idea how I have been told Perlin Noise is one of the best ways

Can somebody teach me this?
if you can add me on skype: tommohawkaction /// so i can easy share screens and source code with you

 on: 2014-07-28 21:17:37 
Started by Ecumene - Last post by Ecumene
TL:DR: So how do I make my light-boxes go behind eachother?

I'm trying to make a lighting-toy thing, and I've noticed a problem with my blending when I was implementing forward-rendering in 2D.

The first shader-pass just renders the texture, but then it passes over the all the lit objects again and does the lighting calculation. But my problem is that its calculating the lighting twice, one for the texture above, then for the texture behind it. I think this can be solved by just rendering the lit boxes at different Z locations, but I'm worried that would cause some problems. Is there any other way I can figure this out? Thanks.

Here's my current render code:

   ambient.setUniformM4("projMatrix", true, camera.getProjection());
   ambient.setUniformM4("viewMatrix", true, camera.getView());
   ambient.setUniformf("ambientLight", 1f, 1f, 1f, 1f);
   //Render textured-boxes
       for (Box b : boxes) {
      ambient.setUniformM4("modelMatrix", false, b.model.transform.getM());

GL11.glBlendFunc(GL11.GL_ONE, GL11.GL_ONE);

//Render lit-boxes
for(Light light : lights){
   for (Box b : boxes) {
      light.bind(camera, b);

With just the light boxes (Removed the texture render):

With just the texture boxes (removed the light-box render):
light.bind(camera, b);

 on: 2014-07-28 20:51:04 
Started by Drenius - Last post by Drenius
@alesky: Erm, it is a circle out of white triangles with another such circle running from white at center to black outside under it. Not quite sure what your question is about, there is no brighter color than white, maybe your eyes play you a trick because of the second mentioned circle, the atmosphere, in contrast?

 on: 2014-07-28 20:42:37 
Started by Drenius - Last post by alesky

the game si very nice

a Technical question

how do you draw the planet so bright?
is it a circle with a white circle texture and  the blend active or samething else?

 on: 2014-07-28 20:40:06 
Started by Ging3rtoby - Last post by Drenius
Voxel engines could mean MANY things. 2D or 3D?
Actually, a voxel can technically only be 3D since voxel = volumetric pixel so...  Smiley

 on: 2014-07-28 20:19:56 
Started by joaogl - Last post by Ecumene
Another way to do this is to switch your blending mode to additive blending.
Sorry, if I wasn't on my phone then I would provide some example code. To aid you in your googling, you change the blending mode to GL_ONE and GL_ONE.

I put in the correct blending code in my reply, I just started an example for forward rendering + additive blending a few days ago and the code I added works Wink

 on: 2014-07-28 20:17:54 
Started by Ging3rtoby - Last post by Longarmx
I think that you want to break blocks with a pickaxe correct? Well, you will need to raycast to find the block the player is pointing at, then you will need to see if the player is close enough to the block. If this is true then you will break the block by setting it to something like air.

Pages: 1 ... 8 9 [10]

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 (12 views)
2014-07-29 18:09:19

Riven (9 views)
2014-07-29 18:08:52

Dwinin (9 views)
2014-07-29 10:59:34

E.R. Fleming (26 views)
2014-07-29 03:07:13

E.R. Fleming (10 views)
2014-07-29 03:06:25

pw (40 views)
2014-07-24 01:59:36

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

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

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

ctomni231 (59 views)
2014-07-18 06:55:21
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 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!