summaryrefslogtreecommitdiffstats
path: root/EssentialsAntiCheat/src/com/earth2me/essentials/anticheat/actions/types/LogAction.java
diff options
context:
space:
mode:
authorementalo <ementalodev@gmx.co.uk>2012-07-17 12:26:55 +0100
committerementalo <ementalodev@gmx.co.uk>2012-07-17 14:21:03 +0100
commita661bce7b3de3f53e2b7b79c1283f0affa6fe9c3 (patch)
tree2aa10b6300f6c8d3cb2b298c124180fade74857a /EssentialsAntiCheat/src/com/earth2me/essentials/anticheat/actions/types/LogAction.java
parent3c385e69271dfe8530fadc3f67e13ee495e4b0e1 (diff)
parent9f05e43ecf8e6e1a8fcaef757678e762f0d82573 (diff)
downloadEssentials-a661bce7b3de3f53e2b7b79c1283f0affa6fe9c3.tar
Essentials-a661bce7b3de3f53e2b7b79c1283f0affa6fe9c3.tar.gz
Essentials-a661bce7b3de3f53e2b7b79c1283f0affa6fe9c3.tar.lz
Essentials-a661bce7b3de3f53e2b7b79c1283f0affa6fe9c3.tar.xz
Essentials-a661bce7b3de3f53e2b7b79c1283f0affa6fe9c3.zip
Merge of server-layer branch
Diffstat (limited to 'EssentialsAntiCheat/src/com/earth2me/essentials/anticheat/actions/types/LogAction.java')
-rw-r--r--EssentialsAntiCheat/src/com/earth2me/essentials/anticheat/actions/types/LogAction.java76
1 files changed, 0 insertions, 76 deletions
diff --git a/EssentialsAntiCheat/src/com/earth2me/essentials/anticheat/actions/types/LogAction.java b/EssentialsAntiCheat/src/com/earth2me/essentials/anticheat/actions/types/LogAction.java
deleted file mode 100644
index 16830b8d7..000000000
--- a/EssentialsAntiCheat/src/com/earth2me/essentials/anticheat/actions/types/LogAction.java
+++ /dev/null
@@ -1,76 +0,0 @@
-package com.earth2me.essentials.anticheat.actions.types;
-
-import com.earth2me.essentials.anticheat.NoCheatPlayer;
-import com.earth2me.essentials.anticheat.checks.Check;
-
-
-/**
- * Print a log message to various locations
- *
- */
-public class LogAction extends ActionWithParameters
-{
- // Some flags to decide where the log message should show up, based on
- // the config file
- private final boolean toChat;
- private final boolean toConsole;
- private final boolean toFile;
-
- public LogAction(String name, int delay, int repeat, boolean toChat, boolean toConsole, boolean toFile, String message)
- {
- super(name, delay, repeat, message);
- this.toChat = toChat;
- this.toConsole = toConsole;
- this.toFile = toFile;
- }
-
- /**
- * Parse the final log message out of various data from the player and check that triggered the action.
- *
- * @param player The player that is used as a source for the log message
- * @param check The check that is used as a source for the log message
- * @return
- */
- public String getLogMessage(NoCheatPlayer player, Check check)
- {
- return super.getMessage(player, check);
- }
-
- /**
- * Should the message be shown in chat?
- *
- * @return true, if yes
- */
- public boolean toChat()
- {
- return toChat;
- }
-
- /**
- * Should the message be shown in the console?
- *
- * @return true, if yes
- */
- public boolean toConsole()
- {
- return toConsole;
- }
-
- /**
- * Should the message be written to the logfile?
- *
- * @return true, if yes
- */
- public boolean toFile()
- {
- return toFile;
- }
-
- /**
- * Create the string that's used to define the action in the logfile
- */
- public String toString()
- {
- return "log:" + name + ":" + delay + ":" + repeat + ":" + (toConsole ? "c" : "") + (toChat ? "i" : "") + (toFile ? "f" : "");
- }
-}