Lil Troll Posted August 12, 2013 Group: Members Topic Count: 38 Topics Per Day: 0.01 Content Count: 276 Reputation: 24 Joined: 07/06/13 Last Seen: April 19, 2014 Share Posted August 12, 2013 (edited) turbo_room,113,89,3 script Server Time 1193,{ end; OnInit: while ( 1 ) { delwaitingroom strnpcinfo(0); waitingroom gettimestr( "[D%d]%I:%M:%S %p",21 ),0; sleep 1000; } end; } If this ^ ^ ^ is Server Time How can you do countdown BEFORE WOE and countdown WHEN WOE END? Bump... Heres the main idea.. prontera,150,150 script Woe Countdown Board#1 999,{ OnClock1900: hideonnpc "Woe Countdown Board#1"; // Appear One Hour Before WOE OnAgitStart: hideoffnpc "Woe Countdown Board#1"; end; OnInit: while ( 1 ) { delwaitingroom strnpcinfo(0); waitingroom gettimestr( "[WOE STARTS]%I:%M:%S %p",21 ),0; //How to make countdown to woe start? sleep 1000; } end; } // When WOE OnAgitStart Script #1 Will be gone, then OnAgitStart same NPC will appear replacing prontera,150,150 script Woe Countdown Board#2 999,{ OnAgitStart: hideoffnpc "Woe Countdown Board#1"; OnAgitEnd: hideonnpc "Woe Countdown Board#1"; end; OnInit: while ( 1 ) { delwaitingroom strnpcinfo(0); waitingroom gettimestr( "[WOE ENDS]%I:%M:%S %p",21 ),0; //How to make countdown woe to end? sleep 1000; } end; } Edited August 12, 2013 by Lil Troll Quote Link to comment Share on other sites More sharing options...
Reynard Posted August 12, 2013 Group: Members Topic Count: 2 Topics Per Day: 0.00 Content Count: 56 Reputation: 9 Joined: 09/22/12 Last Seen: August 16, 2020 Share Posted August 12, 2013 (edited) I dont have the time to write a script right now, but that function was present in Xeons WoE Setter v3, heres how he did it: while (1) { delwaitingroom; //Memory vortex restraining bolt, please don't remove it for the sake of humanity. if (.@woe_e-gettimetick(2) <= 0 || !$woe_chatinfo) { set .@timeset, query_sql("select st,et from `woe_times` order by `st` ASC",.@woe_s,.@woe_e); set $woe_chatinfo, 1; } if (.@timeset) { if (gettimetick(2)>.@woe_s) { set .@sec, .@woe_e-gettimetick(2); set .@day, .@sec / 86400; set .@hr, .@sec % 86400 / 3600; set .@min, .@sec % 3600 / 60; set .@sec, .@sec % 60; waitingroom "Ends: "+.@day+"d "+((.@hr<10)?"0":"")+.@hr+":"+((.@min<10)?"0":"")+.@min+((!.@hr&&!.@min&&.@sec<60)?":"+((.@sec<10)?"0":"")+.@sec:""),0; } else { set .@sec, .@woe_s-gettimetick(2); set .@day, .@sec / 86400; set .@hr, .@sec % 86400 / 3600; set .@min, .@sec % 3600 / 60; set .@sec, .@sec % 60; waitingroom "Next: "+.@day+"d "+((.@hr<10)?"0":"")+.@hr+":"+((.@min<10)?"0":"")+.@min+((!.@hr&&!.@min&&.@sec<60)?":"+((.@sec<10)?"0":"")+.@sec:""),0; } if (.@hr||.@min>1) { sleep 60000-(gettime(1)*1000); } else { sleep 1000; } } else { waitingroom "Next: N/A, none set!",0; sleep 60000-(gettime(1)*1000); } } Maybe this will help you to get an idea how you could do it. Source: http://www.eathena.ws/board/WoE-Setter-3-t198420.html Edited August 12, 2013 by Reynard Quote Link to comment Share on other sites More sharing options...
nobukadnezar Posted November 25, 2013 Group: Members Topic Count: 35 Topics Per Day: 0.01 Content Count: 163 Reputation: 7 Joined: 01/07/12 Last Seen: March 7, 2017 Share Posted November 25, 2013 i have question about this also. Could someone tell me how the time for woe start and woe stop stored since it must be change periodically and convert it to UNIX right? Because if we use condition that sub woe start with current time tick, when woe have been passed it will always have negative value right? Quote Link to comment Share on other sites More sharing options...
Question
Lil Troll
If this ^ ^ ^ is Server Time
How can you do countdown BEFORE WOE and countdown WHEN WOE END?
Bump...
Heres the main idea..
Edited by Lil TrollLink to comment
Share on other sites
2 answers to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.