generalized coloring function to accept time, bgcolors, and txtcolors arguments for fading the friend boxes