Fix Kick Message issue, fix health kicks for 600 health, update tsapi

This commit is contained in:
Zack Piispanen 2014-05-10 16:33:55 -04:00
parent c8125af0cc
commit d413b24b22
4 changed files with 4 additions and 4 deletions

View file

@ -1332,7 +1332,7 @@ namespace TShockAPI
if (args.Player.FirstMaxHP == 0)
args.Player.FirstMaxHP = max;
if (cur < 0 || cur > 500 || max < 100 || max > 500) //Abnormal values have the potential to cause infinite loops in the server.
if (cur < 0 || cur > 600 || max < 100 || max > 600) //Abnormal values have the potential to cause infinite loops in the server.
{
TShock.Utils.ForceKick(args.Player, "Crash Exploit Attempt", true);
Log.ConsoleError("HP Exploit Attempt: Current HP {0}, Max HP {0}", cur, max);

View file

@ -33,7 +33,7 @@ namespace TShockAPI.Net
public override void Pack(Stream stream)
{
stream.WriteBytes(Encoding.UTF8.GetBytes(Reason));
stream.WriteString(Reason);
}
}
}

View file

@ -611,7 +611,7 @@ namespace TShockAPI
return true;
}
public void Heal(int health = 500)
public void Heal(int health = 600)
{
NetMessage.SendData((int)PacketTypes.PlayerHealOther, -1, -1, "", this.TPlayer.whoAmi, health);
}

@ -1 +1 @@
Subproject commit 6a869878bdfcd6ab3fb81c5162e98bec94ee3e26
Subproject commit 41473d9c8bfadbd14fca2e917c8299903827eae5