def process(sender, type, args, client): room = sender.getStripped() comSend = sender.getResource() if len(args) == 0 and xmppUtils.isAdmin(room, comSend): xmppUtils.sendMessage(sender, 'Available commands: help, say, voice, devoice, date, uptime, omegle, quote, act, slap, stab, gift, shoot, scold, google, mode, kick, jid, calc.', type='chat') elif len(args) == 0 and xmppUtils.isMember(room, comSend): xmppUtils.sendMessage(sender, 'Available commands: help, say, voice, date, uptime, omegle, quote, act, slap, stab, gift, shoot, google, calc.', type='chat') elif len(args) == 0 and not xmppUtils.isMember(room, comSend): xmppUtils.sendMessage(sender, 'Available commands: help, date, quote.', type='chat')
def process(sender, type, args, client): room = sender.getStripped() me = sender.getResource() if len(args) == 0 and xmppUtils.isOwner(room, me): xmppUtils.sendMessage(room, 'This is Skullz checking this...', type='groupchat') elif len(args) == 0 and xmppUtils.isMember(room, me): xmppUtils.sendMessage(room, 'This is still probably Skullz checking this.', type='groupchat')
def checkmode(who, room): if len(who) < 1: return -1 if xmppUtils.isAdmin(room, who): xmppUtils.sendMessage(room, 'Administrator', type='groupchat') elif xmppUtils.isModerator(room, who): xmppUtils.sendMessage(room, 'Moderator', type='groupchat') elif xmppUtils.isMember(room, who): xmppUtils.sendMessage(room, 'Member', type='groupchat') return 0