Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added plugin prefix.
- Loading branch information
Showing
10 changed files
with
130 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<classpath> | ||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/> | ||
<classpathentry kind="src" path="src"/> | ||
<classpathentry kind="lib" path="C:/Users/Redacted/Desktop/MCSRV_SPIGOT/spigot-1.13.jar"/> | ||
<classpathentry kind="output" path="bin"/> | ||
</classpath> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -21,3 +21,4 @@ | |
|
||
# virtual machine crash logs, see http://www.java.com/en/download/help/error_hotspot.xml | ||
hs_err_pid* | ||
*.bak |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<projectDescription> | ||
<name>ShinyKicks</name> | ||
<comment></comment> | ||
<projects> | ||
</projects> | ||
<buildSpec> | ||
<buildCommand> | ||
<name>org.eclipse.jdt.core.javabuilder</name> | ||
<arguments> | ||
</arguments> | ||
</buildCommand> | ||
</buildSpec> | ||
<natures> | ||
<nature>org.eclipse.jdt.core.javanature</nature> | ||
</natures> | ||
</projectDescription> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
name: ShinyKicks | ||
|
||
author: YT_Veritas0923 | ||
|
||
version: 0.1b | ||
|
||
main: mc.v0923.ShinyKicks.ShinyKicks | ||
|
||
description: Kick Broadcaster | ||
|
||
<img src="https://proxy.spigotmc.org/eb3c177c7d62063a8f763754fb59136e994e7304?url=https%3A%2F%2Fi.gyazo.com%2F264f00f2a5cc74af0a10673a30030d35.png"> | ||
|
||
A simple plugin that will broadcast whenever a player is kicked | ||
|
||
|
||
SpigotMC https://www.spigotmc.org/resources/shinykicks.59891/ | ||
|
||
Changelog: | ||
|
||
v0.1b 8/22/2018 5:46:53 AM | ||
|
||
Added plugin prefix. | ||
|
||
v0.1a 8/9/2018 2:56:53 PM | ||
|
||
Now supports config.yml | ||
|
||
Simply set your 'message' and | ||
that will be displayed on broadcast | ||
|
||
v0.1 8/8/2018 10:57:28 PM | ||
|
||
First release | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
ShinyKicks: | ||
version: "0.1" | ||
message: "A mighty kick was just delivered to " |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
name: ShinyKicks | ||
author: YT_Veritas0923 | ||
version: 0.1a | ||
main: mc.v0923.ShinyKicks.ShinyKicks | ||
description: Kick Broadcaster |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
ShinyKicks: | ||
version: "0.1" | ||
message: "A mighty kick was just delivered to " |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
package mc.v0923.ShinyKicks; | ||
|
||
import org.bukkit.Bukkit; | ||
import org.bukkit.ChatColor; | ||
import org.bukkit.entity.Player; | ||
import org.bukkit.event.EventHandler; | ||
import org.bukkit.event.Listener; | ||
import org.bukkit.event.player.PlayerKickEvent; | ||
import org.bukkit.plugin.Plugin; | ||
|
||
import mc.v0923.ShinyKicks.ShinyKicks; | ||
|
||
public class EventsClass implements Listener { | ||
Plugin plugin = ShinyKicks.getPlugin(ShinyKicks.class); | ||
String kickPlayer = ""; | ||
String kickReason = ""; | ||
@EventHandler | ||
public void onPlayerKickEvent(PlayerKickEvent event) { | ||
Player player = event.getPlayer(); | ||
String reason = event.getReason(); | ||
kickPlayer = player.getDisplayName(); | ||
kickReason = reason.toString(); | ||
Bukkit.broadcastMessage(ChatColor.YELLOW + "[ShinyKicks] " + ChatColor.LIGHT_PURPLE + plugin.getConfig().getString("ShinyKicks.message") + ChatColor.DARK_RED + kickPlayer + ChatColor.YELLOW + " for " + ChatColor.AQUA + kickReason); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
package mc.v0923.ShinyKicks; | ||
|
||
import java.io.File; | ||
|
||
import org.bukkit.ChatColor; | ||
import org.bukkit.plugin.java.JavaPlugin; | ||
|
||
import mc.v0923.ShinyKicks.EventsClass; | ||
|
||
public class ShinyKicks extends JavaPlugin{ | ||
public void onEnable() { | ||
registerConfig(); | ||
getServer().getConsoleSender().sendMessage(ChatColor.GREEN + "ShinyKicks v" + getConfig().getString("ShinyKicks.version") + " by YT_Veritas0923 Loaded!"); | ||
getServer().getPluginManager().registerEvents(new EventsClass(), this); | ||
|
||
} | ||
public void onDisable() { | ||
getServer().getConsoleSender().sendMessage(ChatColor.RED + "ShinyKicks " + getConfig().getString("ShinyKicks.version") + " by YT_Veritas0923 Unloaded!"); | ||
} | ||
public void registerConfig() { | ||
@SuppressWarnings("unused") | ||
String configPath; | ||
File config = new File(this.getDataFolder(), "config.yml"); | ||
configPath = config.getPath(); | ||
if(!config.exists()) { | ||
this.getConfig().options().copyDefaults(true); | ||
saveConfig(); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
name: ShinyKicks | ||
author: YT_Veritas0923 | ||
version: 0.1a | ||
main: mc.v0923.ShinyKicks.ShinyKicks | ||
description: Kick Broadcaster |