mirror of
https://gitlab.com/2009scape/2009scape.git
synced 2025-12-20 21:40:27 -07:00
potential stability improvements
This commit is contained in:
parent
e2cc31387f
commit
04fe370603
4 changed files with 6 additions and 2 deletions
|
|
@ -111,6 +111,7 @@ public final class DialogueInterpreter {
|
|||
npc.getWalkingQueue().reset();
|
||||
npc.getPulseManager().clear();
|
||||
} catch(Exception e){
|
||||
e.printStackTrace();
|
||||
}
|
||||
} else if (args.length < 1) {
|
||||
args = new Object[] { dialogueKey };
|
||||
|
|
|
|||
|
|
@ -97,6 +97,7 @@ public final class GrandExchangeDatabase {
|
|||
}
|
||||
initialized = true;
|
||||
} catch (Exception e){
|
||||
e.printStackTrace();
|
||||
initNewDB();
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -32,6 +32,7 @@ public final class PlayerParser {
|
|||
}
|
||||
return true;
|
||||
} catch (Exception e){
|
||||
e.printStackTrace();
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
|
@ -58,7 +59,7 @@ public final class PlayerParser {
|
|||
while ((length = is.read(buffer)) > 0) {
|
||||
os.write(buffer, 0, length);
|
||||
}
|
||||
} catch (Exception ignored){
|
||||
} catch (Exception e){ e.printStackTrace();
|
||||
} finally {
|
||||
try {
|
||||
assert is != null;
|
||||
|
|
@ -67,6 +68,7 @@ public final class PlayerParser {
|
|||
os.close();
|
||||
} catch (Exception f){
|
||||
SystemLogger.logWarn("Unable to close file copiers in PlayerParser.java line 216.");
|
||||
f.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -184,7 +184,7 @@ class MiningSkillPulse(private val player: Player, private val node: Node) : Pul
|
|||
altered = true
|
||||
}
|
||||
if (RandomFunction.roll(chance)) {
|
||||
val gem = RandomFunction.rollChanceTable(true, *GEM_REWARDS)[0]
|
||||
val gem = GEM_REWARDS.random()
|
||||
player.packetDispatch.sendMessage("You find a " + gem.name + "!")
|
||||
if (!player.inventory.add(gem, player)) {
|
||||
player.packetDispatch.sendMessage("You do not have enough space in your inventory, so you drop the gem on the floor.")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue