_O_OBJECT SET COLOR reverse engineer the color parameter

The command _O_OBJECT SET COLOR the color parameter was a combination of foreground and background colors. color =-(Black+(256*White)). Is there a way to reverse engineer this number?

Thanks in advance. Garri Ogata

I think it is easier to think of the formula as a 2 byte hexadecimal, like0xwwbb. Multiply by 256 is shifting 2 places to the left. 1 place is 1 byte, or 8 bits.

$value_1:=1
$value_2:=2

$color:=-($value_2+($value_1 << 8))

$value_1:=-$color >> 8 & 0x00FF
$value_2:=-$color & 0x00FF

Thank you! That works great. I appreciate the help.