Ruling by Statute: How Uncertainty and Vote Buying Shape Lawmaking