Jump to content
  • 0

Question

Posted
I want to do this and I have no idea.
 
This image is a time counter that the character is online, the counter returns to 0 when it returns to login.
thump_9166879shot00009.jpg


This image is the same as the first, but the time that the server is online
thump_9166884shot00010.jpg

 

The part in the htm ready, but I need the java side

Thanks in advance and sorry for my english..

11 answers to this question

Recommended Posts

  • 0
Posted
// Server Time
private static String getServerRunTime()
{
int timeSeconds = (GameTimeController.getGameTicks() - 36000) / 10;
String timeResult = (timeSeconds >= 86400 ? Integer.toString(timeSeconds / 86400) + " Days " + Integer.toString((timeSeconds % 86400) / 3600) + " hours." : Integer.toString(timeSeconds / 3600) + " Hours " + Integer.toString((timeSeconds % 3600) / 60) + " mins.");
return timeResult;
}

  • 0
Posted

 

I want to do this and I have no idea.
 
This image is a time counter that the character is online, the counter returns to 0 when it returns to login.
thump_9166879shot00009.jpg

This image is the same as the first, but the time that the server is online
thump_9166884shot00010.jpg

 

The part in the htm ready, but I need the java side

Thanks in advance and sorry for my english..

 

you want that on npcright??

  • 0
Posted (edited)

Sorry for the delayed response, I was sick.

 

I am creating a npc/command which displays the statistics of the character and server. What I lack is the code to display the time line of the session character and server.

 

Sorry for my eng

Edited by ElBato
  • 0
Posted

so you actually need a time counter that will get increased until a player log out?

Yes

 

 

// Server Time
private static String getServerRunTime()
{
int timeSeconds = (GameTimeController.getGameTicks() - 36000) / 10;
String timeResult = (timeSeconds >= 86400 ? Integer.toString(timeSeconds / 86400) + " Days " + Integer.toString((timeSeconds % 86400) / 3600) + " hours." : Integer.toString(timeSeconds / 3600) + " Hours " + Integer.toString((timeSeconds % 3600) / 60) + " mins.");
return timeResult;
}

 

Thanks ExCaLiBuR®, u are amazing.. 1 less, lack the other :D
Guest
This topic is now closed to further replies.


  • Posts

    • ➡ Discount for your purchase: APRIL (10% discount) ➡ Our Online Shop: https://socnet.store ✅ ➡ Our SMM-Boosting Panel: https://socnet.pro ✅ ➡ Telegram Shop Bot: https://socnet.shop ✅ ➡ Telegram Support: https://t.me/solomon_bog ✅ ➡ Telegram Channel: https://t.me/accsforyou_shop ✅ ➡ Discord Support: @AllSocialNetworksShop ✅ ➡ Discord Server: https://discord.gg/y9AStFFsrh ✅ ➡ WhatsApp Support: https://wa.me/79051904467✅ ➡ WhatsApp Channel: https://whatsapp.com/channel/0029Vau0CMX002TGkD4uHa2n ✅ ➡ Email Support: solomonbog@socnet.store ✅
    • ➡ Discount for your purchase: APRIL (10% discount) ➡ Our Online Shop: https://socnet.store ✅ ➡ Our SMM-Boosting Panel: https://socnet.pro ✅ ➡ Telegram Shop Bot: https://socnet.shop ✅ ➡ Telegram Support: https://t.me/solomon_bog ✅ ➡ Telegram Channel: https://t.me/accsforyou_shop ✅ ➡ Discord Support: @AllSocialNetworksShop ✅ ➡ Discord Server: https://discord.gg/y9AStFFsrh ✅ ➡ WhatsApp Support: https://wa.me/79051904467✅ ➡ WhatsApp Channel: https://whatsapp.com/channel/0029Vau0CMX002TGkD4uHa2n ✅ ➡ Email Support: solomonbog@socnet.store ✅
    • Hey. I've been looking all over the internet about this but not being able to find anything about it. I have edited systemmsg using MSG editor changing colors etc. But now I want to change and add some of the sounds as well. But I need the sound IDs for each audiofile and I dont know how to find them. Ive found all the audio files but I cant use the filename as someone said in a thread here, it only seem to take numbers. I have looked into every guide about systemmsg on this website and no one mention anything about the sound, just that its possible to add sound but nothing more. So, do anyone know how to find these sound IDs? Preferably together with the soundname of the audio file that it plays so I know which ID to use for each soundfile. Thanks in advance!
    • We are certainly not an ambulance, but we will definitely cure you of blacklists and empty pockets. Live freely with SX! Each of you will receive a trial version of SX to familiarize yourself with the product, all you have to do is post in this thread
  • Topics

×
×
  • Create New...