Using Cookies to Create Realistic Lighting

Before doing this, drag and drop your cookie into unity. Then create a Spotlight.

In the first step select a cookie and change the texture type to cookie and change the light type to spotlight. Then We need to adjust the Alpha Source to “From Grey Scale”, Also check Alpha is Transparency then hit apply button.

Note: We set light type, according to the type of light we create early.

Now Select the spotlight, drag and drop the cookie to inspector <SpotLight<Emission<Cookie, then hit fix.

Fixing Spot Light cookie.

Let's see the result of the spotlight.

The cookie on Point light looks so great. Follow all the steps, and check Fixed Edge Seams and hit apply button. then select the point light, drag and drop the cookie to the cookie field on the inspector, and hit the fix button.

Let's see the result.

See you in the next article.

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Suleiman Abdullah

Self taught Unity Developer, who is passion about making games ,and he loves Math For Game Development