Skip to content

Commit

Permalink
Add files via upload
Browse files Browse the repository at this point in the history
  • Loading branch information
2xjxn2j authored Dec 22, 2019
0 parents commit a463aaa
Show file tree
Hide file tree
Showing 8 changed files with 91 additions and 0 deletions.
31 changes: 31 additions & 0 deletions VoidNetworkCore.iml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
<?xml version="1.0" encoding="UTF-8"?>
<module type="JAVA_MODULE" version="4">
<component name="FacetManager">
<facet type="minecraft" name="Minecraft">
<configuration>
<autoDetectTypes>
<platformType>SPIGOT</platformType>
</autoDetectTypes>
</configuration>
</facet>
</component>
<component name="NewModuleRootManager" inherit-compiler-output="true">
<exclude-output />
<content url="file://$MODULE_DIR$">
<sourceFolder url="file://$MODULE_DIR$/src" isTestSource="false" />
</content>
<orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" />
<orderEntry type="module-library">
<library>
<CLASSES>
<root url="jar://$MODULE_DIR$/../spigot-1.14.4.jar!/" />
</CLASSES>
<JAVADOC />
<SOURCES>
<root url="jar://$MODULE_DIR$/../spigot-1.14.4.jar!/" />
</SOURCES>
</library>
</orderEntry>
</component>
</module>
Binary file not shown.
Binary file not shown.
Binary file not shown.
6 changes: 6 additions & 0 deletions out/production/VoidNetworkCore/plugin.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
name: VoidNetworkCore
main: org.jacob.spigot.plugins.VNC.Main
version: 1.0
api-version: "1.13"
commands:
announce:
36 changes: 36 additions & 0 deletions src/org/jacob/spigot/plugins/VNC/AnnounceCommand.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
package org.jacob.spigot.plugins.VNC;

import net.md_5.bungee.api.ChatColor;
import org.bukkit.Bukkit;
import org.bukkit.command.Command;
import org.bukkit.command.CommandExecutor;
import org.bukkit.command.CommandSender;

public class AnnounceCommand implements CommandExecutor {
@Override
public boolean onCommand(CommandSender commandSender, Command command, String s, String[] strings) {

if(s.equalsIgnoreCase("announce")) {

if(!commandSender.hasPermission("vnc.announce")) {
commandSender.sendMessage(ChatColor.RED + "No permissions!");
return true;
}

if(strings.length == 0) {
commandSender.sendMessage(ChatColor.RED + "Usage: /announce <message>");
return true;
}

String message = "";
for (int i = 0; i < strings.length; i++) {
message = message + strings[i] + " ";
}

Bukkit.broadcastMessage(ChatColor.RED + "[Voidnetwork MC] " + ChatColor.DARK_GRAY + ">> " + ChatColor.GRAY + message);

}

return true;
}
}
12 changes: 12 additions & 0 deletions src/org/jacob/spigot/plugins/VNC/Main.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
package org.jacob.spigot.plugins.VNC;

import org.bukkit.plugin.java.JavaPlugin;

public class Main extends JavaPlugin {

@Override
public void onEnable() {

getCommand("announce").setExecutor(new AnnounceCommand());
}
}
6 changes: 6 additions & 0 deletions src/plugin.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
name: VoidNetworkCore
main: org.jacob.spigot.plugins.VNC.Main
version: 1.0
api-version: "1.13"
commands:
announce:

0 comments on commit a463aaa

Please sign in to comment.