• Welcome to Freedom Reborn Archive.
 

So Much Map Making Help Needed

Started by UnkoMan, November 23, 2008, 07:06:18 PM

Previous topic - Next topic

UnkoMan

I've tried this map making thing a few times before... every time it is the same. I just don't get it at all. I've read the tutorial stickied in this forum, and it still doesn't help me much. Things I thought I deleted come back. It takes a million years to put anything anywhere. I haven't even tried adding markers yet. I actually just really got the hang of moving objects this week.

But I'll stick to one question at a time, unless somebody wants to take my hand at it explain it from scratch as though I were a small child.

My question right now is... lights. Okay, that's a subject, not a question. How do I do anything at all with lights? There we go. Like, what's this "marker detail box" thing that I can use to change the colours? Can I change the intensity? Will this all be instantly previewed via the in-game editor? And how about the ambient lighting of the level, or does that have to be controlled via scripting or something?

So, yeah, anything people could tell me about light would be great. I know there's plenty of people here who can do this sort of thing in their sleep. I'd love to hear from you. Thanks.

Next time's question? Probably something to do with mist and fog.

GogglesPizanno

Most of the lighting I have done is either the ambient light settings which is done via the mission script or using of  objects that have lights attached to them (like the streetlights etc). You can place a light object in the level, but from what I understand its much more limited than FF was, and I always found them to never look or behave the way Id like them to.

For general ambient lighting, you would add something like this to the mission script then play with the setting to get your desired effect (the scripting documentation explains the values). Once you figure out lighting that looks the way you want it, it will solve about 90% of your level lighting requirements:


def OnPostInit():
Mission_SetSunlight(-40,30,1.2,1.0,(0.8,0.5,0.2))
Mission_SetShadows(-40,30,(0.2,0.3,0.3))
Mission_SetProjShadowBackground((1,1,1))
Mission_SetProjShadowColor((.8,.7,.7,1))


As for the light object you can place in the editor, I THINK you adjust color using the rotation values of the light since all lights are Omni, and rotation is moot. Something like x,y,z = r,g,b  In the parameters section, the first field in the numeric column is used for intensity (decimal value 0-1), and the 3rd field is radius of the light (in game units).

I personally have found that creating a new light object in Nifscope and assigning the color and intensity in the nif file itself works way better that using the light object in FFEdit. It requires more work to set it up and different colored lights require a new object for each (as opposed to setting the value in FFedit), but the effect I think is much more dramatic and you can do a lot more creative stuff with it.

The in game editor will not give you accurate ambient lighting, and dynamic objects with lights (such as the above mentioned streetlamp) will light the level around it, but often it requires you moving a game object or something similar to force a redraw of the level. Its quirky at best. The best way to test it from the editor is to "Run" the level. That's the only way to get a truly accurate view of what the game is rendering.

cmdrkoenig67

...What he said... :lol:

:ff: was so much easier to light (and even change the color of individual lights)... That ease seems to have been removed from :ffvstr:

Dana

UnkoMan

Hmm... you're right. It is tough. I can't even get the lights to show up really. Tried playing with a bunch of the settings and I still only see it once in a while, and then just barely and not when I actually run the game.

How would I go about making a light object in nifskope?

See because basically I want the level to look sort of how I draw things. With those big splashes of intense colour everywhere, combined with really black patches of shadow scattered around. Can't do that with ambient light because everything's so different and they don't even come close to following what light actually does.

cmdrkoenig67

I really had a ball placing lights on my  :ff: maps and changing the colors for certain effects...I miss being able to do that.  Apparently, In  :ff: you could also use lights with negative degrees to make shadowed areas...I don't recall if I was ever able to get it to work.

Dana  :(

GogglesPizanno

The way I do lights is to take a simple existing object, open it in nifskope and shrink it down (it still needs to be big enough to handle in the editor) then attach light(s) to that object. Then I adjust the setting to that light (color etc). Now doing it in nifskope means you can have a single nif object with several lights in it, all with different settings.

The downside to this is obviously you have to create a bunch of light objects and getting the positioning of the lights correct in nifskope when you want to get more creative than just a light at (0,0,0) takes a bit of trial and error, but looking at the art you are trying duplicate, using a really dark ambient light value and some really intense light objects might get you pretty close...

UnkoMan

Thanks a bunch. I'm going to give this a try later this afternoon. Hopefully I will get the hang of it. Say, if you made all the lights way above the object, then could you just sink the object into the ground and have the lights rise above it? That way there's no fear of it showing up at all?

Also, would I have to give each light an object template in FFEdit? If so I'm not sure how to do that. Or how to make it show up in my editor as something I can place. See I tried copying the park streetlight, but turning the lamp invisible and the light blue, and just had it placed in a folder like the rest of the template objects, but I couldn't find it with the in-game editor. Did I explain that well enough? I tried it in a few different places, but it was always in the same directory as all my other object nifs.

Sorry if I'm asking simple questions (in an unsimple way) now, but I feel fairly clueless.

GogglesPizanno

One thin you could do is get the lights placed in relation to the object, make sure it works how you want it then use nifskope to turn the objects visibility off. You had the right idea about the streetlamp, I think all you were missing was probably the template.txt file in the object's folder. All object need a template.txt file in order for the editor to see it as a valid object.

As for templates. I just created a single template in FFEdit called "mylight".
Then in the area_specific directory I created a folder called "mylights" and created a single template.txt file. Now all the lights that I create I just drop into that folder. They all inherit and use that single template.txt file and they all reference that single template in FFEdit, because while the settings of each light object may be different, as far as the game is concerned, they are all the same object in terms of behavior so you can use a single template for all of them.


-area_specific
     - mylights
          - template.txt
          - redlight.nf
          - greenlight.nif
          - combolight1.nif

cmdrkoenig67

Hmmmm...Sounds like too much work to me.

Dana  :P

GogglesPizanno

Well I said it was a bit of work   ;)

