CS.RIN.RU - Steam Underground Community
http://cs.rin.ru/forum/

[Release] [Crysis 2] Beta server list Site + BSLauncher
http://cs.rin.ru/forum/viewtopic.php?f=31&t=58874
Page 2 of 4

Author:  magnitude [ Thursday, 17 Feb 2011, 20:03 ]
Post subject:  Re: [Crysis 2] Beta server list

GSOM9000 wrote:
Else one request, if it will not take much time, can u please add info about server location(by server IP) ? Or maybe country flag? idk.


If you wanted to add that feature really quick, http://freegeoip.appspot.com/xml/IPADDRESS returns all the geo location info.
And if you don't want it returning xml you can replace xml in the url with csv or json (java) to get the info in those formats.

Another site that returns the same thing is http://ipinfodb.com/ip_query.php?ip=IPADDRESS

You looked to be using ASP, here is an example to get geoip details... (generic example, should return geo info of user visiting the site if nothing is changed)

  1.  
  2. <%
  3.  
  4. 'Dim UserIPAddress
  5. UserIPAddress = Request.ServerVariables("HTTP_X_FORWARDED_FOR")
  6. If UserIPAddress = "" Then
  7. UserIPAddress = Request.ServerVariables("REMOTE_ADDR")
  8. End If
  9.  
  10. if NOT UserIPAddress = "" then
  11.  
  12. On Error Resume Next ' prevent tossing unhandled exception
  13. Dim URL, objXML, value
  14.  
  15. Set objXML = Server.CreateObject("MSXML2.DOMDocument.6.0")
  16. URL = "http://freegeoip.appspot.com/xml/" & UserIPAddress
  17. 'response.write URL
  18. if (NOT Err.Description = "") then
  19. 'You could use the following to email an alert
  20. 'Response.Write("An error occured when retrieving data from an external source.")
  21. 'Response.Write(Err.Description)
  22. 'Response.End
  23.  
  24. else
  25.  
  26.  
  27. objXML.setProperty "ServerHTTPRequest", True
  28. objXML.async = False
  29. objXML.Load URL
  30. 'Set oRoot = objXML.selectSingleNode("//response")
  31.  
  32.  
  33. strCountry=objXML.documentElement.childNodes(2).text
  34. strIP = objXML.documentElement.childNodes(0).text
  35. strRegion = objXML.documentElement.childNodes(5).text
  36. strCity = objXML.documentElement.childNodes(6).text
  37. 'ZipPostalCode = objXML.documentElement.childNodes(7).text
  38. 'strRcode = objXML.documentElement.childNodes(4).text
  39. 'value = objXML.documentElement.Text
  40. 'Response.Write "after setting value: " & Err.Description & "<br>"
  41.  
  42. Set objXML = Nothing
  43.  
  44. end if
  45. end if
  46. %>


So For example, [IDF] Pro Crysis 2 Server @ 85.250.161.254 returns

  1. <Response>
  2. <Status>true</Status>
  3. <Ip>85.250.161.254</Ip>
  4. <CountryCode>IL</CountryCode>
  5. <CountryName>Israel</CountryName>
  6. <RegionCode>05</RegionCode>
  7. <RegionName>Tel Aviv</RegionName>
  8. <City>Herzliya</City>
  9. <ZipCode/>
  10. <Latitude>32.1658</Latitude>
  11. <Longitude>34.8367</Longitude>
  12. </Response>


Of course this only works with ip addresses, so with those domain names you would need to translate them to ipaddresses, which is dead simple

  1. Dim IPAddress() As System.Net.IPAddress
  2. IPAddress = System.Net.Dns.GetHostAddresses("smtp.mail.yahoo.com")

Author:  Nomad13 [ Thursday, 17 Feb 2011, 20:20 ]
Post subject:  Re: [Crysis 2] Beta server list

Technologeek wrote:
Wow man, kudos for figuring that out, you did an outstanding work here :D !

I'm not bad with all the networking things, but this is really well done, I don't know if I could've done something like this ^^

Well, sorry I don't have any server but really (I hope) this is gonna bring us some :)

Thanks. There are already 5 right now, all online. But I think everyone is playing using Tunngle :mrgreen:

:?: I have a question for you (or anyone). Do you know the way to connect server without user interaction from a shortcut?

"crysis2.exe +connect ip" does not work (Maybe because you can use connect only from multiplayer menu)!
So maybe we need some "crysis2.exe +exec config.cfg" where several commands automatically switch us to multiplayer menu, then connect to server (skipping everything, going straight to the game)?

Author:  felixkharst [ Thursday, 17 Feb 2011, 20:27 ]
Post subject:  Re: [Crysis 2] Beta server list

Server Runtime Error ?

Author:  Nomad13 [ Thursday, 17 Feb 2011, 20:28 ]
Post subject:  Re: [Crysis 2] Beta server list

GSOM9000 wrote:
Else one request, if it will not take much time, can u please add info about server location(by server IP) ? Or maybe country flag? idk.

It is already done, just need little testing. Version with flags will be uploaded very soon.

