Skip to content

Discord Bot for League of Legends live match tracker

License

Notifications You must be signed in to change notification settings

devwithpug/SABot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SABot

Dicord Bot for League of Legends match auto tracker

SABot

Features:

  1. Search Summoners statistics in League of Legends.
  2. Auto-notifications provide when summoner starts a match, and provide information of participations.

Commands:

*General commands
    !help
    !commands

*LOL Search-informations
    !l match 'SummonerName' // live match info

*LOL live-match-tracker
    !l setup
    !l add 'SummonerName'
    !l remove 'SummonerName'
    !l list
    !l start    // start live-match-tracker
    !l stop     // stop live-match-tracker

How to set up your own bot:

You need to install python packages with pip:

  • requirements.txt
discord.py==1.7.3
pillow==8.0.1
pymongo==3.12.0
dnspython==1.16.0
pandas==1.3.0
PyYAML==5.4.1
requests==2.25.1
  • Install via pip
pip install -r requirements.txt

And, you need to modify config/config.yml:

credentials:
  bot_token_key: ODEyXXXXXXXXXXXXXXXXXXXX.XXXXXX.XXXXXXXXXXXXXXXXXXXXXXXXXXX
  riot_api_key: RGAPI-XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX
  mongodb_cluster: mongodb+srv://XXXXX:XXXXXX@XXXXXXXX.XXXXX.XXXXXXX.XXX/XXXXXXXX?XXXXXXXXXXX=XXXX&X=XXXXXXXX
font: # if empty, OS default fonts will be selected. (DejaVuSans.ttf, arial.ttf, AppleSDGothicNeo.ttc)
  name: # your_truetype_font.ttf or ttc

Finally,

Run src/SABot.py and type !l setup to your Discord server.

How to localization:

You can modify the file config/locale.yml to make changes easily.

For information such as game modes and maps, check the link below provided by CDragon and modify queues and maps.

(https://raw.communitydragon.org/latest/plugins/rcp-be-lol-game-data/)

locale: {
  na1: {
    queues: https://raw.communitydragon.org/latest/plugins/rcp-be-lol-game-data/global/default/v1/queues.json,
    maps: https://raw.communitydragon.org/latest/plugins/rcp-be-lol-game-data/global/default/v1/maps.json,

    tracker_failed: Couldn't start Live-game tracker. Invaild Riot API key.,
    tracker_started: Live-game tracker was started.,
    tracker_stopped: Live-game tracker was stopped.,
    tracker_started_already: Live-game tracker is already working.,
    tracker_stopped_already: Live-game tracker was already stopped.,
    region: Region,
    tracker_list: Live-game tracker Summoner List,
    match_found: New match has been found!,
    loading: Loading data...,

    blue_team: Blue Team,
    red_team: Red Team,
    name: Name,
    tier: Tier,
    ratio: Ratio,
    wins:  Wins,
    losses: Losses,

    invalid_summoner_name: This summoner is not registered. Please check spelling.,
    exists_summoner_name: This summoner was already added in your channel.,
    error: Error occured!,
    db_error: Database Error Occurred.,
    success_added: Summoner have successfully registered.,
    success_removed: Summoner have successfully removed.,
    summoner_not_in_list: Summoner not listed. Enter `!l list` to confirm.,
  },

API Reference:

About

Discord Bot for League of Legends live match tracker

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages