Page 4 of 9

Re: Minecraft remake- Crafter

Posted: Wed Jun 08, 2011 10:49 am
by GroundUpEngine
N64vSNES wrote:Hooray for building things!




...

This building looks sweet! Culling is a pain aha :)

Re: Minecraft remake- Crafter

Posted: Wed Jun 08, 2011 1:30 pm
by N64vSNES
GroundUpEngine wrote:
N64vSNES wrote:Hooray for building things!




...

This building looks sweet! Culling is a pain aha :)
Thanks man. I actually found culling pretty easy :shock: I looked back at a tutorial on culling and it turns out that the counter clockwise vertex arrangement was for culling not transparency. You have to arrange your drawing order for transparencies but since I drew the entire map as a huge mesh then it didn't matter. ( Not the whole map obviously that would kill any PC )

Re: Minecraft remake- Crafter

Posted: Wed Jun 08, 2011 5:21 pm
by dandymcgee
GroundUpEngine wrote:Culling is a pain aha :)
Not when the only shape in your entire game in a cube. :P

Re: Minecraft remake- Crafter

Posted: Wed Jun 08, 2011 5:59 pm
by N64vSNES
dandymcgee wrote:
GroundUpEngine wrote:Culling is a pain aha :)
Not when the only shape in your entire game in a cube. :P
Hooray for simply masterpieces! :)

With a bit of luck Crafter will have more than that later ;)

Re: Minecraft remake- Crafter

Posted: Wed Jun 08, 2011 9:04 pm
by Ginto8
For the "draw as one whole mesh", do you go through the blocks, check to see if it's in line of sight, then render it? Or do you do something else to prevent having the whole map render at once?

Re: Minecraft remake- Crafter

Posted: Thu Jun 09, 2011 1:55 am
by MadPumpkin
Ginto8 wrote:For the "draw as one whole mesh", do you go through the blocks, check to see if it's in line of sight, then render it? Or do you do something else to prevent having the whole map render at once?
are you referring to occlusion culling(figuring hidden surfaces), or loading only visible chunks? for example, not the building 12 feet to the left of you (because you can't see it).

Re: Minecraft remake- Crafter

Posted: Thu Jun 09, 2011 5:59 am
by N64vSNES
Ginto8 wrote:For the "draw as one whole mesh", do you go through the blocks, check to see if it's in line of sight, then render it? Or do you do something else to prevent having the whole map render at once?
ROFL, Even I wouldn't render a 512x512x128 map all at once. Can you imagine how slow that would be?

I just render a chunk of the map within 30 blocks of distance from the camera and use fog to hide anything further from that (so you wouldn't see it even if it were being rendered).

If something is beside you or behind you etc then at this time I just let backface culling do it's best with that stuff.

Re: Minecraft remake- Crafter

Posted: Sun Jun 12, 2011 1:09 am
by MadPumpkin
back face culling is god. Yea usually culling does the trick but definitely 30 blocks render distance sounds reasonable. When I wasn't thinking and just started copying code from another project I worked on a long time ago my game ran for shit and I couldn't figure out why for DAYS. Till finally I realized even though I was rendering a reasonable distance horizontally, I was rendering the god damn caves and NPC's that were under me and not even accessible, like 300 feet down!

Re: Minecraft remake- Crafter

Posted: Sun Jun 12, 2011 1:30 am
by dandymcgee
MadPumpkin wrote:Till finally I realized even though I was rendering a reasonable distance horizontally, I was rendering the god damn caves and NPC's that were under me and not even accessible, like 300 feet down!
Haha! Oops.

Re: Minecraft remake- Crafter

Posted: Mon Jun 13, 2011 9:57 am
by Van-B
Looking sweet, your clearly making some great progress with this.

How are you factoring lighting?

Just wondering, because I've found that just a vertex lightmap can make things look great. Like take the 3D position of each vertex, add a little adjustment for the vertex normal so you get a position that you can project your light source to - then if there's a collision between those points, set the vertex diffuse colour to nothing, otherwise base it on the light colour, strength and direction. I'm making a mining game a little like Minecraft, and that's all I'm doing - it's all underground so that sort of lighting suits it... like no moving lights, each block could be lightmapped on-the-fly and that sort of thing. The reason that I like this method though, is that you don't have to worry too much about normals and dot products and stuff - the vertexes could just be lit, or not, and it tends to look better than standard normal vector lighting - allows for shadows and stuff.

Re: Minecraft remake- Crafter

Posted: Mon Jun 13, 2011 1:11 pm
by D-e-X
Van-B wrote:Looking sweet, your clearly making some great progress with this.

How are you factoring lighting?

Just wondering, because I've found that just a vertex lightmap can make things look great. Like take the 3D position of each vertex, add a little adjustment for the vertex normal so you get a position that you can project your light source to - then if there's a collision between those points, set the vertex diffuse colour to nothing, otherwise base it on the light colour, strength and direction. I'm making a mining game a little like Minecraft, and that's all I'm doing - it's all underground so that sort of lighting suits it... like no moving lights, each block could be lightmapped on-the-fly and that sort of thing. The reason that I like this method though, is that you don't have to worry too much about normals and dot products and stuff - the vertexes could just be lit, or not, and it tends to look better than standard normal vector lighting - allows for shadows and stuff.
To get the initial Minecraft kind of lighting deal, you'd want to be doing emissive lighting, such that you might have values [0,10] which says something about how much light it emits. Let's say that a block has a emission value of 10, then the next block would have 9, and then 8 asf; which gives that blocky kind of feel to the lighting as well.

Re: Minecraft remake- Crafter

Posted: Mon Jun 13, 2011 1:58 pm
by N64vSNES
Van-B wrote:Looking sweet, your clearly making some great progress with this.

How are you factoring lighting?

Just wondering, because I've found that just a vertex lightmap can make things look great. Like take the 3D position of each vertex, add a little adjustment for the vertex normal so you get a position that you can project your light source to - then if there's a collision between those points, set the vertex diffuse colour to nothing, otherwise base it on the light colour, strength and direction. I'm making a mining game a little like Minecraft, and that's all I'm doing - it's all underground so that sort of lighting suits it... like no moving lights, each block could be lightmapped on-the-fly and that sort of thing. The reason that I like this method though, is that you don't have to worry too much about normals and dot products and stuff - the vertexes could just be lit, or not, and it tends to look better than standard normal vector lighting - allows for shadows and stuff.
Thanks for the kind words :)

At the minute lighting is nothing special I'm initializing some ambient, diffuse and specular lighting and setting it at the top right corner of the camera.

However I know in the original Minecraft there is a square for the sun, but I'm not going to be a total rip-off ;)

I do like your idea for lighting though and lighting definitely isn't finished yet, for things such as torches I'll need to figure out how to give blocks an attribute so they can produce light etc.

Re: Minecraft remake- Crafter

Posted: Tue Jun 14, 2011 5:18 pm
by N64vSNES
-yawn-

Too tired to put text so I'll just leave the pretty pictures :lol: :

Da super awesome title screen that says Alpha 0.6 even though it says 0.8 in game ;)
Image

Da super awesome settings menu, nothing of anything works other than continue and quit.
Image

And a screenshot of the map with the rendering distance set to far (my computer doesn't like this one):
Image

Re: Minecraft remake- Crafter

Posted: Tue Jun 14, 2011 8:03 pm
by superLED
Nice work, man! You are getting some progress - that's a good sign ^^
Keep up the good work!

Re: Minecraft remake- Crafter

Posted: Wed Jun 15, 2011 6:51 am
by Milch
Looks great! :D