diff --git a/Assets/XLua/Doc/Configure_EN.md b/Assets/XLua/Doc/Configure_EN.md index c4690a481..ae7268e31 100644 --- a/Assets/XLua/Doc/Configure_EN.md +++ b/Assets/XLua/Doc/Configure_EN.md @@ -120,6 +120,9 @@ public static List> BlackList = new List>() { //new List(){ typeof(UnityEngine.GameObject).FullName, "networkView"}, new List(){"System.IO.FileInfo", "GetAccessControl", "System.Security.AccessControl.AccessControlSections"}, //new List(){ typeof(System.IO.FileInfo).FullName, "GetAccessControl",typeof(System.Security.AccessControl.AccessControlSections).FullName }, + + // If you want to blacklist all methods with specific name, use "All" as first parameter type: + new List() { "UnityEngine.Debug", "Log", "All" }, }; ~~~ diff --git a/Assets/XLua/Src/Editor/Generator.cs b/Assets/XLua/Src/Editor/Generator.cs index b20fa1d15..a412a5da3 100644 --- a/Assets/XLua/Src/Editor/Generator.cs +++ b/Assets/XLua/Src/Editor/Generator.cs @@ -566,6 +566,8 @@ static bool isMethodInBlackList(MethodBase mb) { if (mb.DeclaringType.ToString() == exclude[0] && mb.Name == exclude[1]) { + if(exclude.Count == 3 && string.Equals(exclude[2], "All") + return true; // Blacklist all methods with this name; var parameters = mb.GetParameters(); if (parameters.Length != exclude.Count - 2) {