SA-MP Forums

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

Reply
 
Thread Tools Display Modes
Old 05/08/2020, 09:44 AM   #1
playstores
Huge Clucker
 
Join Date: Feb 2018
Location: Germany
Posts: 221
Reputation: 29
Default Tec9's Discord Include [Kick, Ban, Set Role]

Hey,

currently I am developing an Discord-System for my project "SAMP Luftschlacht".

So I decided to publish my system.

You'll need maddinat0r's Discord connector: https://github.com/maddinat0r/samp-discord-connector

Your advantages:
  • Set role directly ingame
  • Log-function!
  • Check if user already has a role
  • Ban users Ingame from your discord server!
  • And the best: No need to convert anything! Just give in the username Example: Tec9#3343 and here ya go
  • No Bullshit!


Functions:

Code:
BanUserDiscord(victim[],reason[])
RemoveBanUserDiscord(victim[])
KickUserDiscord(victim[],reason[])
AddUserRole(victim[],role[])
RemoveUserRole(victim[],role[])
UserGotRole(victim[],role[])
SendMessageToChannel(ChannelId[],const string[])

Known Bugs:

Code:
--> Names with a space are currently not recognized as user, and return an invalid id. (Tested with sscanf)
Pastebin: https://pastebin.com/kzvF0puM

Last edited by playstores; 08/08/2020 at 06:22 PM.
playstores is offline   Reply With Quote
Old 05/08/2020, 09:06 PM   #2
tysanio
Big Clucker
 
tysanio's Avatar
 
Join Date: May 2012
Location: At my House Duh..
Posts: 148
Reputation: 39
Default Re: Tec9's Discord Include [Kick, Ban, Set Role]

trying to add role and its doesnt work why...

try AddUserRole(inputtext,740667762266865694);

try AddUserRole(inputtext,"740667762266865694");

#define Derp "740667762266865694"
try AddUserRole(inputtext,Derp);


EDIT nvm found it (i'm an idiot)
__________________

Did i ever tell you the définitions of insanity?
tysanio is offline   Reply With Quote
Old 06/08/2020, 07:51 AM   #3
ShadowMortar
Huge Clucker
 
ShadowMortar's Avatar
 
Join Date: Jul 2016
Location: Croatia
Posts: 303
Reputation: 110
Default Re: Tec9's Discord Include [Kick, Ban, Set Role]

Good job.
__________________
If you appreciate(d) my help, I will appreciate +REP .

Quote:
Originally Posted by CheezIt View Post
Follow your heart and own style.
Feel free to PM me if you need help.
Quote:
Originally Posted by Pottus View Post
That is perfectly fine, I'm just pointing out where you made mistakes what does hearing "good job" get you? Absolutely nothing. You need to hear the problems otherwise you'll keep making the same mistakes
ShadowMortar is offline   Reply With Quote
Old 08/08/2020, 06:21 PM   #4
playstores
Huge Clucker
 
Join Date: Feb 2018
Location: Germany
Posts: 221
Reputation: 29
Default Re: Tec9's Discord Include [Kick, Ban, Set Role]

* Functions added:

Quote:
SendMessageToChannel(ChannelId[],const string[])
playstores is offline   Reply With Quote
Old 08/08/2020, 08:42 PM   #5
tysanio
Big Clucker
 
tysanio's Avatar
 
Join Date: May 2012
Location: At my House Duh..
Posts: 148
Reputation: 39
Default Re: Tec9's Discord Include [Kick, Ban, Set Role]

Quote:
Originally Posted by playstores View Post
* Functions added:
That work perfectly Great! Now Discord chat -> InGame Chat :P
__________________

Did i ever tell you the définitions of insanity?
tysanio is offline   Reply With Quote
Old 08/08/2020, 10:07 PM   #6
playstores
Huge Clucker
 
Join Date: Feb 2018
Location: Germany
Posts: 221
Reputation: 29
Default Re: Tec9's Discord Include [Kick, Ban, Set Role]

So true haha,

why would u even need ingame chat
playstores is offline   Reply With Quote
Old 09/08/2020, 03:29 PM   #7
tysanio
Big Clucker
 
tysanio's Avatar
 
Join Date: May 2012
Location: At my House Duh..
Posts: 148
Reputation: 39
Default Re: Tec9's Discord Include [Kick, Ban, Set Role]

The last fonction you added is for Ingame->discord
why not adding Discord -> Ingame

to respond the Ingame -> Discord
__________________

Did i ever tell you the définitions of insanity?
tysanio is offline   Reply With Quote
Old 09/08/2020, 04:28 PM   #8
playstores
Huge Clucker
 
Join Date: Feb 2018
Location: Germany
Posts: 221
Reputation: 29
Default Re: Tec9's Discord Include [Kick, Ban, Set Role]

Like a function?

OnDiscordMessage(channel[],message[]) ?
playstores is offline   Reply With Quote
Old 10/08/2020, 12:42 AM   #9
tysanio
Big Clucker
 
tysanio's Avatar
 
Join Date: May 2012
Location: At my House Duh..
Posts: 148
Reputation: 39
Default Re: Tec9's Discord Include [Kick, Ban, Set Role]

Yes! that will be awsome!
__________________

Did i ever tell you the définitions of insanity?
tysanio 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 Admin Control Panel - Manage players through discord! Exhibit Filterscripts 34 12/08/2020 04:28 PM
[FilterScript] Discord Chat - Real time chatting ( Discord + In Game) Exhibit Filterscripts 36 16/10/2019 08:32 PM
Ammo doesnt register when shooting up & down with TEC9 JaydenJason Scripting Help 4 08/08/2016 01:08 PM
Help me include For Role Play Please *utils* salut693123 Help Archive 2 01/08/2010 01:07 PM
[Include] [INC]Simple Reason Include[Good for kick and ban] Jonte92 Includes 7 23/05/2009 05:35 PM


All times are GMT. The time now is 06:50 PM.


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