Thread: GS2 'cron jobs'
View Single Post
  #3  
Old 05-11-2009, 09:57 PM
LoneAngelIbesu LoneAngelIbesu is offline
master of infinite loops
LoneAngelIbesu's Avatar
Join Date: May 2007
Location: Toldeo, Ohio
Posts: 1,049
LoneAngelIbesu has a spectacular aura aboutLoneAngelIbesu has a spectacular aura about
Send a message via AIM to LoneAngelIbesu
Quote:
Originally Posted by Tigairius View Post
There is, but scheduled events are cancelled when the npcserver restarts, so it would be better to use a sleep or a timeout which is not interrupted by the npcserver.
Timeouts are reset each time the weapon is updated, right? Is there any way to prevent this, or would I have to create a separate weapon for the timeout?
Quote:
Originally Posted by Loriel View Post
This is retarded, just do nothing until a player actually enters the shop and then calculate how much restocking you have to do.
That would defeat the purpose. I don't want the shops to have an endless stock of items at all times. I want a static amount of items each 24 hours; more specific, I want to make sure that there's nothing out of stock after 24 hours. Calculating when 24 hours has passed based on players entering the level seems overly complicated, especially since no facet of the system is used in level NPCs.
__________________
"We are all in the gutter, but some of us are looking at the stars."
— Oscar Wilde, Lady Windermere's Fan

Last edited by LoneAngelIbesu; 05-11-2009 at 10:17 PM..
Reply With Quote