Hi again guys, I want use shader effect in a scene object. If only use one effect to objects works.
ok I do this:
Actions
At the beggining of the scene:
Execute a script:
local eff2="tv2"
shaderAddEffect(eff2)
shaderRemoveEffect(eff2)
shader_effects[eff2].num.strength=1
bind(eff2, "time", field("shader_iTime"))
shaderSetOptions({{shader = shader_effects[eff2].num(), comp_dst=5, comp_src=4 }}, 1)
Objects.object1.ShaderSet = 1
Objects.object2.ShaderSet = 1
Objects.object3.ShaderSet = 1
Objects.object4.ShaderSet = 1
Execute a script:
local eff="ripple3"
shaderAddEffect(eff)
shaderRemoveEffect(eff)
shader_effects[eff].num.strength=1
bind(eff, "time", field("shader_iTime"))
shaderSetOptions({{shader = shader_effects[eff].num(), comp_dst=5, comp_src=4 }}, 1)
Objects.object5.ShaderSet = 1
Ok, If only put one of the script.work perfect.
But if I want two diferent shadereffects in a two diferents objects in the same scene, I cant. Always works only the last shader efecct applied. can you help me? I read wiki but dont get it. Thanks in advance
.