Paste #51732: racist tag bot

Date: 2019/01/24 11:51:28 UTC-08:00
Type: Denizen Script

View Raw Paste Download This Paste
Copy Link


# ███ [ DiscordBot | Discord Control ] ███
Discord_Bots:
    type: world
    debug: false
    script_paths:
# ███ [ Server Startup ] ███
        on server start:
        - debug debug "# ███ [ Discord Connections start in: 15s ] ███"
        - wait 15s
        - yaml load:data/behrbot.yml id:behrbot_temp
        - discord id:behrbot connect code:<yaml[behrbot_temp].read[bots.discord.BehrBotToken]>
        - discord id:generalbot connect code:<yaml[behrbot_temp].read[bots.discord.GeneralBotToken]>
        - yaml unload id:behrbot_temp
# ███ [ Ingame Chat Relay ] ███
        on player chats:
          - if <context.message.starts_with[!P]> && <player.is_op>:
            - determine passively cancelled
            - narrate format:bbf "Parsing <&e><&o><context.message.after[!p<&sp>]><&4>:<&nl> <&6><parse:<context.message>>"
            - queue clear
          ##################################################
          #ingame auto-response template [ Chat >> Discord ] [ 1 ]
          #- if <context.message.to_lowercase.contains[hi<&sp>behr]>:
          #  - wait 6s
          #  - narrate targets:<server.list_online_players> format:bbf "Hi"
          #  - discord id:behrbot channel:<server.flag[updates]> message "**Co-Owner** BehrBot: Hi"
          #########################################################################################
          - discord id:behrbot channel:<server.flag[updates]> message "**<player.groups.get[1]>** <player.name>: <context.message>"
# ███ [ Discord Chat Relay ] ███
        on discord message received by behrbot:
        - narrate "<context.channel>"
        - if <context.channel.contains.[518511535539224618]>:
          - queue clear