Issue with addition

Joe's icon

Hi guys,

I have a patch here which adds together two numbers simple as.. it works fine

I then wanted to change the number being added to a decimal... doesnt work

Max Patch
Copy patch and select New From Clipboard in Max.

Any ideas?

Gregory Taylor's icon

Unless you specify otherwise, Max expects to be working with integers [Yeah, I know. It's been this way forever, though]. Take a look at the "Number boxes" section here:

Joe's icon

Okay I took a look at number boxes and simple math but i am still not getting the results I need.

Max Patch
Copy patch and select New From Clipboard in Max.

I have a patch with 5 different methods, non of which add 0.25 to the total number..

dtr's icon
Max Patch
Copy patch and select New From Clipboard in Max.

This is basic Max behavior and shared by tons of objects.

Btw, you've been opening new topics/help requests every day in the last couple of weeks and a lot of them for basic issues. Makes me wonder if you're checking the standard resources before posting them: object's help patches and references, the included max/msp/jitter tutorials, searching this forum, etc.

Joe's icon

Thanks for that input...

Max Patch
Copy patch and select New From Clipboard in Max.

I got it working in the end with the use of an accum 0.1

zeeshanaayan07's icon

Thank you this code is doing work