A Project for Chronicle 4 based on L2JServer.


    Server loaded in # seconds like l2jserver

    Share
    avatar
    arteon

    Posts : 82
    Join date : 2013-12-14

    Server loaded in # seconds like l2jserver

    Post  arteon on 21st July 2015, 10:23

    I was wondering why this wasnt implemented, anyway here it is.

    https://gist.github.com/JMD13/b0bfe89fdc8aa9b9a6ca

    Code:
    Index: java/net/sf/l2j/gameserver/GameServer.java
    ===================================================================
    --- java/net/sf/l2j/gameserver/GameServer.java   (revision 4)
    +++ java/net/sf/l2j/gameserver/GameServer.java   (working copy)
    @@ -131,6 +131,7 @@
     
        public GameServer() throws Exception
        {
    +      long serverLoadStart = System.currentTimeMillis();
            gameServer = this;
           _log.finest("used mem:" + getUsedMemoryMB()+"MB" );
     
    @@ -551,6 +552,7 @@
     
            _selectorThread.start();
            _log.config("Maximum Number of Connected Players: " + Config.MAXIMUM_ONLINE_USERS);
    +        _log.log(Level.INFO, getClass().getSimpleName() + ": Server loaded in " + ((System.currentTimeMillis() - serverLoadStart) / 1000) + " seconds.");
        }
     
        public static void main(String[] args) throws Exception
    avatar
    DnR
    Admin
    Admin

    Posts : 1027
    Join date : 2012-12-03

    Re: Server loaded in # seconds like l2jserver

    Post  DnR on 25th July 2015, 14:57

    1) It simply wasn't an emergency.
    2) Nobody asked for it.

    Anyway, it's added in revision 514.
    Thanks a lot.

      Current date/time is 19th November 2017, 14:03