fix build

This commit is contained in:
m 2022-10-04 21:18:43 -05:00
parent 60cf2c2b30
commit 873cdebaf5

View File

@ -16,14 +16,6 @@ namespace scripting
return value_ptr;
}
void push_value(const script_value& value)
{
auto* value_ptr = allocate_argument();
*value_ptr = value.get_raw();
game::AddRefToValue(value_ptr->type, value_ptr->u);
}
int get_field_id(const int classnum, const std::string& field)
{
if (scripting::fields_table[classnum].find(field) != scripting::fields_table[classnum].end())
@ -49,6 +41,14 @@ namespace scripting
}
}
void push_value(const script_value& value)
{
auto* value_ptr = allocate_argument();
*value_ptr = value.get_raw();
game::AddRefToValue(value_ptr->type, value_ptr->u);
}
void notify(const entity& entity, const std::string& event, const std::vector<script_value>& arguments)
{
stack_isolation _;
@ -110,7 +110,7 @@ namespace scripting
stack_isolation _;
for (auto i = arguments.rbegin(); i != arguments.rend(); ++i)
{
scripting::push_value(*i);
push_value(*i);
}
game::AddRefToObject(id);