jigsgfx Posted December 20, 2012 Group: Members Topic Count: 20 Topics Per Day: 0.00 Content Count: 83 Reputation: 0 Joined: 06/02/12 Last Seen: June 11, 2018 Share Posted December 20, 2012 (edited) hi, i have this pvp warper script.. and i want it to set autohide or disable every 14:00 and enable again @ 16:00 same with the duplicate npcs .. i tried to add code using enable and disable but its not working with no error on my SSH.. please correct me if i did wrong.. here's the script thanks in advance to those who will help me turbo_room,87,117,6 script PVP Warper 470,{ mes "[Pvp Warper]"; mes "Would You Like Join sRO Pvp Arena"; next; menu "PvP Arena",Arena,"Cancel",Cancel; Arena: mes "[Pvp Warper]"; mes "Are You Ready?"; next; mes "Let Go!!"; next; warp "guild_vs5",0,0; L_All: announce "[Pvp Warper]: "+strcharinfo(0)+" Has Enter Pvp Arena come and Kill him!",bc_all,0xFF9500; close; Cancel: mes "[Pvp Warper]"; mes "Wah !! So Fast u're Surrender"; next; mes "See You Again"; next; emotion e_pif; close; OnClock1600: enablenpc "PVP Warper"; end; OnInit: OnClock1400: disablenpc "PVP Warper"; end; } prontera.gat,151,187,4 duplicate(PVP Warper) PVP Warper#p1-1 469 morocc.gat,159,97,4 duplicate(PVP Warper) PVP Warper#p1-2 469 geffen.gat,111,63,4 duplicate(PVP Warper) PVP Warper#p1-3 469 geffen.gat,111,63,4 duplicate(PVP Warper) PVP Warper#p1-4 469 payon.gat,169,229,4 duplicate(PVP Warper) PVP Warper#p1-5 469 alberta.gat,188,149,4 duplicate(PVP Warper) PVP Warper#p1-6 469 izlude.gat,138,110,4 duplicate(PVP Warper) PVP Warper#p1-7 469 aldebaran.gat,144,123,4 duplicate(PVP Warper) PVP Warper#p1-8 469 xmas.gat,142,126,4 duplicate(PVP Warper) PVP Warper#p1-9 469 comodo.gat,207,152,4 duplicate(PVP Warper) PVP Warper#p1-10 469 hugel.gat,102,149,4 duplicate(PVP Warper) PVP Warper#p1-11 469 Edited December 20, 2012 by jigsgfx Quote Link to comment Share on other sites More sharing options...
mleo1 Posted December 20, 2012 Group: Members Topic Count: 22 Topics Per Day: 0.00 Content Count: 123 Reputation: 4 Joined: 11/21/11 Last Seen: January 26 Share Posted December 20, 2012 [b]OnInit:[/b] [b]OnClock1400:[/b] [b]disablenpc "PVP Warper";[/b] OnInit it will disable. try to remove oninit Quote Link to comment Share on other sites More sharing options...
Joseph Posted December 20, 2012 Group: Members Topic Count: 5 Topics Per Day: 0.00 Content Count: 341 Reputation: 43 Joined: 01/10/12 Last Seen: June 29, 2020 Share Posted December 20, 2012 You can add a check under OnInit to see if the time is within 14:00-16:00. OnInit: .@hour = gettime(3); if (.@hour >= 14 && .@hour < 16) disablenpc strnpcinfo(0); else enablenpc strnpcinfo(0); end; OnClock1400: disablenpc strnpcinfo(0); end; OnClock16000: enablenpc strnpcinfo(0); end; Quote Link to comment Share on other sites More sharing options...
jigsgfx Posted December 20, 2012 Group: Members Topic Count: 20 Topics Per Day: 0.00 Content Count: 83 Reputation: 0 Joined: 06/02/12 Last Seen: June 11, 2018 Author Share Posted December 20, 2012 (edited) thanks guys ill try this out.. btw will it disable also the duplicate npcs? Edited December 20, 2012 by jigsgfx Quote Link to comment Share on other sites More sharing options...
Joseph Posted December 20, 2012 Group: Members Topic Count: 5 Topics Per Day: 0.00 Content Count: 341 Reputation: 43 Joined: 01/10/12 Last Seen: June 29, 2020 Share Posted December 20, 2012 Use strnpcinfo(0) instead of specifying the NPC name as each NPC has different name (hidden name). OnInit: .@hour = gettime(3); if (.@hour >= 14 && .@hour < 16) disablenpc strnpcinfo(0); else enablenpc strnpcinfo(0); end; OnClock1400: disablenpc strnpcinfo(0); end; OnClock16000: enablenpc strnpcinfo(0); end; Quote Link to comment Share on other sites More sharing options...
jigsgfx Posted December 21, 2012 Group: Members Topic Count: 20 Topics Per Day: 0.00 Content Count: 83 Reputation: 0 Joined: 06/02/12 Last Seen: June 11, 2018 Author Share Posted December 21, 2012 i see thanks, it work like a charm Quote Link to comment Share on other sites More sharing options...
Question
jigsgfx
hi, i have this pvp warper script.. and i want it to set autohide or disable every 14:00 and enable again @ 16:00 same with the duplicate npcs ..
i tried to add code using enable and disable but its not working with no error on my SSH..
please correct me if i did wrong..
here's the script thanks in advance to those who will help me
Edited by jigsgfxLink to comment
Share on other sites
5 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.