diff options
Diffstat (limited to 'source/game/scripting/StarWorldLuaBindings.cpp')
-rw-r--r-- | source/game/scripting/StarWorldLuaBindings.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/source/game/scripting/StarWorldLuaBindings.cpp b/source/game/scripting/StarWorldLuaBindings.cpp index 13be5ee..ba4322d 100644 --- a/source/game/scripting/StarWorldLuaBindings.cpp +++ b/source/game/scripting/StarWorldLuaBindings.cpp @@ -539,6 +539,11 @@ namespace LuaBindings { return entity->isInteractive(); return {}; }); + callbacks.registerCallback("entityAimPosition", [world](EntityId entityId) -> Maybe<Vec2F> { + if (auto entity = world->get<ToolUserEntity>(entityId)) + return entity->aimPosition(); + return {}; + }); callbacks.registerCallback("entityMouthPosition", [world](EntityId entityId) -> Maybe<Vec2F> { if (auto entity = world->get<ChattyEntity>(entityId)) return entity->mouthPosition(); |