@@ -0,0 +1,2180 @@
+package com.mcbans.firestar.mcbans.api;%0D%0A%0D%0Aimport org.bukkit.Bukkit;%0D%0Aimport org.bukkit.entity.Player;%0D%0A%0D%0Aimport com.mcbans.firestar.mcbans.BanType;%0D%0Aimport com.mcbans.firestar.mcbans.BukkitInterface;%0D%0Aimport com.mcbans.firestar.mcbans.pluginInterface.Ban;%0D%0A%0D%0Apublic class MCBansAPI %7B%0D%0A    private final BukkitInterface plugin;%0D%0A%0D%0A    public MCBansAPI(final BukkitInterface plugin) %7B%0D%0A        this.plugin = plugin;%0D%0A    %7D%0D%0A%0D%0A    private void Ban(BanType type, String targetName, String senderName, String reason, String duration, String measure)%7B%0D%0A        // check null%0D%0A        if (targetName == null %7C%7C senderName == null)%7B%0D%0A            return;%0D%0A        %7D%0D%0A%0D%0A        String targetIP = %22%22;%0D%0A        if (type != BanType.UNBAN)%7B%0D%0A            final Player target = Bukkit.getPlayerExact(targetName);%0D%0A            targetIP = (target != null) ? target.getAddress().getAddress().getHostAddress() : %22%22;%0D%0A        %7D%0D%0A%0D%0A        Ban banControl = new Ban(plugin, type.getActionName(), targetName, targetIP, senderName, reason, duration, measure);%0D%0A        Thread triggerThread = new Thread(banControl);%0D%0A        triggerThread.start();%0D%0A    %7D%0D%0A%0D%0A    public void LocalBan(String targetName, String senderName, String reason)%7B%0D%0A        reason = (reason == null %7C%7C reason == %22%22) ? plugin.settings.getString(%22defaultLocal%22) : reason;%0D%0A        this.Ban(BanType.LOCAL, targetName, senderName, reason, %22%22, %22%22);%0D%0A    %7D%0D%0A%0D%0A    public void GlobalBan(String targetName, String senderName, String reason)%7B%0D%0A        if (reason == null %7C%7C reason == %22%22) return;%0D%0A        this.Ban(BanType.GLOBAL, targetName, senderName, reason, %22%22, %22%22);%0D%0A    %7D%0D%0A%0D%0A    public void TempBan(String targetName, String senderName, String reason, String duration, String measure)%7B%0D%0A        reason = (reason == null %7C%7C reason == %22%22) ? plugin.settings.getString(%22defaultTemp%22) : reason;%0D%0A        duration = (duration == null) ? %22%22 : duration;%0D%0A        measure = (measure == null) ? %22%22 : measure;%0D%0A        this.Ban(BanType.TEMP, targetName, senderName, reason, duration, measure);%0D%0A    %7D%0D%0A%0D%0A    public void UnBan(String targetName, String senderName)%7B%0D%0A        this.Ban(BanType.UNBAN, targetName, senderName, %22%22, %22%22, %22%22);%0D%0A    %7D%0D%0A%7D%0D%0A

Add MCBansAPI class