mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-04 18:41:51 +00:00
ui: more xml support + hud.close function
This commit is contained in:
parent
e58624d3e8
commit
d8b3920d65
5 changed files with 50 additions and 2 deletions
|
|
@ -60,6 +60,21 @@ doubleconsumer scripting::create_number_consumer(
|
|||
};
|
||||
}
|
||||
|
||||
doublesupplier scripting::create_number_supplier(
|
||||
int env,
|
||||
const std::string& src,
|
||||
const std::string& file
|
||||
) {
|
||||
return [=](){
|
||||
if (processCallback(env, src, file)) {
|
||||
state->callNoThrow(0);
|
||||
lua::luanumber x = state->tonumber(-1); state->pop();
|
||||
return x;
|
||||
}
|
||||
return 0.0;
|
||||
};
|
||||
}
|
||||
|
||||
int_array_consumer scripting::create_int_array_consumer(
|
||||
int env,
|
||||
const std::string& src,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue