Lots of work on look-at widgets

This commit is contained in:
2025-04-07 16:48:27 -04:00
parent e81134473e
commit d35125eb70
24 changed files with 554 additions and 379 deletions

View File

@@ -417,7 +417,7 @@ eng::string World::probe_lua_expr(int64_t actor_id, std::string_view lua) {
return result;
}
void World::probe_lua_call(int64_t place_id, int64_t actor_id, std::string_view datapack, StreamBuffer *retvals) {
void World::probe_lua_call(int64_t actor_id, int64_t place_id, std::string_view datapack, StreamBuffer *retvals) {
assert(stack_is_clear());
lua_State *L = state();

View File

@@ -249,7 +249,7 @@ public:
// Print statements are discarded. The lua function may return a vector
// of values. If so, the values are packed into a StreamBuffer.
//
void probe_lua_call(int64_t place_id, int64_t actor_id, std::string_view datapack, StreamBuffer *retvals);
void probe_lua_call(int64_t actor_id, int64_t place_id, std::string_view datapack, StreamBuffer *retvals);
// Invoke an Invocation object.
//

View File

@@ -18,11 +18,17 @@ function engio.move(action, xyz, facing)
tangible.animate(actor, nil, {action=action, xyz=xyz, facing=facing})
end
function engio.printhi(a1, a2, a3, a4, a5)
pprint("Hi there", a1, a2, a3, a4, a5)
function cube.getlookat()
return { "Hotkeys", "X", "I Am a Cube" }
end
function engio.retmany()
return 7, vec(8,9,10), "Yo", "Banana", 13.2, vec(2,3,4), "Hi"
function sphere.getlookat()
return { "Hotkeys", "X", "I Am a Sphere" }
end
function engio.getlookat()
local place = tangible.place()
local class = tangible.getclass(place)
return class.getlookat()
end