Arduino code help with fade_functions

this is my bad. its actually not the issue. i tried to limit 'h' to see if it will solve these abrupt values. but it did not solve my problem. i feel like the problem is in this part of the code

old_humd_color = new_humd_color;