MC gen

hello, this is project on which im trying to learn maxscript.

Now its only generating terrain made of two types of blocks: grass and dirt (yes, its inspired by Minecraft.)

01

First are placed Grass blocks, theirs position is based on grayscale bitmap(x,y position of pixel and z value is calculated from value of shade)

02

and "gaps" between grass blocks are filled with specified number of Dirt blocks

03

my goal is to generate more block types such as stones, trees, flowers, water etc...but terrain of size 100x100 thats about 16K blocks(depends on terrain diversity) runs my laptop on max performance. My knowledges of maxsripts are small so im stuck here. i tried to slice terrain to smaller Chunks which i convert to proxies, but function VrayMeshExport was too cpu intense - terrain generation 20x20blocks took 5sec and exporting mesh 7minutes on full RAM :( 

Is there any way how fix that or i have to work with only small sizes?

source code: MC gen

Comments

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
Loucher's picture

here is debugg: pastebin

here is debugg: pastebin

Loucher's picture

im getting apllication error

im getting apllication error when im trying to run my script on multiple threads

source code

even when i get error, script is running - its generating new blocks which are apearing in scene viewport one by one until terrain generation is complete. its rly important for me to fix this problem because all other functions are working just this one last piece of code is making trubble :(

tnx for every idea

Loucher's picture

small progress improved

small progress


improved algorithm for generating terrain - new block sand, new function for generating trees. and i still need to figure out how to solve problem with large scale terrain :(
btw image is uploaded on another hosting ^^

br0t's picture

3ds Max does not do well

3ds Max does not do well handling thousands of nodes, your performance would improve a lot if you'd attach those blocks together, I guess. That will make it more difficult to change anything, but still possible. This is a nice project idea, really!
One thing, could you please use an image hoster without pr0n in it, I am at work, dude :D!

Never get low & slow & out of ideas

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.