prontera,150,150,4 script Gold Easter Egg 4_DRAGON_EGG,{
OnInit:
if (strnpcinfo(0) == "Gold Easter Egg")
disablenpc strnpcinfo(0);
end;
OnEnableGoldEgg:
getmapxy .@map$, .@x, .@y, 1;
for (.@i = 0; .@i < 50; .@i++) { // 50 will be spawned
do {
.@x = rand(300);
.@y = rand(300);
} while ( checkcell( .@map$, .@x, .@y, cell_chknopass ) );
duplicatenpc(strnpcinfo(0),"Gold Easter Egg "+ .@i,"","prontera",.@x,.@y,5,998);
donpcevent "Gold Easter Egg "+ @i +"::OnEggMove";
}
OnEggMove:
npcspeed 100;
while ( true ) {
getmapxy .@map$, .@x, .@y, 1;
while ( checkcell( .@map$, .@x2 = .@x + rand(-10,10), .@y2 = .@y + rand(-10,10), cell_chknopass ) );
npcwalkto .@x2, .@y2;
sleep rand(500,1000);
}
end;
}
prontera,151,152,4 script Enabler 89,{
mes "Now enabling";
donpcevent ("Gold Easter Egg")+"::OnEnableGoldEgg";
close;
}