Index: binary-improvements/AllocsCommands/Commands/BuffPlayer.cs
===================================================================
--- binary-improvements/AllocsCommands/Commands/BuffPlayer.cs	(revision 253)
+++ binary-improvements/AllocsCommands/Commands/BuffPlayer.cs	(revision 253)
@@ -0,0 +1,45 @@
+using System;
+using System.Collections.Generic;
+
+namespace AllocsFixes.CustomCommands
+{
+	public class BuffPlayer : ConsoleCmdAbstract
+	{
+		public override string GetDescription ()
+		{
+			return "Apply a buff to a player";
+		}
+
+		public override string GetHelp () {
+			return "Usage:\n" +
+				   "   buffplayer <player name / steam id / entity id> <buff name>\n" +
+				   "Apply the given buff to the player given by the player name or entity id (as given by e.g. \"lpi\").";
+		}
+
+		public override string[] GetCommands ()
+		{
+			return new string[] { "buffplayer" };
+		}
+
+		public override void Execute (List<string> _params, CommandSenderInfo _senderInfo)
+		{
+			try {
+				if (_params.Count != 2) {
+					SdtdConsole.Instance.Output ("Invalid arguments");
+					return;
+				}
+
+				string buff = _params [1];
+
+				ClientInfo receiver = ConsoleHelper.ParseParamIdOrName (_params [0]);
+				if (receiver != null) {
+					receiver.SendPackage (new NetPackageConsoleCmdClient ("buff " + buff, true));
+				} else {
+					SdtdConsole.Instance.Output ("Playername or entity ID not found.");
+				}
+			} catch (Exception e) {
+				Log.Out ("Error in BuffPlayer.Run: " + e);
+			}
+		}
+	}
+}
Index: binary-improvements/AllocsCommands/Commands/DebuffPlayer.cs
===================================================================
--- binary-improvements/AllocsCommands/Commands/DebuffPlayer.cs	(revision 253)
+++ binary-improvements/AllocsCommands/Commands/DebuffPlayer.cs	(revision 253)
@@ -0,0 +1,45 @@
+using System;
+using System.Collections.Generic;
+
+namespace AllocsFixes.CustomCommands
+{
+	public class DebuffPlayer : ConsoleCmdAbstract
+	{
+		public override string GetDescription ()
+		{
+			return "Remove a buff from a player";
+		}
+
+		public override string GetHelp () {
+			return "Usage:\n" +
+				   "   debuffplayer <player name / steam id / entity id> <buff name>\n" +
+				   "Remove the given buff from the player given by the player name or entity id (as given by e.g. \"lpi\").";
+		}
+
+		public override string[] GetCommands ()
+		{
+			return new string[] { "debuffplayer" };
+		}
+
+		public override void Execute (List<string> _params, CommandSenderInfo _senderInfo)
+		{
+			try {
+				if (_params.Count != 2) {
+					SdtdConsole.Instance.Output ("Invalid arguments");
+					return;
+				}
+
+				string buff = _params [1];
+
+				ClientInfo receiver = ConsoleHelper.ParseParamIdOrName (_params [0]);
+				if (receiver != null) {
+					receiver.SendPackage (new NetPackageConsoleCmdClient ("debuff " + buff, true));
+				} else {
+					SdtdConsole.Instance.Output ("Playername or entity ID not found.");
+				}
+			} catch (Exception e) {
+				Log.Out ("Error in DebuffPlayer.Run: " + e);
+			}
+		}
+	}
+}
Index: binary-improvements/AllocsCommands/Commands/ListLandProtection.cs
===================================================================
--- binary-improvements/AllocsCommands/Commands/ListLandProtection.cs	(revision 251)
+++ binary-improvements/AllocsCommands/Commands/ListLandProtection.cs	(revision 253)
@@ -86,31 +86,27 @@
 				}
 
