Sound switch light lever
Posted: Sat Feb 11, 2017 11:32 am
Hello,
When I add lever for light on my map I don't have sound, but when I import building with light in it, the sound work really good and it the same sound file with the same path. But if I duplicate light lever + trigger from building and add it to another building, I don't have sound again.
These 2 lights was with buildings when I import them, so it work
But for this light I duplicate switch lever and I don't have sound and it's the same path
Sorry for my bad english
When I add lever for light on my map I don't have sound, but when I import building with light in it, the sound work really good and it the same sound file with the same path. But if I duplicate light lever + trigger from building and add it to another building, I don't have sound again.
These 2 lights was with buildings when I import them, so it work
Code: Select all
<animatedObject index="lightTunnel">
<controls posKey="LIGHTSWITCH_CLICK" triggerNode="0" posText="input_LIGHTSWITCH_CLICK" negText="input_LIGHTSWITCH_CLICK" />
<sound file="maps/Sound/switch01_0.wav" pitchOffset="1.00" volume="0.20" indoorVolumeFactor="0.55" indoorLowpassGain="0.85" pitchMax="1.15" />
<animation initialTime="0" duration="0.5">
<part node="1|0"> <!--index of Lever of the Lightswitch-->
<keyFrame time="0.00" rotation="0 0 0" />
<keyFrame time="1.00" rotation="-90 0 0" />
</part>
<part node="2|0"> <!--index of TG with realLights and emmisive shape-->
<keyFrame time="0.5" visibility="false" />
<keyFrame time="0.55" visibility="true" />
</part>
<part node="3|0"> <!--index of TG with realLights and emmisive shape-->
<keyFrame time="0.5" visibility="false" />
<keyFrame time="0.55" visibility="true" />
</part>
</animation>
</animatedObject>
Code: Select all
<animatedObject index="Maschinenhalle_kleinLichtIndoor1">
<controls posKey="LIGHTSWITCH_CLICK" triggerNode="0" posText="input_LIGHTSWITCH_CLICK" negText="input_LIGHTSWITCH_CLICK" />
<sound file="maps/Sound/switch01_0.wav" pitchOffset="1.00" volume="0.40" indoorVolumeFactor="0.55" indoorLowpassGain="0.85" pitchMax="1.15" />
<animation initialTime="0" duration="0.25">
<part node="1|0"> <!--index of Lever of the Lightswitch-->
<keyFrame time="0.00" rotation="0 0 0" />
<keyFrame time="1" rotation="0 0 -8" />
</part>
<part node="2|0"> <!--index of TG with realLights and emmisive shape-->
<keyFrame time="0.5" visibility="false" />
<keyFrame time="0.55" visibility="true" />
</part>
<part node="3|0"> <!--index of Lever of the Lightswitch-->
<keyFrame time="0.00" rotation="0 0 0" />
<keyFrame time="1" rotation="0 0 -8" />
</part>
<part node="4|0"> <!--index of TG with realLights and emmisive shape-->
<keyFrame time="0.5" visibility="false" />
<keyFrame time="0.55" visibility="true" />
</part>
<part node="5|0"> <!--index of TG with realLights and emmisive shape-->
<keyFrame time="0.5" visibility="false" />
<keyFrame time="0.55" visibility="true" />
</part>
</animation>
</animatedObject>
Code: Select all
<animatedObject index="lightCompost">
<controls posKey="LIGHTSWITCH_CLICK" triggerNode="0" posText="input_LIGHTSWITCH_CLICK" negText="input_LIGHTSWITCH_CLICK" />
<sound file="maps/Sound/switch01_0.wav" pitchOffset="1.00" volume="0.20" indoorVolumeFactor="0.55" indoorLowpassGain="0.85" pitchMax="1.15" />
<animation initialTime="0" duration="0.5">
<part node="1|0"> <!--index of Lever of the Lightswitch-->
<keyFrame time="0.00" rotation="0 0 0" />
<keyFrame time="1" rotation="0 0 -8" />
</part>
<part node="2|0"> <!--index of TG with realLights and emmisive shape-->
<keyFrame time="0.5" visibility="false" />
<keyFrame time="0.55" visibility="true" />
</part>
<part node="3|0"> <!--index of TG with realLights and emmisive shape-->
<keyFrame time="0.5" visibility="false" />
<keyFrame time="0.55" visibility="true" />
</part>
<part node="4|0"> <!--index of TG with realLights and emmisive shape-->
<keyFrame time="0.5" visibility="false" />
<keyFrame time="0.55" visibility="true" />
</part>
<part node="5|0"> <!--index of TG with realLights and emmisive shape-->
<keyFrame time="0.5" visibility="false" />
<keyFrame time="0.55" visibility="true" />
</part>
<part node="6|0"> <!--index of TG with realLights and emmisive shape-->
<keyFrame time="0.5" visibility="false" />
<keyFrame time="0.55" visibility="true" />
</part>
<part node="7|0"> <!--index of TG with realLights and emmisive shape-->
<keyFrame time="0.5" visibility="false" />
<keyFrame time="0.55" visibility="true" />
</part>
<part node="8|0"> <!--index of TG with realLights and emmisive shape-->
<keyFrame time="0.5" visibility="false" />
<keyFrame time="0.55" visibility="true" />
</part>
<part node="9|0"> <!--index of TG with realLights and emmisive shape-->
<keyFrame time="0.5" visibility="false" />
<keyFrame time="0.55" visibility="true" />
</part>
</animation>
</animatedObject>