Ejemplo n.º 1
0
def top_list(clan):
    (executor, caller, enactor) = pennmush.call_info()
    global conn
    if not conn:
        conn = db.get_conn()
    cursor = conn.cursor()
    pennmush.notify([enactor],"Not implemented at present.")
Ejemplo n.º 2
0
def log_view(victim):
    (executor, caller, enactor) = pennmush.call_info()
    victim = int(victim.lstrip("#"))
    global conn
    if not conn:
        conn = db.get_conn()
    cursor = conn.cursor()
    cursor.execute("SELECT delta, balance, description, dt FROM honor_log WHERE victim = " + str(victim) + " ORDER BY dt desc LIMIT 20")
    pennmush.notify([enactor], util.titlebar("Honor Log: " + pennmush.api.name("#" + str(victim))))
    pennmush.notify([enactor], " Date/Time       Change  Balance  Description")
    for (delta, balance, description, dt) in cursor.fetchall():
        pennmush.notify([enactor], " " + dt.strftime("%d/%m/%y %H:%m") + "  " + str(delta).rjust(6) + "  " + str(balance).rjust(7) + "  " + str(description)[:44])
    pennmush.notify([enactor], util.footerbar())
Ejemplo n.º 3
0
def colortable():
    from ll import ansistyle
    (executor, caller, enactor) = pennmush.call_info()
    retval = ""
    for i in range(0, 264):
        t = ansistyle.Text(i, str(i))
        retval = retval + " " + t.string()
    pennmush.notify([enactor], retval)
    retval = ""
    for i in range(265, 511):
        t = ansistyle.Text(i, str(i))
        retval = retval + " " + t.string()
    pennmush.notify([enactor], retval)