Add support for our updated HeroicDeath jar (hopefully someone will take

over support for heroic Death now it's updated).
This commit is contained in:
ElgarL committed 2012-02-03 00:55:09 +00:00
1 parent 50474cbe2f
commit 5558470cdc
4 files changed
+30 -3

No files matched your search

+1
View File
@@ -9,5 +9,6 @@
<classpathentry kind="lib" path="../lib/CraftIRC.jar"/>
<classpathentry kind="lib" path="../lib/dynmap-api.jar"/>
<classpathentry combineaccessrules="false" kind="src" path="/Towny"/>
<classpathentry kind="lib" path="C:/Users/Steve/git/lib/HeroicDeath.jar"/>
<classpathentry kind="output" path="bin"/>
</classpath>
+2 -1
View File
@@ -88,4 +88,5 @@ v0.16:
v0.17:
- If a player has no permissions for any channel but we are still set to modify chat, remove the channelTag and msgcolour entries.
- Fix Spam timer to work in milliseconds so values of 0.5 actually work.
- Fix craftIRC hook to not spam console with an invalid number format error if the wrong version is detected.
- Fix craftIRC hook to not spam console with an invalid number format error if the wrong version is detected.
- Add support for our updated HeroicDeath jar (hopefully someone will take over support for heroic Death now it's updated).
+26 -1
View File
@@ -14,6 +14,7 @@ import com.palmergames.bukkit.TownyChat.CraftIRCHandler;
import com.palmergames.bukkit.TownyChat.Command.TownyChatCommand;
import com.palmergames.bukkit.TownyChat.channels.ChannelsHolder;
import com.palmergames.bukkit.TownyChat.config.ConfigurationHandler;
import com.palmergames.bukkit.TownyChat.event.HeroicDeathForwarder;
import com.palmergames.bukkit.TownyChat.event.TownyPlayerHighestListener;
import com.palmergames.bukkit.TownyChat.tasks.onLoadedTask;
import com.palmergames.bukkit.TownyChat.util.FileMgmt;
@@ -40,6 +41,8 @@ public class Chat extends JavaPlugin {
private DynmapAPI dynMap = null;
private CraftIRCHandler irc = null;
private HeroicDeathForwarder heroicDeathListener = null;
@Override
public void onEnable() {
@@ -80,6 +83,10 @@ public class Chat extends JavaPlugin {
public void onDisable() {
unregisterPermissions();
// reset any handles
irc = null;
craftIRC = null;
dynMap = null;
heroicDeathListener= null;
towny = null;
pm = null;
logger = null;
@@ -91,7 +98,9 @@ public class Chat extends JavaPlugin {
test = pm.getPlugin("Towny");
if (test != null && test instanceof Towny)
towny = (Towny) test;
/**
* Hook craftIRC
*/
test = pm.getPlugin("CraftIRC");
if (test != null) {
try {
@@ -105,6 +114,17 @@ public class Chat extends JavaPlugin {
}
}
/**
* If we found craftIRC check for HeroicDeath
*/
if (irc != null) {
test = pm.getPlugin("HeroicDeath");
if (test != null) {
heroicDeathListener = new HeroicDeathForwarder(irc);
logger.info("[TownyChat] Found and attempting to relay Heroic Death messages to craftIRC.");
}
}
test = pm.getPlugin("dynmap");
if (test != null) {
dynMap = (DynmapAPI) test;
@@ -116,6 +136,7 @@ public class Chat extends JavaPlugin {
TownyPlayerListener = new TownyPlayerHighestListener(this, irc, dynMap);
pm.registerEvents(TownyPlayerListener, this);
pm.registerEvents(heroicDeathListener, this);
}
@@ -164,4 +185,8 @@ public class Chat extends JavaPlugin {
return towny;
}
public HeroicDeathForwarder getHeroicDeath() {
return heroicDeathListener;
}
}
+1 -1
View File
@@ -1,6 +1,6 @@
name: TownyChat
main: com.palmergames.bukkit.TownyChat.Chat
version: 0.17
version: 0.18
author: ElgarL, Shade
website: http://code.google.com/a/eclipselabs.org/p/towny/
description: >