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.

Newcomers DBPro Corner / Making landscape editor

Author
Message
Regnuar
15
Years of Service
User Offline
Joined: 25th Dec 2008
Location:
Posted: 25th Dec 2008 20:36
So i am planning to make a Landscape editor but i have a few problems. actyally many problems.

first of all, i need to make a tool witch raises the land every second i keep the tool on the spot.

secondary, i need to make a tool what colors the landscape with selected texture.

and then.. how i can import .X (with object textures) files to the program?

And finally, ofc i need to Export it to .X file for later usage.


i just started using dark basic so i hope someone have patience to help me

Attachments

Login to view attachments
Xsnip3rX
17
Years of Service
User Offline
Joined: 20th Feb 2007
Location: Washington State
Posted: 26th Dec 2008 10:30 Edited at: 26th Dec 2008 10:31
First thing's first, you'll never see anyone upload only their source code on here, next, you don't upload the ".dbpro" file, that file only saves the settings of the project, EG: Filename, EXE Name, Copyrights, etc..., you upload the .dba file, , Second, wrap this code around your code and you're set
"
" Third, T.Ed is a good terrain editor, exports to .dbo (Native Dark Basic model format), .x (DirectX Model Format) and many others including .b3d(Blitz 3D)

Regnuar
15
Years of Service
User Offline
Joined: 25th Dec 2008
Location:
Posted: 26th Dec 2008 11:57
Thanks for the tips, as i said i am new comer so i dont really know how things works here. i'd like to use program what is made for my games, not for all of us.
AndrewT
17
Years of Service
User Offline
Joined: 11th Feb 2007
Location: MI, USA
Posted: 26th Dec 2008 16:48
If you're a newcomer you're going to have a hard time making a customized terrain editor with terrain painting and sculpting, and exporting to .X

I'd say your best bet is to either use the terrain that comes with DBP now, with which you can just specify a grayscale heightmap and textures and it builds the terrain for you.

Pillarofire
20
Years of Service
User Offline
Joined: 31st Dec 2003
Location: Good Question, <looks around.>
Posted: 27th Dec 2008 02:17
Regnuar, It is not impossible to make your own terrain editor. Though it might be a more difficult task than many have patience for. If you really want to get started, you need to have a very good understanding about the language; because you will need to take advantage of everything it offers.

Just like any project, you should start breaking the entire system down into more manageable components. Because unless your some god or godlike genius, it is just not possible to build the entirety in your head and systematically code it. Besides the time it would take to code the first half, you would probably forget the second half.

Anyway, you have already started to do that:

Quote: "
So i am planning to make a Landscape editor but i have a few problems. actyally many problems.

first of all, i need to make a tool witch raises the land every second i keep the tool on the spot.

secondary, i need to make a tool what colors the landscape with selected texture.

and then.. how i can import .X (with object textures) files to the program?

And finally, ofc i need to Export it to .X file for later usage.
"


You have the basics of what your code should start out like.



This is a rough draft and will probably change slightly, but the idea is to form a plan and stick to it throughout the entire development process. But as you can see you now have to fill in the blanks for each of these functions so that you can make them work.

You should pick one to start writing. Now, Because some functions will be dependent on others, You will have to periodically write to those as well. And as you go along you will find the need to write new functions not listed. But this at least, gives you a guide to follow.

So you decide, are you ready to tackle this?
Dragon Knight
17
Years of Service
User Offline
Joined: 10th Jan 2007
Location: Newcastle
Posted: 27th Dec 2008 13:16
I remember one of my first projects were creating a level editor.

here's some tips:

a.) export it to your own format e.g. you can do a VERY simple loop to export positions / heights / objects etc.. from your array straight into a file, thus making the importing just as simple.

b.) use terrains, they're fun, and easy.

c.) Look at other level editors to see how they do things heck you can use their HUD just to get a rough idea on how to do yours. e.g. what tools you need and how to do them.

d.) lowering / highering landscape. You can do this two ways, I suggest not re-creating the wheel, make an image updater in DBP. Something to edit/create terrain detail, terrain height map, and finally but not least a texture map, which could be really fun to mess around with then creating a button to remake / update the terrain. (BUT watch out this can be kinda fun.. and addicting.. there for you may not complete your work lol..)

e.) the forums are PACKED with examples of EVERYTHING the trouble is something finding these things, but i'm sure if you look using the right key words you should have no problem .

Hope that helps. If I didn't cover anything you wanted me to cover please feel free to ask again.

----------------------------------
http://www.hybridwolves.co.uk
----------------------------------
Rudolpho
18
Years of Service
User Offline
Joined: 28th Dec 2005
Location: Sweden
Posted: 28th Dec 2008 17:53
Maybe a good idea is to start out using the matrix commands.
Then, when you eventually crave something better, you code your own terrain system (using a memblock mesh) that can initially be very much alike the matrix code (ie. you write your function setGroundHeight(tileX, tileY, height)). In this way you have something easy to start out with, and, when the time comes, you can pretty easily port your code to your new system. After which you can start adding new features to it. Just an idea of how I did


-> Oh, come on...
Regnuar
15
Years of Service
User Offline
Joined: 25th Dec 2008
Location:
Posted: 31st Dec 2008 19:09
Thank you all who bothered to respond, Dragon knight, and Rudolpho. especially for Pillarofire, . I am glad to get even this much help. i am just getting started and i will not stop until my level editor is ready i know this is a hard task for a newbie but i have to start somewhere.
Regnuar
15
Years of Service
User Offline
Joined: 25th Dec 2008
Location:
Posted: 1st Jan 2009 18:33
ehem... i ment... "Thank you all who bothered to respond especially for Dragon knight, Rudolpho and Pillarofire.

Login to post a reply

Server time is: 2024-11-24 16:53:42
Your offset time is: 2024-11-24 16:53:42