Jump to content
  • 0

Kick from a map


Question

8 answers to this question

Recommended Posts

  • 1
Posted

-	script	baselvl_kick_map	-1,{
	
	OnInit:
		.max_level = 150;
		.map$ = "prontera";
		setmapflag .map$,mf_loadevent;
		end;
		
	OnPCLoadMapEvent:
		if ( strcharinfo(3) == .map$ && BaseLevel >= .max_level ) {
			warp "SavePoint",0,0;
		}
		end;
}

 

  • Upvote 1
  • 0
Posted (edited)
8 minutes ago, Azura Skyy said:

You could use OnPCBaseLvUpEvent, do a check for, BaseLevel, and warp the user wherever you'd like. With this example, nothing happens if you aren't hitting level 150

 


OnPCBaseLvUpEvent:
if (BaseLevel > 149) {
	warp "prontera", 150,150;
	close;
}
end;

 

Hope this helps,
~Azura Skyy

-	script	baselvl_kick_map	-1,{
	
	OnInit:
		.max_level = 150;
		.map$ = "prontera";
		setmapflag .map$,mf_loadevent;
		end;
		
	OnPCLoadMapEvent:
		if ( strcharinfo(3) == .map$ && BaseLevel >= .max_level ) {
			warp "SavePoint",0,0;
		}
		end;
}

thank you. i believe that will solve my problem 

Edited by Frozie
  • 0
Posted
Just now, Frozie said:

thank you. i believe that will solve my problem 

I was in the process of correcting mine. Mine would warp you to specific coordinates anytime you hit level 150 regardless of map. Refer to Emistry's post.

Regards,
~Azura Skyy

  • 0
Posted
2 minutes ago, Azura Skyy said:

would warp you to specific coordinates anytime you hit level 150 regardless of map.

yup, but they can re-enter the map, but your script also affect players in other map since it doesnt have the map checking.

anyway, combination of OnPCBaseLvUpEvent + OnPCLoadMapEvent = ideal solution.

 

  • 0
Posted (edited)
39 minutes ago, Emistry said:

yup, but they can re-enter the map, but your script also affect players in other map since it doesnt have the map checking.

anyway, combination of OnPCBaseLvUpEvent + OnPCLoadMapEvent = ideal solution.

 

umm.. i alr try the script and the result is when my char level up to 150, it didnt kick me out of the map instantly..

instead i must relog first for it to kick me out of the map..

---------------------------------------

woot i got the solution.. i try to add this to emistry script and it works.. i got kick when i reach 150 and i cant get in there again..

	OnPCBaseLvUpEvent:
		if ( strcharinfo(3) == .map$ && BaseLevel >= .max_level ) {
			warp "SavePoint",0,0;
		}
		end;

 

Edited by Frozie
  • 0
Posted
56 minutes ago, Frozie said:

woot i got the solution.. i try to add this to emistry script and it works.. i got kick when i reach 150 and i cant get in there again..


	OnPCBaseLvUpEvent:
		if ( strcharinfo(3) == .map$ && BaseLevel >= .max_level ) {
			warp "SavePoint",0,0;
		}
		end;

 

You have to keep Emistry's OnPCLoadMapEvent: to accommodate the players who are already level 150 and just happened to be there suddenly.

  • 0
Posted
Just now, Neffletics said:

You have to keep Emistry's OnPCLoadMapEvent: to accommodate the players who are already level 150 and just happened to be there suddenly.

yea i keep that too, i only add that OnPCBaseLvUpEvent part

  • -1
Posted (edited)

You could use OnPCBaseLvUpEvent, do a check for, BaseLevel, and warp the user wherever you'd like. With this example, nothing happens if you aren't hitting level 150

 

OnPCBaseLvUpEvent:
if (BaseLevel > 149) {
	warp "prontera", 150,150;
	close;
}
end;

 

Hope this helps,
~Azura Skyy

Edited by Azura Skyy

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...