Skip to content

Commit

Permalink
Temporary fix for is_by_ref crashing in Wilds
Browse files Browse the repository at this point in the history
  • Loading branch information
praydog committed Nov 2, 2024
1 parent 2a4e246 commit 294740f
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions shared/sdk/RETypeDefinition.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -704,6 +704,13 @@ bool RETypeDefinition::is_by_ref() const {

static auto by_ref_method = runtime_typedef->get_method("get_IsByRef");

if (by_ref_method == nullptr) {
// well...
// We might need to fix this later for Wilds?
g_by_ref_map[this] = false;
return false;
}

g_by_ref_map[this] = by_ref_method->call<bool>(sdk::get_thread_context(), runtime_type);

return g_by_ref_map[this];
Expand Down

0 comments on commit 294740f

Please sign in to comment.