Commit 6b8ff56016b787a15d2fd7f8d23f46ac7fcef1c0

Authored by Lisa Greene
1 parent 31a13dc2

reduce the rate at which rares learn new talents

... ... @@ -2166,24 +2166,22 @@ function _M:applyRandomClass(b, data, instant)
2166 2166 local t = b:getTalentFromId(tid)
2167 2167 if not t.no_npc_use and not t.no_npc_autolevel and (not t.random_boss_rarity or rng.chance(t.random_boss_rarity)) and not (t.rnd_boss_restrict and util.getval(t.rnd_boss_restrict, b, t, data) ) then
2168 2168 local max = (t.points == 1) and 1 or math.ceil(t.points * 1.2)
2169   - local step = max / 70
  2169 + local step = max / 65
2170 2170 tres[1][tid] = v + math.ceil(step * data.level)
2171 2171 end
2172 2172 end
2173 2173
2174   - -- learn talents based on trees: focus trees we take 3-4 talents from with a decent amount of point investment, shallow trees we only take 1 or 2 with not many points
2175   - -- ideally rares should feel different even within the same class based on what focus trees they get
2176 2174 local nb_focus, nb_shallow = 0, 0
2177 2175 local rank = b.rank
2178 2176 if rank <= 3.2 then --rare
2179   - nb_focus = math.floor(0.2 + rng.float(0.22, 0.35)*(math.max(0,data.level-3))^0.5)
2180   - nb_shallow = 2 + math.floor(0.25 + rng.float(0.08, 0.2)*(math.max(0,data.level-6))^0.5)
  2177 + nb_focus = 1 + math.floor(rng.float(0.15, 0.33)*(math.max(0,data.level-4))^0.5)
  2178 + nb_shallow = 1 + math.floor(0.25 + rng.float(0.08, 0.17)*(math.max(0,data.level-6))^0.5)
2181 2179 elseif rank >= 4 then --boss/elite boss
2182   - nb_focus = 1 + math.floor(0.25 + rng.float(0.15, 0.35)*(math.max(0,data.level-6))^0.5)
2183   - nb_shallow = 1 + math.floor(0.3 + rng.float(0.1, 0.2)*(math.max(0,data.level-4))^0.5)
  2180 + nb_focus = 1 + math.floor(0.2 + rng.float(0.075, 0.3)*(math.max(0,data.level-6))^0.5)
  2181 + nb_shallow = 1 + math.floor(0.3 + rng.float(0.07, 0.18)*(math.max(0,data.level-5))^0.5)
2184 2182 else --unique
2185   - nb_focus = 1 + math.floor(0.2 + rng.float(0.15, 0.3)*(math.max(0,data.level-10))^0.5)
2186   - nb_shallow = 1 + math.floor(0.55 + rng.float(0.1, 0.2)*(math.max(0,data.level-8))^0.5)
  2183 + nb_focus = 1 + math.floor(0.2 + rng.float(0.075, 0.25)*(math.max(0,data.level-10))^0.5)
  2184 + nb_shallow = 1 + math.floor(0.5 + rng.float(0.07, 0.18)*(math.max(0,data.level-8))^0.5)
2187 2185 end
2188 2186 print("Adding "..nb_focus.." primary trees to boss")
2189 2187 print("Adding "..nb_shallow.." secondary trees to boss")
... ... @@ -2255,13 +2253,13 @@ function _M:applyRandomClass(b, data, instant)
2255 2253 if #t_choices <= 2 or #focus_trees >= nb_focus then
2256 2254 if #t_choices > 0 and #shallow_trees < nb_shallow then
2257 2255 table.insert(shallow_trees, tt) -- record that we added the tree as a minor tree
2258   - max_talents_from_tree = rng.percent(65) and 2 or 1
  2256 + max_talents_from_tree = rng.percent(50) and 2 or 1
2259 2257 print("Adding secondary tree "..tt.." to boss with "..max_talents_from_tree.." talents")
2260 2258 for i = max_talents_from_tree,1,-1 do
2261 2259 local t = table.remove(t_choices, 1)
2262 2260 if not t then break end
2263 2261 local max = (t.points == 1) and 1 or math.ceil(t.points * 1.2)
2264   - local step = max / 60
  2262 + local step = max / 65
2265 2263 local lev = math.max(1, math.round(rng.float(0.75,1.15)*math.ceil(step * data.level)))
2266 2264 print(#shallow_trees, " * talent:", t.id, lev)
2267 2265 if instant then -- affected by game difficulty settings
... ... @@ -2276,14 +2274,14 @@ function _M:applyRandomClass(b, data, instant)
2276 2274 end
2277 2275 else
2278 2276 table.insert(focus_trees, tt) --record that we added the tree as a major tree
2279   - local max_talents_from_tree = rng.percent(75) and 4 or 3
  2277 + local max_talents_from_tree = rng.percent(67) and 4 or 3
2280 2278 print("Adding primary tree "..tt.." to boss with "..max_talents_from_tree.." talents")
2281 2279 for i = max_talents_from_tree,1,-1 do
2282 2280 local t = table.remove(t_choices, 1)
2283 2281 if not t then break end
2284 2282 local max = (t.points == 1) and 1 or math.ceil(t.points * 1.2)
2285 2283 local step = max / 50
2286   - local lev = math.max(1, math.round(rng.float(0.75,1.25)*math.ceil(step * data.level)))
  2284 + local lev = math.max(1, math.round(rng.float(0.8,1.2)*math.ceil(step * data.level)))
2287 2285 print(#focus_trees, " * talent:", t.id, lev)
2288 2286 if instant then -- affected by game difficulty settings
2289 2287 if b:getTalentLevelRaw(t) < lev then b:learnTalent(t.id, true, lev - b:getTalentLevelRaw(t.id)) end
... ...