Giter VIP home page Giter VIP logo

bilibilihelper's Introduction

BilibiliHelper

B 站直播实用脚本

功能

  • 每日签到
  • 发送心跳包领经验
  • 自动领限时礼物
  • 自动领宝箱(瓜子)
  • 自动清理(投喂)过期礼物

TODO

  • 抽小电视

安装

  1. 下载 index.php, Bilibili.php 两个文件,并放置在同一个目录下
  2. 修改 index.php, 替换 cookie 为 B 站直播间的 cookie
  3. 键入命令 php index.php, 试运行(可选)
  4. crontab 中设置 3 0 * * * php [path]/index.php > [path]/log.txt

注意事项

  1. 虽然脚本为 PHP,但由于需要长时间运行,因此不能通过访问网页来使用
  2. 需要额外安装 php-gd、php-curl 组件

FAQ

Q: 如何同时挂多个帐号? A: 可以复制 index.phpindex1.php, 同样修改 cookie 后在 crontab 添加记录

Q: 为什么会有 PHP Parse error: syntax error, unexpected '[' 报错? A: 这是因为 PHP 低版本不支持数组中括号写法,建议升级到 PHP5.6+,脚本现已兼容。

Q: 自动清理(投喂)过期礼物给谁? A: 默认投喂给我的直播间,如果需要的话,可以在 index.php 添加两行修改

$api->roomid='3746256'; // 主播房间号
$api->roomuid='14739884'; // 主播 UID

Q: 如何正确获取 cookie? A: 打开 http://live.bilibili.com/ ,登录后刷新一次,按 F12 在网络中类似 live_h5_player?optype= 的数据包中提取。

License

BilibiliHelper is under the MIT license.

bilibilihelper's People

Contributors

metowolf avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.