iZeal 5 Posted June 20, 2014 Is it possible to have an @monster that spawns the monster on a random location on a Map like: @monster2 argiope prontera then it will spawn on different location of the map.. is it possible? Quote Share this post Link to post Share on other sites
0 Sunzuki 1 Posted June 23, 2014 (edited) - script OnInit -1,{end;OnInit: bindatcmd "monster2", "AtCommands::OnMonster2", <GM Level>, 99;end;}- script AtCommands -1,{end;OnMonster2: if(getarraysize(.@atcmd_parameters$) == 1) { set .@mobid,.@atcmd_parameters$[0]; monster ""+strcharinfo(3)+"",0,0,""+strmobinfo(1, .@mobid)+"",.@mobid,1; } else if(getarraysize(.@atcmd_parameters$) == 2) { set .@mobid,.@atcmd_parameters$[0]; set .@map$,.@atcmd_parameters$[1]; monster ""+.@map$+"",0,0,""+strmobinfo(1, .@mobid)+"",.@mobid,1; } else if(getarraysize(.@atcmd_parameters$) == 3) { set .@mobid,.@atcmd_parameters$[0]; set .@amount,.@atcmd_parameters$[1]; if(!.@amount) set .@amount,1; set .@map$,.@atcmd_parameters$[2]; monster ""+.@map$+"",0,0,""+strmobinfo(1, .@mobid)+"",.@mobid,.@amount; } else { message strcharinfo(0), "Wrong command format. Possible formats:"; message strcharinfo(0), " - @monster2 <Mob ID> <amount> <map>"; message strcharinfo(0), " - @monster2 <Mob ID> <map>"; message strcharinfo(0), " - @monster2 <Mob ID>"; message strcharinfo(0), "@monster2 failed."; }end;} It could basically work like that, but I'm not good of a coder and I don't know how to check if a monster ID or a map is valid. There will be a console message when someone enters invalid values I assume. Don't forget to change gm level if you use it Edited June 23, 2014 by Sunzuki 1 iZeal reacted to this Quote Share this post Link to post Share on other sites
0 iZeal 5 Posted June 24, 2014 I will try this Thank you Quote Share this post Link to post Share on other sites
Is it possible to have an @monster that spawns the monster on a random location on a Map like: @monster2 argiope prontera then it will spawn on different location of the map.. is it possible?
Share this post
Link to post
Share on other sites