Reduce chance of receiving system EPF invite

Potential in future for this to be a config option
This commit is contained in:
Ben 2020-01-02 23:16:03 +00:00
parent b507ae13d4
commit a9836f5f2b

View File

@ -26,7 +26,7 @@ async def get_com_messages(p):
@handlers.handler(XTPacket('l', 'mst'), before=handle_start_mail_engine) @handlers.handler(XTPacket('l', 'mst'), before=handle_start_mail_engine)
async def handle_send_job_mail(p): async def handle_send_job_mail(p):
postcards = [] postcards = []
if not p.agent_status and random.random() < 0.4: if not p.agent_status and random.random() < 0.1:
epf_invited = await PenguinPostcard.query.where( epf_invited = await PenguinPostcard.query.where(
(PenguinPostcard.penguin_id == p.id) & ((PenguinPostcard.postcard_id == 112) (PenguinPostcard.penguin_id == p.id) & ((PenguinPostcard.postcard_id == 112)
| (PenguinPostcard.postcard_id == 47))).gino.scalar() | (PenguinPostcard.postcard_id == 47))).gino.scalar()