Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package me.FusionTech.FisionPlugin;
- import java.util.List;
- import java.util.logging.Logger;
- import org.bukkit.ChatColor;
- import org.bukkit.Location;
- import org.bukkit.command.Command;
- import org.bukkit.command.CommandSender;
- import org.bukkit.entity.Player;
- import org.bukkit.event.Event;
- import org.bukkit.plugin.PluginDescriptionFile;
- import org.bukkit.plugin.PluginManager;
- import org.bukkit.plugin.java.JavaPlugin;
- @SuppressWarnings("unused")
- public class Fision extends JavaPlugin {
- public final Logger logger = Logger.getLogger("Minecraft");
- public static Fision plugin;
- @Override
- public void onDisable() {
- PluginDescriptionFile pdfFile = this.getDescription();
- this.logger.info(pdfFile.getName()
- + "[FissionPlugin] Has been Disabled");
- }
- @Override
- public void onEnable() {
- PluginDescriptionFile pdfFile = this.getDescription();
- this.logger.info(pdfFile.getName() + " Version " + pdfFile.getVersion()
- + "[FissionPlugin] Has been Enabled");
- getConfig().options().copyDefaults(true);
- saveConfig();
- }
- public boolean onCommand(CommandSender sender, Command cmd,
- String commandLabel, String[] args) {
- Player player = (Player) sender;
- if (commandLabel.equalsIgnoreCase("staff")) {
- player.sendMessage(getConfig().getString("Staff"));
- }
- if (player.hasPermission("fission.heal.ulti")) {
- if (commandLabel.equalsIgnoreCase("Ultiheal")) {
- player.setHealth(20);
- player.setFoodLevel(20);
- player.setRemainingAir(20);
- player.setFireTicks(0);
- player.sendMessage(ChatColor.DARK_GREEN
- + "You have been healed!");
- }
- if (player.hasPermission("fission.list.speed")) {
- if (commandLabel.equalsIgnoreCase("speed")) {
- player.setWalkSpeed(9);
- player.sendMessage(ChatColor.DARK_GREEN
- + "Walk speed set to 9");
- }
- }
- if (player.hasPermission("fission.away")) {
- if (commandLabel.equalsIgnoreCase("away")) {
- if (args.length == 0) {
- player.sendMessage("Too little arguments");
- if (args.length == 1) {
- Player targetPlayer = player.getServer().getPlayer(
- args[1]);
- Location location = Location(getConfig().getString(
- "AwayLocation"));
- }
- if (player.hasPermission("fission.wanted.addwanted")) {
- if (commandLabel.equalsIgnoreCase("addwanted")) {
- if (args.length == 1) {
- List<String> wanted = getConfig()
- .getStringList("WantedList");
- getConfig().set("Wanted List", args[0]);
- }
- }
- }
- if (player.hasPermission("fission.wanted.list")) {
- if (commandLabel.equalsIgnoreCase("listwanted")) {
- player.sendMessage(getConfig().getString(
- "Wanted List"));
- }
- }
- }
- }
- }
- }
- return false;
- }
- private Location Location(String string) {
- // TODO Auto-generated method stub
- return null;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement