1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Drop Rate - Crystalline Blackrock?

Discussion in 'General Discussion' started by Ce Jayce, Feb 21, 2014.

  1. Ce Jayce
    Offline

    Ce Jayce Member

    Joined:
    Jan 24, 2014
    Messages:
    140
    Likes Received:
    14
    So I couldn't find any information on this out in the world wide web and was wondering if any of you osi-goers knew the rough drop rates for crystalline blackrock from Ratmen & Ore Eles & Ter-Mur Mining?
     
  2. RedBeard
    Offline

    RedBeard Active Member

    Joined:
    May 19, 2013
    Messages:
    365
    Likes Received:
    72
    Mining drop method

    Code (C#):
    1.  
    2. if ( Core.ML )
    3.             {
    4.                 oreAndStone.BonusResources = new BonusHarvestResource[]
    5.                 {
    6. new BonusHarvestResource( 0, 99.3, null, null ),    //Nothing      99.3****************this number is important
    7. new BonusHarvestResource( 100, .1, 1072562, typeof( BlueDiamond ) ),
    8. new BonusHarvestResource( 100, .1, 1072567, typeof( DarkSapphire ) ),
    9. new BonusHarvestResource( 100, .1, 1072570, typeof( EcruCitrine ) ),
    10. new BonusHarvestResource( 100, .1, 1072564, typeof( FireRuby ) ),
    11. new BonusHarvestResource( 100, .1, 1072566, typeof( PerfectEmerald ) ),
    12. new BonusHarvestResource( 100, .1, 1072568, typeof( Turquoise ) ),
    13.                 };
    14. //SA
    15. if (OreAndStoneMap == Server.Map.TerMur)
    16. {
    17. new BonusHarvestResource(100, 0.1, 1113799, typeof(CrystallineBlackrock));
    18. }
    19. else
    20. new BonusHarvestResource(100, 0.1, 1072568, typeof( Turquoise ) ),
    21.  
    22.             }
    23. //End SA
    24.  
    Ore Elementals I made Valorite drop 10% time, Verite 9% time, Agapite 8% and so on...

    From my ValoriteElemental.cs
    Code (C#):
    1.  
    2. publicoverridevoid OnDeath(Container c)
    3. {
    4. base.OnDeath(c);
    5. if (Utility.RandomDouble() < 0.1)
    6. c.DropItem(new CrystallineBlackrock());
    7. }
    8.  
     
    #2 RedBeard, Feb 21, 2014
    Last edited: Feb 21, 2014
    • Two Thumbs Up Two Thumbs Up x 1
  3. Ce Jayce
    Offline

    Ce Jayce Member

    Joined:
    Jan 24, 2014
    Messages:
    140
    Likes Received:
    14
    Thanks very much! Seems like a fair drop rate, i'll monitor this and see how it goes.
    I've added the drop rate at 1% for all the Clan ratmen, it might need to be upped but due to the high volume of them I guess not.
     
  4. Omni
    Offline

    Omni Member

    Joined:
    Dec 22, 2013
    Messages:
    165
    Likes Received:
    24
    • Like Like x 1
  5. Ce Jayce
    Offline

    Ce Jayce Member

    Joined:
    Jan 24, 2014
    Messages:
    140
    Likes Received:
    14
    Is there a way to check for Map in the bonus harvest resources section? I've tried a variety of combination to no avail.

    I realise this has become less discussion and more script support now. Apologies :/ - (Mods, feel free to move this one)
     
  6. Omni
    Offline

    Omni Member

    Joined:
    Dec 22, 2013
    Messages:
    165
    Likes Received:
    24
    Code (C#):
    1. if (item.Stackable)
    2.                         {
    3.                             int amount = def.ConsumedPerHarvest;
    4.                             int feluccaAmount = def.ConsumedPerFeluccaHarvest;
    5.  
    6.                             int racialAmount = (int)Math.Ceiling(amount * 1.1);
    7.                             int feluccaRacialAmount = (int)Math.Ceiling(feluccaAmount * 1.1);
    8.  
    9.                             bool eligableForRacialBonus = (def.RaceBonus && from.Race == Race.Human);
    10.                             bool inFelucca = (map == Map.Felucca);
    11.  
    12.                             if (eligableForRacialBonus && inFelucca && bank.Current >= feluccaRacialAmount && 0.1 > Utility.RandomDouble())
    13.                                 item.Amount = feluccaRacialAmount;
    14.                             else if (inFelucca && bank.Current >= feluccaAmount)
    15.                                 item.Amount = feluccaAmount;
    16.                             else if (eligableForRacialBonus && bank.Current >= racialAmount && 0.1 > Utility.RandomDouble())
    17.                                 item.Amount = racialAmount;
    18.                             else
    19.                                 item.Amount = amount;
    20.                         }
    This is the code that changes the amount of resources you get in Fel so you can use something similar to make certain items drop in maps
     
  7. Ce Jayce
    Offline

    Ce Jayce Member

    Joined:
    Jan 24, 2014
    Messages:
    140
    Likes Received:
    14
    Yeah I thought about editing that bit, there is also a section in HarvestDefiniton that could be changed to check for the map but it was hoping to avoid that and keep it all in the one place. *shrugs* I'll see what solution I can come up with and post it here for others.
     
  8. Omni
    Offline

    Omni Member

    Joined:
    Dec 22, 2013
    Messages:
    165
    Likes Received:
    24
    could try something like this

    Code (C#):
    1.  Region reg = Region.Find(c.GetWorldLocation(), c.Map);
    2.             if (1.0 > Utility.RandomDouble() && reg.Name == "Fire Temple Ruins")
    If you can set regional drops im sure you can tweak it to make it map bound.

    Or

    Code (C#):
    1.  
    2.                         if (!Core.ML || this.Map == Map.Felucca)
    3.                         {
    4.                             new StarRoomGate(true, this.m_Altar.Location, this.m_Altar.Map);
    5.                         }
    Taken from championspawn
     
  9. Ce Jayce
    Offline

    Ce Jayce Member

    Joined:
    Jan 24, 2014
    Messages:
    140
    Likes Received:
    14
    Ended up editing the section you originally suggested Omni
    For anyone wishing to do this themselves;

    Code
    In HarvestSystem.cs
    find this section of code around line 169
    Code (C#):
    1.                       if (item.Stackable)
    2.                         {
    3.                             int amount = def.ConsumedPerHarvest;
    4.                             int feluccaAmount = def.ConsumedPerFeluccaHarvest;
    5.  
    6.                             int racialAmount = (int)Math.Ceiling(amount * 1.1);
    7.                             int feluccaRacialAmount = (int)Math.Ceiling(feluccaAmount * 1.1);
    8.  
    9.                             bool eligableForRacialBonus = (def.RaceBonus && from.Race == Race.Human);
    10.                             bool inFelucca = (map == Map.Felucca);
    Then add the following underneath;
    Code (C#):
    1.  
    2.                            //Begin edit for CrystallineBlackrock
    3.                             if (map == Map.TerMur && (0.01 >= Utility.RandomDouble() && (from.Skills.Mining.Value >= 100) && (def.Veins == Harvest.Mining.System.OreAndStone.Veins))) // 1 in 100 chance
    4.                             {
    5.                                 if (from.TotalWeight < from.MaxWeight)
    6.                                 {
    7.                                     from.AddToBackpack(new CrystallineBlackrock());
    8.                                     from.SendMessage("You dig up some crystalline blackrock");
    9.                                 }
    10.  
    11.                                 else
    12.                                 {
    13.                                     from.SendMessage("You attempted to dig up some crystalline blackrock but your backpack was full");
    14.                                 }
    15.                              
    16.                             }
    17.                             //end edit for CrystallineBlackrock
    18.  
     
    #9 Ce Jayce, Feb 24, 2014
    Last edited: Feb 24, 2014
  10. Omni
    Offline

    Omni Member

    Joined:
    Dec 22, 2013
    Messages:
    165
    Likes Received:
    24
    Probably the best way to do it I believe glad it works :)
     
  11. RedBeard
    Offline

    RedBeard Active Member

    Joined:
    May 19, 2013
    Messages:
    365
    Likes Received:
    72
    Curious does this need to check if you are mining oreandstone tiles, meaning will you have a chance to find crystallineblackrock while mining for sand
     
  12. Ce Jayce
    Offline

    Ce Jayce Member

    Joined:
    Jan 24, 2014
    Messages:
    140
    Likes Received:
    14
    Thanks for pointing this out!
    I've updated the other post with the following;
    Code (C#):
    1.  if (map == Map.TerMur && (0.01 >= Utility.RandomDouble() && (from.Skills.Mining.Value >= 100) && (def.Veins == Harvest.Mining.System.OreAndStone.Veins))) // 1 in 100 chance
     
Similar Threads: Drop Rate
Forum Title Date
Archived Bug Reports Boura hide drop rate is too high Jul 14, 2017
Script Support Script item drop rate change issues Mar 4, 2017
Archived Bug Reports Navry drop rate just changed on servuo REPO. WHY? May 15, 2016
Script Support paragon artifact drop rate Apr 6, 2016
Shard Discussion Treasure Map Drop Rate Apr 5, 2016
Windows Support manage drop rate for spellweaving and mysticism scrolls Oct 6, 2015
General Discussion Champion Artifact Drops, anyone? Sunday at 1:10 PM