From 683bc57921a008abd8c656139c43227b64d6ae27 Mon Sep 17 00:00:00 2001 From: Astoria Floyd Date: Fri, 13 Aug 2021 20:30:21 +0000 Subject: [PATCH] Added comments --- API/tools.lua | 2 ++ commands/complexCommands.lua | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/API/tools.lua b/API/tools.lua index 81291ee..3ba9316 100644 --- a/API/tools.lua +++ b/API/tools.lua @@ -125,6 +125,7 @@ function tools.massDetection(folder, filetype) return(result) end +-- Checks fumoFile after running the fumoLine numbering script, to get the number of .gif files there are. function tools.fumoLines() os.execute("/bin/bash API/fumoLines.sh") local file = io.open("./docs/fumoFile", "r") @@ -133,6 +134,7 @@ function tools.fumoLines() return(fumoFile) end +-- Creates a table of every gif in the /fumoGif folder. Uses the fumoList script to get their location, and the fumoLine script to get what line number they are, which is their key function tools.fumoList() local lineList = tools.fumoLines() local fumoList = {} diff --git a/commands/complexCommands.lua b/commands/complexCommands.lua index ceff95d..6d43f58 100644 --- a/commands/complexCommands.lua +++ b/commands/complexCommands.lua @@ -25,7 +25,7 @@ local commands = { -- Define commands its a table that will contain our commands end }; -[prefix..'fumo'] = { -- To be implemented later.. +[prefix..'fumo'] = { -- Posts a random fumo gif from /fumoGif, fully reloads the list of gifs each run exec = function (message) local fumoLines = tools.fumoLines() local fumoList = tools.fumoList()