Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add new plugin Server-VoteKick.luau #47

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

NoobBucket
Copy link

Adds a new command :votekick

Adds a new votekick command
Add new plugin: Server-VoteKick.luau
Copy link
Contributor

@WalkerOfBacon WalkerOfBacon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You should show the player's name when they do/don't get kicked

local Player = server.Functions.GetPlayers(plr, args[1])[1]

if Yes > No then
	if Player then
		Player:Kick(`Vote kicked. Reason: {args[2] or "No reason provided."}`)
		Logs:AddLog("Script", `{Player.Name} was votekicked. Reason: {args[2] or "No reason provided."}`)
	end
	server.Functions.Notify("Vote kick", `{Player.Name} was vote kicked.`, {plr})
else
	server.Functions.Notify("Vote kick", `{Player.Name} was not vote kicked.`, {plr})
end

@NoobBucket
Copy link
Author

That makes sense, don't know why I didn't think of that 🤦

@cowboyblood
Copy link

This can be abused..

@Dimenpsyonal
Copy link
Member

well you don't have to add it into your game

@cowboyblood
Copy link

cowboyblood commented Jan 12, 2025

Fair enough. We do need some anti-abusive measures if this is going to be added though.

@NoobBucket
Copy link
Author

How can this be abused?

@cowboyblood
Copy link

How can this be abused?

What if people hate a innocent person so they use your command to kick them repeatedly?
Big issue.

@GalacticInspired
Copy link
Member

You need to add anti-spam measures as anyone can spam this at the moment.

@GalacticInspired GalacticInspired added the enhancement New feature or request label Jan 28, 2025
if Yes > No then
if Player then
Player:Kick(`Vote kicked. Reason: {args[2] or "No reason provided."}`)
Logs:AddLog("Script", `{Player.Name} was votekicked. Reason: {args[2] or "No reason provided."}`)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would recommend service.FormatPlayer(Player) over Player.Name.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants