If I am remembering the law correctly, it stipulates that, in order to receive a citation, the officer must be in a clearly-marked police vehicle (i.e., a car that says "POLICE" on it) or in uniform (i.e., he can be in an unmarked car, but he has to then be in his police uniform), and his vehicle must be visible from the road. This latter part is what I think you are referring to. My understanding is this: if its dark, then the officer at least needs to have on his parking/running lights, but doesn't need to have on his headlights, but can't be sitting completely concealed in darkness, either. Again, it's been a while since I referenced the actual letter of the law, so I may be a little or even completely wrong here. We have a few law enforcement guys on here - maybe they will chime in with the official word on this.
BTW, if I'm correct, and, if I am understanding you correctly, you got a citation for speeding at night by a cop that was sitting without any lights on at all on the side of the road, then prooving that he didn't have any lights on at all would be difficult unless you have videotape of him not having any lights on. It would essentially boil down to your word against his, and, well, your screwed if it comes to that.