[SOLVED] Lottery System Help

Is there a package for a lottery system for meteor? What would be the best way to create my own lottery system? Should I use the random package? I’m new to programming and meteor in general so any advice would greatly be appreciated.

This is not something that Meteor does specifically, but there is the entire NPM ecosystem to help you. Meteor lets you integrate any NPM package. A good start could be spadille - npm for generating random lottery codes.

The legalese of the whole thing will be yours to deal with, however :slight_smile:


PS. Welcome to the Meteor Forum!

1 Like

Thanks illustreets for the warm welcome, I’ll look more into spadille but the way I wanted to implement my system is users gets token, those tokens will then be used automatically for the lottery system. But heres the thing, I want one person to win each time a lottery is pulled. How can I make sure one person wins?

You’re welcome! I have next to no experience in game programming, but from a quick look at the NPM package, it allows you to generate verifiable (this is important) tokens. Then you must use a truly random process to pick one of the tickets you handed out to your users.

In computing there is no true random generation, but there are ways to use external phenomena to do that. I do not know if the people at random.org have an API that you can use, but it’s worth asking. True random number generation for gambling and other industries is an actual business model.

Perhaps the games section of StackExchange may be of help. Good luck!

1 Like

Thanks again illustreets I really appreciate the advice.