1
Fork 0
mirror of https://github.com/RYGhub/royalnet.git synced 2024-11-23 19:44:20 +00:00
royalnet/royalpack/commands/rocoinflip.py

29 lines
597 B
Python
Raw Normal View History

2021-05-08 00:00:57 +00:00
import random
import royalnet.engineer as engi
@engi.TeleportingConversation
async def rocoinflip(*, _sentry: engi.Sentry, _msg: engi.Message, teama: str, teamb: str, **__):
"""
Scegli quale delle due squadre inizierà per prima.
"""
flip = random.randrange(0, 2)
if flip == 0:
first = teama
second = teamb
else:
first = teamb
second = teama
text = [
f"❔ Risultati del coin flip:",
f"",
f"🔹 {first}",
f"🔸 {second}",
]
await _msg.reply(text="\n".join(text))
__all__ = ("rocoinflip",)