|
[ANet] Using a hostname to connect to
#343693
10/08/10 23:57
10/08/10 23:57
|
Joined: Nov 2002
Posts: 913 Berlin, Germany
SchokoKeks
OP
User
|
OP
User
Joined: Nov 2002
Posts: 913
Berlin, Germany
|
Hi all, I've tried to use a hostname like "mypc.no-ip.com" to connect to my anet server. When using the IP that is behind that adress, it connects fine. When I try to use the hostname acknex freezes instantly and crashes with the following info (in german):
Problemsignatur:
Problemereignisname: BEX
Anwendungsname: acknex.exe
Anwendungsversion: 0.0.0.0
Anwendungszeitstempel: 4b2a3e3e
Fehlermodulname: MSVCR90.dll
Fehlermodulversion: 9.0.30729.4926
Fehlermodulzeitstempel: 4a1743c1
Ausnahmeoffset: 000369de
Ausnahmecode: c0000417
Ausnahmedaten: 00000000
Betriebsystemversion: 6.1.7600.2.0.0.256.48
Gebietsschema-ID: 1031
Zusatzinformation 1: 1546
Zusatzinformation 2: 15467be466987c95823a957a6a74a0b3
Zusatzinformation 3: ab21
Zusatzinformation 4: ab21d1340cccbedb55fa7d4f575a334a
Is there a way to use PRAGMA_API to resolve the host to an IP i can then connect to? I've never worked with the windows API. Any chance to get this included directly into ANet? Thanks, SchokoKeks
|
|
|
Re: [ANet] Using a hostname to connect to
[Re: SchokoKeks]
#343727
10/09/10 16:08
10/09/10 16:08
|
Joined: Jul 2005
Posts: 1,930 Austria
Dark_samurai
Serious User
|
Serious User
Joined: Jul 2005
Posts: 1,930
Austria
|
Hmmm... I'm not sure about that. I guess you would have to use DNS to resolve the hostname into an IP. But I don't know how difficult this would be to implement.
I think this would be a useful feature. I will take a look into that.
ANet - A stable and secure network plugin with multi-zone, unlimited players, voip, server-list features,... (for A7/A8)! get free version
|
|
|
Re: [ANet] Using a hostname to connect to
[Re: Dark_samurai]
#344314
10/16/10 09:16
10/16/10 09:16
|
Joined: Jul 2005
Posts: 1,930 Austria
Dark_samurai
Serious User
|
Serious User
Joined: Jul 2005
Posts: 1,930
Austria
|
I just tried it with my public server and it works fine. Are you sure that it's not caused by your code? I used this testapplication:
#include <acknex.h>
#include "anet.h"
#include "default.c"
void main()
{
level_load("");
wait(3);
enet_init();
while(1)
{
if(key_1)
{
enet_init_server(2300,4,"");
while(key_1) wait(1);
}
if(key_2)
{
enet_init_client("mail.aauer.com",2300,"");
while(key_2) wait(1);
}
wait(1);
}
}
I used [F11] to open the debug panel and checked if I get a ClientID. Even if ANet can't resolve the name, it shouldn't crash but throw a disconnected event. Please test this out. It's possible that this is a bug of ANet.
ANet - A stable and secure network plugin with multi-zone, unlimited players, voip, server-list features,... (for A7/A8)! get free version
|
|
|
Re: [ANet] Using a hostname to connect to
[Re: Dark_samurai]
#344315
10/16/10 09:24
10/16/10 09:24
|
Joined: Apr 2007
Posts: 3,751 Canada
WretchedSid
Expert
|
Expert
Joined: Apr 2007
Posts: 3,751
Canada
|
I can also confirm that Enet (and thus also Anet) is able to handle hostnames instead of just IP addresses.
Shitlord by trade and passion. Graphics programmer at Laminar Research. I write blog posts at feresignum.com
|
|
|
Re: [ANet] Using a hostname to connect to
[Re: SchokoKeks]
#344416
10/17/10 10:56
10/17/10 10:56
|
Joined: Jul 2005
Posts: 1,930 Austria
Dark_samurai
Serious User
|
Serious User
Joined: Jul 2005
Posts: 1,930
Austria
|
Thanks for the report!
Yes you're right. Because an IP can't be longer than 15 signs, the string was limited to 15 signs. I removed this limit. Now it should work. I've sent you a beta version. Please try it out and tell me if it's working now.
ANet - A stable and secure network plugin with multi-zone, unlimited players, voip, server-list features,... (for A7/A8)! get free version
|
|
|
Re: [ANet] Using a hostname to connect to
[Re: SchokoKeks]
#344668
10/19/10 14:50
10/19/10 14:50
|
Joined: Jul 2005
Posts: 1,930 Austria
Dark_samurai
Serious User
|
Serious User
Joined: Jul 2005
Posts: 1,930
Austria
|
The password bug is also fixed now.
I think I will release the current beta version after another few days of beta testing.
ANet - A stable and secure network plugin with multi-zone, unlimited players, voip, server-list features,... (for A7/A8)! get free version
|
|
|
Re: [ANet] Using a hostname to connect to
[Re: Dark_samurai]
#344671
10/19/10 14:59
10/19/10 14:59
|
Joined: Jun 2006
Posts: 2,640 Earth
Germanunkol
Expert
|
Expert
Joined: Jun 2006
Posts: 2,640
Earth
|
Ah, maybe this is the bug I just sent you an email about? If it's already fixed - great! Would you be able to send me the new version? We want to distribute a demo of the game tomorrow and I'd not like to have to disable the password system...
~"I never let school interfere with my education"~ -Mark Twain
|
|
|
|