diff --git a/src/Rank.js b/src/Rank.js index 529b0714..4ad21450 100644 --- a/src/Rank.js +++ b/src/Rank.js @@ -528,7 +528,7 @@ class Rank { ctx.font = `36px ${ops.fontY}`; ctx.fillStyle = this.data.discriminator.color; ctx.textAlign = "center"; - ctx.fillText(discrim.substring(0, 4), ctx.measureText(name).width + 20 + 335, yCoord); + ctx.fillText(discrim.substring(0, 5), ctx.measureText(name).width + 20 + 335, yCoord); } else { ctx.font = `26px ${ops.fontY}`; ctx.fillStyle = this.data.discriminator.color; diff --git a/test/Gamer.png b/test/Gamer.png index 4e325d27..0b631e51 100644 Binary files a/test/Gamer.png and b/test/Gamer.png differ diff --git a/test/Nerd.png b/test/Nerd.png index 00798bce..82257bc7 100644 Binary files a/test/Nerd.png and b/test/Nerd.png differ diff --git a/test/Player.png b/test/Player.png index 71dd9a8d..feacfe5f 100644 Binary files a/test/Player.png and b/test/Player.png differ diff --git a/test/index.js b/test/index.js index 5c9969f6..a7604082 100644 --- a/test/index.js +++ b/test/index.js @@ -6,20 +6,23 @@ const users = [ requiredXP: 845, username: 'Gamer', handle: '1000', - avatar: 'https://cdn.discordapp.com/embed/avatars/0.png' + avatar: 'https://cdn.discordapp.com/embed/avatars/0.png', + status: 'dnd' }, { xp: 467, requiredXP: 754, username: 'Player', handle: 'player', - avatar: 'https://cdn.discordapp.com/embed/avatars/1.png' + avatar: 'https://cdn.discordapp.com/embed/avatars/2.png', + status: 'idle' }, { - xp: 200, - requiredXP: 400, + xp: 450, + requiredXP: 500, username: 'Nerd', - avatar: 'https://cdn.discordapp.com/embed/avatars/2.png' + avatar: 'https://cdn.discordapp.com/embed/avatars/4.png', + status: 'online' } ]; @@ -28,9 +31,9 @@ Promise.all(users.map((userData) => { .setAvatar(userData.avatar) .setCurrentXP(userData.xp) .setRequiredXP(userData.requiredXP) - .setStatus("dnd") - .setProgressBar(["#000000", "#FEFEFE"], "GRADIENT", true) - .setProgressBarTrack("#FFFFFF") + .setStatus(userData.status) + .setProgressBar("#5865F2") + .setProgressBarTrack("#F6F6F6") .setUsername(userData.username) .setDiscriminator(userData.handle) .setMinXP(300);