- script Sample -1,{ OnInit: setarray .Maps$[0],"prontera","payon","geffen"; .mob_id = 1002; end; OnMinute00: .random_index = rand(getarraysize(.Maps$)); monster .Maps$[.random_index],0,0,getmonsterinfo(.mob_id,0),.mob_id,1,strnpcinfo(1)+"::OnKill"; announce getmonsterinfo(.mob_id,0)+ " has been spawned on map " +.Maps$[.random_index],0; end; OnKill: announce getmonsterinfo(.mob_id,0)+ " has been killed and will spawn again at " +(gettime(3)+1)+ ":" +gettime(2)+ " " +(gettime(3)+1>11?"PM":"AM"),0; end;}
Yeah, it's an MvP (or whichever mob you want to spawn, this one is in fact a poring) each hour, on a random city. If you want to add more monsters and maps there please use my script modification of Patskie's:how do i add monster and map here? is it every hour of mvp?
sorry newbie in scripting.
Thx
- script Sample -1,{ OnInit: setarray .Maps$[0],"prontera","payon","geffen","aldebaran"; // Add more map names here following this syntax (up to 128) setarray .mob_ids[0], 1002,1031,1062,1090,1096,1120,1388,1582,1613,1836,1894; // Add more mob IDs here following this syntax (up to 128) end; OnMinute00: .random_map = rand(getarraysize(.Maps$)); .random_mob = rand(getarraysize(.mob_ids)); monster .Maps$[.random_map],0,0,getmonsterinfo(.mob_ids[.random_mob],0),.mob_ids[.random_mob],1,strnpcinfo(3)+"::OnKill"; announce getmonsterinfo(.mob_ids[.random_mob],0)+ " has been spawned on map " +.Maps$[.random_map],0; end; OnKill: announce getmonsterinfo(.mob_ids[.random_mob],0)+ " has been killed and will spawn again at " +(gettime(3)+1)+ ":" +gettime(2)+ " " +(gettime(3)+1>11?"PM":"AM"),0; end;}
setarray .mob_ids[0],1002,1031,1062,1090,1096,1120,1388,1582,1613,1836,1894; // Add more mob IDs here following this syntax (up to 128)
sir, can u make its announce all mvp from mob_db and all map?Whoa, that's true Patskie. I don't know why the parser passed that but I didn't test the script. Thanks!
@themon There's no big deal, just change the regular spaces on the first line of Patskie's answer to tabulation spaces and it's OK.
Yes, but the NPC is way too different to this one in that case.sir, can u make its announce all mvp from mob_db and all map?Whoa, that's true Patskie. I don't know why the parser passed that but I didn't test the script. Thanks!
@themon There's no big deal, just change the regular spaces on the first line of Patskie's answer to tabulation spaces and it's OK.
Sorry, but scripting engine won't allow you to get the MvP of the monster, so either you conform with that or there's nothing you can do unless you edit the source.This script is flawed because it does not announce who really won the MVP in the event of disputes, he announces who it was who gave the last attack.
We use essential cookies to make this site work, and optional cookies to enhance your experience.