AppModel/C++/JSON/Script: Don't output generic method definitions (no compiled code)
This commit is contained in:
@@ -163,7 +163,7 @@ typedef size_t uintptr_t;
|
||||
writeCode("using namespace app;");
|
||||
writeLine("");
|
||||
|
||||
foreach (var method in model.Methods.Values) {
|
||||
foreach (var method in model.Methods.Values.Where(m => m.HasCompiledCode)) {
|
||||
var arguments = string.Join(", ", method.CppFnPtrType.Arguments.Select(a => a.Type.Name + " " + (a.Name == "this" ? "__this" : a.Name)));
|
||||
writeCode($"DO_APP_FUNC(0x{method.MethodCodeAddress - model.Package.BinaryImage.ImageBase:X8}, {method.CppFnPtrType.ReturnType.Name}, "
|
||||
+ $"{method.CppFnPtrType.Name}, ({arguments}));");
|
||||
|
||||
@@ -64,7 +64,7 @@ namespace Il2CppInspector.Outputs
|
||||
}
|
||||
|
||||
private void writeMethods(IEnumerable<AppMethod> methods) {
|
||||
foreach (var method in methods) {
|
||||
foreach (var method in methods.Where(m => m.HasCompiledCode)) {
|
||||
writeObject(() => {
|
||||
writeTypedFunctionName(method.MethodCodeAddress, method.CppFnPtrType.ToSignatureString(), method.CppFnPtrType.Name);
|
||||
writeDotNetSignature(method.Method);
|
||||
@@ -123,7 +123,7 @@ namespace Il2CppInspector.Outputs
|
||||
// Metedata usage methods
|
||||
writeArray("methodInfoPointers",
|
||||
() => {
|
||||
foreach (var method in model.Methods.Values.Where(m => m.MethodInfoPtrAddress != 0xffffffff_ffffffff)) {
|
||||
foreach (var method in model.Methods.Values.Where(m => m.HasMethodInfo)) {
|
||||
writeObject(() => {
|
||||
writeName(method.MethodInfoPtrAddress, $"{method.CppFnPtrType.Name}__MethodInfo");
|
||||
writeDotNetSignature(method.Method);
|
||||
|
||||
Reference in New Issue
Block a user