Open subsoap opened 7 years ago
I have a file api_ext.lua
function sprite.play_animation(url, animation) msg.post(url, "play_animation", {id = hash(animation)}) end
In a script I have
require("defrs.utils.api_ext") function init(self) sprite.play_animation("#sprite", "character_zombie") end
If I type sprite. I am not shown sprite.play_animation() as an option.
If I instead do
local sprite_ext = require("defrs.utils.api_ext") function init(self) sprite.play_animation("#sprite", "character_zombie") sprite_ext. end
I can then see the function in autocomplete
I don't want to overwrite only extend and keep autocomplete working.
@erikangelin-king maybe need to add “text-editor” label?
I have a file api_ext.lua
In a script I have
If I type sprite. I am not shown sprite.play_animation() as an option.
If I instead do
I can then see the function in autocomplete
I don't want to overwrite only extend and keep autocomplete working.