Number component does not accept 0.0 any more

Hello,
Can someone tell me why in Grasshopper 6 the number component does not keep 0.0 as a number any more. In Grasshopper 5 if the input is 0.0 the output is 0.0, in Grasshopper 6 if the input is 0.0 the output is 0
Thanks!

there’s a setting for that:

Hi Jeff, thanks for the info. I will make the adjustment.

If you don’t mind could you explain a little why it has been decided that a floats component also gives integers as a result. I know that in mathematics 0 is the same as 0.0 but not in programing at list for the little I know. If you have a little time it would be nice to understand.

The number is still 0.0. What you are looking at is a value that you connect to a Panel. Doing so means the number gets formatted. If you ever need to see what values you are working you can of course connect them to a Panel, but you should not use the Panel as input to further components.

In this screenshot you see the a output gets set to the x input. Printing those still shows them as 0.0, as expected. Connecting the a to the panel as well has the formatting kick in.

You may ask why the 0.0 from the out output isn’t formatted. That is simply because out already gives its data as a string.

Sorry, I understand but I think I didn’t explain my self correctly. I have attached 2 screenshots one from Rhino 5 the other from Rhino 6.
Rhino%205%20Capture

This from rhino 6

@franciscok that does not matter. The underlying number is still the decimal number 0.0. It is the panel that does formatting for you.

If you print out the number like I did with a script you will get still 0.0

image

I reiterate: don’t trust what you see in Panel, and don’t use the panel as input to other components - data may have changed.

Sorry again, I understand and still…

In over a year and a half, I have created a manufacturing program with several thousands of components using rhino 5 and it worked perfectly. Now running it in rhino 6 it does not work at all. I have figured out that several components don’t give the same result as in rhino 5 one is clearly the number component.

In this particular case, I gave the input to the component not using other components, I click on the component and under set number I set the number 0.0. If you go with your courser over the input or over the output area both show you 0.0 in rhino 5. If you would do the same procedure again to set a number you will find also 0.0 as the already set number. In rhino 6 you are able to type 0.0 but after you close the component and open it again you find an already set input of 0 and if you go with you courser over input and output area you will see an input and output as 0. There fore and I have seen it, the next component you connect take as an input 0 and not 0.0.

I know that you are probably laughing over my stupid 0 problem, but belief me, it has destroyed countless hours of work and yes, I can and will correct all the problems but it definitively was not was I expected when I decided to upgrade.

I understand almost nothing of programming and as I understood that was the intention of Grasshopper that people like me can do incredible things using simply components like a Lego game but in order to really succeed, we need to be able to trust on that the components don’t lose anything they had before.

I already asked in another comment for a list of all the changes done on the components that already existed in rhino 5 in order to be able to find all the errors.

I would take me countless pages to explain (with my terrible English) why this problem with the number component is so important to me. I have already solved this particular problem at my way, but still it is certainly very annoying.

I’m going tomorrow on as I think well deserved week vacation and then I will fight again full power with rhino 6.

Let me thank you for being a very kind listener. Thank you!

I think you have the rhino 6 I need

but in order to really succeed, we need to be able to trust on that the components don’t lose anything they had before.

To be fair, Grasshopper before Rhino 6 was always a beta, so you have to anticipate changes.

In this particular case, I gave the input to the component not using other components, I click on the component and under set number I set the number 0.0. If you go with your courser over the input or over the output area both show you 0.0 in rhino 5. If you would do the same procedure again to set a number you will find also 0.0 as the already set number. In rhino 6 you are able to type 0.0 but after you close the component and open it again you find an already set input of 0 and if you go with you courser over input and output area you will see an input and output as 0. There fore and I have seen it, the next component you connect take as an input 0 and not 0.0.

But did you listen to @jeff_hammond , what he told you fixes all of that back to the other way, so it is a non-issue for discussion anymore I think. This is from Rhino 6 following Jeff’s tip.
Capture

1 Like