Fixes for pluto update

This commit is contained in:
fed
2023-02-27 01:18:50 +01:00
parent 1d94fdd88d
commit 24b3a9369e
6 changed files with 45 additions and 30 deletions

View File

@ -27,7 +27,7 @@ namespace gsc
{
if (function.second == id)
{
return function.first;
return function.first.data();
}
}
@ -42,7 +42,7 @@ namespace gsc
{
if (function.second == id)
{
return function.first;
return function.first.data();
}
}
@ -251,7 +251,8 @@ namespace gsc
const auto index = function_map_start++;
functions[index] = func;
(*game::plutonium::function_map_rev)[name] = index;
const auto name_view = utils::memory::get_allocator()->duplicate_string(name);
(*game::plutonium::function_map_rev)[name_view] = index;
}
}
@ -262,7 +263,8 @@ namespace gsc
const auto index = method_map_start++;
methods[index] = func;
(*game::plutonium::method_map_rev)[name] = index;
const auto name_view = utils::memory::get_allocator()->duplicate_string(name);
(*game::plutonium::method_map_rev)[name_view] = index;
}
}