Signup Now
Page 1 of 3 123 LastLast
Results 1 to 10 of 29
  1. #1
    Free User pedegie's Avatar
    Join Date
    Dec 2015
    Location
    Poland
    Posts
    264
    Reputation
    28
    Rep Power
    17

    sstime() not works?

    Returns amount of seconds left for the next server save.

    09:55 Server is saving game in 5 minutes.
    Please come back later.

    And what is sstime showing:

    09:56:40 83000 --its from console

    Am I missing something or it not work?

  2. #2
    Moderator Raphael's Avatar
    Join Date
    Dec 2013
    Location
    raphseller.com
    Posts
    2,441
    Reputation
    309
    Rep Power
    28
    Is your computer's clock correct?

  3. #3
    Free User pedegie's Avatar
    Join Date
    Dec 2015
    Location
    Poland
    Posts
    264
    Reputation
    28
    Rep Power
    17
    Ye im sure, it worked few days ago, i didnt change anything. Now it shows that ss will be at 9:00 o'clock instead of 10:00 if im counting well.

  4. #4
    Free User Connor's Avatar
    Join Date
    Jul 2014
    Posts
    455
    Reputation
    22
    Rep Power
    20
    Isn't it easier this way?


    function sstiem()
    if os.date("%X") >= "09:30" and os.date("%X") <= "10:10" then
    return true
    else
    return false
    end
    end
    function relogtiem()
    if os.date("%X") >= "10:30" and os.date("%X") <= "11:00" then
    return true
    else
    return false
    end
    end

  5. #5
    Moderator Raphael's Avatar
    Join Date
    Dec 2013
    Location
    raphseller.com
    Posts
    2,441
    Reputation
    309
    Rep Power
    28
    Quote Originally Posted by Connor View Post
    Isn't it easier this way?


    function sstiem()
    if os.date("%X") >= "09:30" and os.date("%X") <= "10:10" then
    return true
    else
    return false
    end
    end
    function relogtiem()
    if os.date("%X") >= "10:30" and os.date("%X") <= "11:00" then
    return true
    else
    return false
    end
    end
    That assumes your clock is on CE(S)T, which isn't true for 90% of the users.
    Last edited by Raphael; 02-10-2016 at 03:15 PM.

  6. #6
    Moderator Raphael's Avatar
    Join Date
    Dec 2013
    Location
    raphseller.com
    Posts
    2,441
    Reputation
    309
    Rep Power
    28
    Quote Originally Posted by pedegie View Post
    Ye im sure, it worked few days ago, i didnt change anything. Now it shows that ss will be at 9:00 o'clock instead of 10:00 if im counting well.
    Can you please run the following code? Post the printed values and please also inform your location (Country/City) and timezone.

    print('os.date(\'*t\')')
    print(os.date('*t'))
    print('os.date(\'!*t\')')
    print(os.date('!*t'))
    print('os.date(\'!%X\')')
    print(os.date('!%X'))
    print('os.date(\'%X\')')
    print(os.date('%X'))
    print('utcoffset()')
    print(utcoffset())
    print('cetoffset()')
    print(cetoffset())
    print('utctime()')
    print(utctime())
    print('cettime()')
    print(cettime())
    print('sstime()')
    print(sstime())
    Last edited by Raphael; 02-24-2016 at 08:45 PM.

  7. #7
    Free User pedegie's Avatar
    Join Date
    Dec 2015
    Location
    Poland
    Posts
    264
    Reputation
    28
    Rep Power
    17
    Poland,(UTC+01:00) Sarajewo, Skopie, Warsaw, Zagrzeb


    @Raphael

  8. #8
    Moderator Raphael's Avatar
    Join Date
    Dec 2013
    Location
    raphseller.com
    Posts
    2,441
    Reputation
    309
    Rep Power
    28
    Try with this version:
    Attached Files Attached Files
    Last edited by Raphael; 02-10-2016 at 04:28 PM.

  9. #9
    Free User pedegie's Avatar
    Join Date
    Dec 2015
    Location
    Poland
    Posts
    264
    Reputation
    28
    Rep Power
    17
    I replaced files and reload libraries and still same, there was a typo btw


  10. #10
    Moderator Raphael's Avatar
    Join Date
    Dec 2013
    Location
    raphseller.com
    Posts
    2,441
    Reputation
    309
    Rep Power
    28
    Try again with this one: (please recopy the printing script, as I've changed a few things on it)
    Attached Files Attached Files

 

 

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •