Workers at a massive new Shell plant in Pennsylvania had to attend a speech by President Donald Trump there earlier this week to be paid — and were ordered not to protest, reported the Pittsburgh Post-Gazette.

Attendance was not mandatory for thousands of union workers at Royal Dutch Shell’s petrochemical plant north of Pittsburgh, but they had to forfeit pay for the day if they skipped, according to attendance and comportment information obtained by the newspaper.

“Your attendance is not mandatory,” one manager told workers, summarizing a memo that Shell sent to union leaders, the Post-Gazette reported, but only those who showed up at 7 a.m., scanned their ID cards and prepared to stand for hours through lunch would be paid.

“No scan, no pay,” workers were warned.

In addition, workers who decided not to listen to the president’s speech reportedly would not be paid overtime rates routinely built in for extra time during the week.

The newspaper said that they were also told: “No yelling, shouting, protesting or anything viewed as resistance will be tolerated at the event. An underlying theme of the event is to promote good will from the unions. Your building trades leaders and jobs stewards have agreed to this.”

“This is just what Shell wanted to do and we went along with it,” Ken Broadbent, business manager for Steamfitters Local 449, told the newspaper. He said he wouldn’t “bad rap” the situation.

“We’re glad to have the jobs. We’re glad to have the project built,” he said. “The president is the president whether we like him or dislike him. We respect him for the title.”

The new $6 billion plant, which has been under construction since 2017, is an “ethane cracker” plant. It will “crack” ethane, a natural gas liquid found in some natural gas deposits, and turn it into plastic pellets to be used in various plastic products. The plant will produce over 1 million tons of plastic. Environmentalists and community groups complain that the operation will harm the region’s air quality and will increase carbon emissions and plastic pollution.

Trump took full credit for the plant in his speech, even though it was initially approved in June 2016, during the Obama administration, CNN reported.

“It was the Trump administration that made it possible,“ Trump told workers. “No one else. Without us, you would never have been able to do this.”

He also told workers: “I’m going to speak to some of your union leaders to say, ’I hope you’re going to support Trump. If they don’t, vote them the hell out of office because they’re not doing their job.”

Trump was supposed to stick to addressing energy in his speech, but it morphed into a full-blown, free-range campaign speech.