In Memoriam: Tai'lahr

OpenUru.org, along with the rest of the Mystonline community, is mourning the loss of Tai'lahr on October 16th, 2019.

Rest in Peace, friend.

Light Regions: Controlling The Light On The Avatar

From OpenUru
Revision as of 12:26, 29 July 2011 by Andylegate (talk | contribs) (Created page with "If you've been building Ages, or exploring Fan Ages made by other people, one thing you may have noticed: Objects do not block the light falling on both the Avatar and Animated ...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

If you've been building Ages, or exploring Fan Ages made by other people, one thing you may have noticed:

Objects do not block the light falling on both the Avatar and Animated Objects.

Many times I've linked into a Fan Age and walked around outside with my Avatar lit up by that Age's sun, only to walk inside a building or cave and see my Avatar still brightly lit by the sun, while everything else around me is darker.

The way to fix this is by putting in Soft Volumes that we call Light Regions.

Using Light Regions, we can do all sorts of neat things:

We can control how much light, or completely block that light from outside falling on the Avatar.
We can make the transition of light going from outside to inside, or the other way around, so that it looks gradual.
We can keep lights that are inside somewhere from lighting up the Avatar while they are outside.



Getting Started......

I'm going to use my outside Test Age for an example of how to set up a light region.

I threw in a dome that the player will enter. I also put in a red light inside it that is a Plasma Run Time light (keep in mind that only Plasma Run Time lights are controlled by Soft Volumes. Max lights are not.). This light will light up my Avatar:

http://assets.openuru.org/wiki/andy/MaxTutPics2/Litreg1.jpg

But, I don't want the outside sun light to keep lighting up the avatar once he's inside this dome. So I'm going to need a region.

So I create a sphere to use as the light region on the dome:

http://assets.openuru.org/wiki/andy/MaxTutPics2/Litreg2.jpg

Once it is made and in position, I then call up the Component Manager and click on New > Region > Soft Region:

http://assets.openuru.org/wiki/andy/MaxTutPics2/Litreg4.jpg

And assign that to the region I made.

Go to the Utils Tab and select the Soft Region component. In the roll out for it, look at the picture below:

http://assets.openuru.org/wiki/andy/MaxTutPics2/Litreg11.jpg

Notice that I put a check mark where it says "Partial Power", and I've set the power for Inside to 0.0, and the power for Outside to 100.00. This tells the soft volume that whatever kind of region I'm making this (Light or Sound), that I want something to be turned OFF when the player is inside the region, and turned all the way back ON when he is outside the region.

Next, click on the Component Manager and click New > Region > Light Region and assign it to your region:

http://assets.openuru.org/wiki/andy/MaxTutPics2/Litreg5.jpg

Go to your Utils Tab and select the Light Region component and look at it's roll out. You need to click on the button in the Regions box. Then pick your Soft Region that you assigned to this region:

http://assets.openuru.org/wiki/andy/MaxTutPics2/Litreg6.jpg

As I said above, I put in a red light that is a Plasma Run Time light inside the dome, and adjusted it's values to what I wanted:

http://assets.openuru.org/wiki/andy/MaxTutPics2/Litreg7.jpg

While I have that light selected, I open up my Component Manager and assign my Light Region component to this light:

http://assets.openuru.org/wiki/andy/MaxTutPics2/Litreg8.jpg

This is telling Plasma that this light is controlled by the Light Region.

I then select my Plasma Run Time light in the sky that I use to light up my Avatar:

http://assets.openuru.org/wiki/andy/MaxTutPics2/Litreg9.jpg

And again, I assign it the Light Region component:

http://assets.openuru.org/wiki/andy/MaxTutPics2/Litreg10.jpg

You should do this for ALL lights that you want controlled by the light region.

Now, this will make the Avatar be lit up by only the lights you have in the Light Region, and keep the outside sun light off of him.

Check out my video of it:

Light Region Video




Return To: 3DS Max Plugin Tutorials

Copyright (C) 2011 Andy Legate.
Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.3 or any later version published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts.
A copy of the license is included in the section entitled "GNU Free Documentation License".