improved the code
This commit is contained in:
parent
708b455d6b
commit
e7807f6378
1 changed files with 1 additions and 4 deletions
|
|
@ -1603,15 +1603,12 @@ namespace TShockAPI
|
|||
// Why 0.2?
|
||||
// @bartico6: Because heal other player only happens when you are using the spectre armor with the hood,
|
||||
// and the healing you can do with that is 20% of your damage.
|
||||
if (amount >= TShock.Config.Settings.MaxDamage * 0.2)
|
||||
if (amount >= TShock.Config.Settings.MaxDamage * 0.2 && !args.Player.HasPermission(Permissions.ignoredamagecap)
|
||||
{
|
||||
if (!args.Player.HasPermission(Permissions.ignoredamagecap)
|
||||
{
|
||||
TShock.Log.ConsoleDebug("Bouncer / OnHealOtherPlayer 0.2 check from {0}", args.Player.Name);
|
||||
args.Player.Disable("HealOtherPlayer cheat attempt!", DisableFlags.WriteToLogAndConsole);
|
||||
args.Handled = true;
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
if (args.Player.HealOtherThreshold >= TShock.Config.Settings.HealOtherThreshold)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue