BROCKTON — Ajhier Gilmore and Deja Tench were enthralled.
Motion sensors on their new video game console captured the 8-year-old boy and a 7-year-old girl walking "like an Egyptian" and grooving to Beyonce. How? The children weren't quite sure, but behind them, their grandparents Gloria and John Gilmore applauded every shoulder shimmy and hip swivel — as any parent would.
After a long custody battle that began three years ago, the Gilmores are the legal guardians of both children, which the grandparents said is a dream come true.
Four months ago, the state Department of Children and Families said they had "no present concerns" about the children staying in the custody of Deja's father, a man who had multiple pending criminal cases across the state. On Thursday, one month after The Boston Globe highlighted the family's plight as a snapshot of difficult choices facing DCF, a judge reversed that decision: The Gilmores have been awarded temporary emergency custody, at least until March. It is unclear what prompted the judge's reversal or if DCF maintained its previous position, but the grandparents of the children said they could not care less.
After years, Gloria and John Gilmore said, justice was served for their beloved granchildren, nicknamed Rocky and Deja Vu. "It brought tears to my eyes," John Gilmore said, while sitting on the couch in the family living room.
On cue, Deja rushed through the kitchen bouncing a basketball and laughing.
"I was elated," Gloria Gilmore said of the judge's decision. "It's been a long, hard struggle and finally we can do better for the children. That what it's always been about."
From 2012 until Thursday, Jason Tench, Ajhier's father, had exclusive custody of both children. The arrangement was the voluntary decision of Ajhier and Deja's mother, Gideanne Gilmore, who said she believed that Tench was more financially secure and would better care for both children, according to court records.
In a previous interview, Gideanne Gilmore said she and Tench used crack cocaine around the children and would frequently keep them out of school. She remains mostly uninvolved with her children's life, her parents said.
As the Globe reported in November, three months after DCF said they had no concerns about the children's home life, court records showed that Tench was arrested in August on a defaulted warrant and has pending criminal cases in Dorchester and Quincy for check forgery, producing a false check, credit card fraud, larceny, and breaking and entering.
Tench did not respond to requests for comment for this story. But when interviewed for the previous story, Tench denied the allegations of drug use and said he had turned his life around after finding a new job.
At that time, the grandparents argued that it was too little too late from Tench, and they feared that their grandchildren could become the state's next high-profile tragedy of children lost despite DCF involvement.
On Thursday, a judge agreed the Gilmores were currently best suited to care for the children. The temporary custody order runs through March 10, when another hearing will be held to extend the temporary order or grant full custody to either Tench or the Gilmores.
Tench did not appear in court Thursday, the Gilmores said.
"The kids were screaming that they wanted their daddy all the way from Boston to Brockton," Gloria Gilmore said, before adding that she and her husband will seek permanent custody. "But now they're adapting. They know us and they know we love them."
That love was on display in a tangible way during the children's first weekend at their new home.
A shopping spree on Saturday yielded new high-top black Jordan basketball shoes and a Batman-themed hoodie for Ajhier, which he wore the following day. Deja rode a bike on their new suburban street and practiced breaking on a neighbor's sprawling front lawn.
In Dorchester, where they lived with Tench, the streets were less conducive for biking, the kids said.
Later, they rattled off the names of their newfound friends on Boundary Circle as Grandma and Grandpa paced the side of the road, watching for cars. "I have to learn all that kid language again," Gloria Gilmore said.
Gilmore, 66, and her husband, 76, said they have prayed to God for about "12 healthy years" to see the two children through to adulthood.
Shortly after, a small fight broke out among the siblings and the grandparents were forced to impart a lesson about sharing.
The courts had granted their wishes for custody.
Now it was time to parent.