Procedural Generation for beginners[PDF]

Post your own tutorials, guides and demos.

Post » Wed Jul 06, 2011 10:34 am

This is a tutorial on Procedural Generation for beginners. This part doesn't contain anything spectacular, just some basics on Arrays and how to manipulate them.


1st Part
Download

2nd Part [29-July-2011]
PDF
http://dl.dropbox.com/u/5811650/Progentut2/Tutorial.doc.pdf
HTML
http://dl.dropbox.com/u/5811650/Progentut2/Tutorial.doc.zipabhilash28632011-07-29 12:52:07
B
9
S
3
G
3
Posts: 366
Reputation: 2,301

Post » Wed Jul 06, 2011 3:07 pm

I was promised procedurally generated caves, and all I got was grass and water ... I feel robbed !
B
45
S
16
G
18
Posts: 845
Reputation: 13,673

Post » Wed Jul 06, 2011 3:36 pm

This is the first part introducing people to the Array object. The next part will contain caves,I promise! :D
B
9
S
3
G
3
Posts: 366
Reputation: 2,301

Post » Sun Jul 17, 2011 9:03 pm

When will the next part come? This helped me alot i can now make "Rivers, Flowers, Trees, Sand, etc" But i dont know what game i should make yet :(
B
3
G
1
Posts: 14
Reputation: 553

Post » Mon Jul 18, 2011 12:51 pm

The next part will come in a week or two, I was busy in some other projects. Sorry for the delay.
B
9
S
3
G
3
Posts: 366
Reputation: 2,301

Post » Fri Jul 29, 2011 1:37 am

This is great! Can't wait for the next part. :D
B
26
S
7
G
5
Posts: 202
Reputation: 5,235

Post » Fri Jul 29, 2011 12:51 pm

Here's the 2nd(final) part.
PDF
http://dl.dropbox.com/u/5811650/Progentut2/Tutorial.doc.pdf
HTML
http://dl.dropbox.com/u/5811650/Progentut2/Tutorial.doc.zip

I'd prefer the HTML download, since the layout in the PDF is pretty bad.

I haven't verified the tutorial, if you find any mistake please post it here.
B
9
S
3
G
3
Posts: 366
Reputation: 2,301

Post » Fri Jul 29, 2011 3:57 pm

This is so helpful! You have no idea.

Also, what is with the odd ground objects in the four corners? I get that on every map.
B
26
S
7
G
5
Posts: 202
Reputation: 5,235

Post » Fri Jul 29, 2011 4:43 pm

I too noticed that while I was writing the tutorial, but didn't know what was causing it at that time.

It happens because of the 'clean up' events, the condition checks if the number of neighboring wall times is more than or equal to 3, if it is less than 3 then convert the current tile to ground. It works good for all the tiles except the corner tiles, because no matter what, the number of neighboring wall tiles will never be greater than 3.

If we change the condition from 'less than or equal to 3' to 'less than 3', it fixes the corner tiles problem, but for some reason the 3rd tile is always blank or sometimes a ground tile. I have no idea why that happens.

I'll try to find out. Glad you liked the tutorial. :)

B
9
S
3
G
3
Posts: 366
Reputation: 2,301

Post » Wed Sep 14, 2011 6:27 pm

I have a couple questions. First, I want the ground to be randomly generated from a few different textures. So let me explain. I have three different types of "ground" textures: grass, tundra, desert. Each has its own value (will be a resource value in game). I want to make it so that the miner sprites will leave behind a random choosing of the three. Is there a way to do that? Also, is there a way to have the clean up event turn whatever is not desert, grass, or tundra into ocean?
B
4
G
2
Posts: 44
Reputation: 1,088

Next

Return to Your tutorials & example files

Who is online

Users browsing this forum: No registered users and 0 guests