GT5-Unofficial/main/java/gregtech/common/GT_PlayerActivityLogger.java
2015-10-14 22:33:33 -04:00

36 lines
871 B
Java

package gregtech.common;
import gregtech.GT_Mod;
import gregtech.api.util.GT_Log;
import java.io.PrintStream;
import java.util.ArrayList;
public class GT_PlayerActivityLogger
implements Runnable
{
public void run()
{
try
{
for (;;)
{
if (GT_Log.pal == null) {
return;
}
ArrayList<String> tList = GT_Mod.gregtechproxy.mBufferedPlayerActivity;
GT_Mod.gregtechproxy.mBufferedPlayerActivity = new ArrayList();
String tLastOutput = "";
int i = 0;
for (int j = tList.size(); i < j; i++)
{
if (!tLastOutput.equals(tList.get(i))) {
GT_Log.pal.println((String)tList.get(i));
}
tLastOutput = (String)tList.get(i);
}
Thread.sleep(10000L);
}
}
catch (Throwable e) {}
}
}