Change server time ?

Support for the latest build of L2J Server, get help here with installations, upgrades, problems.
Do not post bugs reports here, use viewforum.php?f=77 instead.
There is no support for other server builds than the official provided by l2jserver.com
Forum rules
READ NOW: L2j Forums Rules of Conduct
Post Reply
Menuval
Posts: 42
Joined: Sat Feb 02, 2008 11:44 pm

Change server time ?

Post by Menuval »

If you want to receive support we need this info to help you properly.
» Find Revision
L2J Revision Number:
L2JDP Revision Number:

Hii there,

From some reason my site castle status script and 7s script shows the date is 1970 & 1987.

any clue on where i can change that ?

and another thing, i was looking through npc's and was looking for the right npc to spawn as the glittering meda trader. which one is it ?

Thanks in advance,
User avatar
janiii
L2j Veteran
L2j Veteran
Posts: 4269
Joined: Wed May 28, 2008 3:15 pm
Location: Slovakia

Re: Change server time ?

Post by janiii »

Menuval wrote:and another thing, i was looking through npc's and was looking for the right npc to spawn as the glittering meda trader. which one is it ?
must have been included in the script where you downloaded it.
DO NOT EVEN TRY TO MESS WITH ME!
forum flOOder dancing dEVILoper
I don't give private support - PM will be ignored!
Menuval
Posts: 42
Joined: Sat Feb 02, 2008 11:44 pm

Re: Change server time ?

Post by Menuval »

can't find it anywhere. /= any idea where is the main server time settings ?
Menuval
Posts: 42
Joined: Sat Feb 02, 2008 11:44 pm

Re: Change server time ?

Post by Menuval »

bump.

I know my linux server time is right.

how can I know what's my gameserver time ?
User avatar
janiii
L2j Veteran
L2j Veteran
Posts: 4269
Joined: Wed May 28, 2008 3:15 pm
Location: Slovakia

Re: Change server time ?

Post by janiii »

Menuval wrote:bump.

I know my linux server time is right.

how can I know what's my gameserver time ?
what you mean by gameserver time? the time in game? /time ? time on the map? but the time, the real time is taken from jvm and that takes the time from OS region settings.
DO NOT EVEN TRY TO MESS WITH ME!
forum flOOder dancing dEVILoper
I don't give private support - PM will be ignored!
Menuval
Posts: 42
Joined: Sat Feb 02, 2008 11:44 pm

Re: Change server time ?

Post by Menuval »

@mysql_connect ( $db_serv, $db_user, $db_pass ) or die ('Coudn\'t connect to host');
@mysql_select_db( $db_name ) or die ('Couldn\'t select database');

$sql = @mysql_query('SELECT id,name,taxPercent,siegeDate FROM `castle`') or die('Query failed!');

$gen = "\n";

while ($castle = @mysql_fetch_array($sql))
{
$gen .= "\n".strtolower($castle['name']) . 'info = \'<div class="castleWrapper">';
$gen .= '<div class="castlePic" id="' . ucfirst(strtolower($castle['name'])) . 'Pic"></div>';
$gen .= '<div class="castleInfo">';
$gen .= '<div class="castleName"><strong>' . ucfirst(strtolower($castle['name'])) . ' Castle</strong></div>';

$clan = @mysql_fetch_array(mysql_query('SELECT clan_name,hasCastle FROM `clan_data` WHERE hasCastle = ' . $castle['id']));
$clan_name = (isset($clan['clan_name'])) ? htmlspecialchars($clan['clan_name'], ENT_QUOTES) : 'UNCLAIMED';

$gen .= '<div><strong>Controlled by:</strong> ' . $clan_name . '</div>';

if (isset($clan['clan_name'])) $gen .= '<div><strong>Tax Rate:</strong> ' . $castle['taxPercent'] . '%</div>';

$gen .= '<div><strong>Next Siege:</strong> ' . date('M d Y ',$castle['siegeDate']/1000) . $castle['siegeHourOfDay'] . date(':00 T') . '</div>';
$gen .= '</div></div>\';'."\n\n";
}

$handle = @fopen($filename, 'w+');
@fwrite($handle, $gen);
@fclose($handle);

?>

this is my scrupt btw,
anyone have a link to the newer script with the castle map maybe ?
Menuval
Posts: 42
Joined: Sat Feb 02, 2008 11:44 pm

Re: Change server time ?

Post by Menuval »

I just noticed i don't even have the siegehour in my tables.
User avatar
janiii
L2j Veteran
L2j Veteran
Posts: 4269
Joined: Wed May 28, 2008 3:15 pm
Location: Slovakia

Re: Change server time ?

Post by janiii »

Menuval wrote:this is my scrupt btw,
anyone have a link to the newer script with the castle map maybe ?
http://l2jserver.com/forum/viewtopic.php?f=94&t=10730
DO NOT EVEN TRY TO MESS WITH ME!
forum flOOder dancing dEVILoper
I don't give private support - PM will be ignored!
Menuval
Posts: 42
Joined: Sat Feb 02, 2008 11:44 pm

Re: Change server time ?

Post by Menuval »

Thanks man.
Menuval
Posts: 42
Joined: Sat Feb 02, 2008 11:44 pm

Re: Change server time ?

Post by Menuval »

btw, i've seen a share (not the one you post) that shows the castle status on a map , can't find anymore,

any clue ?
Post Reply