onstart scene invoke function

  • I whant to invoke function onstart in one of multiple scence, but it not working.

    If I make something like this its working fine:
    <scene name="scene_3" title="3" onstart="set(plugin[radar].heading, 0);"...

    But how to invoke javascript interface function?
    I tryed many things:
    <scene name="scene_3" title="3" onstart="startup2();"...
    <action name="startup2">
    alert('spot');
    </action>

    or something like this:
    <scene name="scene_3" title="3" onstart="startup2(90);"...
    <action name="startup2" args="de">
    korrect_comp(de)
    </action>
    And I didnt get the argument value...

    Please help! )

  • Thank you! This is work for me.
    <action name="startup2" autorun="">
    js(add_hotspot_onstart_scene(%1));
    </action>

    But how can I pass arguments with type="Javascript" way?
    <scene name="scene_698_nw" title="698 nw" onstart="startup2('scene_3');"...
    <action name="startup2" type="Javascript" autorun="">
    <![CDATA[
    alert(%1);
    ]]>
    </action>


    I tryed wirth args="scene" - not working too.


Jetzt mitmachen!

Sie haben noch kein Benutzerkonto auf unserer Seite? Registrieren Sie sich kostenlos und nehmen Sie an unserer Community teil!