The following warnings occurred:
Warning [2] Use of undefined constant SAPI_NAME - assumed 'SAPI_NAME' (this will throw an Error in a future version of PHP) - Line: 3388 - File: inc/functions.php PHP 7.4.33-nmm6 (Linux)
File Line Function
/inc/functions.php 3388 errorHandler->error
/showthread.php 116 build_archive_link
Warning [2] Use of undefined constant IN_ARCHIVE - assumed 'IN_ARCHIVE' (this will throw an Error in a future version of PHP) - Line: 3331 - File: inc/functions.php PHP 7.4.33-nmm6 (Linux)
File Line Function
/inc/functions.php 3331 errorHandler->error
/inc/functions.php 3324 build_forum_breadcrumb
/showthread.php 195 build_forum_breadcrumb
Warning [2] Use of undefined constant IN_ARCHIVE - assumed 'IN_ARCHIVE' (this will throw an Error in a future version of PHP) - Line: 3331 - File: inc/functions.php PHP 7.4.33-nmm6 (Linux)
File Line Function
/inc/functions.php 3331 errorHandler->error
/showthread.php 195 build_forum_breadcrumb






Post Reply 
 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[solved] Final touch on Sphere.ini. Server selection problem
Author Message
VeTaL
Journeyman
*

Posts: 53
Likes Given: 0
Likes Received: 0 in 0 posts
Joined: May 2012
Reputation: 0



Post: #1
[solved] Final touch on Sphere.ini. Server selection problem
Looking like everything goes nice: i can play on my server, my friends can play there either through Internet. Its time for last (he-he, you also didnt believe me?) cosmetic tough.

While logging-in, and while shard selection, i can see two lines:
[Image: 1336173811-clip-69kb.jpg]

Firs one works fine,i click there and i'm in the game.
But second one stops everything, and in Sphere i see
Quote:WARNING:9:Unknown game packet (0x46) received.

Where they are from? Well, firs one is from the very beginning of sphere.ini, second one is from the end:
Quote:[SPHERE]
// Name of your Sphere shard
ServName=UO Templars
// The IP of your server, this will be 127.0.0.1 almost always
ServIP=127.0.0.1
// The port of your server, this is 2593 by default
ServPort=2593

********

[SERVERS]
Templars Shard
uotemplars.hopto.org
2593

//External
//my.ip.goes.here
//2593

[EOF]

Still didnt tested, but looking like only second one works for my friends to join me.

What are recommendations on this field?
(This post was last modified: 05-06-2012 08:10 AM by VeTaL.)
05-05-2012 09:28 AM
Find all posts by this user Like Post Quote this message in a reply
Shaklaban
Master
**

Posts: 378
Likes Given: 0
Likes Received: 1 in 1 posts
Joined: Mar 2012
Reputation: 8

DOT

Post: #2
RE: Final touch on Sphere.ini
Just comment the following lines:

[SERVERS]
//Templars Shard
//uotemplars.hopto.org
//2593

Also for stable sphere use following settings:

// Number of network threads. Clients are distributed evenly amongst each thread. Set to 0 to not
// use a separate networking thread.
NetworkThreads=0

// Use asynchronous data sends (changing this setting at runtime may produce unexpected behaviour)
// 0 = Off
// 1 = On
// 2 = On for 4.0.0+ game clients only
UseAsyncNetwork=0


// Prioritise outgoing packets (provides a smoother experience in crowded areas)
UsePacketPriority=0
(This post was last modified: 05-05-2012 11:35 AM by Shaklaban.)
05-05-2012 11:34 AM
Visit this user's website Find all posts by this user Like Post Quote this message in a reply
Valios
Super Moderator
****

Posts: 390
Likes Given: 0
Likes Received: 12 in 9 posts
Joined: Mar 2010
Reputation: 6

Sphere Suite 2013

Post: #3
RE: Final touch on Sphere.ini
Use different ports for each one, you can forward the port 2594 for the second
05-05-2012 05:44 PM
Find all posts by this user Like Post Quote this message in a reply
VeTaL
Journeyman
*

Posts: 53
Likes Given: 0
Likes Received: 0 in 0 posts
Joined: May 2012
Reputation: 0



Post: #4
RE: Final touch on Sphere.ini
2 Shaklaban:
I commented [SERVERS] part, so now i have only second option "UO Templars". After trying to login there, i got "WARNING:9:Unknown game packet (0x46) received." on the server side, and endless waiting on the client side.

What about threads: some years ago i found pretty cool article on codeproject.com about server dynamic threads management.. i spent about hour, trying to find it (on the site, and on my HDD, i definitely saved it), but no results right now. I think, it could be usefull, i'll continue my search a little later.

2 Valios:
Hm.. can i make only 1, which would be working for me and for friends?
(This post was last modified: 05-05-2012 08:04 PM by VeTaL.)
05-05-2012 08:04 PM
Find all posts by this user Like Post Quote this message in a reply
admin phoenix
Master
**

