Implement more map api functions

This commit is contained in:
Marcus Huderle
2020-04-30 18:30:24 -05:00
parent d685718f8d
commit 95012838fd
7 changed files with 295 additions and 66 deletions

View File

@@ -73,3 +73,10 @@ QJSValue Scripting::fromBlock(Block block) {
obj.setProperty("rawValue", block.rawValue());
return obj;
}
QJSValue Scripting::dimensions(int width, int height) {
QJSValue obj = instance->engine->newObject();
obj.setProperty("width", width);
obj.setProperty("height", height);
return obj;
}