Good dialogue writing rules are that dialogue is used to move the plot along and reveal the characters. It needs to be a substitute for narration. Never use dialogue and narration to tell the reader the same thing. It should also reveal the character's intention in the story and also set the tone.