Although once its set up for the first one, its easy to just open up a light, change the color and "save as"
For just general lighting needs its a bit tedious and overkill, but if you have a specific situation where you want that kind of dynamic stylized lighting it works really well...

UnkoMan

Do I have to put something in the template.txt and then make an object template or something?

I actually tried it without and it didn't show up, then tried making am object template and since I have no idea what I am doing there it also didn't show up. Err... that is... it shows up as chooseble but then doesn't show up in the actual game as anything. Like I said, I don't know what to put in all the parts for its object template.

On the other hand I copied the pumpkin and made a smaller pumpkin in the same folder that WILL show up ingame. However, the lights were still orange even after I changed them to green via nifskope, so I'm not using that, clearly.

Oh man, I can't wait to figure this light thing out so I can start bugging you about that "dream_fog" stuff. Then it's on to making custom civilians, nodes for them and traffic to move about, and finally when the level looks perfect on to all those little markers and such you need to actually make it work!

As an aside, you don't happen to know an easy way to measure what the colours and light values'll look like in pure python script, do you?

GogglesPizanno

QuoteOn the other hand I copied the pumpkin and made a smaller pumpkin in the same folder that WILL show up ingame. However, the lights were still orange even after I changed them to green via nifskope, so I'm not using that, clearly.

Actually, the lantern (along with the book pile off the top of my head) are kind of oddball, because they have animated lightsources - thats what causes the flickering. From the best I can tell, the color is set for each of the frames, so it doesn't work right to just change the color. To make it work with those objects, you need to turn off the animated color controller of the object.

- Open the object in nifskope.
- Expand out the two light NiNodes
- Then expand out each NiPointlight
- There should be a node for each at that point called "NiLightColorController" and next to it a little flag. Click the flag.
- In the pop up, uncheck the "active" checkbox and resave.

This should disable the color controller (turns off the animated flicker) and makes the object emit the colors you assigned the two lights.

QuoteAs an aside, you don't happen to know an easy way to measure what the colours and light values'll look like in pure python script, do you?

