Easy guide for level making + problem

You are an experienced programmer and have a problem with the engine, shaders, or advanced effects? Here you'll get answers.
No questions about C++ programming or topics which are answered in the tutorials!
Post Reply
LarvaExotech
Posts: 5
Joined: Sun Mar 01, 2009 9:25 pm

Easy guide for level making + problem

Post by LarvaExotech »

Hello. I am not so skillfull to make my own world editor, but I'd love to have a CSG features etc.

In the past I was making levels in Serious Editor, a WE for game Serious Sam First/Second Encounter. Its great editor and I can manage everything in it like managing things in my home - I got used to it so much.

I'm now learning Irrlich, its great engine but it lacks decent World Editor (Irrlich is still great, I am not complaining!).

So I decidec to use Serious Editor for making levels. There is an option to export it to .RAW 3d model, which I have converted to .3ds with Milkshape.

I have loaded node like in example number 2, "Quake Level", and of course I positioned it at x/y/z 0,0,0. When I ran my program, well it loaded my level model correctly but it was WAY too small (I used Serious Sam units). So i enarged it 16 times using milkshape and I tried again. It was good now (though strangely oriented - Serious Editor "down" is Irrlich "left", but its no problem to rotate model in Milkshape after importing and scaling).

What is my question - about texturing. Because Serious Editor does not export it with textures, I'd like to texture it manually.

-----------
creating simple world in serious editor:

Image

importing crap in milkshape

Image

my level in irrlich

Image
-----------

As u can see my world is loaded correctly, collided correctly, its great. But its untextured (I have added light scene node with circle fly'er because without lighting node was unreconizable - it was plain shape with extact color everywhere). Now I'm looking after ideas about texturizing that.

I though about creating something like "Level editor", which would have option to import those mesh'es created in Serious Editor, adding lighting nodes, textures and other stuff. I have already ideas about lighting/nodes, it could be xml file with stored positions and propeties of nodes, well thats not my problem.

Problem is in texturing - how should I texture those polygons and how I should save it? I really dont have idea, AFAIK I can texture only full mesh with one texture calling

Code: Select all

        q3node->getMaterial(0).setTexture(0, driver->getTexture("../../media/wall.jpg"));
        q3node->setMaterialFlag(video::EMF_LIGHTING, true);
how about texturizing single polygons? Or maybe better solution would be using some external program for adding textures to the mesh? If yes, then which one?

Thanks in advance for all replies and so :)
sudi
Posts: 1686
Joined: Fri Aug 26, 2005 8:38 pm

Re: Easy guide for level making + problem

Post by sudi »

LarvaExotech wrote:how about texturizing single polygons?
You can't. Irrlicht uses meshbuffers which have materials assigned, including textures. so if there is just one meshbuffer exportet by your editor u can only assign one texture. Of course u can create a new mesh with your own meshbuffers.
We're programmers. Programmers are, in their hearts, architects, and the first thing they want to do when they get to a site is to bulldoze the place flat and build something grand. We're not excited by renovation:tinkering,improving,planting flower beds.
LarvaExotech
Posts: 5
Joined: Sun Mar 01, 2009 9:25 pm

Re: Easy guide for level making + problem

Post by LarvaExotech »

Sudi wrote:
LarvaExotech wrote:how about texturizing single polygons?
You can't. Irrlicht uses meshbuffers which have materials assigned, including textures. so if there is just one meshbuffer exportet by your editor u can only assign one texture. Of course u can create a new mesh with your own meshbuffers.
so how are handled quake 3 levels? they dont have one texture applied to whole world (mesh)? so maybe there is possibility to texturize that mesh in some 3rd party program?
Strong99
Admin
Posts: 687
Joined: Fri Mar 31, 2006 7:06 pm
Location: Netherlands
Contact:

Post by Strong99 »

its not stored in one meshbuffer, as sudi told one meshbuffer has one texture but a model can exist out of several buffers.
LarvaExotech
Posts: 5
Joined: Sun Mar 01, 2009 9:25 pm

Post by LarvaExotech »

so, do you have any ideas how I could texturize that?
B@z
Posts: 876
Joined: Thu Jan 31, 2008 5:05 pm
Location: Hungary

Post by B@z »

seperate the mesh where you want to use different texture.
meshbuffer called group in milkshape :D
so one group can only have one texture. make a lot of group, every group with one texture, and you have multitexture xD
Image
Image
Strong99
Admin
Posts: 687
Joined: Fri Mar 31, 2006 7:06 pm
Location: Netherlands
Contact:

Post by Strong99 »

if you apply textures to your model in 3ds max and export it you should be fine. it will automaticly seperate in several buffers than.

As long as one polygon has not more than 1 texure it works well, although b3d has some more settings I not know ;)
LarvaExotech
Posts: 5
Joined: Sun Mar 01, 2009 9:25 pm

Post by LarvaExotech »

strong99 wrote:if you apply textures to your model in 3ds max and export it you should be fine. it will automaticly seperate in several buffers than.

As long as one polygon has not more than 1 texure it works well, although b3d has some more settings I not know ;)
thanks, I will try it. but AFAIK textures are stored in seperate file (at least example models do), so how 3ds max will export it? it will generate one texture with UV grid?

thanks for your responses guys ^^

if I will manage how 2 do it I will write a tutorial about creating maps in SED and using them in Irrlicht;)
Post Reply