TORONTO — The Toronto Raptors‘ past sins aren’t a mystery. They weren’t committed under a cover of darkness. Their moral failings were played out in front of huge crowds in brightly lit arenas.

The defensive indifference. The belief that things would eventually straighten themselves out. The idea that the first 50-odd games of the season would somehow predict the final 30 regardless of their effort or attention to detail. That the playoffs would wipe the slate clean.

It ended in hellfire and damnation — a 13-16 record after the all-star break and an ugly sweep at the hands of the Washington Wizards.

It also sparked a resolve to live the right way, defensively, and for most of the season the Raptors’ new-found belief in the importance of doing so has been evident. This year Toronto reached the all-star break as the ninth-ranked defensive team in the NBA.

All was good.

But since? Old habits seem hard to break, or new ones take longer to form. Tuesday night’s game against the Brooklyn Nets was the Raptors’ 10th since the city hosted the all-star break in February and Toronto has been the 27th-rated defensive team in the NBA over that stretch.

Hosting the woeful Nets should have been an opportunity to cleanse the soul and beef up their stats. Instead, the Raptors’ 104-99 win only offered more fuel that something is amiss, turning up the heat higher on a team, organization and fan base for which good fortune only means one thing: the worst is yet to come.

It wasn’t that they won, it was the way they won. The Nets, a team so far in NBA purgatory that they may never emerge, should have been the listless, disorganized squad. The Raptors made them look like they were fighting for home court advantage instead of their 19th win of the season as they had Toronto down by 16 points midway through the third quarter.

The better team finally emerged, washing away a lacklustre effort with a stellar run after that point that tumbled over into the early moments of the fourth. The Raptors still didn’t do it the easy way. The Nets had the ball down three with a minute left but Patrick Patterson hounded Thadeus Young into a turnover. Kyle Lowry’s floater in the lane pushed the Raptors’ advantage to five and that was enough.

DeMar DeRozan led the Raptors with 25 points while Lowry had 23 and nine assists. Perhaps the pivotal line belonged to Bismack Biyombo, who sparked the Raptors’ second half comeback with 10 rebounds and two blocked shots at critical moments late in the game.

The Raptors have gotten away with their slippage. Their win over Brooklyn improved their post-all-star record to 7-3 — 42-20 on the season — and they are just two games behind the Cleveland Cavaliers for top spot in the Eastern Conference. But sometimes wins can hide blemishes that need to be dealt with.

No wonder Raptors head coach Dwane Casey hasn’t been shy about referencing last year’s biggest sin of all — how this team, with the current core intact, letting their defence slide from poor to bad to non-existent — a year ago. No preacher misses a chance to make a point

“Believe me, that’s been talked about,” said Casey. “I didn’t get off that last potato truck. It’s been talked about, reiterated. These are mature men, they understand the importance of maintaining a sense of discipline on the defensive end.”

But just to make sure, Casey did what he’s typically loathe to do over the course of the regular season as he made not just one but two changes to his lineup, inserting rookie Norman Powell and newcomer Jason Thompson into the first five at the expense of James Johnson (himself a replacement for the long-injured DeMarre Carroll) and Luis Scola, respectively.

Powell’s been tapped to fill the small forward spot in the past, in particular against a lineup like Brooklyn’s which features three smaller perimeter players.

But those concerned about the Raptors’ defensive woes have long been fixated on Scola’s play at power forward. The veteran Argentinean is savvy and tough-minded, but is perceived to give up too much quickness to defend the four spot, particularly when paired with Jonas Valanciunas. Scola has been under fire in some quarters given he appears in all of the lineup combinations used most frequently by the Raptors that struggle defensively — those with a defensive rating of 107 or more — and none that have a rating of less than 100.

The official version is that Scola was just being rested, but given that Thompson looked comfortable in his first start in Toronto — he added nine points and five rebounds in 24 minutes — since being acquired after he was bought out by Golden State, it’s a situation that bears watching.

For all the chatter it was the Raptors defence that finally answered the call when the game turned in the third quarter, but not until Casey began calling very loudly.

“Our guys didn’t play well in the first half. It shouldn’t take me going in at halftime and jumping up and down and challenging them,” he said after the game.

His team responded.

“It was a good one,” DeRozan said of his coach’s halftime performance. “And one we definitely needed. The way we came out in the second half definitely speaks volumes for how he came in and really got on us and we responded like we were supposed to.”

After allowing Brooklyn to own them in the second quarter — the Nets shot 14-of-24 and won the period 35-14 to take a 58-42 lead into the half — the Raptors energized themselves.

Down 16 early in the third quarter Toronto used a lineup of familiar faces — Lowry, DeRozan, Patterson, Biyombo and Cory Joseph — to ignite a 22-2 run that was punctuated by a couple of threes by Terrence Ross, who took over midway for DeRozan.

Notable was that Toronto’s turnaround was defined by defence: the Nets went seven straight possessions without a score to ignite the Raptors’ run and were held to 39 per cent shooting in the fourth quarter.

The Raptors aren’t the only good team to be sinking in some late season quicksand, to have found it difficult to stay on the straight and narrow as the season grows longer, the playoffs still distant.

Golden State Warriors head coach Steve Kerr was lamenting his club’s lackadaisical approach since the all-star break – they’re 8-2, including a loss to the Los Angeles Lakers, perhaps the NBA’s worst team. The Cleveland Cavaliers have LeBron James subtweeting them after they mailed it in against an under-manned Memphis Grizzlies team. The San Antonio Spurs lost.

“It’s one of those things, I don’t know if it’s that time of year, that 40 through 60 [game] number, that malaise, as you’re looking at the whole league,” said Casey. “But we’re definitely as a whole, as a unit, not tied together defensively, not as physical as we need to be defensively.”

Not all the time, anyway. For about 16 minutes in the second half against Brooklyn they were and the effort rescued a game that seemed almost unsalvageable.

That burst of defensive energy and focus — should it prove catching — could ending up saving their basketball souls as they try to avoid sins and temptations at every turn down the stretch.