Godmode Other Permission

This commit is contained in:
PhoenixICE 2015-02-23 09:26:51 +11:00
parent 5b3ff0ed8b
commit 6bb3a2f2ab
2 changed files with 8 additions and 0 deletions

View file

@ -5194,6 +5194,11 @@ namespace TShockAPI
TSPlayer playerToGod;
if (args.Parameters.Count > 0)
{
if (!args.Player.Group.HasPermission(Permissions.godmodeother))
{
args.Player.SendErrorMessage("You do not have permission to god mode another player!");
return;
}
string plStr = String.Join(" ", args.Parameters);
var players = TShock.Utils.FindPlayer(plStr);
if (players.Count == 0)

View file

@ -349,6 +349,9 @@ namespace TShockAPI
[Description("Player recovers health as damage is taken. Can be one shotted.")]
public static readonly string godmode = "tshock.godmode";
[Description("User can godmode other players")]
public static readonly string godmodeother = "tshock.godmode.other";
[Description("Player can chat")]
public static readonly string canchat = "tshock.canchat";