= moved plugins and localization

This commit is contained in:
Matthew Cech
2019-06-19 23:00:21 -07:00
parent 29972ff2fc
commit 091e06e4ff
11 changed files with 28 additions and 25 deletions
@@ -58,4 +58,4 @@ fetch=
crouton=
invite=
@@ -1,19 +1,19 @@
local time = os.time();
function plugin(message, user)
if(string.match(string.lower(message), "purple"))then
local timedif = os.time() - time;
time = os.time();
days = (timedif / (60*60*24));
hours = ((timedif / (60*60)) % 24);
mins = ((timedif / (60)) % 60);
secs = timedif % 60;
return "*GASP!!!* \n" .. user.name .. " said **THE** word! It's been " .. round(days) .. " days, " .. round(hours) .. " hours, " .. round(mins) .. " minutes, and " .. round(secs) .. " seconds since the last time!";
end
return nil;
end
function round(num)
return math.floor(num + 0.5)
local time = os.time();
function plugin(message, user)
if(string.match(string.lower(message), "purple"))then
local timedif = os.time() - time;
time = os.time();
days = (timedif / (60*60*24));
hours = ((timedif / (60*60)) % 24);
mins = ((timedif / (60)) % 60);
secs = timedif % 60;
return "*GASP!!!* \n" .. user.name .. " said **THE** word! It's been " .. round(days) .. " days, " .. round(hours) .. " hours, " .. round(mins) .. " minutes, and " .. round(secs) .. " seconds since the last time!";
end
return nil;
end
function round(num)
return math.floor(num + 0.5)
end
+2 -1
View File
@@ -4,6 +4,7 @@ import java.io.File;
import java.io.IOException;
import javax.imageio.ImageIO;
import core.Command;
import core.Config;
import core.LocStrings;
import dataStructures.KittyChannel;
import dataStructures.KittyGuild;
@@ -53,7 +54,7 @@ public class CommandTeey extends Command
return;
teeyeeFile = new File(yeeteeFilename);
ImageOverlayBuilder builder = new ImageOverlayBuilder("assets/teey/frames/", "teey ", 24, 18);
ImageOverlayBuilder builder = new ImageOverlayBuilder(Config.AssetDirectory + "teey/frames/", "teey ", 24, 18);
builder.overlay(ImageIO.read(teeyeeFile), name);
}
catch (IOException e)
+2 -1
View File
@@ -4,6 +4,7 @@ import java.io.File;
import java.io.IOException;
import javax.imageio.ImageIO;
import core.Command;
import core.Config;
import core.LocStrings;
import dataStructures.KittyChannel;
import dataStructures.KittyGuild;
@@ -53,7 +54,7 @@ public class CommandYeet extends Command
return;
yeeteeFile = new File(yeeteeFilename);
ImageOverlayBuilder builder = new ImageOverlayBuilder("assets/yeet/frames/", "yeet ", 24, 18);
ImageOverlayBuilder builder = new ImageOverlayBuilder(Config.AssetDirectory + "yeet/frames/", "yeet ", 24, 18);
builder.overlay(ImageIO.read(yeeteeFile), name);
}
catch (IOException e)
@@ -29,7 +29,7 @@ public class BenchmarkCommandCompare extends BenchmarkCommand
if(entries.size() < 1)
output += "Couldn't find any models containing `" + inputSplit[i] + "`!";
output += BenchmarkCommandInfo.FormatInfo(entries.get(0));
output += BenchmarkCommandInfo.formatInfo(entries.get(0));
output += lineDelimiter;
if(entries.size() > 1)
@@ -14,7 +14,7 @@ public class BenchmarkCommandInfo extends BenchmarkCommand
{
static final String lineDelimiter = "\n";
public static String FormatInfo(BenchmarkEntry entry)
public static String formatInfo(BenchmarkEntry entry)
{
String output = "";
+1 -1
View File
@@ -492,7 +492,7 @@ public class ObjectBuilderFactory
lazyInit();
if(pluginManager == null)
pluginManager = new PluginManager("./plugins/");
pluginManager = new PluginManager(Config.AssetDirectory + "plugins/");
return pluginManager;
}
+2 -1
View File
@@ -5,6 +5,7 @@ import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
import core.Config;
import dataStructures.Pair;
import utils.io.DirectoryMonitor;
import utils.io.FileUtils;
@@ -16,7 +17,7 @@ import utils.io.MonitoredFile;
public class BenchmarkManager
{
// Variables
public final String directory = "assets/userbench/";
public final String directory = Config.AssetDirectory + "userbench/";
public final String extension = ".csv";
public final String lineDelimiter = "\n";