old drop system(odin)

Page 1 of 2 12 LastLast
Results 1 to 25 of 29
  1. #1
    Enthusiast MikeyPwnz is offline
    MemberRank
    Jul 2008 Join Date
    32Posts

    old drop system(odin)

    Quote Originally Posted by MikeyPwnz View Post
    this is for ppl that has screwed up droprate (mostly for people using sean's repack).
    this is the old code before he changed it around 5.6.
    repackers that based off seanpack has screwed up droprates too thats why i posted this.
    and also lets you change the droprates on world.properties again
    in MapleMap.java find:
    Code:
    private void dropFromMonster(MapleCharacter dropOwner, MapleMonster monster) {
    		if (dropsDisabled)
    			return;
    		/*
    		 * drop logic: decide based on monster what the max drop count is get drops (not allowed: multiple mesos,
    		 * multiple items of same type exception: event drops) calculate positions
    		 */
    		int maxDrops;
    		MapleItemInformationProvider ii = MapleItemInformationProvider.getInstance();
    		final boolean isBoss = monster.isBoss();
    		if (isBoss) {
    			maxDrops = 15; // boss droprate
    		} else {
    			maxDrops = 50; // mob droprate
    		}
    
    		List<Integer> toDrop = new ArrayList<Integer>();
    		for (int i = 0; i < maxDrops; i++) {
    			toDrop.add(monster.getDrop());
    		}
    
    		Set<Integer> alreadyDropped = new HashSet<Integer>();
    		for (int i = 0; i < toDrop.size(); i++) {
    			if (toDrop.get(i) == -1) {
    				if (alreadyDropped.contains(-1) && !isBoss) {
    					toDrop.remove(i);
    					i--;
    				} else {
    					alreadyDropped.add(-1);
    				}
    			} else {
    				MapleInventoryType type = ii.getInventoryType(toDrop.get(i));
    				if (alreadyDropped.contains((int) type.getType()) && !isBoss) {
    					toDrop.remove(i);
    					i--;
    				} else {
    					alreadyDropped.add((int) type.getType());
    				}
    			}
    		}
    replace it with:
    Code:
     private void dropFromMonster(MapleCharacter dropOwner, MapleMonster monster) {
            if (dropsDisabled)
                return;
            /*
             * drop logic: decide based on monster what the max drop count is get drops (not allowed: multiple mesos,
             * multiple items of same type exception: event drops) calculate positions
             */
            int maxDrops;
            MapleItemInformationProvider ii = MapleItemInformationProvider.getInstance();
            final boolean isBoss = monster.isBoss();
            if (isBoss) {
                maxDrops = 10 * ChannelServer.getInstance(channel).getBossDropRate();
            } else {
                maxDrops = 10 * ChannelServer.getInstance(channel).getDropRate();
            }
    
            List<Integer> toDrop = new ArrayList<Integer>();
            for (int i = 0; i < maxDrops; i++) {
                toDrop.add(monster.getDrop());
            }
    
            Set<Integer> alreadyDropped = new HashSet<Integer>();
            for (int i = 0; i < toDrop.size(); i++)  
                            {
                if (alreadyDropped.contains(toDrop.get(i)) && !isBoss) // Check the drop list whether it contains same item regardless of how many items
                            {
                                toDrop.remove(i); //remove if it contains the same
                                i--;
                }
    in ChannelServer.java add:
    Code:
    dropRate = Integer.parseInt(props.getProperty("net.sf.odinms.world.drop"));
    bossdropRate = Integer.parseInt(props.getProperty("net.sf.odinms.world.bossdrop"));
    under
    Code:
    mesoRate = Integer.parseInt(props.getProperty("net.sf.odinms.world.meso"));
    if theres 2 add on both [if you see 2 mesoRate = Integer.parseInt(props.getProperty("net.sf.odinms.world.meso")); then add under both of them]

    in world.properties add:
    Code:
    # drop factor
    net.sf.odinms.world.drop=(droprate)
    # bossdrop factor
    net.sf.odinms.world.bossdrop=(bossdroprate)
    under:
    Code:
    # meso factor
    net.sf.odinms.world.meso=(mesorate)
    and recompile
    Last edited by MikeyPwnz; 04-09-08 at 10:32 AM. Reason: channelserver.java


  2. #2
    Account Upgraded | Title Enabled! lightstory is offline
    MemberRank
    Aug 2008 Join Date
    246Posts

    Re: [release]old drop system(odin)

    Lol. What you mean by "Old Drop System"?

  3. #3
    Alpha Member ClericKn1ght is offline
    MemberRank
    Jun 2008 Join Date
    RagezoneLocation
    1,639Posts

    Re: [release]old drop system(odin)

    Yea, i don't get what u mean by Old Drop system, Sorry mind explain it to me XD

  4. #4
    IHF iPlayHard is offline
    MemberRank
    Apr 2008 Join Date
    SingaporeLocation
    600Posts

    Re: [release]old drop system(odin)

    I think his trying to say editing the droprate in the world.properties file o.o

  5. #5
    Account Upgraded | Title Enabled! magetrooper is offline
    MemberRank
    Jun 2008 Join Date
    Nautilus PortLocation
    273Posts

    Re: [release]old drop system(odin)

    system and rate is different, dude.

  6. #6
    Account Upgraded | Title Enabled! chuayaowei is offline
    MemberRank
    Jul 2008 Join Date
    SingaporeLocation
    1,410Posts

    Re: [release]old drop system(odin)

    Dun understand

  7. #7
    Account Upgraded | Title Enabled! Haiku01 is offline
    MemberRank
    Jul 2008 Join Date
    celtic.zapto.orgLocation
    437Posts

    Re: [release]old drop system(odin)

    Thisll allow you to now change the drop rate through world.properties like before. Since it was last time glitched o_0

  8. #8
    Account Upgraded | Title Enabled! Ridiculous is offline
    MemberRank
    Apr 2008 Join Date
    1,146Posts

    Re: [release]old drop system(odin)

    Quote Originally Posted by Haiku01 View Post
    Thisll allow you to now change the drop rate through world.properties like before. Since it was last time glitched o_0
    Oh, Now I see, Thanks for explaining.

  9. #9
    Account Upgraded | Title Enabled! YaNdAoGM is offline
    MemberRank
    Apr 2008 Join Date
    public boolean isSingapore { return true; }Location
    568Posts

    Re: [release]old drop system(odin)

    I understand wad he means u noe last time when Sean's repack was v4.x u can edit bossdroprate and mesosdroprate droprate all those from the world.properties file

  10. #10
    Member SGxiaosin is offline
    MemberRank
    Aug 2008 Join Date
    Singapore, AljuniedLocation
    82Posts

    Re: [release]old drop system(odin)

    I thought this was posted b4? o.O

  11. #11
    Account Upgraded | Title Enabled! Ridiculous is offline
    MemberRank
    Apr 2008 Join Date
    1,146Posts

    Re: [release]old drop system(odin)

    Probably was posted before, but at least this will keep us reminded.

  12. #12
    Account Upgraded | Title Enabled! xazerrx is offline
    MemberRank
    Jul 2008 Join Date
    SiNGaPoReLocation
    718Posts

    Re: [release]old drop system(odin)

    Don't get it.. But i used to change the drop rates of items through mysql.

  13. #13
    Account Upgraded | Title Enabled! megoesrawr is offline
    MemberRank
    May 2008 Join Date
    CaliforniaLocation
    873Posts

    Re: [release]old drop system(odin)

    Quote Originally Posted by xazerrx View Post
    Don't get it.. But i used to change the drop rates of items through mysql.
    No... I don't think you quite understand... This changes the RATE not the drop rates of items in the db... This release also allows you to changes drop rates through your world.properties

  14. #14
    Alpha Member Moogra is offline
    MemberRank
    Jul 2008 Join Date
    1,804Posts

    Re: [release]old drop system(odin)

    Very good release but you might want to fix up the first script
    You didn't include the whole method. Or you might want to mention that you end the paste in the first for loop.
    Do this before noobs start coming and saying that this script gives errors

  15. #15
    Account Upgraded | Title Enabled! megoesrawr is offline
    MemberRank
    May 2008 Join Date
    CaliforniaLocation
    873Posts

    Re: [release]old drop system(odin)

    yeah LOL
    by the time you know it... This thread will be filled with noobs asking for a fix :)

  16. #16
    Account Upgraded | Title Enabled! xazerrx is offline
    MemberRank
    Jul 2008 Join Date
    SiNGaPoReLocation
    718Posts

    Re: [release]old drop system(odin)

    Ohh I get it now (lol slow I know).. But will changing the drop rates in the world.properties be normal? As in you set the drop rates to 50 in the world.properties and you get 50x droprate? Because from what I noe changing it in mysql is different.. Change the droprate value to 1 and you get 100% item drop for that item. E.g. Set zak helm droprate value to 1 and u get 15 helms dropping set it to 50 and u get none until like 10 zaks are killed.

  17. #17
    Omega ihatehaxor is offline
    MemberRank
    Apr 2008 Join Date
    JerseyLocation
    5,461Posts

    Re: [release]old drop system(odin)

    oh i get it
    well thanks for the release

  18. #18
    Alpha Member Moogra is offline
    MemberRank
    Jul 2008 Join Date
    1,804Posts

    Re: [release]old drop system(odin)

    Ok, the drop rate change in world.properties never worked (except before seanpack 5.6?). They don't work in my repack or pc maple's
    They will work iff you add this.

  19. #19
    Account Upgraded | Title Enabled! RMZero213 is offline
    MemberRank
    Apr 2008 Join Date
    Far, far awayLocation
    1,280Posts

    Re: [release]old drop system(odin)

    Quote Originally Posted by Moogra View Post
    Ok, the drop rate change in world.properties never worked (except before seanpack 5.6?). They don't work in my repack or pc maple's
    They will work iff you add this.
    Proof that repack-makers don't make/fix stuff by themselves(How did you manage to get DROPRATE failing ._.)

  20. #20
    Account Upgraded | Title Enabled! chuayaowei is offline
    MemberRank
    Jul 2008 Join Date
    SingaporeLocation
    1,410Posts

    Re: [release]old drop system(odin)

    So does this script work?

  21. #21
    Enthusiast MikeyPwnz is offline
    MemberRank
    Jul 2008 Join Date
    32Posts

    Re: [release]old drop system(odin)

    this is for ppl that has screwed up droprate (mostly for people using sean's repack)
    this is the old code before he changed it around 5.6
    repackers that based off seanpack has screwed up droprates too thats why i posted this

    and also lets you change the droprates on world.properties again

    sorry for the late reply~

  22. #22
    Account Upgraded | Title Enabled! Mgssidley is offline
    MemberRank
    Apr 2008 Join Date
    443Posts

    Re: [release]old drop system(odin)

    Great release thanks!

  23. #23
    Account Upgraded | Title Enabled! Ridiculous is offline
    MemberRank
    Apr 2008 Join Date
    1,146Posts

    Re: [release]old drop system(odin)

    Quote Originally Posted by MikeyPwnz View Post
    this is for ppl that has screwed up droprate (mostly for people using sean's repack)
    this is the old code before he changed it around 5.6
    repackers that based off seanpack has screwed up droprates too thats why i posted this

    and also lets you change the droprates on world.properties again

    sorry for the late reply~
    So, if it's messed up, what happens if you use the original code?

  24. #24
    Member aeronex is offline
    MemberRank
    May 2008 Join Date
    91Posts

    Re: [release]old drop system(odin)

    What was the original intention of creating the newer code? I mean, there is surely some rationale and benefits of the new system that wasn't existent in the older script? Just asking because I wanna compare the two scripts and decide which is better to be used for my personal test server. No offense to anyone ;)

    Thank you thread starter for releasing this! (:

  25. #25
    Account Upgraded | Title Enabled! chuayaowei is offline
    MemberRank
    Jul 2008 Join Date
    SingaporeLocation
    1,410Posts

    Re: [release]old drop system(odin)

    After much thoughts i still don't understand the difference between the new and old system. Besides it's quite hard to test right?

    Correct me if i am wrong =)



Page 1 of 2 12 LastLast

Advertisement