Git Product home page Git Product logo

not-clash's Introduction

Not Clash

Not Clash is a tool based off the original League of Legends event called "Clash" where teams of 5 players face off against one another in a bracket style tournament to see who is the winner. Thus, "Not Clash" borrows that idea and converts its functionality to fit the purpose of a smaller friend group rather than many teams. 10 players are randomly sorted into 2 teams and battle against one another. The winners gain Elo and the losers lose Elo. Their statistics are saved in a database that utilizes SQL commands executed by the sqlite3 Python3 library. Match data is saved as a pickle object and commands are utilized in Discord to help with the logistics of the game.

Setup

  1. Install Python3 v3.5.3+.
  2. Install discord.py.
  3. Set up Discord Bot and insert credentials into configtemplate.py.
  4. Install pickle if Python3 is less than v3.8.
  5. Rename configtemplate.py to config.py and change variables.

Usage

Starting the Program

  1. Enter directory of main.py.
  2. Execute python3 ./main.py &.

Stopping the Program

  1. Execute ps aux | grep python.
  2. Kill pid located on the left side of the display

Commands

League

Commands for Not Clash tournaments.

league <@player1> <@player2> ... <@player10>

Starts a new game and randomly allocates the pinged players into two teams. Displays the match in Discord.

finish <team number>

Finishes the game and updates statistics of the players. Team number is either 1 or 2, representing the winning team.

cancel

Cancels the current game if there is one.

swap <@player1> <@player2>

Swaps the two players if they are on the same team.

display

Displays the current game if there is one.

register [@player]

Registers the player or the pinged player if provided.

primary <role>

Sets the primary role to be either Fill, Top, Jungle, Mid, Bot, or Support.

secondary <role>

Sets the secondary role to be either Fill, Top, Jungle, Mid, Bot, or Support.

stats [@player]

Displays the player's statistics or the pinged player's statistics if provided.

leaderboard [top n/all]

Displays the top n players or if called with all, displays all players.

Legacy

Legacy commands from the Clash Helper that was the predecessor for the Not Clash bot.

lteam <n teams> <player1> <player2> ... <player10>

Creates n teams and equally distributes players among the teams.

lleague <player1> <player2> ... <player10>

Creates 2 teams and equally distributes players among the teams with their roles.

Examples

League Command

Swap Command

Display & Finish Command

Leaderboard Command

Stats Command 1

Stats Command 2

not-clash's People

Contributors

williamsantosa 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.