Jump to content
  • 0

need help with invasion script


ewanjeli

Question


  • Group:  Members
  • Topic Count:  11
  • Topics Per Day:  0.00
  • Content Count:  41
  • Reputation:   0
  • Joined:  12/08/12
  • Last Seen:  

how to make boss spawn only 1 after all the mvp is kill??

thank in advance

here my script

- script invasion -1,{

OnInit:
setarray .Map$[0],"prontera","payon","izlude","dicastes01";
end;
//OnMinute00:
OnWhisperGlobal:
set .RandMap,rand( getarraysize( .Map$ ) );
set .mvp1,1658;
set .mvp2,1648;
set .mvp3,1751;
set .mvp4,1312;
set .boss,2600;
set .ItemID,12484;
announce "[ Rune-Midgard Guard ]: We have trouble here in the town " + .Map$[.RandMap] +"!", bc_all;
sleep2 5000;
announce "[ Rune-Midgard Guard ]: Everyone, we need your help to get rid of these monsters!", bc_all;
monster .Map$[ .RandMap ],0,0,"Invasion Soldier",.mvp1,10,;
monster .Map$[ .RandMap ],0,0,"Invasion Soldier",.mvp2,10,;
monster .Map$[ .RandMap ],0,0,"Invasion Soldier",.mvp3,10,;
monster .Map$[ .RandMap ],0,0,"Invasion Soldier",.mvp4,10,"::OnKilled";
end;

OnKilled:
if (mobcount("+.Map$[.RandMap]+", "Invasion Soldier") > 0) {
mes "^008000 The Invasion Soldier is still alive! ^000000";
}
else {
announce "[ Rune-Midgard Guard ]: The " + strmobinfo(1,.boss) + " has spawned in " + .Map$[.RandMap] + "!", bc_all;
monster .Map$[ .RandMap ],0,0,"Invasion Boss",.boss,1,strnpcinfo(0)+"::OnSpecialMobDead:";
}
OnSpecialMobDead:
announce strcharinfo(0)+" has fought off the Invasion and has been awarded a worthy prize!", bc_all;
getitem .ItemID,3;
end;
}

Link to comment
Share on other sites

7 answers to this question

Recommended Posts


  • Group:  Members
  • Topic Count:  43
  • Topics Per Day:  0.01
  • Content Count:  815
  • Reputation:   86
  • Joined:  10/26/12
  • Last Seen:  

-    script    Sample    -1,{
OnInit:
setarray .Map$[0],"prontera","payon","izlude","lighthalzen","louyang","comodo","xmas","aldebaran","geffen","morocc";
setarray .MVP[0],1658,1648,1751,1312,1511,1647,1785,1630,1399,1874,2068,1272,1719,1046,1389,1112,1115,1418,1871,1252,1768,1086,1885,1649,1651,1832,1734,1779,1688,1646,1623,1650,1583,1708,1685,1648,1658;
end;

OnTimer3300000:
killmonster .Map$[ .RandMap ],"All";
set .RandMap,rand( getarraysize( .Map$ ) );
set .RandMVP,rand( getarraysize( .MVP ) );
monster .Map$[ .RandMap ],0,0,"MVP Event",.MVP[ .RandMVP ],1,strnpcinfo(0)+"::OnKilled";
announce "MVP Event : "+getmonsterinfo( .MVP[ .RandMVP ],0 )+" occur in "+.Map$[ .RandMap ]+" .",0;
end;

OnKilled:
announce "MVP Event : End...MVP Died",0;
end;
}

here btw this is just mvp invasion with normal drops

Link to comment
Share on other sites


  • Group:  Forum Moderator
  • Topic Count:  93
  • Topics Per Day:  0.02
  • Content Count:  10013
  • Reputation:   2348
  • Joined:  10/28/11
  • Last Seen:  

monster .Map$[ .RandMap ],0,0,"Invasion Boss",.boss,1,strnpcinfo(0)+"::OnSpecialMobDead:";

