It's always better to post the original FULL request in the very beginning (although I know what it's like - you just wonder if somethings possible, then once you realise it is, you know your formula may be able to do even more, so start expanding).........
However..
=IF(SUM(H4:H8)>10,SUM(H4:H8)-0.4, IF(SUM(H4:H8)>4,SUM(H4:H8)-0.35,SUM(H4:H8)))
.........should do the trick for you.
Knowing your actual requirement in the first instance may have resulted in a better (and more rounded) formula to suit all your needs, so this is an altered version of the original.
Hopefully you can see how to "Nest" the If statements to suit your needs.
Happy Xcelling!!