Watch Scripts
From ElectronicWar
| This Article is Incomplete | |
| This article is apparently incomplete. You can help the ElectronicWar wiki by expanding it |
Watches are used to inform you when specific things happen. For example, when you get scanned.
[edit] Scan Watches
Scan watches trigger when another player scans you.
Scan watch example:
logMessage("Scanned by " + getTargetIP());
[edit] Health Watches
Health watches trigger when the chosen port's health drops below a specified threshold.
Simple health watch example:
logMessage(getTargetIP()+ " port " +getTargetPort()+ " attacked you");
If you were attacked, this watch could put this into your log:
(4:04:09 PM) 123.456.7.890 port 3 attacked you.
When you have installed the watch, make sure you set the health value to 99!
Advanced health watch example:
attacker = getTargetIP(); logMessage(attacker+ " port " +getTargetPort()+ " attacked port " +getPort()); message(attacker,"You stand no chance against my defenses!"); counterattack(getPort()); switchAnyFireWall();
This script will notify you, launch a counterattack and move a firewall infront of the port. Make sure you set the observed port to an active attack port when installed.
[edit] Petty Cash Watches
Petty Cash watches trigger when your petty cash reaches a specified level.
Petty Cash watch example:
logMessage("Petty Cash at watch level.");

