Log Message on fire with name of player
From Hack Wars Wiki
Log message of the player name AND their ip, port and which port they attacked.
This works as both Scan and Health watches.
Create a text file and put a list of players ips and names like so:
900.800.5.400,Government Supply Admin |
Then change "string IPList = "IPLIST HERE"; // This is your list of IPs" to the name of the list you created.
Enjoy
/* Created By: Jamjardavies */ // Settings to change! string IPList = "IPLIST HERE"; // This is your list of IPs int main() { string vIP = getTargetIP(); int vPort = getTargetPort(); int size = countLines(IPList); int i = 0; string Player[]; Player[0] = vIP; Player[1] = "Unknown"; while(i < size) { if(indexOf(readLine(IPList, i), vIP, 0) >= 0) { spl(Player, readLine(IPList, i), ","); i = size; } i++; } logMessage("Player: " + Player[1] + " IP: " + vIP + "[" + vPort + "] scanned/attacked port: " + getPort()); } void spl(string arr[], string inString, string charSplit) { string tString = inString; int delimLen = strlen(charSplit); int i = 0; int x = 0; while(indexOf(tString, charSplit, 0) > 0) { i = indexOf(tString, charSplit, 0); arr[x] = substr(tString, 0, i); tString = substr(tString, i + delimLen, strlen(tString)); x++; } arr[x] = tString; } |
