Skip to content

Commit

Permalink
Merge pull request #398 from Mr-Auto/fix-get-entity-name
Browse files Browse the repository at this point in the history
Fix get_entity_name
  • Loading branch information
Dregu authored Sep 18, 2024
2 parents d6af083 + 88bda25 commit 5040eb3
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/game_api/script/lua_vm.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1758,7 +1758,7 @@ end
/// Returns STRINGID of the new string
lua["add_string"] = add_string;

/// Get localized name of an entity, pass `fallback_strategy` as `true` to fall back to the `ENT_TYPE.*` enum name
/// Get localized name of an entity from the journal, pass `fallback_strategy` as `true` to fall back to the `ENT_TYPE.*` enum name
/// if the entity has no localized name
lua["get_entity_name"] = [](ENT_TYPE type, sol::optional<bool> fallback_strategy) -> std::u16string
{
Expand Down
6 changes: 3 additions & 3 deletions src/game_api/search.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1582,9 +1582,9 @@ std::unordered_map<std::string_view, AddressRule> g_address_rules{
{
"get_entity_name"sv,
PatternCommandBuffer{}
.find_inst("\x44\x21\xe2\x4c\x8b\x91\x78\x02\x00\x00"sv)
.at_exe()
.function_start(0xff),
.find_after_inst("48 89 F2 66 41 B8 80 00 45 31 C9"_gh)
.decode_call()
.at_exe(),
},
{
"construct_soundmeta"sv,
Expand Down

0 comments on commit 5040eb3

Please sign in to comment.