Permalink
Browse files

v1.0.1.88 - allow giving/taking food for pvp killing

  • Loading branch information...
1 parent 950e997 commit 240ea4063c2127f9b71894ba075b53c723773a64 @slipcor committed Mar 23, 2013
Showing with 8 additions and 0 deletions.
  1. +1 −0 README.creole
  2. +6 −0 src/net/slipcor/pvparena/classes/PACheck.java
  3. +1 −0 src/net/slipcor/pvparena/core/Config.java
View
@@ -45,6 +45,7 @@ A PVP experience enhancing plugin.
=== Changelog
+* v1.0.1.88 - allow giving/taking food for pvp killing
* v1.0.1.87 - add /pa [arena] shutup - disables arena announcements
* v1.0.1.86 - repair tools when breaking blocks
* v1.0.1.85 - pro tip: when altering the Config, save it!
@@ -415,6 +415,12 @@ public static void handlePlayerDeath(final Arena arena, final Player player, fin
StatisticsManager.kill(arena, player.getKiller(), player, doesRespawn);
event.setDeathMessage(null);
+ if (player.getKiller() != null) {
+ player.getKiller().setFoodLevel(
+ player.getKiller().getFoodLevel() +
+ arena.getArenaConfig().getInt(CFG.PLAYER_FEEDFORKILL));
+ }
+
if (!arena.getArenaConfig().getBoolean(CFG.PLAYER_DROPSINVENTORY)) {
DEBUG.i("don't drop inventory", player);
event.getDrops().clear();
@@ -102,6 +102,7 @@
PLAYER_AUTOIGNITE("player.autoIgniteTNT", false),
PLAYER_DROPSINVENTORY("player.dropsInventory", false),
PLAYER_EXHAUSTION("player.exhaustion", 0.0),
+ PLAYER_FEEDFORKILL("player.hungerforkill", 0),
PLAYER_FOODLEVEL("player.foodLevel", 20),
PLAYER_HEALTH("player.health", 20),
PLAYER_PREVENTDEATH("player.preventDeath", true),

0 comments on commit 240ea40

Please sign in to comment.