Skip to content

Commit

Permalink
UObjectHook: Display out parameters
Browse files Browse the repository at this point in the history
  • Loading branch information
praydog committed Oct 9, 2024
1 parent 378cbfd commit 49a276a
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion src/mods/UObjectHook.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3175,7 +3175,17 @@ void UObjectHook::ui_handle_functions(void* object, sdk::UStruct* uclass) {
}

for (auto param = parameters; param != nullptr; param = param->get_next()) {
ImGui::Text("%s %s", utility::narrow(param->get_class()->get_name().to_string()), utility::narrow(param->get_field_name().to_string()).data());
const auto cname = utility::narrow(param->get_class()->get_name().to_string());
ImGui::Text("%s %s", cname.data(), utility::narrow(param->get_field_name().to_string()).data());

if (cname.contains("Property")) {
const auto prop = (sdk::FProperty*)param;

if (prop->is_out_param()) {
ImGui::SameLine();
ImGui::TextColored(ImVec4{0.0f, 1.0f, 0.0f, 1.0f}, "[Out]");
}
}
}

ImGui::TreePop();
Expand Down

0 comments on commit 49a276a

Please sign in to comment.