Merge branch 'general-devel' into user-equatable

This commit is contained in:
Ivan 2017-08-05 21:46:39 +02:00 committed by GitHub
commit a9e1d835b8
10 changed files with 108 additions and 43 deletions

View file

@ -201,8 +201,9 @@ namespace TShockAPI.DB
if (ply.HasPermission(Permissions.usebanneditem))
return true;
if (PlayerHooks.OnPlayerItembanPermission(ply, this))
return true;
PermissionHookResult hookResult = PlayerHooks.OnPlayerItembanPermission(ply, this);
if (hookResult != PermissionHookResult.Unhandled)
return hookResult == PermissionHookResult.Granted;
var cur = ply.Group;
var traversed = new List<Group>();

View file

@ -206,8 +206,9 @@ namespace TShockAPI.DB
if (ply.HasPermission(Permissions.canusebannedprojectiles))
return true;
if (PlayerHooks.OnPlayerProjbanPermission(ply, this))
return true;
PermissionHookResult hookResult = PlayerHooks.OnPlayerProjbanPermission(ply, this);
if (hookResult != PermissionHookResult.Unhandled)
return hookResult == PermissionHookResult.Granted;
var cur = ply.Group;
var traversed = new List<Group>();

View file

@ -206,8 +206,9 @@ namespace TShockAPI.DB
if (ply.HasPermission(Permissions.canusebannedtiles))
return true;
if (PlayerHooks.OnPlayerTilebanPermission(ply, this))
return true;
PermissionHookResult hookResult = PlayerHooks.OnPlayerTilebanPermission(ply, this);
if (hookResult != PermissionHookResult.Unhandled)
return hookResult == PermissionHookResult.Granted;
var cur = ply.Group;
var traversed = new List<Group>();