forked from mttu-developers/konabot
摇骰子
This commit is contained in:
46
konabot/plugins/roll_dice/roll_dice.py
Normal file
46
konabot/plugins/roll_dice/roll_dice.py
Normal file
@ -0,0 +1,46 @@
|
||||
number_arts = {
|
||||
1: ''' _
|
||||
/ |
|
||||
| |
|
||||
| |
|
||||
|_|
|
||||
|
||||
''',
|
||||
2: ''' ____
|
||||
|___ \
|
||||
__) |
|
||||
/ __/
|
||||
|_____|
|
||||
''',
|
||||
3: ''' _____
|
||||
|___ /
|
||||
|_ \
|
||||
___) |
|
||||
|____/
|
||||
''',
|
||||
4: ''' _ _
|
||||
| || |
|
||||
| || |_
|
||||
|__ _|
|
||||
|_|
|
||||
''',
|
||||
5: ''' ____
|
||||
| ___|
|
||||
|___ \
|
||||
___) |
|
||||
|____/
|
||||
''',
|
||||
6: ''' __
|
||||
/ /_
|
||||
| '_ \
|
||||
| (_) |
|
||||
\___/
|
||||
'''
|
||||
}
|
||||
|
||||
def get_random_number(min: int = 1, max: int = 6) -> int:
|
||||
import random
|
||||
return random.randint(min, max)
|
||||
|
||||
async def roll_dice() -> str:
|
||||
return number_arts[get_random_number()]
|
||||
Reference in New Issue
Block a user