Fix XP Rate Multiplier & add ::xprate to cooamnds list if enabled

This commit is contained in:
Dark98
2021-12-10 19:32:58 +00:00
parent c15722c766
commit 8761116b9b
3 changed files with 4 additions and 2 deletions
@@ -34,7 +34,7 @@ public class GameConstants {
public static boolean FILE_SERVER = true, SERVER_DEBUG = false, MEMBERS_ONLY = false, TUTORIAL_ISLAND = false,
PARTY_ROOM_DISABLED = false, CLUES_ENABLED = true, ITEM_REQUIREMENTS = true,
ADMIN_CAN_TRADE = false, ADMIN_DROP_ITEMS = false, ADMIN_CAN_SELL_ITEMS = false, VARIABLE_XP_RATE = true;
public static double XP_RATE = Player.xpRate;
public static double XP_RATE = 1.0;
/**
@@ -2033,7 +2033,8 @@ public class PlayerAssistant {
if (player.tutorialProgress < 36 && player.playerLevel[skill] == 3 && GameConstants.TUTORIAL_ISLAND) {
return false;
}
amount *= GameConstants.XP_RATE;
amount *= GameConstants.XP_RATE * player.getXPRate();
int oldLevel = getLevelForXP(player.playerXP[skill]);
player.playerXP[skill] += amount;
if (oldLevel < getLevelForXP(player.playerXP[skill])) {
@@ -299,6 +299,7 @@ public class Commands implements PacketType {
"",
"::snow",
"Add some snow in your mainscreen(works only in december)",
(GameConstants.VARIABLE_XP_RATE ? "\\n" + "::xprate\\n" + "Opens dialogue for the player to set/increase their XP rate." : ""),
};
// Clear all lines