I had a look at the AHK documentation and I can't find anything obvious that would make this break. The only thing I can really think of that might break would be the filter for the application name, if you're using a launcher or something it may have to be updated from factorio.exe to something else. Other than that the script is very basic and has looked the same for something like 5 years so I can't really see those parts breaking.
I'm afraid I can't really help you more with this as I no longer have a Windows machine to be able to run tests on.
Feel free update here if you manage to figure it out and I'll have a look at updating the provided script.