BANGOR, Maine -&nbspBy the time Lily Knowlton turned 4, she already had been through four area preschool programs, and her out-of-control behaviors had cost her mother her job.

But Peace Pals, a Bangor program for children who have behavioral problems, has turned things around for Lily and her mother. And though the program, run by the Bangor chapter of United Cerebral Palsy, recently was slated for closure due to the state’ s precarious finances, a meeting last week between parents, state officials and the program managers has ensured its continuation, at least for the near future.

The agreement augurs well not just for the families served by Peace Pals but also for other families and agencies trying to meet the needs of children who have behavioral problems. And it ties in, at least indirectly, with a class-action lawsuit brought last month on behalf of Maine children whose access to mental health services has been jeopardized by funding difficulties in the state’ s Medicaid program, MaineCare.

Lily’ s mother, 25-year-old Haleigh Higgins of Bangor, said her little girl has been diagnosed with oppositional defiance disorder, obsessive-compulsive disorder and sensory integration disorder. With too much going on in her environment — noise, activity, bright lights, rough textures against her skin — Lily can become obstinate, disruptive and physically violent. Showing impatience with her need to have things ordered just so in her cubby, or using a “because I said so” approach to getting her dressed for recess, only compounds her frustration and escalates her behavior.

“I was getting calls all the time to come and get her,” Higgins said Monday. “She just wasn’ t getting the personal attention she needed.”

Those calls, coming two or three times a week and sometimes daily, cost Higgins a full-time job she had taken to support herself and her daughter. And, without getting appropriate guidance and instruction in a group setting, Lily was missing out on vital preparation for entering school — all the more important considering her behavioral challenges.

But since Lily started attending the Peace Pals program six months ago, it’ s been smooth sailing. An intimate enrollment of just 11 children, a curriculum that includes scheduled therapeutic exercises and a cadre of specially trained teachers have made a world of difference to Lily and her mother.

“I haven’ t gotten called once,” Higgins said. Not only has Higgins begun looking for another job — she’ s had two recent interviews — but Lily also is making clear progress in her ability to control her behavior and seems to be on schedule for transitioning to a regular kindergarten class at Bangor Christian Schools in the fall.

Peace Pals is one of two Bangor programs aiding youngsters who have behavioral problems that lost all their state funding late last year when the state Department of Health and Human Services announced budget reductions due to lower-than-expected tax revenues. Peace Pals relied on MaineCare, the state’ s Medicaid program, for about half of its approximately $300,000 annual budget, according to Executive Director Bobbi Yeager.

The other Bangor program, offered for seven years by Northeast Occupational Exchange, was a nationally recognized after-school and summer camp program for children who have mental health diagnoses in kindergarten through grade 12.

NOE Director Charles Tingley said Tuesday the program shut down in February, leaving about 300 youngsters with no place to go after school and no summer program to meet their needs.

Yeager said too many Maine children who have behavioral problems are falling through the cracks. Because the state eliminated funding for the day treatment services provided at NOE and Peace Pals, and because bright youngsters with mental health diagnoses may not qualify for school-based services through the Department of Education, children like Lily can be denied the help they need to succeed in public school, she said.

In response to the budget cuts, United Cerebral Palsy eliminated a day treatment program for older children but has tried to keep patching Peace Pals together, despite the lost state funding.

“We know we are the last resort for these families,” Yeager said Monday.

March was the last time MaineCare paid Peace Pals for the therapeutic services being provided. But at a meeting last week with officials from the Office of Child and Family Services, Yeager said, families and staff at Peace Pals heard what they wanted to hear — the state will help them find continued funding for the program and also will pay the program retroactively to March.

Doug Patrick, manager of children’ s behavioral services at DHHS, said Monday that MaineCare has an obligation to provide certain “medically necessary” mental health and behavioral treatments to children. When services can’ t be delivered in a regular school or preschool setting, he said, the state is willing to help identify alternatives. A special Medicaid program known as EPSDT — Early and Periodic Screening, Diagnosis and Treatment — often will pick up the tab for services not otherwise covered and “opens a door for us when all the previous doors were shut,” he said.

Eligibility and covered services are determined on a child-by-child basis, Patrick cautioned. “We’ re willing to work with the families about how they want services to be arranged around these kids,” he said.

At the nonprofit legal services organization Maine Equal Justice Partners, attorney Jack Comart said Tuesday that DHHS is under pressure to meet the mental health needs of Maine children. Comart has been advising United Cerebral Palsy about the Peace Pals program and also represents plaintiffs in a class-action lawsuit filed in June that charges the state with failing to comply with federal Medicaid regulations in meeting the mental health needs of Maine children.

“[DHHS] has been advertising recently that there should be ‘ no wrong door’ for getting services,” Comart said. “But for some people, there seems to have been no right door.”

Comart said Monday he is discussing a settlement with state officials and hopes to have the class-action lawsuit resolved within a month.