mirror of
https://github.com/inexcode/ixizi
synced 2024-11-27 08:51:27 +00:00
Топпинги
This commit is contained in:
parent
c5c2ffa5ff
commit
dd86c8ce5c
|
@ -74,12 +74,31 @@ class Teas(Enum):
|
||||||
self.id = id
|
self.id = id
|
||||||
self.title = title
|
self.title = title
|
||||||
|
|
||||||
|
class Toppings(Enum):
|
||||||
|
topping1 = (1, "Шоколадный топпинг")
|
||||||
|
topping2 = (2, "Топпинг солёная карамель")
|
||||||
|
topping3 = (3, "Ореховый топпинг")
|
||||||
|
topping4 = (4, "Топпинг ягодное печенье")
|
||||||
|
topping5 = (5, "Топпинг бельгийская вафля")
|
||||||
|
topping6 = (6, "Карамельный топпинг")
|
||||||
|
topping7 = (7, "Маршмеллоу")
|
||||||
|
topping8 = (8, "")
|
||||||
|
topping9 = (9, "")
|
||||||
|
|
||||||
|
def __init__(self, id, title):
|
||||||
|
self.id = id
|
||||||
|
self.title = title
|
||||||
|
|
||||||
|
|
||||||
class CoffeePlugin(Plugin):
|
class CoffeePlugin(Plugin):
|
||||||
@Plugin.command('coffee', '[param:str]')
|
@Plugin.command('coffee', '[param:str]')
|
||||||
def on_coffee(self, event, param=''):
|
def on_coffee(self, event, param=''):
|
||||||
try:
|
try:
|
||||||
result = ""
|
result = ""
|
||||||
|
if param.lower() == 'topping':
|
||||||
|
result1, expl1 = rolldice.roll_dice('1d7')
|
||||||
|
result += list(Toppings)[result1 - 1].title
|
||||||
|
else:
|
||||||
if param.lower() == 'classic':
|
if param.lower() == 'classic':
|
||||||
result1, expl1 = rolldice.roll_dice('1d12')
|
result1, expl1 = rolldice.roll_dice('1d12')
|
||||||
elif param.lower() == 'raf':
|
elif param.lower() == 'raf':
|
||||||
|
@ -88,10 +107,10 @@ class CoffeePlugin(Plugin):
|
||||||
result1, expl1 = rolldice.roll_dice('1d23')
|
result1, expl1 = rolldice.roll_dice('1d23')
|
||||||
result += list(Drinks)[result1-1].title
|
result += list(Drinks)[result1-1].title
|
||||||
if result1 == 5:
|
if result1 == 5:
|
||||||
result2, expl2 = rolldice.roll_dice('1d18')
|
result2, expl2 = rolldice.roll_dice('1d22')
|
||||||
if result2 > 16:
|
if result2 > 19:
|
||||||
result2, expl2 = rolldice.roll_dice('1d15')
|
result2, expl2 = rolldice.roll_dice('1d19')
|
||||||
result21, expl21 = rolldice.roll_dice('1d15')
|
result21, expl21 = rolldice.roll_dice('1d19')
|
||||||
result += "\n**Сиропы**: {} и {}".format(list(Syrops)[result2 - 1].title, list(Syrops)[result21 - 1].title)
|
result += "\n**Сиропы**: {} и {}".format(list(Syrops)[result2 - 1].title, list(Syrops)[result21 - 1].title)
|
||||||
else:
|
else:
|
||||||
result += "\n**Сироп**: {}".format(list(Syrops)[result2 - 1].title)
|
result += "\n**Сироп**: {}".format(list(Syrops)[result2 - 1].title)
|
||||||
|
|
Loading…
Reference in a new issue