Skip to main content
Inspiring
December 15, 2022

Functions: negative integer processing is not working properly

  • December 15, 2022
  • 5 replies
  • 425 views

    5 replies

    Luca Giarrizzo
    Community Manager
    Community Manager
    December 19, 2022

    Hello,

     

    Thank you @_Olivier_L for reporting this issue and @davescm for merging issues related to negative integers. I have done the same on our end.

     

    Best regards.

     

    Luca Giarrizzo | Quality Engineer - Substance 3D Designer | Adobe
    davescm
    Community Expert
    Community Expert
    December 19, 2022

    @kirkr5689 I merged your post with an existing bug report.

    There are issues with comparisons on negative integers and cast to float does not work correctly.

     

    Dave

    Inspiring
    December 18, 2022

    I tried it with > <  kind  of nodes to detect negative integers , then abs , turn to float and *-1   .   But >  considers -2  be greater than 0.  Is it right?   I always though otherwise.

     

    Any other way to turn negative integer input  into negative float?

     

     

    davescm
    Community Expert
    Community Expert
    December 15, 2022

    I've moved this to Bugs.

    There are a few problems with negative integers - for example a comparison of -15 > +10 comes out as true. As you have discovered casting to float does not work correctly either.

     

    Dave

     

     

    Inspiring
    December 15, 2022

    Please someone move this in the Bug section, for some reason I cannot edit my own message...