SA-MP Forums

Go Back   SA-MP Forums > SA-MP Scripting and Plugins > Filterscripts

Reply
 
Thread Tools Display Modes
Old 17/04/2020, 04:29 PM   #1
CyberH4wk
Little Clucker
 
CyberH4wk's Avatar
 
Join Date: Mar 2020
Posts: 15
Reputation: 10
Post DChat - Discord IRC System


DChat is a basic filterscript which lets player on discord to communicate with in-game players and vice versa. It works with latest version of discord-connector plugin by maddinat0r.

Features:
  • Chating with In Game Players Using Discord
  • Player Joining and Leaving Message
  • Blocking Discord Irc Bot Message in Game

Useful Links:
How to Create Discord Bot Account
How to get Token and Channel ID for Discord

How to use:
  • Add this line in server.cfg 'discord_bot_token REPLACE_WITH_BOT_TOKEN'
  • Add discord-connector plugin in server.cfg
  • Add discord-connector.inc in Pawno's include folder
  • Add logcore-2 plugin in samp server folder
  • Open your pawn editor
  • Copy the code from link below
  • Update 'Discord_Channel_ID'
  • Compile the script

Required Plugins:
<a_samp> by SA-MP Team
<discord-connector> by maddinat0r (samp forum) (github)


Download:
Solidfiles: https://www.solidfiles.com/v/DGrZR4q33yPeY
Pastebin: https://pastebin.com/XRSSPZ4P
GitHub: https://github.com/CyberH4wk/DChat


Screenshot:



Thank You
__________________
Join our new Server!


https://discord.gg/yC7sJBF
CyberH4wk is offline   Reply With Quote
Old 17/04/2020, 09:27 PM   #2
Chaprnks
Gangsta
 
Chaprnks's Avatar
 
Join Date: Sep 2007
Location: Soviet America
Posts: 597
Reputation: 69
Default Re: DChat - Discord IRC System

I'm glad to see a filterscript finally updated to the newest discord-connector. All of the other filterscripts/includes that make use of this plugin are for older versions that have major code-breaking changes in the latest version.
__________________
Chaprnks is offline   Reply With Quote
Old 18/04/2020, 03:35 PM   #3
CyberH4wk
Little Clucker
 
CyberH4wk's Avatar
 
Join Date: Mar 2020
Posts: 15
Reputation: 10
Default Re: DChat - Discord IRC System

Quote:
Originally Posted by Chaprnks View Post
I'm glad to see a filterscript finally updated to the newest discord-connector. All of the other filterscripts/includes that make use of this plugin are for older versions that have major code-breaking changes in the latest version.
Thanks, I also searched for Discord IRC scripts but they all were using older version of discord-connector plugin so thought to make new one using latest version.
__________________
Join our new Server!


https://discord.gg/yC7sJBF
CyberH4wk is offline   Reply With Quote
Old 19/04/2020, 12:39 AM   #4
Muamar
Little Clucker
 
Join Date: Jan 2020
Posts: 9
Reputation: 3
Default Re: DChat - Discord IRC System

How to put my bot token to the script
Muamar is offline   Reply With Quote
Old 19/04/2020, 05:53 AM   #5
Mike861
Huge Clucker
 
Join Date: Feb 2018
Posts: 231
Reputation: 16
Default Re: DChat - Discord IRC System

Good work, i'll use it as another example to write the system for my server.
Mike861 is offline   Reply With Quote
Old 19/04/2020, 11:28 AM   #6
CyberH4wk
Little Clucker
 
CyberH4wk's Avatar
 
Join Date: Mar 2020
Posts: 15
Reputation: 10
Default Re: DChat - Discord IRC System

Quote:
Originally Posted by Muamar View Post
How to put my bot token to the script
You will have to add Bot Token in 'server.cfg' file and Channel ID can be change from script.

See this:
__________________
Join our new Server!


https://discord.gg/yC7sJBF
CyberH4wk is offline   Reply With Quote
Old 19/04/2020, 11:30 AM   #7
CyberH4wk
Little Clucker
 
CyberH4wk's Avatar
 
Join Date: Mar 2020
Posts: 15
Reputation: 10
Default Re: DChat - Discord IRC System

Quote:
Originally Posted by Mike861 View Post
Good work, i'll use it as another example to write the system for my server.
Thanks dude
__________________
Join our new Server!


https://discord.gg/yC7sJBF
CyberH4wk is offline   Reply With Quote
Old 19/04/2020, 05:19 PM   #8
Fairuz
Huge Clucker
 
Fairuz's Avatar
 
Join Date: Sep 2015
Location: Indonesia
Posts: 452
Reputation: 64
Default Re: DChat - Discord IRC System

Sweet!
__________________
Los Santos based Cops and Robbers with many features.
209.58.183.101:7777
Fairuz is offline   Reply With Quote
Old 19/04/2020, 05:40 PM   #9
Ironboy
High-roller
 
Ironboy's Avatar
 
Join Date: Nov 2010
Location: Isle of Man
Posts: 1,942
Reputation: 433
Default Re: DChat - Discord IRC System

Never thought one of these would come around, great work.
__________________
Ironboy is offline   Reply With Quote
Old 20/04/2020, 01:13 PM   #10
Symon
Gangsta
 
Symon's Avatar
 
Join Date: Apr 2019
Location: Italy
Posts: 885
Reputation: 85
Default Re: DChat - Discord IRC System

A question. To send a message to a channel, do we have to add everytime:

pawn Code:
if(_:g_Discord_Chat == 0)
g_Discord_Chat = DCC_FindChannelById("CHANNEL_ID");

I don't get it. Is it so necessary as we check it already on OnGameModeInit?
Symon is offline   Reply With Quote
Reply

Thread Tools
Display Modes

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
[FilterScript] Discord irc System [first filterscript] RJTabish Filterscripts 13 26/06/2020 08:09 PM
[FilterScript] Discord Admin Control Panel - Manage players through discord! Exhibit Filterscripts 29 14/05/2020 05:45 PM
[FilterScript] Discord Chat - Real time chatting ( Discord + In Game) Exhibit Filterscripts 36 16/10/2019 08:32 PM
[Tutorial] Discord PM system DeadBrain Tutorials 2 21/08/2018 07:17 AM


All times are GMT. The time now is 09:25 PM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.