A 69-year-old Northam man was found guilty of masturbating in front of a local school, when he appeared in court on Monday.
Police Sgt Phil Milne told the court Robert George Batory parked his car outside St Joseph's School on April 27, 2017 around 11am.
He told the court Batory opened the car door while sitting in the driver's seat, pulled his pants down and proceeded to masturbate.
Two staff members saw the man and called police.
The witnesses told police he frequents the car park and was previously seen doing the same act under a newspaper.
The students were in class at the time having just finished recess, Sgt Milne said.
Batory told the court he was sorry for what had happened.
He told Northam Magistrate Jennifer Hawkins he did not suffer from a mental illness but had high blood pressure and a prostate problem.
Magistrate Hawkins took into account Batory’s guilty plea and that he was on aged care benefits.
He was fined $900 for obscene acts in public and ordered to pay $98.50 in court costs.