Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- prontera,119,168,6 script Skormy 904,{
- if(getgmlevel()<.gmlevel) end;
- set .@MVPID,-3;
- L_Menu:
- mes .NPC$;
- mes "Select an option from the menu below and click [ ^0000FFSummon!^000000 ] when you're done.";
- next;
- if(.@MVPID==-3){ set .@tmp$,"Random MVP"; } else { set .@tmp$,getmonsterinfo(.@MVPID,0); }
- Switch(select("Monster ID ( ^0000FF"+.@tmp$+"^000000 ) :Map Name ( ^0000FF"+.@MAPNAME$+"^000000 ) :Amount ( ^0000FF"+.@AMOUNT+"^000000 ):[ ^0000FFSummon!^000000 ]")) {
- case 1:
- mes .NPC$;
- mes "Input the id of the monster you'd like to spawn.";
- next;
- input(.@MVPID);
- while(!query_sql("(SELECT `ID` from `mob_db` where `ID` = "+.@MVPID+") UNION ALL (SELECT `ID` from `mob_db2` where `ID` = "+.@MVPID+" LIMIT 1);",.@a))
- input(.@MVPID);
- if( compare(.blacklist$,"|"+.@MVPID+"|" ) ) {
- message strcharinfo(0),"I'm sorry but "+getmonsterinfo(.@MVPID,0)+" was blacklisted!";
- message strcharinfo(0),"Please use a different id.";
- set(.@MVPID,0);
- }
- goto L_Menu;
- case 2:
- mes .NPC$;
- mes "Input the name of the map you'd like to spawn the monster on.";
- next;
- input(.@MAPNAME$);
- while(mobcount(.@MAPNAME$,"all")==-1){
- input(.@MAPNAME$);
- if(mobcount(.@MAPNAME$,"all")!=-1){
- mes "Would you like to spawn "+(.@MVPID==-3?"Random MVPs":getmonsterinfo(.@MVPID,0))+" on the map "+.@MAPNAME$+"?";
- next;
- if(select("Yes:No")-1) { set .@MAPNAME$,""; continue; } else { break; }
- }
- }
- goto L_Menu;
- case 3:
- mes .NPC$;
- mes "Input the amount you'd like to spawn.";
- mes "( Maximum "+.Lamount+" )";
- next;
- input(.@AMOUNT);
- while(.@AMOUNT<=0||.@AMOUNT>.Lamount) {
- input(.@AMOUNT);
- if(.@AMOUNT>0&&.@AMOUNT<=.Lamount) {
- mes "Would you like to spawn "+.@AMOUNT+" monsters?";
- next;
- if(select("Yes:No")-1) { set .@AMOUNT,0; continue; } else { break; }
- }
- }
- goto L_Menu;
- case 4:
- if( mobcount(.@MAPNAME$,"all")==-1 || .@AMOUNT<=0 ) {
- if(!.fiesta) {
- mes .NPC$;
- mes "I'm sorry you need to fill-out all the fields before summoning a monster!";
- next;
- goto L_Menu;
- } else {
- if(mobcount(.@MAPNAME$,"all")==-1) set .@MAPNAME$,"this";
- if(.@AMOUNT<=0) set .@AMOUNT,.fiesta;
- }
- }
- if(.Mamount){
- if(mobcount(.@MAPNAME$,"MVP Spawner::OnMVPDeath")+.@AMOUNT>.Mamount&&.Mamount>0) {
- mes .NPC$;
- mes "I'm sorry but there can only be "+.Mamount+" MVPs in one map.";
- set .@tmp,.Mamount-mobcount(.@MAPNAME$,"MVP Spawner::OnMVPDeath");
- if(.@tmp>0) {
- mes "Would you like to spawn "+.@tmp+" instead?";
- if(select("Yes:No")-1) { mes "Ok!"; close; }
- announce ""+strcharinfo(0)+" : Summoned "+.@AMOUNT+" "+.@tmp$+"(s) in "+(.@MAPNAME$=="this"?strcharinfo(3):.@MAPNAME$)+".",bc_all,"0x"+.fontcolor$;
- monster .@MAPNAME$,0,0,"--ja--",.@MVPID,.@tmp,"MVP Spawner::OnMVPDeath";
- close;
- }
- next;
- goto L_Menu;
- }
- }
- announce ""+strcharinfo(0)+" : Summoned "+.@AMOUNT+" "+.@tmp$+"(s) in "+(.@MAPNAME$=="this"?strcharinfo(3):.@MAPNAME$)+".",bc_all,"0x"+.fontcolor$;
- monster .@MAPNAME$,0,0,"--ja--",.@MVPID,.@AMOUNT,"MVP Spawner::OnMVPDeath";
- close;
- }
- end;
- OnMVPDeath:
- end;
- OnInit:
- //=-=-=-=-=-=Configuration=-=-=-=-=-=
- set .NPC$,"[ ^D2691ESkormy^000000 ]"; // Npc Name
- set .gmlevel,99; //Minimum Gm level allowed to spawn MVPS.
- set .fiesta,0; // If enabled will spawn that many random MVPs on the players map if no other information is provided! (Off=0) Will bypass Maximum amount!
- set .fontcolor$,"FFFF00"; // Hexi color text is announced in.
- set .Lamount,150; // Maximum amount of mvps that can be spawned at once.
- set .Mamount,0; // Maximum amount of mvps on one map at a time. (Off=0)
- set .blacklist$,"|1002|1003|1004|1005|";
- //=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement