In just a few short lines, the speaker describes the pull of gambling as a kind of downward spiral. "In and in" suggests going deeper and deeper, while "paying and buying" makes the whole thing sound like a transaction that never stops. The speaker doesn't stand outside the habit; they say "I go," as if carried along by it.
The surprising move comes with the metaphors. Chance is called "a pretty church," which makes luck feel almost sacred, something people worship and put faith in. It's also "pretty," so the appeal is real and a little deceptive. Then chance becomes "an encyclopedia," a huge book of lessons, but one that "cost me much pain." The speaker has learned a lot, though not cheaply.
The mood is rueful and quietly weary. There's no shouting or self-pity, just a dry, honest summing-up. The speaker seems to know the attraction and the price at the same time, and the short, abrupt ending leaves the pain hanging there.