A 23-year-old Canadian man who is accused of murdering four people allegedly sent messages to his online gaming buddies before the massacre — saying he “slaughtered” his entire family “so that they didn’t suffer knowing how much of a pathetic subhuman” he was.

“Its all very selfish,” wrote Menhaz Zaman, according to CBC News.

“I did this [because] I dont want my parents to feel the shame of having a son like me,” he reportedly told users on Discord, an online gaming community.

“I choose to kill them instead out of my own cowardess [sic]. I know it might sound confusing but whats done is done and what had been planned has been concluded.”

Noting how he “will most likely spend life in jail,” Zaman allegedly added: “i deserve punishment.”

CBC and other local outlets have obtained screenshots of the alleged messages, which were posted by a user named “Menhaz.” Sources told the outlets that Zaman was behind the account.

In some of his postings, the young man reportedly describes how he had been lying to his parents about going to college.

“For three years Ive been telling my parents i go to uni, when actually I was just hanging out at the mall four days a week,” he allegedly told users.

Zaman claimed he went to school for just one year, and suffered from depression. He eventually “became an atheist, and ultimately created this plan,” according to the messages, which were sent about 12 hours before cops were called to the Markham, Ontario, home where the killings occurred.

Discord users reportedly alerted police about the posts.

Authorities have yet to identify Zaman’s alleged victims, but did describe them as a man and three women. They charged him with four counts of first-degree murder for their deaths.

Residents told the Toronto Star that Zaman lived in Markham with his parents, sister and grandmother.

“He was such a nice, quiet, calm guy,” said former tenant Ammara Riaz. “I saw that guy all the time helping his parents … I’ve always heard good stuff about him.”

Zaman was described by users as a longtime online gamer who regularly posted in the “Perfect World Void” forum on Discord. He reportedly claimed in his messages that his alleged massacre had “nothing to do with Perfect World” or anyone in the gaming community.

“We thank the anonymous player who had the cleverness to trace his address, and the braveness to immediately report it to the local cops,” a user wrote online. “Thanks to this act, it is highly possible that some lives have been saved.”