Puera Posted August 17, 2017 Group: Members Topic Count: 1 Topics Per Day: 0.00 Content Count: 5 Reputation: 0 Joined: 07/26/17 Last Seen: November 28, 2017 Share Posted August 17, 2017 (edited) The title self explain .... its possible? Thanks Edited August 17, 2017 by Puera Quote Link to comment Share on other sites More sharing options...
0 Z3R0 Posted August 17, 2017 Group: Members Topic Count: 39 Topics Per Day: 0.01 Content Count: 618 Reputation: 201 Joined: 11/09/11 Last Seen: June 14, 2024 Share Posted August 17, 2017 What map? How do the players get to the map? If it's viper only then check onpcloadmapevent... then run a loop timer on players that have entered that map and check their status... if expire warp out. Quote Link to comment Share on other sites More sharing options...
0 Puera Posted August 17, 2017 Group: Members Topic Count: 1 Topics Per Day: 0.00 Content Count: 5 Reputation: 0 Joined: 07/26/17 Last Seen: November 28, 2017 Author Share Posted August 17, 2017 32 minutes ago, Z3R0 said: What map? How do the players get to the map? If it's viper only then check onpcloadmapevent... then run a loop timer on players that have entered that map and check their status... if expire warp out. My custom map , only vip members. But onpcloadmapevent its only loading the map correct? If the player is inside the map and the VIP expires he will not be kicked off the map. Quote Link to comment Share on other sites More sharing options...
0 benching Posted August 17, 2017 Group: Members Topic Count: 26 Topics Per Day: 0.01 Content Count: 350 Reputation: 43 Joined: 09/07/12 Last Seen: August 30, 2019 Share Posted August 17, 2017 Im not sure of whats the best way to do that, But as temporary, you can use the ontick/ontimer. Quote Link to comment Share on other sites More sharing options...
0 Z3R0 Posted August 18, 2017 Group: Members Topic Count: 39 Topics Per Day: 0.01 Content Count: 618 Reputation: 201 Joined: 11/09/11 Last Seen: June 14, 2024 Share Posted August 18, 2017 Right but I am assuming viper players use either a warp or npc to get to that map... meaning u could record all the charid... that go there into an array... using a check say every OnMinute15: loop through array and delete any chars from the array that are no longer logged in or on that map... and check their expire times... if their time is expired then boot em... if they onpcloadmapevent ... meaning they logged out on that map and warped back in check their viper and either kick em if expired or add their code back into the array Quote Link to comment Share on other sites More sharing options...
0 Puera Posted August 18, 2017 Group: Members Topic Count: 1 Topics Per Day: 0.00 Content Count: 5 Reputation: 0 Joined: 07/26/17 Last Seen: November 28, 2017 Author Share Posted August 18, 2017 (edited) 1 hour ago, Z3R0 said: Right but I am assuming viper players use either a warp or npc to get to that map... meaning u could record all the charid... that go there into an array... using a check say every OnMinute15: loop through array and delete any chars from the array that are no longer logged in or on that map... and check their expire times... if their time is expired then boot em... if they onpcloadmapevent ... meaning they logged out on that map and warped back in check their viper and either kick em if expired or add their code back into the array Here's my current teleporter script prontera,142,179,6 script Teleporter Vip Room 984,{ mes "[ ^0065DFHueRO Vip Room Warper^000000 ]"; mes "Would you like to enter"; mes "the HueRO Vip Room?"; next; if (select("Yes!","No thanks.") == 2) close; if(vip_status(1)){ warp "vip_room",360,61; }else{ mes ""; mes "You are not vip, please get your vip in the npc ^0065DFHueRO Vip System^000000"; } close; } - script kickmap_vip -1,{ OnPCLoadMapEvent: if ( strcharinfo(3) == "vip_room" && !vip_status(1) && getgmlevel()==0) { warp "SavePoint",0,0; } } vip_room mapflag loadevent That way it works but only when loading a map, but if the vip expires inside the map he can stay in there until you logout How would I get your idea from this script? Edited August 18, 2017 by Puera Quote Link to comment Share on other sites More sharing options...
0 M4karov Posted August 18, 2017 Group: Members Topic Count: 30 Topics Per Day: 0.01 Content Count: 149 Reputation: 37 Joined: 04/01/13 Last Seen: June 18, 2024 Share Posted August 18, 2017 22 minutes ago, Puera said: Aqui está o meu script de teleporter atual Prontera 142,179,6 script Teleporter Vip Room 984, { mes "[^ 0065DFHueRO Vip Room Warper ^ 000000]"; Mes "Deseja entrar"; Show "HueRO Vip Room?"; Próximo; Se (selecione ("Sim!", "Não, obrigado.") == 2) feche; Se (vip_status (1)) { warp "vip_room", 360,61; } Else { mes ""; Mes "Você não é vip, pegue seu vip no npc ^ 0065DFHueRO Vip System ^ 000000"; } Fechar; } - script kickmap_vip -1, { OnPCLoadMapEvent: if (strcharinfo (3) == "vip_room" &&! Vip_status (1) && getgmlevel () == 0) { warp "SavePoint", 0,0; } } Vip_room mapflag loadevent Dessa forma, funciona, mas apenas quando carrega um mapa, mas se o vip expirar dentro do mapa, ele pode permanecer lá até você sair Como eu conseguiria sua idéia desse script? - script kickmap_vip -1,{ OnInit: .Time = 5; while( 1 ){ if (strcharinfo (3) == "vip_room" &&! Vip_status (1) && getgmlevel () == 0) { warp "SavePoint", 0,0; } sleep ( .Time * 60000 ); } end; } Quote Link to comment Share on other sites More sharing options...
0 Puera Posted August 18, 2017 Group: Members Topic Count: 1 Topics Per Day: 0.00 Content Count: 5 Reputation: 0 Joined: 07/26/17 Last Seen: November 28, 2017 Author Share Posted August 18, 2017 4 minutes ago, M4karov said: - script kickmap_vip -1,{ OnInit: .Time = 5; while( 1 ){ if (strcharinfo (3) == "vip_room" &&! Vip_status (1) && getgmlevel () == 0) { warp "SavePoint", 0,0; } sleep ( .Time * 60000 ); } end; } Console Errro: buildin_strcharinfo fatal error! player not attached! Quote Link to comment Share on other sites More sharing options...
0 M4karov Posted August 18, 2017 Group: Members Topic Count: 30 Topics Per Day: 0.01 Content Count: 149 Reputation: 37 Joined: 04/01/13 Last Seen: June 18, 2024 Share Posted August 18, 2017 1 hour ago, Puera said: Console Errro: buildin_strcharinfo fatal error! player not attached! Sorry. - script kickmap_vip -1,{ OnInit: .map$ = "prontera"; .interval = 5; setmapflag .map$, mf_loadevent; end; OnPCLoadMapEvent: if (strcharinfo(3) == .map$) { if (!vip_status(VIP_STATUS_ACTIVE) ) { warp "SavePoint",0,0; } else { addtimer (.interval * 1000), strnpcinfo(0)+"::OnPCLoadMapEvent"; } } end; } Quote Link to comment Share on other sites More sharing options...
Question
Puera
The title self explain ....
its possible?
Thanks
Edited by PueraLink to comment
Share on other sites
8 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.