#1, by yoyanWednesday, 03. June 2015, 12:36 8 years ago
Hi, i put a shaderlamp in a scene.. and all rest of scene is black. ¿why?...and if i move for the scena with the character and scroll the scene, the shaderlamp also Move!.Can I block shaderlamp? I want the shaderlamp fixed. It Is posible? Thanks a lot .
#2, by afrlmeWednesday, 03. June 2015, 12:59 8 years ago
If you activate lighting then it requires you to create lights with the shader, otherwise the scene will be in darkness. When you create lights (spot or point lights) it will light up the areas that the lights are attached to based on the parameters you use.
I'm still not very savvy with the lighting, so I'll just let Simon answer this thread, if he sees it.
P.S: could you please post the code you used for the lighting.
#4, by afrlmeWednesday, 03. June 2015, 13:38 8 years ago
The lighting should be fixed to the specified coordinates unless you bind it to a character or the position of an animation.
To disable it in scenes that you don't want it in, you could create an execute a script action part, at the beginning of each scene that you don't want to add lighting to. Or you could add it inside of an at end of scene action part for the scene or inside the actions that trigger the scene change.
#5, by yoyanWednesday, 03. June 2015, 13:51 8 years ago
the problem arises when I put a shaderlamp on a big scene. If I put the lamp in a scene from normal size (no scrolling scene). I have no problem. But if the scene is big and there scroll, the lamp moves. This is the problem. I cant solve this. This is my main handicap. Thanks a lots .
#6, by afrlmeWednesday, 03. June 2015, 14:09 8 years ago
I'm not sure if the position is based on current viewport or the entire scene. If it's the viewport then it might require creating a function which can calculate the correct position & adding it to a bind or inside of a loop.
#8, by yoyanWednesday, 03. June 2015, 21:51 8 years ago
Hi simon! Ok, firstly , thanks. now the shaderlamp it fixed where i would want and the lamp dont move, but now the problem is that the lamp turns when the character move. Like a light surveillance. Know what I mean?..
#11, by yoyanWednesday, 03. June 2015, 23:36 8 years ago
the target pos is defined in shaderlamp...no?. shaderLamp(index, type, position, "targetpos", falloff, ambient, diffuse, diffusefactor, exponent, cutoff). I do not get it working. The lamp turn .. :-(.