yobot插件,Steam雷达,可自动播报玩家的Steam游戏状态和DOTA2图文战报

Overview

Steam_watcher

这是 prcbot/yobot 的自定义插件,可自动播报玩家的Steam游戏状态和DOTA2图文战报

都有些什么功能?

本插件可以在用户绑定后自动推送Steam游戏状态的更新和 Dota2 图文战报,以及提供一些手动查询功能

指令列表

atbot 表示需要@BOT

atsb 表示@某人

xxx yyy 等表示自定义参数

[] 方括号表示参数可以省略

Steam

负责Steam相关的功能

指令 说明
Steam帮助 查看帮助
订阅Steam 在本群开启Steam内容的推送
取消订阅Steam 在本群关闭Steam内容的推送
绑定Steam 好友代码 绑定Steam账号,一人一号
可直接覆盖绑定
解除绑定Steam 解除绑定Steam账号
xxx在干嘛 查询xxx的Steam游戏状态
查询xxx的天梯段位
查询xxx的常用英雄
查询xxx的英雄池

Whois

负责区分各个群的各位群友

指令0 说明
atbot 我是xxx 为自己增加一个别名xxx1
atbot 请叫我xxx 为自己增加一个别名xxx并设为默认2
atbot 我不是xxx 删除自己的别名xxx
atbot yyyxxx yyy增加一个别名xxx3
xxx是谁? 查询xxx的别名
xxx是不是yyy 比对xxxyyy的默认别名
查询群友 查询群内所有拥有别名的群友的默认别名

0 简单地说,涉及修改的指令需要 atbot,而查询的指令不需要

1, 2 一个人可以拥有多个别名,其中第一个是默认别名

3 yyy可以是atsb

使用方法

事前准备

Steam APIKEY

获取 Steam APIKEY

Steam APIKEY 的权限与其所属账号挂钩,要看到被观察者的游戏状态,需要满足以下两个条件之一

  • 被观察者的 Steam 隐私设置中游戏详情设置为 公开 ,且好友与聊天状态设置为在线
  • APIKEY 账号与被观察者为好友,被观察者的 Steam 隐私设置中游戏详情设置为 仅限好友 ,且好友与聊天状态设置为在线

条件不满足时,从 API 获取到的被观察者的游戏状态为空,即没在玩游戏

Linux

0. yobot 源码版

本插件基于 yobot 运行,所以首先需要 部署 yobot 源码版go-cqhttp,并保持两者同时运行

1. 下载本项目

# 在 ybplugins 目录下克隆本项目
cd yobot/src/client/ybplugins
git clone https://github.com/SonodaHanami/Steam_watcher

2. 安装依赖

cd Steam_watcher
pip3 install -r requirements.txt --user
# 国内可加上参数 -i https://pypi.tuna.tsinghua.edu.cn/simple

3. 导入

将 Steam_watcher 导入 yobot ,请参考 这个例子 修改 yobot.py

4. 填写配置文件

启动 yobot ,第一次启动 Steam_watcher 后会在 Steam_watcher 文件夹下自动生成 config.json,修改它

{
    "ADMIN": "123456789",   // 填写管理员的QQ号
    "BOT": "987654321",     // 填写BOT的QQ号
    "STEAM_APIKEY": ""      // 填写 Steam APIKEY
}

5. 应该可以了

重新启动 yobot ,开始使用

Windows

0. yobot 源码版

本插件基于 yobot 运行,所以首先需要 部署 yobot 源码版go-cqhttp,并保持两者同时运行

1. 下载本项目

推荐使用 Github Desktopyobot/src/client/ybplugins 目录下克隆本项目,后续更新可直接pull

下载源码(不推荐) 下载 https://github.com/SonodaHanami/Steam_watcher/archive/refs/heads/master.zip ,将整个 Steam_watcher 文件夹解压到 yobot/src/client/ybplugins 目录下

完成本步骤后,项目目录结构应该如下所示(仅列出本文档相关的关键文件/文件夹示意)

yobot
  └─src
      └─client
          ├─yobot.py
          └─ybplugins
              └─Steam_watcher
                  └─steam.py

2. 安装依赖

进入 Steam_watcher 文件夹,在空白处Shift+右键,点击“在此处打开 PowerShell 窗口”(或者命令提示符)

pip3 install -r requirements.txt --user
# 国内可加上参数 -i https://pypi.tuna.tsinghua.edu.cn/simple

3. 导入

将 Steam_watcher 导入 yobot ,请参考 这个例子 修改 yobot.py

4. 填写配置文件

启动 yobot ,第一次启动 Steam_watcher 后会在 Steam_watcher 文件夹下自动生成 config.json,修改它

{
    "ADMIN": "123456789",   // 填写管理员的QQ号
    "BOT": "987654321",     // 填写BOT的QQ号
    "STEAM_APIKEY": ""      // 填写 Steam APIKEY
}

5. 应该可以了

重新启动 yobot ,开始使用

开始使用

1. 订阅Steam

在群内发送“订阅Steam”,开启Steam内容的推送

2. 成为群友

在群内发送“atbot 我是xxx”,为自己添加一个别名

