Code Monkey home page Code Monkey logo

cs2-discord-chat's Introduction

Infra's Simple Discord Chat Relay for CounterStrikeSharp

Simple CounterStrikeSharp plugin that logs chats to Discord via webhooks. Just a CS2 equivalent for my previous SourceMod relay: https://github.com/1zc/SM-Discord-Chat

Webhook Styles:

The plugin features two webhook styles, one super simple style suited for logging and the other looking slighly prettier. Styles can be configured in addons/counterstrikesharp/configs/DiscordChat/DiscordChat.json using the DiscordChatStyle variable.

Pretty Style ("DiscordChatStyle": 1):

Pretty Style

Simple Style ("DiscordChatStyle": 0):

Simple Style

If you are looking to use this plugin purely to log chats, I recommend using the simple style. While it may not be as pretty as the other option, it makes searching SteamIDs in Discord possible.

How to Install:

You need CounterStrikeSharp installed and running on your server.

How to Configure:

All configuration is done in game/csgo/addons/counterstrikesharp/configs/DiscordChat/DiscordChat.json.

Setting up DiscordChatWebhook:

The plugin needs a WebHook URL from Discord to be able to send chat messages to. Follow the steps below if you are unsure how this can be done:

  • Step 1: Edit a channel > enter the Webhooks section inside the Integrations sub-menu > Make a new webhook.
  • Step 2: Customize your new webhook! I recommend naming it according to the server you're going to use the webhook for, and adding an avatar related to your servers. (Making separate webhooks, accordingly named, for each server you host is a great way to identify what server a chat message was sent in!)
  • Step 3: Copy your webhook URL, go back to DiscordChat.json, and configure DiscordChatWebhook to your webhook URL.

Webhook Setup

Setting up DiscordChatSteamKey:

The plugin uses a SteamAPI key to access the Steam Web API to get player's profile pictures. This is an optional ConVar, disabling it will default the plugin to the simple webhook style since it can't pull profile pictures.

You can get your SteamAPI key here: https://steamcommunity.com/dev/apikey (DO NOT SHARE THIS KEY WITH ANYONE.)

cs2-discord-chat's People

Contributors

1zc avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

dollannn

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.