-				Dictionary<Vector3i, PersistentPlayerData> d = ppl.m_lpBlockMap;
-				if (d != null) {
-					Dictionary<PersistentPlayerData, List<Vector3i>> owners = new Dictionary<PersistentPlayerData, List<Vector3i>> ();
-					foreach (KeyValuePair<Vector3i, PersistentPlayerData> kvp in d) {
-						if (!onlyCloseToPlayer || (Math.Abs (kvp.Key.x - closeTo.x) <= closeToDistance && Math.Abs (kvp.Key.z - closeTo.z) <= closeToDistance)) {
-							if (!owners.ContainsKey (kvp.Value)) {
-								owners.Add (kvp.Value, new List<Vector3i> ());
-							}
-							owners [kvp.Value].Add (kvp.Key);
-						}
-					}
 
-					foreach (KeyValuePair<PersistentPlayerData, List<Vector3i>> kvp in owners) {
-						if (steamIdFilter.Length == 0 || kvp.Key.PlayerId.Equals (steamIdFilter)) {
-							PersistentData.Player p = PersistentData.PersistentContainer.Instance.Players [kvp.Key.PlayerId, false];
-							string name = string.Empty;
-							if (p != null) {
-								name = p.Name;
-							}
-							name += " (" + kvp.Key.PlayerId + ")";
+				LandClaimList.OwnerFilter[] ownerFilters = null;
+				if (!string.IsNullOrEmpty (steamIdFilter)) {
+					ownerFilters = new LandClaimList.OwnerFilter[] { LandClaimList.SteamIdFilter (steamIdFilter) };
+				}
+				LandClaimList.PositionFilter[] posFilters = null;
+				if (onlyCloseToPlayer) {
+					posFilters = new LandClaimList.PositionFilter[] { LandClaimList.CloseToFilter2dRect (closeTo, closeToDistance) };
+				}
 
-							SdtdConsole.Instance.Output (String.Format ("Player \"{0}\" owns {3} keystones (protected: {1}, current hardness multiplier: {2})", name, w.IsLandProtectionValidForPlayer (kvp.Key), w.GetLandProtectionHardnessModifierForPlayer (kvp.Key), kvp.Value.Count));
-							if (!summaryOnly) {
-								foreach (Vector3i v in kvp.Value) {
-									SdtdConsole.Instance.Output ("   (" + v.ToString () + ")");
-								}
-							}
+				Dictionary<PersistentData.Player, List<Vector3i>> claims = LandClaimList.GetLandClaims (ownerFilters, posFilters);
+
+				foreach (KeyValuePair<PersistentData.Player, List<Vector3i>> kvp in claims) {
+					SdtdConsole.Instance.Output (String.Format (
+						"Player \"{0} ({1})\" owns {4} keystones (protected: {2}, current hardness multiplier: {3})",
+						kvp.Key.Name,
+						kvp.Key.SteamID,
+						kvp.Key.LandProtectionActive,
+						kvp.Key.LandProtectionMultiplier,
+						kvp.Value.Count));
+					if (!summaryOnly) {
+						foreach (Vector3i v in kvp.Value) {
+							SdtdConsole.Instance.Output ("   (" + v.ToString () + ")");
 						}
 					}
@@ -118,5 +114,5 @@
 
 				if (steamIdFilter.Length == 0)
-					SdtdConsole.Instance.Output ("Total of " + d.Count + " keystones in the game");
+					SdtdConsole.Instance.Output ("Total of " + ppl.m_lpBlockMap.Count + " keystones in the game");
 			} catch (Exception e) {
 				Log.Out ("Error in ListLandProtection.Run: " + e);
Index: binary-improvements/AllocsCommands/Commands/RemoveLandProtection.cs
===================================================================
--- binary-improvements/AllocsCommands/Commands/RemoveLandProtection.cs	(revision 251)
+++ binary-improvements/AllocsCommands/Commands/RemoveLandProtection.cs	(revision 253)
@@ -40,5 +40,5 @@
 				List<BlockChangeInfo> changes = new List<BlockChangeInfo> ();
 				foreach (Vector3i pos in ppl.Players[_id].LPBlocks) {
-					BlockChangeInfo bci = new BlockChangeInfo (pos, 0, true);
+					BlockChangeInfo bci = new BlockChangeInfo (pos, new BlockValue (0), true);
 					changes.Add (bci);
 				}
@@ -79,5 +79,5 @@
 				}
 
-				BlockChangeInfo bci = new BlockChangeInfo (v, 0, true);
+				BlockChangeInfo bci = new BlockChangeInfo (v, new BlockValue (0), true);
 
 				List<BlockChangeInfo> changes = new List<BlockChangeInfo> ();
Index: binary-improvements/AllocsCommands/Commands/ShowInventory.cs
===================================================================
--- binary-improvements/AllocsCommands/Commands/ShowInventory.cs	(revision 251)
+++ binary-improvements/AllocsCommands/Commands/ShowInventory.cs	(revision 253)
@@ -6,4 +6,5 @@
 {
 	public class ShowInventory : ConsoleCmdAbstract {
+
 		public override string GetDescription () {
 			return "list inventory of a given player";
@@ -69,29 +70,33 @@
 
 		private void PrintEquipment (InvItem[] _equipment) {
-			AddEquipment ("head", _equipment, XMLData.Item.EnumEquipmentSlot.Head, NGuiInvGridEquipment.EnumClothingLayer.Middle);
-			AddEquipment ("eyes", _equipment, XMLData.Item.EnumEquipmentSlot.Eyes, NGuiInvGridEquipment.EnumClothingLayer.Middle);
-			AddEquipment ("face", _equipment, XMLData.Item.EnumEquipmentSlot.Face, NGuiInvGridEquipment.EnumClothingLayer.Middle);
+			AddEquipment ("head", _equipment, EquipmentSlots.Headgear);
+			AddEquipment ("eyes", _equipment, EquipmentSlots.Eyewear);
+			AddEquipment ("face", _equipment, EquipmentSlots.Face);
 
-			AddEquipment ("armor", _equipment, XMLData.Item.EnumEquipmentSlot.Chest, NGuiInvGridEquipment.EnumClothingLayer.Outer);
-			AddEquipment ("jacket", _equipment, XMLData.Item.EnumEquipmentSlot.Chest, NGuiInvGridEquipment.EnumClothingLayer.Middle);
-			AddEquipment ("shirt", _equipment, XMLData.Item.EnumEquipmentSlot.Chest, NGuiInvGridEquipment.EnumClothingLayer.Inner);
+			AddEquipment ("armor", _equipment, EquipmentSlots.ChestArmor);
+			AddEquipment ("jacket", _equipment, EquipmentSlots.Jacket);
+			AddEquipment ("shirt", _equipment, EquipmentSlots.Shirt);
 
-			AddEquipment ("legarmor", _equipment, XMLData.Item.EnumEquipmentSlot.Legs, NGuiInvGridEquipment.EnumClothingLayer.Outer);
-			AddEquipment ("pants", _equipment, XMLData.Item.EnumEquipmentSlot.Legs, NGuiInvGridEquipment.EnumClothingLayer.Inner);
-			AddEquipment ("boots", _equipment, XMLData.Item.EnumEquipmentSlot.Feet, NGuiInvGridEquipment.EnumClothingLayer.Inner);
+			AddEquipment ("legarmor", _equipment, EquipmentSlots.LegArmor);
+			AddEquipment ("pants", _equipment, EquipmentSlots.Legs);
+			AddEquipment ("boots", _equipment, EquipmentSlots.Feet);
 
-			AddEquipment ("gloves", _equipment, XMLData.Item.EnumEquipmentSlot.Hands, NGuiInvGridEquipment.EnumClothingLayer.Inner);
-			AddEquipment ("backpack", _equipment, XMLData.Item.EnumEquipmentSlot.Back, NGuiInvGridEquipment.EnumClothingLayer.Outer);
+			AddEquipment ("gloves", _equipment, EquipmentSlots.Hands);
 		}
 
-		private void AddEquipment (string _slotname, InvItem[] _items, XMLData.Item.EnumEquipmentSlot _slot, NGuiInvGridEquipment.EnumClothingLayer _layer) {
-			int index = (int)_slot + (int)_layer * (int)XMLData.Item.EnumEquipmentSlot.Count;
-			if (_items != null && _items [index] != null) {
-				if (_items [index].quality < 0) {
-					SdtdConsole.Instance.Output (string.Format ("    Slot {0:8}: {1:000}", _slotname, _items [index].itemName));
-				} else {
-					SdtdConsole.Instance.Output (string.Format ("    Slot {0:8}: {1:000} - quality: {2}", _slotname, _items [index].itemName, _items [index].quality));
+		private void AddEquipment (string _slotname, InvItem[] _items, EquipmentSlots _slot) {
+			int[] slotindices = XUiM_PlayerEquipment.GetSlotIndicesByEquipmentSlot (_slot);
+
+			for (int i = 0; i < slotindices.Length; i++) {
+				if (_items != null && _items [slotindices [i]] != null) {
+					InvItem item = _items [slotindices [i]];
+					if (item.quality < 0) {
+						SdtdConsole.Instance.Output (string.Format ("    Slot {0:8}: {1:000}", _slotname, item.itemName));
+					} else {
+						SdtdConsole.Instance.Output (string.Format ("    Slot {0:8}: {1:000} - quality: {2}", _slotname, item.itemName, item.quality));
+					}
+					DoParts (_items [slotindices [i]].parts, 1);
+					return;
 				}
-				DoParts (_items [index].parts, 1);
 			}
 		}
Index: binary-improvements/AllocsCommands/Commands/TeleportPlayer.cs
===================================================================
--- binary-improvements/AllocsCommands/Commands/TeleportPlayer.cs	(revision 251)
+++ binary-improvements/AllocsCommands/Commands/TeleportPlayer.cs	(revision 253)
@@ -16,5 +16,5 @@
 				"  3. teleportplayer <inc x> <inc y> <inc z>\n" +
 				"1. Teleports the player given by his SteamID, player name or entity id (as given by e.g. \"lpi\")\n" +
-				"   to the specified location\n" +
+				"   to the specified location. Use y = -1 to spawn on ground.\n" +
 				"2. As 1, but destination given by another player which has to be online\n" +
 				"3. Teleport the local player to the position calculated by his current position and the given offsets";
@@ -33,4 +33,5 @@
 					ClientInfo ci1 = null;
 					EntityPlayer ep1 = null;
+					UnityEngine.Vector3 destPos;
  
 					if (_params.Count == 2 || _params.Count == 4) {
@@ -56,7 +57,7 @@
 							}
 
-							ep1.position.x = x;
-							ep1.position.y = y;
-							ep1.position.z = z;
+							destPos.x = x;
+							destPos.y = y;
+							destPos.z = z;
 						} else if (_params.Count == 2) {
 							ClientInfo ci2 = ConsoleHelper.ParseParamIdOrName (_params [1]);
@@ -67,11 +68,11 @@
 							EntityPlayer ep2 = GameManager.Instance.World.Players.dict [ci2.entityId];
 
-							ep1.position = ep2.GetPosition ();
-							ep1.position.y += 1;
-							ep1.position.z += 1;
+							destPos = ep2.GetPosition ();
+							destPos.y += 1;
+							destPos.z += 1;
 						}
 					} else if (_params.Count == 3) {
 						if (_senderInfo.RemoteClientInfo == null) {
-							SdtdConsole.Instance.Output ("This command can only be executed on the in-game console.");
+							SdtdConsole.Instance.Output ("This command can only be executed in variant 3 on the in-game console.");
 							return;
 						}
@@ -93,10 +94,10 @@
 						}
 
-						ep1.position.x = ep1.position.x + x;
-						ep1.position.y = ep1.position.y + y;
-						ep1.position.z = ep1.position.z + z;
+						destPos.x = ep1.position.x + x;
+						destPos.y = ep1.position.y + y;
+						destPos.z = ep1.position.z + z;
 					}
 
-					NetPackageEntityTeleport pkg = new NetPackageEntityTeleport (ep1);
+					NetPackageTeleportPlayer pkg = new NetPackageTeleportPlayer (destPos);
 
 					ci1.SendPackage (pkg);
