The state Senate passed a sweeping gambling expansion bill Wednesday that's projected to generate between $109 million and $147 million in new revenue amid a growing deficit.

Fantasy contests, online gaming and tablets at airports are a few of the key components of House Bill 271, which was amended by the Senate on its way back to the House. Reaching an agreement on these measures has proven elusive in the past.

HB 271 also fixes the so-called "local share" payments that casinos pay to their host communities. Last year, the state Supreme Court ruled that the current method of calculating payments violated a constitutional provision barring unequal tax rates.

The Legislature is running up against a May 26 deadline, which was the result of a previous extension granted after it adjourned without resolving the issue last year. Without a fix, counties and municipalities risk losing more than $140 million.

"We cannot delay this effort any longer," said Sen. Camera Bartolotta, R-Washington County, prior to voting for the bill.

Instead of the more complex "local share" calculation, the bill charges most of the state's casinos a flat $10 million annual slot machine operation fee that will be set aside to fund local governments.

Under the bill's fantasy sports provision, players must be at least 18 years old to play and operators cannot host contests based on collegiate or high school sports. The use of computer scripts to manage bets is prohibited and operators must maintain a self-exclusion list for compulsive gamblers. Operators will pay the state 12 percent of adjusted revenues.

Online gaming, which comes with an age limit of 21, is split between peer-to-peer games, such as poker, with a 16 percent tax and non-peer-to-peer games, such as slots and banked table games, with a 54 percent tax.

Pennsylvania's six international airports, including Harrisburg, and two regional airports with at least 50,000 passengers each year will be able to install interactive computer gaming devices. The daily gross revenues from those games will be taxed at 34 percent.

The Department of Revenue will also be authorized to provide online sales of its existing Pennsylvania Lottery games, as well as instant lottery games, online games where the result is immediately known.

Senate Minority Leader Jay Costa, D-Allegheny, said provisions are particularly important in light of the state's current budget woes and in order to remain competitive.

"It's imperative we do what we can," he said.

The Senate Appropriations Committee estimated that the amended bill would generate between $109 million and $147 million, a nod to the unpredictability of how such changes play out in the real world.

In terms of General Fund revenue, online gaming is expected to bring in between roughly $100 and $135 million. The Lottery changes are expected to bring in up to $19 million. Airport gaming could bring in between $5 million and $12 million. Fantasy contests could bring up to $2 million.

If the amended bill passes the House and signed into law, it would take effect within 60 days.