Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Dark GDK / Automatically generated scenery

Author
Message
thm120
15
Years of Service
User Offline
Joined: 28th Dec 2008
Location:
Posted: 16th Jul 2009 03:05
ok, is it possible to have/make autogen(automatically generated scenery)? sorta generic scenery that generates in designated areas as you move forward? or if that can't be done, is there a way to control the draw distance of the application?
Lilith
16
Years of Service
User Offline
Joined: 12th Feb 2008
Location: Dallas, TX
Posted: 16th Jul 2009 05:04
I'm not sure what the technique is but I understand that sometimes fractal geometry is used to generate landscapes. I'm not big on fractals (except lyopinovs (sp?) and I'm not big on 3D so I can't say much beyond that.

Lilith, Night Butterfly
I'm not a programmer but I play one in the office
thm120
15
Years of Service
User Offline
Joined: 28th Dec 2008
Location:
Posted: 16th Jul 2009 20:50
ok lets say i made the map with lots of trees in the places i want them, but if i run the game all the trees will load at the same time(which will cause a sucky frame rate) i was wondering if there was a way to control how many objects are loaded from a certain distance.
prasoc
16
Years of Service
User Offline
Joined: 8th Oct 2008
Location:
Posted: 16th Jul 2009 22:47
dont load separate objects: use dbInstanceObject() and use a level of detail system for different distances away


Your signature has been erased by a mod
thm120
15
Years of Service
User Offline
Joined: 28th Dec 2008
Location:
Posted: 17th Jul 2009 03:00
yea i really wish i knew what that was or how to use dbInstanceObject()
Mista Wilson
16
Years of Service
User Offline
Joined: 27th Aug 2008
Location: Brisbane, Australia
Posted: 17th Jul 2009 06:19
If you are looking for foliage specifiacaclly, you could look at the Tree Party addon, which is designed for doing exactly what you are looking for with trees. It even animated them and comes with a tree editor.

Or there is also a pretty cool little library that Dark Coder wrote, its in the WIP section under "Foliage Library" and it does a some of what tree party does(though not nearly all, they are 2 different things), but it comes with the source, so if you wanted to, you could modify it to work with whatever kinds of objects you wanted to give it.

Link to dark coder's Foliage Library :

http://forum.thegamecreators.com/?m=forum_view&t=144892&b=8

Otherwise, its all down to you to come up with and design efficient sets of code to do what you want it to. Looking at the source of Dark Coder's foliage library, which actually does trees, grass, rocks, weeds and clutter(tree stumps, fallen branches, misc objects etc)pretty well, will give you a really good idea of how you would do something like you want.

I think there are a fair few threads in these forums and the dbpro ones too that deal with generating various things in various ways, from terrains and heightmaps to textures and numbers. Most DBPro programs and ideas can be ported to GDK quite easily, so its always a good place to look aswell when you need a solution to something.

If it ain't broke.... DONT FIX IT !!!

Login to post a reply

Server time is: 2024-11-19 00:17:50
Your offset time is: 2024-11-19 00:17:50