From 4b369ac221d64ed5b6d12710b9e9e4e78f7382e3 Mon Sep 17 00:00:00 2001 From: tommy aka doge <59783653+dowoge@users.noreply.github.com> Date: Sun, 3 Apr 2022 18:48:13 -0400 Subject: [PATCH] a --- .gitignore | 1 - README.md | Bin 912 -> 836 bytes restart.txt | 0 src/modules/commands.lua | 2 ++ 4 files changed, 2 insertions(+), 1 deletion(-) create mode 100644 restart.txt diff --git a/.gitignore b/.gitignore index 2d9e590..80f41b4 100644 --- a/.gitignore +++ b/.gitignore @@ -2,5 +2,4 @@ discordia.log gateway.json apikey.lua token.lua -restart.txt deps \ No newline at end of file diff --git a/README.md b/README.md index e8e7f829835629702c511427bd28285bf7a96b8c..1906b432533ab8299ca81867c7dbde1e2d7df465 100644 GIT binary patch delta 133 zcmbQheuQm85GyYO7lYx%_tKM?3MSVunz(8(lrUs4WHJ;pC@_=*=^P+bU`S#}1(KBv z`3$8DMPPnDP@Mu$E}tPCs45T0E&;N$f$H)YG$*fSR24<=)fqsxB!J+=m(r8}Fdmxx Lj8SCrC8m7<#~UBv delta 246 zcmX9&yA8rH5PePo5)uU^ojW=tP)4AkWr7$IK1u=+HWE~<5ad1BfG!KL0+aCWB1`w~ z-p6;{pdGfG=K^zBG^pUPL%}}as94}m^khyrtH-Hkalw_dC)RX`UmSaN<|v6h*Jq{P zsOR(+T5~cL({!%5HgNQ;j^75JvsG@45te$~nqkkVsFs=>lMx%PEy+LP#~fb2G-k$5 Vl)wxU&*a5AnZ~#2Od5Ui{R5eWF=GG# diff --git a/restart.txt b/restart.txt new file mode 100644 index 0000000..e69de29 diff --git a/src/modules/commands.lua b/src/modules/commands.lua index 2de74f6..0c477e9 100644 --- a/src/modules/commands.lua +++ b/src/modules/commands.lua @@ -1,6 +1,7 @@ local discordia=require('discordia') discordia.extensions() local commands={command_list={}} +_G.init=false setmetatable(commands.command_list,{__index=function(self,index) for i,v in pairs(self) do for i2,v2 in pairs(v.alias) do @@ -28,6 +29,7 @@ function commands:Get(name) end function commands:INIT() -- self.command_list={} + _G.init=true for file in io.popen([[dir "./src/modules/commands" /b]]):lines() do require('./commands/'..file) end print('commands done') end