/hmm ? isnt that your script only spawn 1 boss ???

refer monster

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  11
  • Topics Per Day:  0.00
  • Content Count:  41
  • Reputation:   0
  • Joined:  12/08/12
  • Last Seen:  

yes it 1 boss in this script.. but in game it spawn 4 boss

Link to comment
Share on other sites


  • Group:  Forum Moderator
  • Topic Count:  93
  • Topics Per Day:  0.02
  • Content Count:  10013
  • Reputation:   2348
  • Joined:  10/28/11
  • Last Seen:  

in your pm box

it should be

if( mobcount( .Map$[.RandMap],strnpcinfo(0)+"::OnKilled" ) > 0 ){

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  11
  • Topics Per Day:  0.00
  • Content Count:  41
  • Reputation:   0
  • Joined:  12/08/12
  • Last Seen:  

- script invasion -1,{
OnInit:
setarray .Map$[0],"prontera","payon","izlude","dicastes01";
end;
//OnMinute00:
OnWhisperGlobal:
set .RandMap,rand( getarraysize( .Map$ ) );
set .mvp1,1658;
set .mvp2,1648;
set .mvp3,1751;
set .mvp4,1312;
set .boss,2600;
set .ItemID,12484;
announce "[ Rune-Midgard Guard ]: We have trouble here in the town " + .Map$[.RandMap] +"!", bc_all;
sleep2 5000;
announce "[ Rune-Midgard Guard ]: Everyone, we need your help to get rid of these monsters!", bc_all;
monster .Map$[ .RandMap ],0,0,"Invasion Soldier",.mvp1,10,"::OnKilled";
monster .Map$[ .RandMap ],0,0,"Invasion Soldier",.mvp2,10,"::OnKilled";
monster .Map$[ .RandMap ],0,0,"Invasion Soldier",.mvp3,10,"::OnKilled";
monster .Map$[ .RandMap ],0,0,"Invasion Soldier",.mvp4,10,"::OnKilled";
end;
OnKilled:
if( mobcount( .Map$[.RandMap],strnpcinfo(0)+"::OnKilled" ) > 0 ){
mes "^008000 The Invasion Soldier is still alive! ^000000";
}
else {
announce "[ Rune-Midgard Guard ]: The " + strmobinfo(1,.boss) + " has spawned in " + .Map$[.RandMap] + "!", bc_all;
monster .Map$[ .RandMap ],0,0,"Invasion Boss",.boss,1,strnpcinfo(0)+"::OnSpecialMobDead:";
}
OnSpecialMobDead:
announce strcharinfo(0)+" has fought off the Invasion and has been awarded a worthy prize!", bc_all;
getitem .ItemID,3;
end;
}

like this??. but it still spawn many boss..

Capture.png

and error

Capture.png

Edited by ewanjeli
Link to comment
Share on other sites


  • Group:  Forum Moderator
  • Topic Count:  93
  • Topics Per Day:  0.02
  • Content Count:  10013
  • Reputation:   2348
  • Joined:  10/28/11
  • Last Seen:  

monster .Map$[ .RandMap ],0,0,"Invasion Soldier",.mvp1,10,strnpcinfo(0)+"::OnKilled";
monster .Map$[ .RandMap ],0,0,"Invasion Soldier",.mvp2,10,strnpcinfo(0)+"::OnKilled";
monster .Map$[ .RandMap ],0,0,"Invasion Soldier",.mvp3,10,strnpcinfo(0)+"::OnKilled";
monster .Map$[ .RandMap ],0,0,"Invasion Soldier",.mvp4,10,strnpcinfo(0)+"::OnKilled";

and your screenshot =='' cant understand what is it.... can you ??/swt

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  11
  • Topics Per Day:  0.00
  • Content Count:  41
  • Reputation:   0
  • Joined:  12/08/12
  • Last Seen:  

thx a lot Emistry... it solved

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...