netsh advfirewall firewall add rule name="TCP Port <port>" dir=in action=allow protocol=TCP localport=<port>
2.1. Run this command to open a port on the UDP protocol:
netsh advfirewall firewall add rule name="UDP Port <port>" dir=in action=allow protocol=UDP localport=<port>
netsh advfirewall firewall add rule name="TCP Port 30120" dir=in action=allow protocol=TCP localport=30120 & netsh advfirewall firewall add rule name="UDP Port 30120" dir=in action=allow protocol=UDP localport=30120
netsh advfirewall firewall add rule name="TCP Port 25565" dir=in action=allow protocol=TCP localport=25565
netsh advfirewall firewall add rule name="TCP Port 27015" dir=in action=allow protocol=TCP localport=27015 & netsh advfirewall firewall add rule name="UDP Port 27015" dir=in action=allow protocol=UDP localport=27015
netsh advfirewall firewall add rule name="TCP Port 28015" dir=in action=allow protocol=TCP localport=28015 & netsh advfirewall firewall add rule name="UDP Port 28015" dir=in action=allow protocol=UDP localport=28015