Raised This Month: $51 Target: $400
 12% 

[CSGO] Command to trigger Discord link in chat


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
DabberDoug
Member
Join Date: Feb 2016
Location: USA
Old 12-23-2018 , 06:52   [CSGO] Command to trigger Discord link in chat
Reply With Quote #1

Simple Plugin,

Need it to post a discord link in the chat, I have found similar but no way to configure it to write my own discord link, if you can make it possible i can also ad !website !group and !discord I would appreciate it

Last edited by DabberDoug; 12-23-2018 at 07:05.
DabberDoug is offline
iskenderkebab33
Senior Member
Join Date: Jun 2018
Old 12-23-2018 , 08:56   Re: [CSGO] Command to trigger Discord link in chat
Reply With Quote #2

https://forums.alliedmods.net/showthread.php?t=310630

PHP Code:
#include <sourcemod>

#pragma semicolon 1
#pragma newdecls required

public void OnPluginStart()
{
    
RegConsoleCmd("sm_discord"Cmd_Discord);
    
RegConsoleCmd("sm_website"Cmd_Website);
    
RegConsoleCmd("sm_group"Cmd_Group);
}

public 
Action Cmd_Discord(int clientint args)
{
    
PrintToChat(client"» \x08Discord: \x04https://discord.gg/1234567");
}

public 
Action Cmd_Website(int clientint args)
{
    
PrintToChat(client"» \x08Website: \x04http://example.com");
}

public 
Action Cmd_Group(int clientint args)
{
    
PrintToChat(client"» \x08Group: \x04https://steamcommunity.com/id/example/");


Last edited by iskenderkebab33; 12-23-2018 at 09:11.
iskenderkebab33 is offline
DabberDoug
Member
Join Date: Feb 2016
Location: USA
Old 12-23-2018 , 14:45   Re: [CSGO] Command to trigger Discord link in chat
Reply With Quote #3

This is wonderful but how would I configure it to change the links... I'm megatard,
the smx file didnt generate a cfg, Idk how to decompile edit and recompile if that's the case I guess we are learning today.
DabberDoug is offline
iskenderkebab33
Senior Member
Join Date: Jun 2018
Old 12-23-2018 , 15:32   Re: [CSGO] Command to trigger Discord link in chat
Reply With Quote #4

Quote:
Originally Posted by DabberDoug View Post
This is wonderful but how would I configure it to change the links... I'm megatard,
the smx file didnt generate a cfg, Idk how to decompile edit and recompile if that's the case I guess we are learning today.
copy paste this code:

PHP Code:
#include <sourcemod>

#pragma semicolon 1
#pragma newdecls required

public void OnPluginStart()
{
    
RegConsoleCmd("sm_discord"Cmd_Discord);
    
RegConsoleCmd("sm_website"Cmd_Website);
    
RegConsoleCmd("sm_group"Cmd_Group);
}

public 
Action Cmd_Discord(int clientint args)
{
    
PrintToChat(client"» \x08Discord: \x04https://discord.gg/1234567");
}

public 
Action Cmd_Website(int clientint args)
{
    
PrintToChat(client"» \x08Website: \x04http://example.com");
}

public 
Action Cmd_Group(int clientint args)
{
    
PrintToChat(client"» \x08Group: \x04https://steamcommunity.com/id/example/");

here -> https://spider.limetech.io/

now edit the text, print your Discord server link, website link and steam group link

after that you go right to compile and then download.

move your .smx file in your plugins folder.

restart the server or change the map, then you can use this commands, !discord, !website, !group in the chat.

Last edited by iskenderkebab33; 12-23-2018 at 15:34.
iskenderkebab33 is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 05:10.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode