From b8b61eb06784aa9f7dcf18cfa13a61be5f68fa0c Mon Sep 17 00:00:00 2001 From: Jesusaves Date: Sat, 26 Jan 2019 15:34:59 -0200 Subject: Ultra Rare treasures are 0% for the first 10 chests, and raise in 0.01% each 10 chests open, capped at 0.1% at 100 chests. No easy Shemagh, ha! --- npc/functions/treasure.txt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/npc/functions/treasure.txt b/npc/functions/treasure.txt index 75fd3945c..4b2cd4b6d 100644 --- a/npc/functions/treasure.txt +++ b/npc/functions/treasure.txt @@ -26,7 +26,8 @@ function script TreasureBox { // You're warranted an ultra rare (0.1%) every 149 open chests // You're warranted a super rare (1%) every 50 open chests // There's also rares (10%), uncommons (40%) and commons (60%) - if (.@t % 149 == 0 || .@r < 10) + .@ur_rate=min(10, (TREASURE_OPEN/10)); + if (.@t % 149 == 0 || .@r < .@ur_rate) .@loot=any(AtroposMixture, GoldenApple, DivineApple, MercBoxA, SilverGift, Shemagh, EverburnPowder, IridiumOre, PlatinumOre); else if (.@t % 50 == 0 || .@r < 100) .@loot=any(Grenade, SnakeEgg, LachesisBrew, ArrowAmmoBox, CoinBag, BronzeGift, TerraniteOre, LeadOre, TinOre, SilverOre, GoldOre, TitaniumOre, FluoPowder); -- cgit v1.2.3-60-g2f50