A security officer outside Maryland Live, the state’s largest casino. (Mark Gail/The Washington Post.)

A bill that will create penalties for underage gamblers who are caught inside any of Maryland’s casinos is close to becoming law.

The Maryland House passed its version of the legislation unanimously, without discussion or debate, on Wednesday — two weeks after a similar bill was unanimously approved by the Maryland SenateOne of the two chambers will have to pass the other one’s bill before it reaches Gov. Martin O’Malley’s desk.

Currently, the state’s policy for punishing underage violators is that it doesn’t. People younger than 21 who find their way into any of the state’s four casinos are simply sent home.

There were 46 underage violations statewide in 2013 and 30 in 2012, according to casino regulators. (Previously, regulators reported 47 violations in 2013, but the total has been revised.)

Multiple states, including New Jersey and Pennsylvania, have statutes in place to penalize underage casino gamblers. Casino operators and state regulators covet similar legislation in Maryland.

Last month, the Maryland Lottery and Gaming Control Agency finalized consent agreements with three casinos, which were penalized for underage violations. Under the agreements, Maryland Live will pay $1,000 for a New Year’s Eve incident; Hollywood Casino in Perry­ville will pay $5,000 for a ­mid-December incident; and the Casino at Ocean Downs will pay $10,000 for two incidents, in July and September. Last year, Maryland Live — the state’s largest casino — paid a $20,000 penalty, and Hollywood paid $10,000.

The casino operators have lobbied over the course of several sessions for legislation to hold underage gamblers accountable; but the bills stalled in the General Assembly in each of the two previous years.

Under the bill approved by the Senate and the House, an adult under the age of 21 would be subject to a fine of up to $100 the first time he or she gets caught in one of Maryland’s ­casinos. The fine would rise to a maximum of $500 for a second offense. A third violation would carry a maximum fine of $1,000 along with mandatory participation in a gambling addiction treatment program. Someone under 18 would be sent to juvenile court.