Jump to content
  • 0

Broadcast if the dead branch summon a MiniBoss


Vali

Question


  • Group:  Members
  • Topic Count:  20
  • Topics Per Day:  0.00
  • Content Count:  128
  • Reputation:   7
  • Joined:  12/29/11
  • Last Seen:  

Im looking to check if its possible. I know that is possible do a broadcast directly adding it to the dead branch script, but how to do this only if the monster summoned is a miniboss?

Thank you!

Edited by Vali
Link to comment
Share on other sites

5 answers to this question

Recommended Posts


  • Group:  Members
  • Topic Count:  70
  • Topics Per Day:  0.02
  • Content Count:  1245
  • Reputation:   392
  • Joined:  11/19/11
  • Last Seen:  

Do you wish to broadcast this only to the user who used the dead branch? That way everyone on the server won't be spammed by continuous minibosses dead branch spawn broadcast messages?

Edited by Syouji
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  20
  • Topics Per Day:  0.00
  • Content Count:  128
  • Reputation:   7
  • Joined:  12/29/11
  • Last Seen:  

That is just what i want, a global broadcast (but only launched in a certain map, that is easy to know). In the other hand my server only have ~15 players that is not a problem. /no1

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  70
  • Topics Per Day:  0.02
  • Content Count:  1245
  • Reputation:   392
  • Joined:  11/19/11
  • Last Seen:  

Note: NOT TESTED

Source: Original Post

To do this you can edit the dead branch item in your item_db so that it calls a function instead of the mob_branch.txt file when it spawns a monster. This will look like this:

{ callfunc "newbranch"; },{},{}

Afterwards make a new script file and in it will be your new mob information. Here you can add the minibosses and normal monsters.

function	script	newbranch	{
setarray .@group[0], //Keep Populating this List
	1001,  // Scorpion - Normal
	1002,  // Poring - Normal
	1004,  // Hornet - Normal
	1005,  // Familiar - Normal
	1120,  // Ghostring - Miniboss
//Set .@i as the starting point for where the miniboss entries are all the way to the end.
set .@chosen, .@group[rand(getarraysize(.@group))];
monster "this",-1,-1,strmobinfo(1,.@chosen),.@chosen,1,"";
for (set @i,4; @i <= getarraysize(.@group); set @i,@i+1){
 if(.@chosen == .@group[.@i]){
   mapannounce "maphere","A miniboss was spawned!",0;
		  }
  }
end;
}

Edited by Syouji
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  20
  • Topics Per Day:  0.00
  • Content Count:  128
  • Reputation:   7
  • Joined:  12/29/11
  • Last Seen:  

Thank you Syouji!

That was what i was looking for! /no1

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  70
  • Topics Per Day:  0.02
  • Content Count:  1245
  • Reputation:   392
  • Joined:  11/19/11
  • Last Seen:  

Welcome ^^

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...