diff --git a/README.md b/README.md index 731988b5..9f753ffc 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -PeripheralsPlusPlus [![Build Status](https://drone.io/github.com/austinv11/PeripheralsPlusPlus/status.png)](https://drone.io/github.com/austinv11/PeripheralsPlusPlus/files) +PeripheralsPlusPlus [![Build Status](https://drone.io/github.com/justync7/PeripheralsPlusPlus/status.png)](https://drone.io/github.com/austinv11/PeripheralsPlusPlus/files) =================== ![Logo](http://puu.sh/fB9TB/66231fda96.png) diff --git a/build.gradle b/build.gradle index 7677c39a..6623c426 100644 --- a/build.gradle +++ b/build.gradle @@ -22,10 +22,10 @@ plugins { */ version = "1.4.0" group= "com.austinv11.peripheralsplusplus" // http://maven.apache.org/guides/mini/guide-naming-conventions.html -archivesBaseName = "Peripherals++" +archivesBaseName = "Peripherals++" + mcversion minecraft { - version = "1.8.9-11.15.1.1755" + version = "1.8.9-11.15.1.1902-1.8.9" runDir = "run" // the mappings can be changed at any time, and must be in the following format. @@ -33,7 +33,7 @@ minecraft { // stable_# stables are built at the discretion of the MCP team. // Use non-default mappings at your own risk. they may not allways work. // simply re-run your setup task after changing the mappings to update your workspace. - mappings = "stable_20" + mappings = "stable_22" // makeObfSourceJar = false // an Srg named sources jar is made by default. uncomment this to disable. } diff --git a/gradle.properties b/gradle.properties new file mode 100644 index 00000000..ef825b4a --- /dev/null +++ b/gradle.properties @@ -0,0 +1 @@ +mcversion = "1.8.9" \ No newline at end of file diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index 9397848f..845ea664 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,6 +1,6 @@ -#Mon Sep 14 12:28:28 PDT 2015 +#Sat Jul 02 04:03:50 CDT 2016 distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-2.7-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-2.7-all.zip diff --git a/src/main/java/com/austinv11/peripheralsplusplus/tile/TileChatBox.java b/src/main/java/com/austinv11/peripheralsplusplus/tile/TileChatBox.java index fe555670..eddfa77b 100644 --- a/src/main/java/com/austinv11/peripheralsplusplus/tile/TileChatBox.java +++ b/src/main/java/com/austinv11/peripheralsplusplus/tile/TileChatBox.java @@ -11,6 +11,7 @@ import net.minecraft.util.EntityDamageSource; import net.minecraftforge.event.ServerChatEvent; import net.minecraftforge.event.entity.living.LivingDeathEvent; +import net.minecraftforge.event.entity.living.LivingSpawnEvent; import net.minecraftforge.fml.common.eventhandler.SubscribeEvent; import java.util.ArrayList; @@ -36,7 +37,8 @@ public boolean say(Object[] arguments) throws LuaException { String message = (String) arguments[0]; int range = (int) (double) (Double) arguments[1]; - String label = String.format("[%d,%d,%d]", getPos().getX(), getPos().getY(), getPos().getZ()); + String coords = String.format("[%d,%d,%d]", getPos().getX(), getPos().getY(), getPos().getZ()); + String label = "ChatBox"; if (arguments.length > 2) { if (!(arguments[2] instanceof String)) { @@ -44,7 +46,7 @@ public boolean say(Object[] arguments) throws LuaException { } label = (String) arguments[2]; } - sendChatMessageInRange(message, range > Config.chatBoxMaxRange ? Config.chatBoxMaxRange : range, label); + sendChatMessageInRange(message, range > Config.chatBoxMaxRange ? Config.chatBoxMaxRange : range, label, coords); return true; } @@ -59,7 +61,8 @@ public boolean tell(Object[] arguments) throws LuaException { String recipientName = (String) arguments[0]; String message = (String) arguments[1]; - String label = String.format("[%d,%d,%d]", getPos().getX(), getPos().getY(), getPos().getZ()); + String coords = String.format("[%d,%d,%d]", getPos().getX(), getPos().getY(), getPos().getZ()); + String label = "ChatBox"; if (arguments.length > 2) { if (!(arguments[2] instanceof String)) { @@ -68,7 +71,7 @@ public boolean tell(Object[] arguments) throws LuaException { label = (String) arguments[2]; } - String messageWithLabel = label + " " + message; + String messageWithLabel = coords + "[PM] " + label + ": " + message; EntityPlayer recipient = MinecraftServer.getServer().getConfigurationManager().getPlayerByUsername(recipientName); if (recipient != null) { recipient.addChatMessage(new ChatComponentText(messageWithLabel)); @@ -77,8 +80,8 @@ public boolean tell(Object[] arguments) throws LuaException { return false; } - private void sendChatMessageInRange(String message, int range, String label) { - String messageWithLabel = label + " " + message; + private void sendChatMessageInRange(String message, int range, String label, String coords) { + String messageWithLabel = coords + " " + label + ": " + message; List players; if (range >= 0) {