I am trying to make this script work, am not sure whats wrong? Anyone can help?
need to be able to properly execute a random date/time-triggered activation where target NPC warps from original position to a random map with random xy coordinates, and returns to original position after an hour. so far all attempts at tweaking the script doesn't execute the "return to original position" part.
- script EndActive -1,{
OnInit:
OnDay0101:
OnDay0201:
OnDay0301:
OnDay0401:
OnDay0501:
OnDay0601:
OnDay0701:
OnDay0801:
OnDay0901:
OnDay1001:
OnDay1101:
OnDay1201:
setarray .@amonwarp$[0],"prontera","geffen","morocc","aldebaran","xmas","yuno","alberta","rachel","veins","hugel","payon","umbala","jawaii","comodo","niflheim","ayothaya","gonryun","louyang","mid_camp","lighthalzen","einbech","einbroch";
setarray .@monthday[0],01,02,03,04,05,06,07,08,09,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28;
setarray .@daytime[0],10,11,12,13,14,15,16,17,18,19,20,21,22;
if (gettime(5) == .@monthday[rand(28)] && gettime(3) == .@daytime[rand(14)])
while(1) {
set $@jx,rand(30,225);
set $@jy,rand(30,225);
unitwarp getnpcid(0,"Amon"),""+.@amonwarp$[rand(22)]+"",$@jx,$@jy;
if(checkcell(""+.@amonwarp$+"",$@jx,$@jy,cell_chkpass) == 1) break;
}
announce "An unspeakable evil has appeared. Netorian, Irunite and Schicksal units, proceed with caution.",bc_all,0xFF0000;
end;
}
else {
unitwarp getnpcid(0,"Amon"),"jupe_area2",145,10;
announce "Absolute Evil has retreated back into the Void. Everyone, be vigilant.",bc_all,0xFF0000;
end;
}
}
Question
chronoscrowler
Requesting for support!
I am trying to make this script work, am not sure whats wrong? Anyone can help?
need to be able to properly execute a random date/time-triggered activation where target NPC warps from original position to a random map with random xy coordinates, and returns to original position after an hour. so far all attempts at tweaking the script doesn't execute the "return to original position" part.
- script EndActive -1,{ OnInit: OnDay0101: OnDay0201: OnDay0301: OnDay0401: OnDay0501: OnDay0601: OnDay0701: OnDay0801: OnDay0901: OnDay1001: OnDay1101: OnDay1201: setarray .@amonwarp$[0],"prontera","geffen","morocc","aldebaran","xmas","yuno","alberta","rachel","veins","hugel","payon","umbala","jawaii","comodo","niflheim","ayothaya","gonryun","louyang","mid_camp","lighthalzen","einbech","einbroch"; setarray .@monthday[0],01,02,03,04,05,06,07,08,09,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28; setarray .@daytime[0],10,11,12,13,14,15,16,17,18,19,20,21,22; if (gettime(5) == .@monthday[rand(28)] && gettime(3) == .@daytime[rand(14)]) while(1) { set $@jx,rand(30,225); set $@jy,rand(30,225); unitwarp getnpcid(0,"Amon"),""+.@amonwarp$[rand(22)]+"",$@jx,$@jy; if(checkcell(""+.@amonwarp$+"",$@jx,$@jy,cell_chkpass) == 1) break; } announce "An unspeakable evil has appeared. Netorian, Irunite and Schicksal units, proceed with caution.",bc_all,0xFF0000; end; } else { unitwarp getnpcid(0,"Amon"),"jupe_area2",145,10; announce "Absolute Evil has retreated back into the Void. Everyone, be vigilant.",bc_all,0xFF0000; end; } }
Link to comment
Share on other sites
1 answer to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.