Split permission to hurt NPCs
This commit is contained in:
parent
10634c4621
commit
bcebc2efc5
2 changed files with 5 additions and 2 deletions
|
|
@ -3158,9 +3158,9 @@ namespace TShockAPI
|
|||
return true;
|
||||
}
|
||||
|
||||
if (Main.npc[id].townNPC && !args.Player.Group.HasPermission(Permissions.movenpc))
|
||||
if (Main.npc[id].townNPC && !args.Player.Group.HasPermission(Permissions.hurttownnpc))
|
||||
{
|
||||
args.Player.SendMessage( "You don't have permission to move this NPC.", Color.Yellow);
|
||||
args.Player.SendErrorMessage("You do not have permission to hurt this NPC.");
|
||||
args.Player.SendData(PacketTypes.NpcUpdate, "", id);
|
||||
return true;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -170,6 +170,9 @@ namespace TShockAPI
|
|||
[Description("User can start an invasion.")]
|
||||
public static readonly string invade = "tshock.npc.invade";
|
||||
|
||||
[Description("User can hurt town NPCs.")]
|
||||
public static readonly string hurttownnpc = "tshock.npc.hurttown";
|
||||
|
||||
[Description("User can spawn bosses.")]
|
||||
public static readonly string spawnboss = "tshock.npc.spawnboss";
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue