The text encouraged Roy to keep his "head up, have fun out there and stay positive."
Roy, who has struggled in the second half of the season after double knee surgery, had lamented about how he was being treated after playing limited minutes in Game 2.
Boosted by his family and dozens of encouraging texts such as Barkley's, Roy came off the bench and scored 16 points to help the Blazers to a 97-92 victory.
The win narrowed Dallas' lead in the first-round series to 2-1.
"I was playing tonight. I was in go mode," Roy said. "I didn't worry about nothing else. I didn't worry about playing time, I didn't worry about who was playing. When it was my time I was going."
The Mavs and Blazers split their regular-season series, with each team winning at home twice.
Portland has won 11 of its past 12 at the Rose Garden. Overall against Dallas, the Blazers have a 47-18 advantage at home in the regular season, and they are 7-1 in playoff games.
The Blazers led by as many as 13 points in the fourth quarter, but Nowitzki hit consecutive jumpers to make it 87-81 midway through the period.
J.J. Barea's layup closed the gap to 93-87. Aldridge answered with a jumper for the Blazers, but Nowitzki came back after a free throw with a turnaround jumper to make it 95-90 with 42.8 seconds left.
Jason Kidd made a long jumper with 12.9 seconds to go but Dallas ultimately couldn't catch Portland.
Roy, who touched off a minor controversy over the comments he made after playing just 8 minutes in Game 2, came into the game with 2:17 left in the first quarter to a standing ovation. He made a 21-foot jumper to give the Blazers a 28-23 lead heading into the second.
The three-time All-Star underwent arthroscopic surgery on both knees in mid-January. Upon his return, Roy struggled to find his place with the Blazers.
And after sitting for much of Game 2, Roy voiced his frustration to The Oregonian newspaper.
"I'd be lying if I said I wasn't a little hurt or disappointed," Roy told the paper. "I just always thought I would be treated a little better. That was a little disappointing for me."
Before Thursday's game, Roy apologized for the comments, saying he was caught up in the emotion of the loss.
"I wasn't nervous," Roy said afterward. "The fans were really supportive. They were cheering for me before I went in the game. That's really big for me. We've been through a lot together and to know that they still have my back was great for me tonight."
Coach Nate McMillan wasn't surprised.
"This is a guy we know is capable of producing, and tonight he did that," McMillan said.
Terry's 3-pointer to open the second quarter gave the Mavericks a 31-28 lead, and Nowitzki capped an 11-4 run with a 10-foot jumper that made it 37-32.
But Portland, elevated by the home crowd, came back to tie it at 41 on Andre Miller's layup. The Blazers went ahead 44-43 on Roy's 3-pointer.
Portland held the lead until Nowitzki's 3-pointer tied it at 52, but Matthews' layup gave the Blazers a 54-52 advantage at halftime.
Matthews had 22 points in the first half. Terry, whom coach Rick Carlisle sent in off the bench early, led the Mavs with 17.
"Our problems began at the beginning of the game when we got off to a very poor start and their aggressiveness put us on our heels," Carlisle said.
Terry's 3-pointer gave the Mavs a 57-54 lead, but both teams wrestled back-and-forth throughout the third quarter.
Portland went ahead 85-74 in the fourth after consecutive 3-pointers from Batum and Gerald Wallace.
"We hang our hat on defense," Terry said. "We gave up 95 points to this team, which we hadn't done in the first two games. That's the reason why we lost.
Dallas is 2-1 overall when it has opened a 2-0 lead in 15 previous best-of-7 series. The exception was the 2006 NBA Finals, when the Miami Heat defeated the Mavericks in six games. The Heat were just the third team to claim a championship after trailing 0-2.
The last time Dallas and Portland met in the playoffs was 2003. The Mavs claimed the first three games before the Blazers won the next three. The Mavericks took the deciding game in Dallas.
At the shootaround before Thursday's game, McMillan was asked what he told his team first thing that morning. "Win, baby. Win," was his reply. ... Matthews' four 3-pointers in the first quarter matched the team playoff record for a quarter, held by Terry Porter and Rudy Fernandez. ... Aldridge received the team's inaugural Maurice Lucas Award for the player that best represents the true spirit of Lucas, the former Blazers player and assistant coach who died in October after a battle with cancer. ... Dallas' Tyson Chandler fouled out with 7:24 left.