(a) The court may, in its discretion, appoint a guardian ad litem to represent a minor child who is the subject of a paternity petition. Payment of the guardian ad litem shall be as ordered by the court. Neither the child's mother nor the alleged or presumed father may represent the child as guardian ad litem.
(b) The natural mother shall be made a party or, if not subject to the jurisdiction of the court, shall be given notice in a manner prescribed by the court and an opportunity to be heard.