From fe2cafe5c96959e653c935abc93e57ff4ea896a1 Mon Sep 17 00:00:00 2001 From: Louis Vogt Date: Sat, 26 Jul 2014 14:19:31 +0200 Subject: [PATCH] Wrong receiver; new plop; no simplejson; still 1 bug --- mentio.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/mentio.py b/mentio.py index c2f985d..f557a5f 100644 --- a/mentio.py +++ b/mentio.py @@ -1,4 +1,4 @@ -import simplejson as json +import json from helpers import * from re import compile as reg_compile from traceback import format_exc as print_traceback @@ -22,9 +22,9 @@ def onChat(event): sender = event.getPlayer() words = event.getMessage().split(" ") recipients = event.getRecipients() - listeners = mentions[sender.getUniqueId()] for recipient in list(recipients): + listeners = mentions[str(recipient.getUniqueId())] rec_words = words[:] # copy for i in range(len(rec_words)): word = rec_words[i] @@ -49,7 +49,7 @@ def onChat(event): pass message = " ".join([sender.getDisplayName(), arrow] + rec_words) msg(recipient, message, usecolor = False) - recipient.playSound(recipient.getLocation(), "mob.chicken.plop", 1, 0) + recipient.playSound(recipient.getLocation(), "liquid.lavapop", 1, 2) except: error("Failed to handle PlayerChatEvent:") error(print_traceback())