Data storage token

keep-around/d31701866686f66088b78de2e29736ae36e55a68
Pingex aka Raphaël 9 years ago
parent d4785ade27
commit 6d9f31f592

@ -4,6 +4,9 @@ general.bot_name = DCF Bot
# Plugins directory location
general.plugins_dir = plugins
# Data storage location
general.storage_dir = data
# Initial connection token...
discord.token = tokenGoesHere

@ -84,6 +84,11 @@ public class Configuration
*/
public static String PLUGINS_DIR = "plugins";
/**
* Data storage directory
*/
public static String DATA_DIR = "data";
/**
* Tells if the bot is configured to connect using a token or an username/password tuple.
* @return Whether the main connection is a bot, or not
@ -99,7 +104,8 @@ public class Configuration
public static void init()
{
BOT_NAME = store.getString("general.bot_name", BOT_NAME);
PLUGINS_DIR = store.getString("generel.plugins_dir", PLUGINS_DIR);
PLUGINS_DIR = store.getString("general.plugins_dir", PLUGINS_DIR);
DATA_DIR = store.getString("general.storage_dir", DATA_DIR);
// Validate main connection username/password or token
if(isConnectionToken())