* Build value based on a UStruct */
| 309 | * Build value based on a UStruct |
| 310 | */ |
| 311 | void FLuaDebugValue::BuildFromUStruct(UStruct *Struct, void *ContainerPtr, UObjectBaseUtility *ContainerObject) |
| 312 | { |
| 313 | if (!Struct || !ContainerPtr) |
| 314 | { |
| 315 | return; |
| 316 | } |
| 317 | |
| 318 | if (ContainerObject && ContainerObject->HasAnyFlags(RF_NeedInitialization)) |
| 319 | { |
| 320 | return; |
| 321 | } |
| 322 | |
| 323 | for (FProperty *Property = Struct->PropertyLink; Property; Property = Property->PropertyLinkNext) |
| 324 | { |
| 325 | // filter out deprecated FProperty |
| 326 | if (Property->HasAnyPropertyFlags(CPF_Deprecated)) |
| 327 | { |
| 328 | continue; |
| 329 | } |
| 330 | |
| 331 | FLuaDebugValue *Key = AddKey(); |
| 332 | if (Key) |
| 333 | { |
| 334 | Key->ReadableValue = Property->GetNameCPP(); |
| 335 | } |
| 336 | FLuaDebugValue *Value = AddValue(); |
| 337 | if (Value) |
| 338 | { |
| 339 | Value->BuildFromUProperty(Property, Property->ContainerPtrToValuePtr<void>(ContainerPtr)); |
| 340 | } |
| 341 | } |
| 342 | } |
| 343 | |
| 344 | /** |
| 345 | * Build value based on a TArray |
nothing calls this directly
no test coverage detected