- Home /
light.intensity is obsolete
Heya!
So does anyone happen to know what should I use if .intensity is obsolete? I used light.intensity and Unity said that it's obsolete and I should make backup before continuing. And it seams that light.color is obsolete too. Does this have something to do with "light"?
thanks.
Huh. The manual says light intensity and color are current. How did it tell you this? What version? Is there a context (a standard pointLight object)?
have you already tried replacing light with
GetComponent<Light>()
Answer by Eric5h5 · Dec 29, 2014 at 06:29 AM
Unity didn't say that light.intensity or light.color were obsolete. It said that UnityEngine.Component.light was obsolete, and not to use the light property, but GetComponent instead. In fact, Unity told you exactly what to do, with the exact code you needed. Reading = winning! ;)
Actually it didn't. https://www.dropbox.com/s/drko45nii93vpr1/nimet%C3%B6n.png?dl=0 I got this message but when I clicked "I made backup. Go ahead", nothing happened. I know that it should change my scripts but it didn't.
Your answer
Follow this Question
Related Questions
GUI Problem 1 Answer
Light Draining Script 1 Answer
Error CS(11,10)an object reference is required non static member 'UnityEngine.Light.intensity‘ 2 Answers
Light intensity with mouse scrollwheel 1 Answer
How to change the intensity to go down over time and to go up after colliding with an object. 1 Answer