It depends upon the method of connection. If you connect to a machine using a LAN then a local address will be returned. If you connect remotely then a WAN address will be returned.
This applies to both commands.
You can fake a WAN connection if your server PC is the gateway to the internet (ie: not using a router) by specifying the IP# of the WAN connection and then, using your LAN connect the second PC to the servers internet IP# and then HostIP() returns the WAN IP.
If you connect to the LAN IP# such as 192.168.0.1 then HostIP() returns the LAN IP.
You might also be able to sort through IP's with countHostIP's and specify the index but i've not personally ever bothered with that so don't know for sure.
EQ (and therefore I guess EqEmu) uses UDP. I suppose the EqEmu docs do not clarify it because most end users do not know what UDP is. This post being a prime example of that, and as UDP is using IP# for target ident, /shrug: 1+1=2.
This applies to both commands.
You can fake a WAN connection if your server PC is the gateway to the internet (ie: not using a router) by specifying the IP# of the WAN connection and then, using your LAN connect the second PC to the servers internet IP# and then HostIP() returns the WAN IP.
If you connect to the LAN IP# such as 192.168.0.1 then HostIP() returns the LAN IP.
You might also be able to sort through IP's with countHostIP's and specify the index but i've not personally ever bothered with that so don't know for sure.
EQ (and therefore I guess EqEmu) uses UDP. I suppose the EqEmu docs do not clarify it because most end users do not know what UDP is. This post being a prime example of that, and as UDP is using IP# for target ident, /shrug: 1+1=2.