1
0
mirror of https://github.com/essentials/Essentials.git synced 2025-08-22 06:12:56 +02:00

Essentials should run now...

This commit is contained in:
snowleo
2012-01-10 01:02:23 +01:00
parent d64c73fc51
commit 703c5741bd
3 changed files with 9 additions and 4 deletions

View File

@@ -27,7 +27,7 @@ public class Kits extends AsyncStorageObjectHolder<com.earth2me.essentials.setti
@Override @Override
public File getStorageFile() throws IOException public File getStorageFile() throws IOException
{ {
throw new UnsupportedOperationException("Not supported yet."); return new File(ess.getDataFolder(), "kits.yml");
} }
@Override @Override

View File

@@ -141,6 +141,10 @@ public abstract class AsyncStorageObjectHolder<T extends StorageObject> implemen
public File onStart() throws IOException public File onStart() throws IOException
{ {
final File file = getStorageFile(); final File file = getStorageFile();
while (rwl.getReadHoldCount() > 0)
{
rwl.readLock().unlock();
}
rwl.writeLock().lock(); rwl.writeLock().lock();
return file; return file;
} }

View File

@@ -29,6 +29,7 @@ public class EssentialsConnect
} }
ess = (IEssentials)essPlugin; ess = (IEssentials)essPlugin;
protect = (IProtect)essProtect; protect = (IProtect)essProtect;
protect.setSettings(new ProtectHolder(ess));
ProtectReloader pr = new ProtectReloader(); ProtectReloader pr = new ProtectReloader();
pr.onReload(); pr.onReload();
ess.addReloadListener(pr); ess.addReloadListener(pr);