View previous topic :: View next topic |
Author |
Message |
bibz1st Member
Joined: 31 Dec 2004 Posts: 13
|
Posted: Sat Jan 01, 2005 4:38 pm Post subject: lightmapping in DarkBasic |
|
|
how do I go about implementing lightmaps into a DBC level?
thanx in advance |
|
Back to top |
|
|
moogle Member
Joined: 28 Dec 2004 Posts: 6
|
Posted: Sat Jan 01, 2005 11:47 pm Post subject: |
|
|
you can't use deled lightmapping with dbpro , just use the light command in order to do the same things _________________ www.whitechaos.tk |
|
Back to top |
|
|
Chris Member
Joined: 08 Aug 2004 Posts: 161 Location: UK
|
Posted: Sun Jan 02, 2005 12:05 am Post subject: |
|
|
Your not going to be able to light a whole level using the DBPro light commands, your limited to 7 of them. |
|
Back to top |
|
|
Paul-Jan Site Admin
Joined: 08 Aug 2004 Posts: 3066 Location: Lage Zwaluwe
|
Posted: Sun Jan 02, 2005 9:22 am Post subject: |
|
|
First of all, I think the question was about DBC, not DBPro
The problem with Darkbasic is that you load DeleD levels through the use of .X files. X files don't support multitexturing (at least, not in a way DB supports), so you can't load the lightmaps through an .X file. However, DBPro (and probably DBC as well) _do_ support multitexturing, so I'd say there is nothing stopping you from writing your own .dmf loader and load the lightmaps manually. I am not exactly a darkbasic wizard, so I can't really go into coding details here
The good news is we have a darkbasic exporter planned, and the darkbasic native fileformat does support multitexturing (doesn't it?), so in the future things will become easier. |
|
Back to top |
|
|
bibz1st Member
Joined: 31 Dec 2004 Posts: 13
|
Posted: Mon Jan 03, 2005 3:53 pm Post subject: |
|
|
it wasnt the lights I wanted cos I know about DB's lights, it was for the shadowing effect.
oh well I guess I'll just wait until the exporter comes along.
one other thing, when rotating an object, does DeleD use euler rotation (not that I know what it is) but I tried rotating an object and it didnt rotate using its own axis but used the " world " axis instead just like DB does or maybe I was doing it wrong, any help on that would be welcome |
|
Back to top |
|
|
Paul-Jan Site Admin
Joined: 08 Aug 2004 Posts: 3066 Location: Lage Zwaluwe
|
Posted: Tue Jan 04, 2005 7:50 am Post subject: |
|
|
Yes, DeleD does use Euler angles, and is thus sensitive to gimbal lock and the likes. But I don't really see how that would be a problem in practise, as the human mind isn't too good with combinations of multiple rotations either. During modelling, you would usually rotate one axis at the time (with two consecutive rotation actions getting you where-ever you want), so there wouldn't be a problem at all.
However, if you have a specific situation that gets you (seemingly or real) erraneous behaviour, please post it. There might be something else going on. |
|
Back to top |
|
|
bibz1st Member
Joined: 31 Dec 2004 Posts: 13
|
Posted: Tue Jan 04, 2005 8:42 pm Post subject: |
|
|
I'll try and explain what I mean,
I make a rectangle in the TOP view, this will be my floor.
then I make another rectangle in, say, the FRONT view, this wiil be a sloping road eventually.
I rotate it on the Y axis a few degrees ( am using an aerial photo of my home town textured onto floor ) to line up with real road.
now I want my "road" to lean back to get the desired slope ( using guesswork rather than known angles )
now whichever axis I rotate with, in whichever view, it takes a lot of messing about to get it at the desired angle.
I know I could rotate it on the X axis first to get it to lean back, then on the Y axis, but if I then find its not at the correct leaning angle, subsequent rotations take it further out of alignment. I know I could reset the X axis back to its original angle and then Y rotate it again, but isnt there a better way to save all the messing about resetting angles.....phew....hope you understood that. |
|
Back to top |
|
|
Jeroen Site Admin
Joined: 07 Aug 2004 Posts: 5332 Location: The Netherlands
|
Posted: Tue Jan 04, 2005 8:46 pm Post subject: |
|
|
Just a few questions before I'm off... do you have the Snap Method of the Front view rectangle set to None? And maybe you can use the Rotate Properties in de lowerright window to manually set rotation angles? |
|
Back to top |
|
|
Paul-Jan Site Admin
Joined: 08 Aug 2004 Posts: 3066 Location: Lage Zwaluwe
|
Posted: Wed Jan 05, 2005 7:39 am Post subject: |
|
|
Hmmm, I am apparantly not enough of a modeler for this...
I tried reproducing this, and assuming the first rectangle you drew in the top view would be the road, I had no troubles aligning things at all. Everything rotated nicely around their own centres, moved the way I expected them to. I tried rotating the two rectangles simultaneously and separately (visually realigning them later one), both worked fine.
However, like Jeroen said, definitely make sure you have object snapping off (F9) while rotating, otherwise things will go horribly wrong |
|
Back to top |
|
|
bibz1st Member
Joined: 31 Dec 2004 Posts: 13
|
Posted: Sat Jan 08, 2005 12:23 pm Post subject: |
|
|
yes snapping is turned off and the first rectangle I create has to be the floor (created in the TOP view) cos this is textured with the aerial photo and is used as the reference picture to place all other rectangles including walls and sloping roads. I suppose I could use a GRID object as the floor, then raise certain points on the GRID but as this is a photo, the Grid points never seem to line up with where I want them to without subdividing the Grid which increases the polycount and so will decrease performance.
Maybe I'm looking at this problem in the wrong way, will have to keep trying. |
|
Back to top |
|
|
Paul-Jan Site Admin
Joined: 08 Aug 2004 Posts: 3066 Location: Lage Zwaluwe
|
Posted: Sun Jan 09, 2005 9:31 am Post subject: |
|
|
I think part of your problem lies in the fact that if you first draw a rectangle (or any other polygon) on the road, then try to match the slope, the size won't match up anymore (i.e. pythagoras ). Hope you figure out a convenient way to do things, let us know how things work out.
Also, if you come up with any particular technical things we could add to DeleD to assist you in this task, please let us know. We'll add them to the list |
|
Back to top |
|
|
bibz1st Member
Joined: 31 Dec 2004 Posts: 13
|
Posted: Sun Jan 09, 2005 12:39 pm Post subject: |
|
|
dumb? oh yes I am...cos I was just using rectangles all I had to do was...
create rectangle in TOP view
create second rectangle(sloping road) also in TOP view
ROTATE sloping road on the Y axis to match image of road on ariel photo
MOVE POLYGONS on one end of sloping road up on the Y axis.
sorted..yay!
sorry for bothering you with such trivialities but thanx for your input and prompt responses.
as for any additions, maybe simple collision for example...
if were making a game level such as a warehouse, make the floor, put a crate ( simple cube ) on floor then make another crate and push it against the first crate but the first crate stops second one going through it. do you get what I mean? |
|
Back to top |
|
|
|