The bill addressing businesses like DraftKings and FanDuel passed the Senate on an 18-16 vote Thursday. It moves to the House.

It says state law doesn’t prohibit offering or participating in fantasy games, or impose fines or criminal penalties.

The bill says games must tell participants about prizes before they start playing. It says skill and knowledge are necessary, and games must be based on accumulated statistics of individuals, including athletes.

It assures games aren’t based on the spread or score of one team, or the individual performance of one player in one event.

Some state attorneys general have asserted that the games are illegal gambling. Lawsuits over legality are ongoing in New York and Illinois, for example.