| 495 | } |
| 496 | |
| 497 | bool IsValid(const UFunction* Function) |
| 498 | { |
| 499 | if (!Function) |
| 500 | return false; |
| 501 | |
| 502 | if (Function->HasAnyFunctionFlags(FUNC_UbergraphFunction)) |
| 503 | return false; |
| 504 | |
| 505 | // 这个会导致USubsystemBlueprintLibrary.GetWorldSubsystem之类的被过滤掉 |
| 506 | // if (!UEdGraphSchema_K2::CanUserKismetCallFunction(Function)) |
| 507 | // return false; |
| 508 | |
| 509 | const FString Name = Function->GetName(); |
| 510 | if (Name.IsEmpty()) |
| 511 | return false; |
| 512 | |
| 513 | // 避免运行时生成智能提示,把覆写的函数也生成了 |
| 514 | if (Name.EndsWith("__Overridden")) |
| 515 | return false; |
| 516 | |
| 517 | return true; |
| 518 | } |
| 519 | |
| 520 | bool IsValidFunctionName(const FString Name) |
| 521 | { |
no test coverage detected