Posts: 354
Likes Given: 1
Likes Received: 23 in 13 posts
Joined: Mar 2012
Reputation: 3



Post: #5
RE: Final touch on Sphere.ini
also have the problem with the 2 server.
first one people can connect and the second one they can´t (but I do not need the second one).
when I comment out theline, the second one is showing on the login page (but as I said, I don´t need it Smile )
05-05-2012 08:09 PM
Find all posts by this user Like Post Quote this message in a reply
Vendetta
Apprentice
*

Posts: 39
Likes Given: 1
Likes Received: 0 in 0 posts
Joined: Mar 2012
Reputation: 0



Post: #6
RE: Final touch on Sphere.ini
the simple way is to on f_onserver_start
serv.ip =<external_ip>

the all will connect to same shard
05-05-2012 08:12 PM
Find all posts by this user Like Post Quote this message in a reply
VeTaL
Journeyman
*

Posts: 53
Likes Given: 0
Likes Received: 0 in 0 posts
Joined: May 2012
Reputation: 0



Post: #7
RE: Final touch on Sphere.ini
Same here. Now i commented [SPHERE] part. (Didnt want to do it, because i thought, it is critical for server).

This time, i see "Templars Shard" and "Sphere". Looking like, second name is default one.

So, is it possible to have only one line for everybody?
2 Vendetta

I found f_onserver_start in sphere_serv_triggers.scp, now its looking like
Code:
// This function is called on server startup
[FUNCTION f_onserver_start]
serv.ip =<external_ip>

Then i changed Sphere.ini to
Code:
[SPHERE]
AGREE=1
// Name of your Sphere shard
ServName=UO Templars
// The IP of your server, this will be 127.0.0.1 almost always
ServIP=uotemplars.hopto.org
// The port of your server, this is 2593 by default
ServPort=2593

****

[SERVERS]
//Templars Shard
//uotemplars.hopto.org
//2593

Sphere doesn't launch.
Now i return back

Code:
[SPHERE]
// Name of your Sphere shard
ServName=UO Templars
// The IP of your server, this will be 127.0.0.1 almost always
ServIP=127.0.0.1
// The port of your server, this is 2593 by default
ServPort=2593

***

[SERVERS]
Templars Shard
uotemplars.hopto.org
2593

And got warning
Code:
13:30:ERROR:(sphere_serv_triggers.scp,64)Can't resolve <external_ip>
13:30:ERROR:(sphere_serv_triggers.scp,64)Undefined keyword 'ip'
(This post was last modified: 05-05-2012 08:31 PM by VeTaL.)
05-05-2012 08:16 PM
Find all posts by this user Like Post Quote this message in a reply
Vendetta
Apprentice
*

Posts: 39
Likes Given: 1
Likes Received: 0 in 0 posts
Joined: Mar 2012
Reputation: 0



Post: #8
RE: Final touch on Sphere.ini
USE SERV.SERVIP=

lol of course external ip is the ip you got when you connect to internet.

the one that is resolved on uotemplars.hopto.org

maybe you can try also with

SERV.SERVIP=uotemplars.hopto.org

don't use <external_ip> but your ip 88.114.89.161 or uotemplars.hopto.org
05-05-2012 11:06 PM
Find all posts by this user Like Post Quote this message in a reply
VeTaL
Journeyman
*

Posts: 53
Likes Given: 0
Likes Received: 0 in 0 posts
Joined: May 2012
Reputation: 0



Post: #9
RE: Final touch on Sphere.ini
Ah xD
I thought, it would be found by itself Smile
Yep, it works

SOLUTION: in sphere_serv_triggers.scp, add
Code:
// This function is called on server startup
[FUNCTION f_onserver_start]
SERV.SERVIP =<put_here_your_external_ip>
(This post was last modified: 05-05-2012 11:19 PM by VeTaL.)
05-05-2012 11:11 PM
Find all posts by this user Like Post Quote this message in a reply
VeTaL
Journeyman
*

Posts: 53
Likes Given: 0
Likes Received: 0 in 0 posts
Joined: May 2012
Reputation: 0



Post: #10
RE: [solved] Final touch on Sphere.ini. Server selection problem
Probably, not only that is needed. Also, i found this

So i also added
Code:
[FUNCTION f_onserver_save]
SERV.SERVIP = uotemplars.hopto.org

// This function is called after server has saved correctly (once per stage with background save).
[FUNCTION f_onserver_save_ok]
SERV.SERVIP = uotemplars.hopto.org

// This function is called after server hasn't saved correctly (once per stage with background save).
[FUNCTION f_onserver_save_fail]
SERV.SERVIP = uotemplars.hopto.org

I expected it it solve my world save problem, but it didnt help Sad
(This post was last modified: 05-06-2012 09:52 AM by VeTaL.)
05-06-2012 09:51 AM
Find all posts by this user Like Post Quote this message in a reply
Post Reply 


Forum Jump:


User(s) browsing this thread: 2 Guest(s)