A lottery draw just starts with some base jackpot (funded somehow) and adds a fraction of each ticket purchase price to that jackpot. If any ticket matches all the numbers, they get a payout, usually a large percentage of the jackpot. Partial matches may get smaller fixed prizes. If nobody matches all numbers, the jackpot is usually rolled over into the next drawing.

A raffle ticket system handles the jackpot the same way, but there is always a guarenteed winner. In a raffle, you pay for any number of tickets, and one of those numbers is drawn. That person wins (most of) the jackpot. You may also draw for runner up prizes.

Since the mechanics are pretty similar, you might want to support both.

good points, was trying to make sure I covered most the bases on the lotterys, lol while allowing it to be simple to use overall. yea the raffle idea is simple to add. id likely just do a bool raffle, if thats true when it draws have it draw a bought ticket lol. have considered scratch offs also haha. I even joked to someone I might have to add in the typical gambling help line info lol.

So, I'm picturing various NPC's wandering into town to buy lottery tickets. An orc buys a ticket and wins. After collecting his winnings and wandering back out into the forest, a WANTED poster suddenly goes up with his picture and a bounty. *grin*

Also there is no way for players to see the winning numbers and what their ticket numbers are if they use quickpick. Also are quick picks suppose to save like this, The winner Hokai are actually the tickets I just bought

that bug must come from your change of !has_gold to ch->gold < lottery->price

Also there is no way for players to see the winning numbers and what their ticket numbers are if they use quickpick. Also are quick picks suppose to save like this, The winner Hokai are actually the tickets I just bought

Use to have that in but then since the code does all the handling of if they win or not is it needed?

Also the Jprecent doesn't actually work. I have mine set at 75 and it still increase the jackpot by 100% of the ticket cost.

Ok, I'll take a look at this in a few.

Well if you would be so find to show me where I would add the message and what I would do for it to display a certain lotteries timer on who I would appreciate it.

My advise would be to do a next lottery display counter on who (just cycle through the lotterys looking for the next one that will draw, and display what lottery that is and when it will draw (or a countdown till it draws). For the message on when it is drawn I would suggest in lottery_update when it does the drawing. if you want it to announce the winners go with handle_winnings