Use of this command: Tap the player you want to ban with the correct tool to ban them!
Why command was made: Someone requested it because they were tired of typing out player's full name
Remember To: Trigger it to damage trigger if haven't already (and unregister the command)
Give yourself the banhammer: /give <name> 275 1 {display:{Name:"§r§c§lBAN HAMMER"}}
Why command was made: Someone requested it because they were tired of typing out player's full name
Remember To: Trigger it to damage trigger if haven't already (and unregister the command)
Give yourself the banhammer: /give <name> 275 1 {display:{Name:"§r§c§lBAN HAMMER"}}
Code:
cmd add banhammer let %id% = %args%[4]
cmd add banhammer if %id% != 1 then exit
cmd add banhammer let %killer% = %args%[3]
cmd add banhammer let %hand% = playerhand(%killer%)
cmd add banhammer if (%hand%["id"] != 275) or (%hand%["name"] != \"§r§c§lBAN HAMMER\") then exit
cmd add banhammer let %status% = playerstatus(%killer%)
cmd add banhammer if %status%["op"] = %true% then goto 10
cmd add banhammer message %killer% §cYou do not have permission to use the almighty §4§lBAN HAMMER! §7~CosG/CosmG
cmd add banhammer exit
cmd add banhammer let %gui%["type"] = \"modal\"
cmd add banhammer let %gui%["title"] = \"§cBAN HAMMER\"
cmd add banhammer let %gui%["content"] = \"Are you sure you want to ban §e\" + %p% + \"§f?\"
cmd add banhammer let %gui%["button1"] = \"§a§lYes\"
cmd add banhammer let %gui%["button2"] = \"§c§lNo\"
cmd add banhammer let %res% = dialog(%killer%, %gui%)
cmd add banhammer if %res% != %false% then goto 19
cmd add banhammer message %killer% §cBan request repealed!
cmd add banhammer exit
cmd add banhammer ascon /ban %p% §c§lBAN HAMMERED!
cmd add banhammer message onlineplayers() §8[§cCosGBAN§8] §7%p% §ejust received the §c§lBAN HAMMER§e! Justice has been served by §7%killer%!
cmd add banhammer exit