1. How can the amount in satoshi be negative when any nValue aside the True condition must return false?
I think you are misinterpreting the the code.
The variable type
CAmount is a signed integer which means that variables of this type can hold both positive and negative numbers. That does not mean that a
CAmount with a negative value is valid in every context. However, it allows for the possibility, and the comment (as I interpret it) is a warning that negative values are a possibility.
There can be instances where a negative value is reasonable. For example, when displaying the history of a wallet's balance, a transaction sending bitcoins from the wallet would show the change in the balance as a negative number of satoshis.
Finally, if you want to get into some C/C++ programming nitty-gritty ...
In C/C++, signed and unsigned integers are assigned to each other without conversion, so an unsigned integer variable can be assigned and can hold a negative value. A programmer might make the mistake of thinking that using an unsigned integer will somehow protect them from negative values, but it won't
A programmer may use an unsigned integer type to indicate that a variable is never expected to be negative, but that creates a false sense of security. In fact, it prevents them from verifying that value is not negative because the the value of an unsigned integer variable is always interpreted to be >= 0.
Consider that
(unsigned)-2 >= 0,
(unsigned)0 - (unsigned)2 == (unsigned)-2, and
(unsigned)-2 + (unsigned)2 == 0 are all
true.
So for those reasons, I never use unsigned integers for any variables involved in any mathematical operations, even if I never expect the values to ever be negative.
There is only one way to ensure that a variable is not negative and that is to allow it to be negative and then check its value, which is what the code you referenced does.