Basic flashlight effect
I'm making a survival horror game, and I want to make a flashlight effect. No battery or anything, not even a flashlight model. Just a basic spot light that can be toggled on and off. I tried attaching a spot light component to the first person character prefab but nothing happened when I clicked play. How do I make this?
Answer by Yoshinator2 · Nov 24, 2016 at 11:40 PM
You may want to make sure that the spotlight is enabled, and not inside the character when spawned. To make sure that the flashlight isn't inside the player, adjust the offset of the spotlight, and angle it correctly in the world. Then, attach it to the player in the world and test. I'm not sure that's the problem but I hope I helped!
I figured that out, but now it's not bright enough. I changed the intensity to 0 and it's barely visible.
increase the intensity and range to make it brighter
enable the entire spotlight with something like this
[serialized field] private GameObject spotlight;
public void ToggleSpotlight (bool tf){ spotlight.setActive(tf); }
Answer by axlya · Oct 06, 2017 at 06:20 AM
Flashlight Editor: https://www.assetstore.unity3d.com/en/#!/content/98664
Answer by JTAGames · Jul 11, 2021 at 04:18 PM
https://www.youtube.com/watch?v=SumkdpuPjLg
This is a 4 minute tutorial the non fancy stuff is shown first so you can just skipped the rest when your done.
Your answer
Follow this Question
Related Questions
how to make flashlight point where your looking? 1 Answer
Flashlight (spot light) doesn't work the way I want it to 1 Answer
Flashlight battery 1 Answer
How do I make a working flashlight with batteries? 0 Answers
Underwater effect 2 Answers