Skip to content

Commit

Permalink
remove useless cast
Browse files Browse the repository at this point in the history
  • Loading branch information
Yangff committed Feb 19, 2024
1 parent 1741ceb commit 80ee5b4
Show file tree
Hide file tree
Showing 8 changed files with 10 additions and 10 deletions.
2 changes: 1 addition & 1 deletion UE4SS/src/GUI/BPMods.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ namespace RC::GUI::BPMods
const auto& mod_button = mod_info.ModButtons[i2];
if (ImGui::Button(std::format("{}", mod_button).c_str()))
{
Output::send(SYSSTR("Mod button {} hit.\n"), to_system(mod_button));
Output::send(SYSSTR("Mod button {} hit.\n"), mod_button);
mod_info.ModActor->ModMenuButtonPressed(static_cast<int32_t>(i2));
}
}
Expand Down
2 changes: 1 addition & 1 deletion UE4SS/src/GUI/LiveView.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2844,7 +2844,7 @@ namespace RC::GUI
}
else
{
Output::send(SYSSTR("Search for: {}\n"), search_buffer.empty() ? STR("") : to_wstring(search_buffer));
Output::send(SYSSTR("Search for: {}\n"), search_buffer.empty() ? SYSSTR("") : search_buffer);
s_name_to_search_by = search_buffer;
m_object_iterator = &LiveView::guobjectarray_by_name_iterator;
m_is_searching_by_name = true;
Expand Down
2 changes: 1 addition & 1 deletion UE4SS/src/LuaLibrary.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ namespace RC::LuaLibrary
// Logging will only happen to the debug console but it's something at least
if (!Output::has_internal_error())
{
Output::send(SYSSTR("Error: {}\n"), to_system(e));
Output::send(SYSSTR("Error: {}\n"), e);
}
else
{
Expand Down
6 changes: 3 additions & 3 deletions UE4SS/src/Mod/LuaMod.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1151,7 +1151,7 @@ No overload found for function 'RegisterKeyBindAsync'.
}
catch (std::runtime_error& e)
{
Output::send(SYSSTR("{}\n"), to_system(lua.handle_error(e.what())));
Output::send(SYSSTR("{}\n"), lua.handle_error(e.what()));
}
};

Expand Down Expand Up @@ -1270,7 +1270,7 @@ No overload found for function 'RegisterKeyBind'.
}
catch (std::runtime_error& e)
{
Output::send(SYSSTR("{}\n"), to_system(lua.handle_error(e.what())));
Output::send(SYSSTR("{}\n"), lua.handle_error(e.what()));
}
};

Expand Down Expand Up @@ -3801,7 +3801,7 @@ No overload found for function 'FPackageName:IsValidLongPackageName'.
}
catch (std::runtime_error& e)
{
Output::send(SYSSTR("{}\n"), to_system(e.what()));
Output::send(SYSSTR("{}\n"), e.what());
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion UE4SS/src/SDKGenerator/TMapOverrideGen.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ namespace RC::UEGenerator
{
continue;
}
Output::send(SYSSTR("Found Relevant TMap Property: {} in Class: {}\n"), property_name, to_system(object->GetName()));
Output::send(SYSSTR("Found Relevant TMap Property: {} in Class: {}\n"), property_name, object->GetName());

auto& fm_json_object = fm_object.new_object(property_name);
auto& uaapi_array = uaapi_object.new_array(property_name);
Expand Down
2 changes: 1 addition & 1 deletion UE4SS/src/UE4SSProgram.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ namespace RC
#define OUTPUT_MEMBER_OFFSETS_FOR_STRUCT(StructName) \
for (const auto& [name, offset] : Unreal::StructName::MemberOffsets) \
{ \
Output::send(SYSSTR(#StructName "::{} = 0x{:X}\n"), to_system(name), offset); \
Output::send(SYSSTR(#StructName "::{} = 0x{:X}\n"), name, offset); \
}

auto output_all_member_offsets() -> void
Expand Down
2 changes: 1 addition & 1 deletion UVTD/src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ auto thread_dll_start([[maybe_unused]] LPVOID thread_param) -> unsigned long
}
catch (std::exception& e)
{
Output::send(SYSSTR("Exception caught: {}\n"), to_wstring(e.what()));
Output::send(SYSSTR("Exception caught: {}\n"), e.what());
}

return 0;
Expand Down
2 changes: 1 addition & 1 deletion deps/first/Unreal

0 comments on commit 80ee5b4

Please sign in to comment.