magnitude wrote:
If you wanted to add that feature really quick, http://freegeoip.appspot.com/xml/IPADDRESS returns all the geo location info.

No need xml parsing. I've done it using wipmania.
It gives me Country Code in exchange of IP, that's all I need. For example, http://api.wipmania.com/85.250.161.254

Author:  Technologeek [ Thursday, 17 Feb 2011, 20:30 ]
Post subject:  Re: [Crysis 2] Beta server list

That would be a good idea :D
But I don't think making another config file is the best solution, because everyone has to have it...

Have you tried
"crysis2.exe" -g_multiplayerdefault 1 +connect IP

Seems to work :D ! Well not really, it makes the sound when you join a lobby... But it seems to quit right after :s

PS : Seems that your website is having a little trouble ^^"
EDIT : Nevermind, nice little improvement ;)

Author:  Nomad13 [ Thursday, 17 Feb 2011, 20:31 ]
Post subject:  Re: [Crysis 2] Beta server list

felixkharst wrote:
Server Runtime Error ?

Was uploading new version. Now its back online.

-- Edit --

Technologeek wrote:
That would be a good idea :D
But I don't think making another config file is the best solution, because everyone has to have it...

Have you tried
"crysis2.exe" -g_multiplayerdefault 1 +connect IP

Seems to work :D ! Well not really, it makes the sound when you join a lobby... But it seems to quit right after :s


EDIT: Please, just try to find a working way, no matter command prompt or config way. :8=)

Author:  Technologeek [ Thursday, 17 Feb 2011, 20:41 ]
Post subject:  Re: [Crysis 2] Beta server list

Nvm for my previous message ><
I thought you found a way, so yeah... can't think of any other way to do that :s

I found a way !! :D
Crysis2.exe -g_multiplayerdefault 1 +connect_repeatedly <insert_ip_here>

Author:  GSOM9000 [ Thursday, 17 Feb 2011, 20:57 ]
Post subject:  Re: [Crysis 2] Beta server list

Nomad13, good job man, looks like its time to promote teh site=)
Technologeek, can u post link in ur dedi server tutorial?

Author:  Technologeek [ Thursday, 17 Feb 2011, 21:00 ]
Post subject:  Re: [Crysis 2] Beta server list

The link is in my signature ^^
And it's one of the latest and most active threads in this section :p not too hard to find

EDIT: Oh ! You mean to promote this thread >< sure ! I'm so tired these times I don't understand half what you all say xD !

Oh and I was just thinking about something... Could you make a link to my thread on your website ? So that people will know how to create their own servers :)
It's all right if you don't want to ^^

Author:  GSOM9000 [ Thursday, 17 Feb 2011, 21:08 ]
Post subject:  Re: [Crysis 2] Beta server list

Technologeek wrote:
The link is in my signature ^^
And it's one of the latest and most active threads in this section :p not too hard to find

Oh and I was just thinking about something... Could you make a link to my thread on your website ? So that people will know how to create their own servers :)
It's all right if you don't want to ^^


:D I meant edit that 1st post like that:

VI) Include ur server in global server list
bla bla bla http://beta-servers.co.cc/

in ur thread =)
; great tut btw!

Author:  Technologeek [ Thursday, 17 Feb 2011, 21:10 ]
Post subject:  Re: [Crysis 2] Beta server list

GSOM9000 wrote:
:D I meant edit that 1st post like that:

VI) Include ur server in global server list
bla bla bla http://beta-servers.co.cc/

in ur thread =)

Yeah lol I got it now, sure I'll do it, this thread deserve it :p !

GSOM9000 wrote:
; great tut btw!

Thank you very much :')



@Nomad13 :
Not sure if you've seen it, but I just told you above,
I found a way !! :D
Crysis2.exe -g_multiplayerdefault 1 +connect_repeatedly <insert_ip_here>

Author:  Nomad13 [ Thursday, 17 Feb 2011, 22:45 ]
Post subject:  Re: [Crysis 2] Beta server list

Technologeek wrote:
Crysis2.exe -g_multiplayerdefault 1 +connect_repeatedly <insert_ip_here>

This works, but with a big delay in multiplayer menu, before attempting to connect. Is there any smoother way?

Author:  Technologeek [ Thursday, 17 Feb 2011, 22:56 ]
Post subject:  Re: [Crysis 2] Beta server list

I don't have any idea on how to reduce the delay :s

Author:  daweed [ Thursday, 17 Feb 2011, 23:28 ]
Post subject:  Re: [Crysis 2] Beta server list

seems that all servers getting these errors after a while :

Map = N/A and Mode = Unknown (4192086207) [or some other numbers...]

Any ideas?
Maybe something with levelrotation.xml?

Author:  draykore [ Friday, 18 Feb 2011, 06:32 ]
Post subject:  Re: [Crysis 2] Beta server list

hi i cannot seem to get online with this im a pretty big noob so a complete step by step would be most appreciated thank you very much everyone.

Page 2 of 4 All times are UTC + 3 hours
Powered by phpBB® Forum Software © phpBB Group
https://www.phpbb.com/