Jump to content
  • 0
Sign in to follow this  
mrlongshen

MVP Card annoucement

Question

24 answers to this question

Recommended Posts

  • 0

@mrlongshen 

I took them from the script Dogpatch posted.

.@mvpIdList holds the MVP IDs.

.mvpCardIds holds the according card ids.

.mvpCardRates holds the according drop rate.

Edited by Winterfox

Share this post


Link to post
Share on other sites
  • 0

You can use settings in conf/battle/drops.cof

 

// Make broadcast ** Player1 won Pupa's Pupa Card (chance 0.01%) ***// This can be set to any value between 0~10000.// Note: It also announces STEAL skill usage with rare items// 0 = don't show announces at all// 1 = show announces for 0.01% drop chance items// 333 = show announces for 3.33% or lower drop chance items// 10000 = show announces for all itemsrare_drop_announce: 0 

 

@edit lol all cards will be announced xD Sorry

Share this post


Link to post
Share on other sites
  • 0

I think writing that as script is possible, but you would need some source changes / plugins. Either a OnLoot label or a getareauserids command.

But if you request such a thing you also could ask for a mvp announcer plugin / source mod in the first place.

 

You could ask @@AnnieRuru as it seems she did what you want allready.

Atleast i found a snippet that seems to do what you want that she did here: http://www.eathena.ws/board/index.php?showtopic=272695.

Share this post


Link to post
Share on other sites
  • 0

 

 

I use this for MVP cards.

http://pastebin.com/QqwPbean

 

No source mods needed. Already posted a script for it which includes all the MVP cards in Pre-RE.

@@Dogpatch It is kind of inefficient and requires you to edit the mobs to not loot the item the normal way. I dont think that kind of workaround is a good way to go. Also you can't really show the rate of the card by calculation atleast not with a pretty big effort since the script language doesn't support fractions.

 

But well thats just my opinion on that solution, if one wants to go with it, i would recommend to use this optimized version:

http://upaste.me/7559210089e1481dc

Edited by Winterfox

Share this post


Link to post
Share on other sites
  • 0

@@Winterfox

 

remove card from mob loot with 

 

 

---------------------------------------
 
*delmonsterdrop(<mob id or name>, <item id>)
 
This command will temporarily remove a drop from an existing monster.
 
Both the monster and the item must be valid.
 
Return value will be 1 in case of success (the item was removed), and 0
otherwise (the monster didn't have the specified item in its drop list).
 
Example:
// Remove Jellopy (909) from the Poring's (1002) drops
delmonsterdrop(1002, 909);
 
---------------------------------------

 

Share this post


Link to post
Share on other sites
  • 0

@@mrlongshen I named a variable wrong, thats why it didn't get executed. Also the cards will go directly into the inventory since the card drop is disabled by script and given to the player by the rate you can configure in the script.

Check it out here: http://upaste.me/36f421015cab9f3e5

 

Also i am no sir. :/

Edited by Winterfox

Share this post


Link to post
Share on other sites
  • 0

@@Winterfox so now all mvp card are 1% ?

 

 // Rate : 1 = 0.01%  /  1000 = 10%  /  10000 = 100%                setarray( .mvpCardRates, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 );

 

Right? 

 

Share this post


Link to post
Share on other sites
  • 0

@@Winterfox ups sory.

ok I done edit this.

 

-	script	MVP_CARD_ANNOUNCER	-1,{	OnInit:		setarray( .@mvpIdList, 1871, 1874, 1719, 1492, 1147, 1688, 1583, 1623, 1389, 1046, 1087, 1190, 1272, 1115, 1418, 1779, 1157, 1685, 1734, 1658, 1647, 1649, 1651, 1646, 1650, 1648, 1630, 1059, 1159, 1038, 1511, 1373, 1751, 1150, 1039, 1086, 1785, 1768, 1832, 1112, 1312, 1251, 1252 );		setarray( .mvpCardIds, 4441, 4145, 4386, 4263, 4146, 4376, 4302, 4342, 4134, 4142, 4143, 4135, 4168, 4123, 4330, 4419, 4148, 4374, 4403, 4352, 4359, 4363, 4365, 4357, 4367, 4361, 4372, 4132, 4121, 4144, 4236, 4276, 4407, 4131, 4147, 4128, 4425, 4408, 4430, 4137, 4305, 4318, 4324 );				// Rate : 1 = 0.01%  /  1000 = 10%  /  10000 = 100%		setarray( .mvpCardRates, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 10000, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 );		for(.@i = 0; .@i < getarraysize( .@mvpIdList ); .@i++ ) {			.mvpIds[ .@mvpIdList[ .@i ] ] = .@i;			delmonsterdrop( .@mvpIdList[ .@i ],  .mvpCardIds[ .@i ] );		}	end;	OnNPCKillEvent:		.@mvpIndex = .mvpIds[ killedrid ];		if( .@mvpIndex == 0) end;		if( rand( 10000 ) <= .mvpCardRates[ .@mvpIndex ] ){			getitem( .mvpCardIds[ .@mvpIndex ], 1 );			announce( "[ " + strcharinfo(PC_NAME) + " ] just got a " + getitemname( .mvpCardIds[.@mvpIndex] ), bc_all );		}	end;}

so that means, eddga card, 100% drop.

I killed 100 eddga nothing happen -_-

Share this post


Link to post
Share on other sites
  • 0

@mrlongshen 

I took them from the script Dogpatch posted.

.@mvpIdList holds the MVP IDs.

.mvpCardIds holds the according card ids.

.mvpCardRates holds the according drop rate.

 

 

Yeah mine was just a quick fix and never really had the time to edit it. Thanks for optimizing it. I'll use the version you made. 

Share this post


Link to post
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.   Restore formatting

  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.

Loading...
Sign in to follow this  

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.