From eaac6efd2aded18689cf30a64080585d46cbcc48 Mon Sep 17 00:00:00 2001 From: David espinosa <104380606+davespser@users.noreply.github.com> Date: Fri, 6 Dec 2024 11:19:59 +0100 Subject: [PATCH] Update characterCreator.js --- js/characterCreator.js | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/js/characterCreator.js b/js/characterCreator.js index 45de897f..7f5be3c1 100644 --- a/js/characterCreator.js +++ b/js/characterCreator.js @@ -67,12 +67,12 @@ submitButton.addEventListener("click", async () => { // Derivar estadísticas secundarias const stats = { - ATK: (r / 255) * 100, - SPD: ((r + g) / 510) * 100, + ATK: (r + g) / (2 * 255) * 100, + SPD: (g / 255) * 100, MAG: (b / 255) * 100, - DEF: ((r * 0.6 + g * 0.4) / 255) * 100, - ACC: ((g + b) / 510) * 100, - VIT: ((r + g + b) / 765) * 100 + DEF: ((r / 255) * 100, + ACC: ((g + b) / (2 * 255) * 100, + VIT: ((r + g + b) / 3 * 255) * 100 }; // Obtener usuario actual