Select the point light object and look at its details (you should see the four color bars that represent the colors of the light). Instead of clicking the color wheel icon to change the color, double click on the hex value of the color (ie #00cc33) it should then change to a numeric entry form and the values are decimal numbers between 0 and 1. Those values are the ones you can use in python scripts when setting ambient light color etc...

As for intensity, I THINK its the value of the Linear Attenuation number but I'm not sure. That starts going way beyond my pay grade.

UnkoMan

Oh man, thanks so much. I've finally got lights showing up how I'd like them. I still DO have the little streetlamp showing up, but I'm going to just turn them all invisible when I'm finally done all the maps. If I need to reposition them I can just turn them visible again. Simple (I hope).

Too bad that you can't change the lights for the flickering ones. That'd be something cool, I think.

Say, I was wondering... this one is about fog. When I place "dream fog" in a map I can't seem to click on anything and move it around. Likewise with pidgeons and crows. Do you know why this is, or what I should be trying to click to solve this? Also, I had this idea of using dream fog, but making it real black and placing that in some shadows. Would that produce a really dark area, do you think or is that fog too see through?

GogglesPizanno

One other option for the lights is to make a single version with the object for manipulation purposes and then a bunch without. So you place all your lights using the one with the object and then swap them out for the non-object version in FFEdit using the dropdown list on the mission tab.

As for the fog (and birds and other) you cant manipulate them directly because as objects they have no bounding box to grab onto. You could Alt-Tab out of the in-game editor back into FFEdit and manipulate the position of them manually using the numeric fields though. I think dark fog might be an interesting idea, you might try playing with alpha channel of the texture as well to see what you could come up with.

I had another quick thought if you were trying to capture the style of your artwork. In the map you are making make the texture directory a custom one (in the texture field at the top of the Mission tab), and copy over all the textures into it that your map uses. Then run a photoshop batch on all of them to reduce the color saturation a bit. So that you have a slightly washed out looking map with bright colors illuminating it. Don't know how well it would work, but it would be an interesting experiment.

cmdrkoenig67

Quote from: UnkoMan on November 26, 2008, 05:58:14 PM
Say, I was wondering... this one is about fog. When I place "dream fog" in a map I can't seem to click on anything and move it around. Likewise with pidgeons and crows. Do you know why this is, or what I should be trying to click to solve this? Also, I had this idea of using dream fog, but making it real black and placing that in some shadows. Would that produce a really dark area, do you think or is that fog too see through?

The quick fix for moving the immovable is to go to the templates tab, find the item you can't move (fog, pigeons, etc...) and change them from generic objects to buildings (and save it).  You'll be able to move them around to where you'd like (once you re-open the map), then make sure to change them back   in the Templates tab after (and save again).

Darkened fog would basically look like black smoke, instead of shadows...It may not be the effect you're looking for.

As for making a dark shadowed map...Goggles is right on, darkening textures always works well.

Dana

UnkoMan

I've got the lights working and they look great. Seriously. Thanks a ton. Also I'm able to move fog around so that's very sweet. As to the shadows, actually a weird black smoke is sort of what I would like in the really darkened areas. You know, like within shadows already there. Then it makes, say, a back alley even darker and mysterious. I'd also be using the normal purple fog, or maybe just make it a light blueish/purpleish grey.

The black thing isn't working though. When I change the images to black they hardly show up ingame. Brighter colours are way more opaque, it seems. Black just makes things a bit greyish, if you see it at all. I'm going to play with it more, of course, but I don't see it changing much. I think the nif itself has a level of transparency on it.

GogglesPizanno

You can check the alpha layer of the texture tga for the smoke. Also the nif file itself (in the material node) there is a alpha value that you can play with.

UnkoMan

I did use the alpha in the texture, but it didn't seem to do too much. Anyhow, I've skipped past this idea, unless somebody else can figure it out. Maybe skope some smoke from a character mesh onto the fog? I dunno.

What I want to ask about now are civilian nodes. How do I use them? How to I add some wandering civilians and cars that'll move about on their own and give the map some life? Also... where the heck are the documentation files anyhow? I don't know if I deleted them or what but I cannot find them.

AND, so nobody thinks I am just jerkin' people's chains here, some pictures of my map in progress:
[spoiler]

(This is what the fog looks like with a really dark purple)



[/spoiler]

GogglesPizanno

Nice job... and cmdrkoenig67 said it was too much work. Pffffth.

As for the civilian and traffic nodes. Civilians should technically walk anywhere you place them. If it happens to be on a node, they will follow the path, if not then just aimlessly around the map. Cars need to be on a traffic node. In FFEdit, its usually denoted by a bunch of little icons hovering over the ground that form paths. You should just be able to place the civ's/cars on the ground below where those icons reside and they will behave and just work.

The bad news is that the map has to have those nodes created as part of the export from 3D Max. A spline mesh is converted to a series of coordinates and stored in the level layout file. In theory if you hand edited the level layout file in a text editor and re-imported it in FFEdit (much like Tommy did to place buildings on his Manhattan map) you could add your own, but Ive never gotten it to work and I was just trying to stick with a simple straight line. There are so many possible quirks in terms of placement, location, rules about where they start and end... stuff that the Max plugins do for you that I don't know if it would even be worth the effort given the amount of variables. So my best advice is to build your new maps based on maps that already have them  :D

UnkoMan

Thanks a lot, you guys.

Actually the hardest part is trying to figure when there isn't enough lights in a spot or if I am going overboard anywhere. Placing them around is no big deal though, since I placed every single object in this map except for half the manholes.

Anyhow, this map IS based on an actual, in game map... but, as I implied, I deleted all the objects off it first including any nodes. There were some around. I think only civilian though, but if they walk around anyhow... Still, is there any way to add these nodes back? I don't know anything about editing the level via text only.

GogglesPizanno

You cant really edit the level per se via text file, you can manipulate the level layout file and re-import which is way more trouble than its worth unless you have a very specific reason to.

To get those civilian walk nodes back, you would have to re-import the original level layout file (which means you would probably have to extract them from one of the *.ff files in the data directory). What I don't remember off the top of my head is whether that will wipe all your manually placed objects or not. Part of me thinks not... but dont hold me to it.

You could try it.

- Make a backup of your map
- extract the level layout files from layout.ff (I think -- I'm at work and going from memory)
- In FFEdit at the top of the mission tab is a field for selecting a layout file. Choose the layout file for the original map and import it. At that point the original layout (all the objects nodes, etc...) should have returned. If all your objects are still there, great, remove the objects you dont want from layout list (keeping the nodes) and test. If it just reverted the whole thing back to the beginning, restore the map you backed up and you learned better for next time.

And as always if any of this information is wrong, It's Prev's fault.

AfghanAnt


cmdrkoenig67

Quote from: GogglesPizanno on December 03, 2008, 03:34:50 PM
Nice job... and cmdrkoenig67 said it was too much work. Pffffth.

:P

I should have been more specific in my wording...It isn't too much work if you want to do it for your own personal use in your own maps...It is too much work to use in maps you want to release to the public(along with detailed notes on how the map-user has to set up the light objects)...I don't have the patience to write out the read-me notes (and I'm getting too old for it...LOL!).

Dana  :P :P :P