A telegram bot like werewolfbot with a game like PUBG
Tony Chyi 09a0b8f8e4 update 3 months ago
.readme update 3 months ago
.vscode 1st 3 months ago
assets union invalid hint 3 months ago
basis log support 3 months ago
bot union invalid hint 3 months ago
config log support 3 months ago
consts update nextgame 3 months ago
controllers feature, with next bug fix 3 months ago
database log support 3 months ago
lang log support 3 months ago
models update 3 months ago
tools remove image build script 3 months ago
utils 勉强完成了,准备测试 3 months ago
.gitignore update .gitignore 3 months ago
CONTRIBUTORS.md 1. more hint 2. fix replay bug 3 months ago
LICENSE almost running 3 months ago
README.md update 3 months ago
build.sh almost running 3 months ago
main.go 勉强完成了,准备测试 3 months ago

README.md

Black Forest bot (aka Dark Forest bot)

A telegram bot like werewolfbot with a game like PUBG

Rules

  1. Every player will get a position (x, y) (x and y are double of players). Every player can shoot at a position every night. Player will be killed when someone shoot at his position.
  2. Every shoot would expose one axis of his position.
  3. Player would convert to a BEAST when all axes of his position is exposed. When two players kill each other, BEAST will live.
  4. Player who abort action at night will convert to BEAST.
  5. Two players can unite each other, only of they know.
  6. Players who join a union would not expose his position.
  7. Player can betray his union at night and kill another one, no position is needed.
  8. Player can set a trap at night, player who betrayed you will be killed
  9. Only one player live, or all DEAD

Requirements

  1. Go >= 1.10.3
  2. redis >= 3.0.0
  3. MySQL >= 5.8 or MariaDB

Build

go get -v git.wetofu.top/tonychee7000/blackForestBot # check the directory name, it must be `blackForestBot`
cd blackForestBot
./build.sh

Configuraion File

config.json

{
    "tgApiToken": "OMITTED",  // You may need one bot to run this.
    "debug": true,
    "updateTimeout": 60,
    "database": "bl:[email protected](127.0.0.1:3306)/blackforest?charset=utf8mb4&parseTime=True",
    "redis": "redis://localhost:6379/1",
    "adminPassword": "OMITTED",  // Change it.
    "threadLimit": 1024
}

Running

You may need to upload some gif for running this game. Just run the bot, and input /admin YOUR_PASSWORD to make admin mode ON. Then just upload gif to the bot with filename in win, lose, start, killed, trapped, beast and finally use /admin without password to make admin mode OFF.

Or you may use official bot

Donation

alipay wechat

PayPal