Issue Information
-
#001296
-
0 - None Assigned
-
Unable To Reproduce
Issue Confirmations
-
Yes (0)No (0)
Originally posted by Barron-Monster
http://www.eathena.w...er&showbug=1296
Well
You can use variable for map name in monster script command but if you use a var for map name in killmonster script command you'll get:
[Debug]: mapindex_id2name: Requested name for non-existant map index [0] in cache.
The killmonster will work bug why getting this stupid debug msg?
You can try the following script for try.
Ps: I don't care if the code sux it was for try.
http://www.eathena.w...er&showbug=1296
Well
You can use variable for map name in monster script command but if you use a var for map name in killmonster script command you'll get:
[Debug]: mapindex_id2name: Requested name for non-existant map index [0] in cache.
The killmonster will work bug why getting this stupid debug msg?
You can try the following script for try.
- script Dark_Lord_Invasion -1,{<br /> end;<br /><br />OnRandom:<br /> set $@maplordchoose,rand(22);<br /> setarray $@mapdarklord$[0], "prontera", "morocc", "geffen", "payon", "alberta", "izlude", "aldebaran", "xmas", "comodo", "yuno", "amatsu", "gonryun", "umbala", "niflheim", "louyang", "jawaii", "ayothaya", "einbroch", "lighthalzen", "hugel", "rachel", "veins";<br /> setarray $@mapdarklordx[0], 156, 159, 119, 155, 102, 128, 139, 145, 188, 158, 262, 159, 138, 193, 218, 203, 207, 131, 159, 146, 150, 197;<br /> setarray $@mapdarklordy[0], 285, 163, 112, 239, 221, 159, 144, 237, 165, 167, 191, 196, 227, 186, 121, 292, 227, 200, 130, 106, 242, 257;<br /> set $@mapchoosendarklord$, $@mapdarklord$[$@maplordchoose];<br /> set $@mapchoosendarklordx, $@mapdarklordx[$@maplordchoose];<br /> set $@mapchoosendarklordy, $@mapdarklordy[$@maplordchoose];<br /> end;<br /><br />OnClock0324:<br /> donpcevent "Dark_Lord_Invasion::OnRandom";<br /> donpcevent "DL_Invasion::OnEnable";<br /> end;<br />}<br /><br />- script Dark Lord::DL_Invasion -1,{<br /> end;<br /><br />OnEnable:<br /> Announce "Dark Lord: Mowhahahaha",8;<br /> Announce "Dark Lord: Ce soir mon couroux tombera sur " + $@mapchoosendarklord$ + ".",8;<br /> initnpctimer;<br /> end;<br /><br />OnTimer5000:<br /> donpcevent "DL_Invasion::OnFirstVague";<br /> end;<br /><br />OnTimer300000:<br /> if(.FirstVague > 0) {<br /> Announce "Dark Lord: Vous �tes vraiment pitoyable vous ne pouvez pas tuer de simple Skogul.",8;<br /> atcommand "@doommap";<br /> killmonster "" + $@mapchoosendarklord$ + "","DL_Invasion::OnMobDeadFirstVague";<br /> }<br /> end;<br /><br />OnFirstVague:<br /> set .FirstVague,15;<br /> monster "" + $@mapchoosendarklord$ + "",$@mapchoosendarklordx,$@mapchoosendarklordy,"Slave of Dark Lord",1752,15,"DL_Invasion::OnMobDeadFirstVague";<br /> end;<br /><br />OnMobDeadFirstVague:<br /> set .FirstVague,.FirstVague-1;<br /> if (.FirstVague < 1) {<br /> Announce "Dark Lord: Mowhahahaha",8;<br /> Announce "Dark Lord: Tr�s bien, passons � la suite.",8;<br /> }<br /> else {<br /> set .badluck,rand(1,25);<br /> if(.badluck == 3) {<br /> charcommand "#effect 183 "+strcharinfo(0);<br /> percentheal -100,0;<br /> Announce "Dark Lord: Voil� pour toi " + strcharinfo(0) + ".",8;<br /> Announce "Habitant de " + $@mapchoosendarklord$ + ": Ho non " + strcharinfo(0) + " vient d'�tre tuer par la vengeance de Dark Lord, il est vraiment sans coeur.",8;<br /> }<br /> }<br /> end;<br />}
Ps: I don't care if the code sux it was for try.