From 74d92aa671792059b9a54258ab76b90b1466c15d Mon Sep 17 00:00:00 2001 From: FatBoy-DOTC Date: Tue, 25 Jul 2023 20:59:23 -0500 Subject: [PATCH 1/2] mob max roll audit --- src/engine/devcmd/cmds/InfoCmd.java | 9 ++++++++- src/engine/loot/LootManager.java | 4 ++-- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/src/engine/devcmd/cmds/InfoCmd.java b/src/engine/devcmd/cmds/InfoCmd.java index 6a95992b..ddf8bbbf 100644 --- a/src/engine/devcmd/cmds/InfoCmd.java +++ b/src/engine/devcmd/cmds/InfoCmd.java @@ -489,8 +489,15 @@ public class InfoCmd extends AbstractDevCmd { output += "Curr Loc : " + targetMob.getLoc() + newline; } else { output += newline; - output += "No building found."; + output += "No building found." + newline; + } + int max = 200 + (targetMob.level * 3); + if(max > 320){ + max = 320; } + int min = targetMob.level * 2; + output += "Min Loot Roll = " + min; + output += "Max Loot Roll = " + max; break; case Item: //intentional passthrough case MobLoot: diff --git a/src/engine/loot/LootManager.java b/src/engine/loot/LootManager.java index 89e75d95..5a80c2a1 100644 --- a/src/engine/loot/LootManager.java +++ b/src/engine/loot/LootManager.java @@ -219,11 +219,11 @@ public class LootManager { return outItem; } private static int TableRoll(int mobLevel){ - int max = 210 + (mobLevel * 2); + int max = 200 + (mobLevel * 3); if(max > 320){ max = 320; } - int min = (int)(mobLevel * 2.5f); + int min = mobLevel * 2; int roll = ThreadLocalRandom.current().nextInt(max-min) + min; return roll; } From 763971acc6d592e55fb1c17c13d1a9e5dc2a94f1 Mon Sep 17 00:00:00 2001 From: FatBoy-DOTC Date: Tue, 25 Jul 2023 21:07:40 -0500 Subject: [PATCH 2/2] regression calculator usage --- src/engine/devcmd/cmds/InfoCmd.java | 6 +++--- src/engine/loot/LootManager.java | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/engine/devcmd/cmds/InfoCmd.java b/src/engine/devcmd/cmds/InfoCmd.java index ddf8bbbf..1e220925 100644 --- a/src/engine/devcmd/cmds/InfoCmd.java +++ b/src/engine/devcmd/cmds/InfoCmd.java @@ -491,9 +491,9 @@ public class InfoCmd extends AbstractDevCmd { output += newline; output += "No building found." + newline; } - int max = 200 + (targetMob.level * 3); - if(max > 320){ - max = 320; + int max = (int)(4.882 * targetMob.level + 121.0); + if(max > 321){ + max = 321; } int min = targetMob.level * 2; output += "Min Loot Roll = " + min; diff --git a/src/engine/loot/LootManager.java b/src/engine/loot/LootManager.java index 5a80c2a1..172033ae 100644 --- a/src/engine/loot/LootManager.java +++ b/src/engine/loot/LootManager.java @@ -219,9 +219,9 @@ public class LootManager { return outItem; } private static int TableRoll(int mobLevel){ - int max = 200 + (mobLevel * 3); - if(max > 320){ - max = 320; + int max = (int)(4.882 * mobLevel + 121.0); + if(max > 321){ + max = 321; } int min = mobLevel * 2; int roll = ThreadLocalRandom.current().nextInt(max-min) + min;