Such as the repo below:
Feature Introduction
-
The initiator can start a lottery based on a template in a specified category/tag.
-
Lottery posts must specify: lottery name, prizes, number of winners, drawing time, and a brief description.
-
Users participate by replying as required, no button clicking needed.
-
Automatic drawing at the specified time, excluding the initiator and duplicate users.
-
Automatically announce the winners in the topic.
-
Automatically add the tag “Lottery Ended” to the lottery topic.
-
Automatically add the tag “抽奖结束” (Lottery Ended).
-
Winners will be marked as winners in the winning post.
-
A system message will be automatically sent to the winners as notification.
-
After automatic drawing, the main post is automatically locked, preventing editing and replies (0710).
-
When posting, add
【抽奖】...【/抽奖】(using square brackets) tags, and automatically check input content correctness, with front-end beautification (0711 requires cooperation with validation and beautification components). -
New: Support setting a “Minimum Points” threshold for a single lottery (points come from the discourse-gamification plugin). If not set or set to 0, it means no restriction; users below the threshold will be automatically ignored, and a notice will be displayed on the topic page.
Usage Instructions
-
The administrator sets the tags allowed for lotteries (e.g., Lottery Activity).
-
Posting format example:
🎉 Floor-grabbing Activity: 2025 Summer Lottery
Prizes: One pair of Bluetooth headphones
Number of Winners: 2
Drawing Time: 2025-07-10 20:00
Minimum Points: 10
Brief Description: One entry per person, participation only via reply (one sentence)
Welcome to participate, good luck to everyone! Floor-grabbing activity instructions and posting method
Other activity descriptions and introductions.
-
Users only need to reply to participate.
-
The plugin automatically draws the lottery and announces the results.