01.06.2015, 14:13
If in every line an IP is stored without anything else such as tags etc, the code about reading and comparing is correct though I'd still not recommend file functions for such things. SQL is far better.
Also few tips: get the player's IP only once (outside of the loop) and if the IPs do match, stop the loop as there isn't any reason to keep reading from the file.
Also few tips: get the player's IP only once (outside of the loop) and if the IPs do match, stop the loop as there isn't any reason to keep reading from the file.