Browse Source

tweak roll ranges, fix r8 loot bug

master
FatBoy-DOTC 1 year ago
parent
commit
46bb1cd8e8
  1. 11
      src/engine/devcmd/cmds/simulateBootyCmd.java
  2. 5
      src/engine/loot/LootManager.java

11
src/engine/devcmd/cmds/simulateBootyCmd.java

@ -68,9 +68,12 @@ public class simulateBootyCmd extends AbstractDevCmd {
case Mob: case Mob:
Mob mob = (Mob) target; Mob mob = (Mob) target;
output += "Name: " + mob.getName() + newline; output += "Name: " + mob.getName() + newline;
int minRollRange = mob.getLevel() + 0 + mob.getParentZone().minLvl; int max = (int)(4.882 * mob.level + 127.0);
int maxRollRange = (mob.getLevel() * 2) + 120 + (mob.getParentZone().maxLvl * 2); if(max > 320){
output += "Roll Range: " + minRollRange + " - " + maxRollRange + newline; max = 320;
}
int min = (int)(4.469 * mob.level - 3.469);
output += "Roll Range: " + min + " - " + max + newline;
output += "Special Loot:" + newline; output += "Special Loot:" + newline;
if (mob.bootySet != 0) { if (mob.bootySet != 0) {
for (BootySetEntry entry : NPCManager._bootySetMap.get(mob.bootySet)) { for (BootySetEntry entry : NPCManager._bootySetMap.get(mob.bootySet)) {
@ -87,7 +90,7 @@ public class simulateBootyCmd extends AbstractDevCmd {
ArrayList<Item> Offerings = new ArrayList<Item>(); ArrayList<Item> Offerings = new ArrayList<Item>();
ArrayList<Item> OtherDrops = new ArrayList<Item>(); ArrayList<Item> OtherDrops = new ArrayList<Item>();
int failures = 0; int failures = 0;
for (int i = 0; i < 1; ++i) { for (int i = 0; i < 100; ++i) {
try { try {
mob.loadInventory(); mob.loadInventory();

5
src/engine/loot/LootManager.java

@ -175,7 +175,7 @@ public class LootManager {
if(mobLevel > 65){ if(mobLevel > 65){
mobLevel = 65; mobLevel = 65;
} }
int max = (int)(4.882 * mobLevel + 121.0); int max = (int)(5.882 * mobLevel + 127.0);
if(max > 320){ if(max > 320){
max = 320; max = 320;
} }
@ -235,7 +235,8 @@ public class LootManager {
} }
} }
public static void RollForGlass(Mob mob){ public static void RollForGlass(Mob mob){
if (ThreadLocalRandom.current().nextInt(101) > 99) { int glassRoll = ThreadLocalRandom.current().nextInt(100) + 1;
if (glassRoll >= 99 - mob.getRank()){
int roll2 = TableRoll(mob.level); int roll2 = TableRoll(mob.level);
if (itemTables.get(126).getRowForRange(roll2) == null) { if (itemTables.get(126).getRowForRange(roll2) == null) {
return; return;

Loading…
Cancel
Save