Skip to content
This repository has been archived by the owner on Jan 10, 2021. It is now read-only.

Add kick command #116

Open
Abdur-rahmaanJ opened this issue Apr 16, 2019 · 10 comments
Open

Add kick command #116

Abdur-rahmaanJ opened this issue Apr 16, 2019 · 10 comments

Comments

@Abdur-rahmaanJ
Copy link
Owner

if bot admin,

.kick <username>
@AngeloGiacco
Copy link
Collaborator

I am using this code currently in a russian roulette plugin i am developing.

Screenshot 2019-04-17 at 11 41 02

It will let me kick the bot out if i am an admin, but it will not let the bot kick me even if the bot is the admin. Any ideas?

I can easily make a seperate kill plugin after this one is complete.

@GlennToms
Copy link
Contributor

Is it giving any error messages? Check the bot user is admin in the channel and not just server rights.

Also create a Thanos/Snap plugin that kicks half the server. HAHAHAHA

@AngeloGiacco
Copy link
Collaborator

HAHAHA.

No error messages.

@Abdur-rahmaanJ
Copy link
Owner Author

@AngeloGiacco kick is not implemented by /Kick you have to use send_raw to implement the protocol from scratch

@AngeloGiacco
Copy link
Collaborator

@Abdur-rahmaanJ have tried that as well

@AngeloGiacco
Copy link
Collaborator

@Abdur-rahmaanJ @GlennToms

When using send_raw the kick message does not appear in the chat. However the terminal does raise an error in the terminal with send_raw.

Screenshot 2019-04-18 at 9 52 24

It is the same for "/kick" "/KICK" and "/Kick"

@GlennToms
Copy link
Contributor

GlennToms commented Apr 18, 2019

Don't use the '/'
RAW would be KICK #TESTINGCHANNEL GLENN

@AngeloGiacco
Copy link
Collaborator

Is there a way to check that the bot is channel operator so that i can give an error message in case the bot does not have authority to issue KICK command?

@GlennToms
Copy link
Contributor

You'll get back the error ERR_CHANOPRIVSNEEDED. I don't think there is a way to query privileges...
RFC is here but I can't see anything and I can't remember is ever used it in my last bot.

@AngeloGiacco
Copy link
Collaborator

Okay I'll leave it as is. I've made the russian_roulette plugin code now, will leave the plugin so that somebody can make it as a first contribution.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants