PtokaX forum

Archive => Archived 5.1 boards => HOW-TO's => Topic started by: Naithif on 11 April, 2007, 11:53:40

Title: GetHubIp problem
Post by: Naithif on 11 April, 2007, 11:53:40
Hi guys

Anyone knows if it's possible to grab a hub's actual IP if it's dynamic? I mean like sending active searches with frmHub:GetHubIp() and frmHub:GetHubUdpPort() works (with resolve to IP checked at the GUI), but it isn't aware of the host's IP change.
Is it possible to make it referring to the actual IP everytime? (or would it require resolving from the hubsoft everytime?  :-\) Or is there something similiar lua side? Something like resolving dns addresses or such?

Thanks in advance
Title: Re: GetHubIp problem
Post by: Cêñoßy†ê on 11 April, 2007, 12:23:35
mayby with pxwsa library ?

Code (lua) Select

WSA.GetHostByName(frmHub:GetHubAddress())
Title: Re: GetHubIp problem
Post by: Naithif on 11 April, 2007, 15:43:53
Great idea, thanks  :D
Title: Re: GetHubIp problem
Post by: bastya_elvtars on 11 April, 2007, 16:00:08
PPK would it be hard to add non-blocking DNS lookup and reverse lookup?