This script works on any version of mIRC supporting /scid, which was added in 6.0 in 2002, only $unsafe is a recent addition, you can use a scripted $safe alias in this case (see
https://en.wikichip.org/wiki/mirc/msl_injection#The_.2Ftimer_command), or update to the latest version of mIRC.
The code works but no, $network can't be 192.168.1.123:1234, for various reason.
That being said that code was made to relay two different networks or two different server, I'm not so sure what's your situation, are you connecting to the same ip twice on different port? in this case you need to only check the server/network + the port