Fix giving and receiving amounts

Fixes #1127, and a few other bugs (including the 4th item of #2630).
`NULL` means "unknown", we haven't determined yet if the tip is funded or not.