Created
September 19, 2021 16:56
-
-
Save Zbizu/4ea116c0eddcb5b8ab8824caa5514daf to your computer and use it in GitHub Desktop.
Get current script directory
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--[[ | |
dumps file directory to a console | |
example output: | |
linedefined 0 | |
lastlinedefined 207 | |
source @F:\ot\data\scripts\filename.lua | |
what main | |
short_src ...ot\data\scripts\filename.lua | |
]] | |
local str = debug.getinfo(1,'S') | |
function dumpTable_loop(str) | |
for k, v in pairs(s) do | |
print(k, v) | |
end | |
end | |
addEvent(dumpTable_loop, 3000, str) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment