Round and trunc functions

  • Hi!

    When I'm doing with the auto-panorama, then after some time hlookat value exceeds 360. and sometimes more than 4000 (if the long turn), so if you switch to another panorama, and when calling the function tween (view.hlookat, 0) takes place a few spins around its axis before hlookat takes the value 0

    I'm trying to solve it this way:

    XML
    div(tmp,view.hlookat,360);
    round(tmp,tmp,0);
    mul(tmp,tmp,360);
    sub(tmp,view.hlookat,tmp);
    tween(view.hlookat, tmp);

    but the function "round" or "reject" it seems no ...

    How do I solve this problem?

    P.S. А по русски тут кто-нибудь говорит?

Jetzt mitmachen!

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