Thread: Zenith Scape Charm Drop Amount

Results 1 to 2 of 2
  1. #1 Zenith Scape Charm Drop Amount 
    Registered Member
    Join Date
    Jul 2012
    Posts
    134
    Thanks given
    3
    Thanks received
    5
    Rep Power
    11
    Hey guys,

    I'm using a Zenith Scape source and I'm trying to figure out how to minimize the amount of charms dropped at once. Currently, the amount ranges from like.. 11 charms to 30 charms. I want this to be just 1 single charm instead.

    What I have in NPC.java :

    Code:
    int [] charms = {12159, 12160, 12158, 12163};
    		int li = Misc.random(3);
    		Drop dr = new Drop(charms[li],85,11,31,false);
    		sendDrop(killer,dr);
    			Drop[] possibleDrops = new Drop[drops.length];
    			int possibleDropsCount = 0;
    			for (Drop drop : drops) {
    				if (drop.getRate() == 10)
    					sendDrop(killer, drop);
    				else {
    					if ((Utils.getRandomDouble(99) + 1) <= drop.getRate() * 1)
    						possibleDrops[possibleDropsCount++] = drop;
    				}
    			}
    			if (possibleDropsCount > 0)
    				sendDrop(killer,
    						possibleDrops[Utils.getRandom(possibleDropsCount - 1)]);
    Also, as you can see, I tried changing the rate the charms are dropped to 10%, but every NPC I kill, still drops charms, being a 100% drop rate.

    Can anyone help?
    Reply With Quote  
     

  2. #2  
    Registered Member
    Join Date
    Aug 2012
    Posts
    57
    Thanks given
    0
    Thanks received
    0
    Rep Power
    11
    yea see the 11 and 31 change those to what ever you want
    Reply With Quote  
     


Thread Information
Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)


User Tag List

Similar Threads

  1. Zenith Scape Drop Editor?
    By PvMLegacyTyler in forum Help
    Replies: 3
    Last Post: 09-12-2012, 11:04 PM
  2. Replies: 13
    Last Post: 07-04-2012, 11:28 PM
  3. Replies: 6
    Last Post: 09-23-2011, 04:33 AM
  4. Random amount of an item on a drop[DELTA]
    By shoopdawhoop in forum Snippets
    Replies: 2
    Last Post: 12-10-2010, 11:43 AM
Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •