|
@@ -1,4 +1,5 @@
|
|
|
import pickle
|
|
|
+import random
|
|
|
|
|
|
from command_system import as_plugin, as_group_singleton, pop_arg
|
|
|
|
|
@@ -35,7 +36,12 @@ def add(args, data):
|
|
|
|
|
|
|
|
|
def pick(args, data):
|
|
|
- pass
|
|
|
+ items = data.get_items()
|
|
|
+ if len(items) == 0:
|
|
|
+ return "You have to add items before I can pick one!"
|
|
|
+ ind = random.randint(0, len(items) - 1)
|
|
|
+ chosen = items[ind]
|
|
|
+ return f"I have selected {ind + 1} - {chosen}! If you want to remove this from the list now, you can use !wlr {ind + 1}"
|
|
|
|
|
|
|
|
|
def remove(args, data):
|