为什么需要这样做? 这样做的目的是隔离。因为bot可以加入多个群,同一个人也可以同时在不同的的群里,但是同一个人的推送不一定要发到所有群
bot仅向每个群里发送绑定了Steam的群友的推送。
举个例子:
有A和B两个群,两个群里都有枫哥、甲哥、翔哥和bot,枫哥、甲哥和翔哥各自都绑定了Steam
A群的群友有枫哥和甲哥
B群的群友有枫哥和翔哥
则bot会向A群发送枫哥和甲哥的推送,向B群发送枫哥和翔哥的推送
或者说,枫哥的推送会被bot发送到A和B两个群,甲哥的推送只会被bot发送到A群,翔哥的推送只会被bot发送到B群

3. 绑定Steam

在群内发送“绑定Steam 好友代码”,绑定自己的Steam号

4. 试一下

在群内发送“xxx是谁?”,bot将回复xxx的别名

在群内发送“查询群友”,bot将回复该群的群友列表

在群内发送“xxx在干嘛”,bot将回复xxx的Steam游戏状态

Owner
羽波
羽波
LoL API is a Python application made to serve League of Legends data.

LoL API is a Python application made to serve League of Legends data.

Caique Cunha Pereira 1 Nov 06, 2021
Kakatua discord music bot

Donate Ayo donasi! Lokal Internasional Ucapan Terima Kasih Tentu saja, donatur Bunga dan talent-talent h!mawari. Semoga rezeki teman-teman semakin lan

1 Oct 30, 2021
Charged's cogs for Red!

Light-Cogs Charged's cogs for Red! Read below for more information. Features and Cogs TechInfo Lots of commands helping you and your devices! Extended

Charged 2 Jan 07, 2022
Tinkoff social pulse api wrapper

Tinkoff social pulse api wrapper

Semenov Artur 9 Dec 20, 2022
Collect links to profiles by username through search engines

Marple Summary Collect links to profiles by username through search engines (currently Google and DuckDuckGo). Quick Start ./marple.py soxoj Results:

125 Dec 19, 2022
Anti-corruption-bot - Anti corruption bot with python

anti-corruption-bot Test API (running via Flask) is currently hosted at https://

Richard Bankole 2 Feb 16, 2022
Report-snapchat - Report Snapchat acc with python

report-snapchat Report Snapchat acc Report users on Snapchat about the tool : 4

17 Dec 01, 2022
Bot Auto Chess.com

Bot Auto Chess.com Is a suggestion for chess moves on the chess.com platform. The available features are: chess suggestions and moves automatically. i

Tn. Ninja 34 Jan 01, 2023
Anti Spam/NSFW Telegram Bot Written In Python With Pyrogram.

Anti Spam/NSFW Telegram Bot Written In Python With Pyrogram.

Wahyusaputra 2 Dec 29, 2021
A minimalistic library designed to provide native access to YNAB data from Python

pYNAB A minimalistic library designed to provide native access to YNAB data from Python. Install The simplest way is to install the latest version fro

Ivan Smirnov 92 Apr 06, 2022
Bot per la chat live del corso di sistemi operativi UniBO

cravattaBot TL;DR: Ho fatto un bot telegram per la chat del corso di sistemi. Indice Installazione e prerequisiti Prerequisiti Installazione Setup Con

Alessandro Frau 3 May 21, 2022
Nflmetrics - Johns Hopkins Spring 2022 Sports Analytics research project about NFL Draft Metrics

nflmetrics GitHub repo for Johns Hopkins Spring 2022 Sports Analytics research p

Anish Kulkarni 4 Feb 24, 2022
Aria/qBittorrent Telegram mirror/leech bot

This is a Telegram Bot written in Python for mirroring files on the Internet to your Google Drive or Telegram. Based on python-aria-mirror-bot Feature

28 Dec 25, 2022
Automatically pulls specified repository whenever a specified file is pushed. Great for working collaboratively when you need to run something locally.

autopull Simple python tool that allows you to automatically pull from a github repository whenever a file with a specified name is uploaded installat

carreb 0 Sep 27, 2022
A telegram bot help you to get stylish fonts and text

Stylish Font Bot 🐿 This is a telegram bot help you to get stylish fonts and text. Config Vars 🤖 API_HASH: Get this value from my.telegram.org. API_K

MSTL updates 1 Nov 08, 2021
A powerful, cool and well-made userbot for your Telegram profile with promising extension capabilities.

Telecharm userbot A powerful, fast and simple Telegram userbot written in Python 3 and based on Pyrogram 1.X. Currently in active WIP state, so feel f

Daniil Kovalenko 16 Dec 01, 2022
A GitHub Follower Bot that is a WIP.

GitHub Follower Bot (WIP) Work In Progress This bot is a WIP. There are still many features I plan to add and code I need to improve (I'm still fairly

Christian Deacon 71 Dec 29, 2022
Huan Xu 1.6k Jan 04, 2023
Official Python client for the MonkeyLearn API. Build and consume machine learning models for language processing from your Python apps.

MonkeyLearn API for Python Official Python client for the MonkeyLearn API. Build and run machine learning models for language processing from your Pyt

MonkeyLearn 157 Nov 22, 2022
This is a okay that is okay that means none is okay

Owner: Masterolic 🇮🇳 CatUB A Powerful, Smart And Simple Userbot In Telethon. Credits This is A Remix Bot Of Many UserBot. DARKCOBRA FridayUserBot Ja

Masterolic 1 Nov 28, 2021