BUG: Something kills evaluation of 0 in JS

  • Everything is normal until I load a new xml.
    Before I load the xml I try to wipe the environment
    For one action I'm checking the x of a plugin but it's NaN
    ok. I set my x to a known value 77,
    then I check it again

    krpano.call("if(plugin[scene1129].x GE 0,trace(hi)))");
    krpano.call("if(plugin[scene1129].x LE 0,trace(hi)))");

    Neither work even though x is 77.
    And this affects ALL evaluations against 0, not just this plugin.
    So common functions of previous scene where it uses GE 0 are now broken.

    also using 0 no longer works.. set(i,0);
    Using 1 instead, and everything is normal. For the initial xml load things are normal

  • I tracked this down to the use of vars in loadpano or loadscene
    HTML5 ONLY problem

    loadscene(get(scene[0].name),null,MERGE);
    works
    loadscene(get(scene[0].name),wtf=whoknows,MERGE);

    suddenly breaks the use of 0

    krpano.call("if(plugin[hide].x GE 0,trace(hi)))");

    xml used...

    embed code

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!