From 734d5585800870f50e91423f11b7a9310be570c2 Mon Sep 17 00:00:00 2001 From: Sabe Jones Date: Sat, 1 Mar 2014 18:56:09 -0600 Subject: [PATCH] fix(drops): Boost base drop chance Initial feedback from the drop chance overhaul was that non-minmaxed characters had their drops severely curtailed, while tricked-out Rogues with enormous streaks were still scoring drops every time. Lots of complaining ensued! This commit doubles the base chance, establishes a minimum base chance of 2%, and halves the effectiveness of the high-end offenders. --- dist/habitrpg-shared.js | 4 ++-- script/index.coffee | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/dist/habitrpg-shared.js b/dist/habitrpg-shared.js index 5b066cf5ad..e4716dadcc 100644 --- a/dist/habitrpg-shared.js +++ b/dist/habitrpg-shared.js @@ -12681,8 +12681,8 @@ var process=require("__browserify_process");(function() { var acceptableDrops, chance, drop, dropK, quest, rarity, task, _base, _base1, _base2, _name, _name1, _name2, _ref, _ref1, _ref2, _ref3, _ref4; task = modifiers.task; - chance = Math.abs(task.value - 25) / 1000; - chance *= task.priority * (1 + (task.streak / 100 || 0)) * (1 + (user._statsComputed.per / 50)) * (1 + (user.contributor.level / 25 || 0)) * (1 + (user.achievements.rebirths / 25 || 0)) * (1 + (user.achievements.streak / 100 || 0)) * (user._tmp.crit || 1) * (1 + (_.reduce(task.checklist, (function(m, i) { + chance = _.max([Math.abs(task.value - 25) / 500, .02]); + chance *= task.priority * (1 + (task.streak / 100 || 0)) * (1 + (user._statsComputed.per / 100)) * (1 + (user.contributor.level / 25 || 0)) * (1 + (user.achievements.rebirths / 25 || 0)) * (1 + (user.achievements.streak / 200 || 0)) * (user._tmp.crit || 1) * (1 + (_.reduce(task.checklist, (function(m, i) { return m + (i.completed ? 1 : 0); }), 0) || 0)); quest = content.quests[(_ref = user.party.quest) != null ? _ref.key : void 0]; diff --git a/script/index.coffee b/script/index.coffee index e5707a5df0..ee442c357e 100644 --- a/script/index.coffee +++ b/script/index.coffee @@ -983,15 +983,15 @@ api.wrap = (user, main=true) -> # % chance of getting a drop - chance = Math.abs(task.value - 25) / 1000 # Base drop chance based on task value. Subtract more than the max possible task value so we never get a 0 + chance = _.max([Math.abs(task.value - 25) / 500,.02]) # Base drop chance based on task value. A typical, fresh task will be around 5%. Oldest tasks have a base around 15%, and there's a minimum of 2% for blues. chance *= task.priority * # Task priority: +50% for Medium, +100% for Hard (1 + (task.streak / 100 or 0)) * # Streak bonus: +1% per streak - (1 + (user._statsComputed.per / 50)) * # PERception: +2% per point + (1 + (user._statsComputed.per / 100)) * # PERception: +1% per point (1 + (user.contributor.level / 25 or 0)) * # Contrib levels: +4% per level (1 + (user.achievements.rebirths / 25 or 0)) * # Rebirths: +4% per achievement - (1 + (user.achievements.streak / 100 or 0)) * # Streak achievements: +1% per achievement + (1 + (user.achievements.streak / 200 or 0)) * # Streak achievements: +0.5% per achievement (user._tmp.crit or 1) * # Use the crit multiplier if we got one (1 + (_.reduce(task.checklist,((m,i)->m+(if i.completed then 1 else 0)),0) or 0)) # +100% per checklist item complete