<commit_before>package org.royaldev.royalcommands.rcommands;

import org.bukkit.ChatColor;
import org.bukkit.command.Command;
import org.bukkit.command.CommandExecutor;
import org.bukkit.command.CommandSender;
import org.bukkit.entity.Player;
import org.royaldev.royalcommands.RUtils;
import org.royaldev.royalcommands.RoyalCommands;

public class Slap implements CommandExecutor {

    RoyalCommands plugin;

    public Slap(RoyalCommands plugin) {
        this.plugin = plugin;
    }

    @Override
    public boolean onCommand(CommandSender cs, Command cmd, String label, String[] args) {
        if (cmd.getName().equalsIgnoreCase("slap")) {
            if (!plugin.isAuthorized(cs, "rcmds.slap")) {
                RUtils.dispNoPerms(cs);
                return true;
            }
            if (args.length < 1) {
                cs.sendMessage(cmd.getDescription());
                return false;
            }
            Player victim;
            victim = plugin.getServer().getPlayer(args[0]);
            if (victim == null || plugin.isVanished(victim)) {
                cs.sendMessage(ChatColor.RED + "That person is not online!");
                return true;
            }
            if (plugin.isAuthorized(victim, "rcmds.exempt.slap")) {
                cs.sendMessage(ChatColor.RED + "You may not slap that player.");
                return true;
            }
            plugin.getServer().broadcastMessage(ChatColor.GOLD + cs.getName() + ChatColor.WHITE + " slaps " + ChatColor.RED + victim.getName() + ChatColor.WHITE + "!");
            return true;
        }
        return false;
    }

}<commit_msg>Added: /slap pushes people<commit_after>package org.royaldev.royalcommands.rcommands;

import org.bukkit.ChatColor;
import org.bukkit.command.Command;
import org.bukkit.command.CommandExecutor;
import org.bukkit.command.CommandSender;
import org.bukkit.entity.Player;
import org.bukkit.util.Vector;
import org.royaldev.royalcommands.RUtils;
import org.royaldev.royalcommands.RoyalCommands;

public class Slap implements CommandExecutor {

    RoyalCommands plugin;

    public Slap(RoyalCommands plugin) {
        this.plugin = plugin;
    }

    @Override
    public boolean onCommand(CommandSender cs, Command cmd, String label, String[] args) {
        if (cmd.getName().equalsIgnoreCase("slap")) {
            if (!plugin.isAuthorized(cs, "rcmds.slap")) {
                RUtils.dispNoPerms(cs);
                return true;
            }
            if (args.length < 1) {
                cs.sendMessage(cmd.getDescription());
                return false;
            }
            Player victim;
            victim = plugin.getServer().getPlayer(args[0]);
            if (victim == null || plugin.isVanished(victim)) {
                cs.sendMessage(ChatColor.RED + "That person is not online!");
                return true;
            }
            if (plugin.isAuthorized(victim, "rcmds.exempt.slap")) {
                cs.sendMessage(ChatColor.RED + "You may not slap that player.");
                return true;
            }
            Vector push = victim.getVelocity();
            push.setY(push.getY() + .5);
            push.setX(push.getX() + .5);
            push.setZ(push.getZ() + .5);
            victim.setVelocity(push);
            plugin.getServer().broadcastMessage(ChatColor.GOLD + cs.getName() + ChatColor.WHITE + " slaps " + ChatColor.RED + victim.getName() + ChatColor.WHITE + "!");
            return true;
        }
        return false;
    }

}
{'fraction_non_alphanumeric': 0.11563657077755625, 'fraction_numerical': 0.0019937339789233835, 'mean_word_length': 2.155435759209344, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2885152', 'n_tokens_mistral': 1039, 'n_tokens_neox': 996, 'n_words': 199}