From 81f845df541feefad1edaa5c8063ecf05a4f1ea0 Mon Sep 17 00:00:00 2001 From: kvan7 Date: Thu, 19 Dec 2024 15:56:35 -0600 Subject: [PATCH] Revert "no pseudo" This reverts commit 78b3ed07e546123373fc6f6c989b00f698f5480c. --- main/package-lock.json | 4 +- main/package.json | 2 +- .../web/price-check/filters/pseudo/index.ts | 136 +++++++++--------- 3 files changed, 71 insertions(+), 71 deletions(-) diff --git a/main/package-lock.json b/main/package-lock.json index ba996250a..5ab6100f6 100644 --- a/main/package-lock.json +++ b/main/package-lock.json @@ -1,12 +1,12 @@ { "name": "exiled-exchange-2", - "version": "0.1.2-no-pseudo", + "version": "0.1.2", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "exiled-exchange-2", - "version": "0.1.2-no-pseudo", + "version": "0.1.2", "dependencies": { "electron-overlay-window": "3.3.0", "uiohook-napi": "1.5.x" diff --git a/main/package.json b/main/package.json index 27380fd31..8c756e177 100644 --- a/main/package.json +++ b/main/package.json @@ -1,6 +1,6 @@ { "name": "exiled-exchange-2", - "version": "0.1.2-no-pseudo", + "version": "0.1.2", "private": true, "scripts": { "dev": "node build/script.mjs", diff --git a/renderer/src/web/price-check/filters/pseudo/index.ts b/renderer/src/web/price-check/filters/pseudo/index.ts index 056af43b4..02fa7466e 100644 --- a/renderer/src/web/price-check/filters/pseudo/index.ts +++ b/renderer/src/web/price-check/filters/pseudo/index.ts @@ -1,7 +1,7 @@ import { // populatePseudoRules, // pseudoRules, - // stat, + stat, STAT_BY_REF, } from "@/assets/data"; // import { STAT_BY_REF } from "@/assets/data"; @@ -12,45 +12,45 @@ import { } from "../create-stat-filters"; import type { StatFilter } from "../interfaces"; -// const RESISTANCES_INFO = [ -// { -// ref: stat("+#% to All Resistances"), -// elements: ["fire", "cold", "lightning"], -// chaos: true, -// }, -// { -// ref: stat("+#% to all Elemental Resistances"), -// elements: ["fire", "cold", "lightning"], -// }, -// { ref: stat("+#% to Fire Resistance"), elements: ["fire"] }, -// { ref: stat("+#% to Cold Resistance"), elements: ["cold"] }, -// { ref: stat("+#% to Lightning Resistance"), elements: ["lightning"] }, -// { -// ref: stat("+#% to Fire and Lightning Resistances"), -// elements: ["fire", "lightning"], -// }, -// { ref: stat("+#% to Fire and Cold Resistances"), elements: ["fire", "cold"] }, -// { -// ref: stat("+#% to Cold and Lightning Resistances"), -// elements: ["cold", "lightning"], -// }, -// { ref: stat("+#% to Chaos Resistance"), elements: [""], chaos: true }, -// { -// ref: stat("+#% to Fire and Chaos Resistances"), -// elements: ["fire"], -// chaos: true, -// }, -// { -// ref: stat("+#% to Cold and Chaos Resistances"), -// elements: ["cold"], -// chaos: true, -// }, -// { -// ref: stat("+#% to Lightning and Chaos Resistances"), -// elements: ["lightning"], -// chaos: true, -// }, -// ]; +const RESISTANCES_INFO = [ + // { + // ref: stat("+#% to All Resistances"), + // elements: ["fire", "cold", "lightning"], + // chaos: true, + // }, + { + ref: stat("+#% to all Elemental Resistances"), + elements: ["fire", "cold", "lightning"], + }, + { ref: stat("+#% to Fire Resistance"), elements: ["fire"] }, + { ref: stat("+#% to Cold Resistance"), elements: ["cold"] }, + { ref: stat("+#% to Lightning Resistance"), elements: ["lightning"] }, + // { + // ref: stat("+#% to Fire and Lightning Resistances"), + // elements: ["fire", "lightning"], + // }, + // { ref: stat("+#% to Fire and Cold Resistances"), elements: ["fire", "cold"] }, + // { + // ref: stat("+#% to Cold and Lightning Resistances"), + // elements: ["cold", "lightning"], + // }, + // { ref: stat("+#% to Chaos Resistance"), elements: [""], chaos: true }, + // { + // ref: stat("+#% to Fire and Chaos Resistances"), + // elements: ["fire"], + // chaos: true, + // }, + // { + // ref: stat("+#% to Cold and Chaos Resistances"), + // elements: ["cold"], + // chaos: true, + // }, + // { + // ref: stat("+#% to Lightning and Chaos Resistances"), + // elements: ["lightning"], + // chaos: true, + // }, +]; // const ATTRIBUTES_INFO = [ // { ref: stat("+# to all Attributes"), attributes: ["str", "dex", "int"] }, @@ -76,34 +76,34 @@ interface PseudoRule { } const PSEUDO_RULES: PseudoRule[] = [ - // { - // pseudo: stat("+#% total Elemental Resistance"), - // disabled: false, - // stats: RESISTANCES_INFO.filter((info) => info.elements.length).map( - // (info) => ({ ref: info.ref, multiplier: info.elements.length }), - // ), - // }, - // { - // pseudo: stat("+#% total to Fire Resistance"), - // group: "to_x_ele_res", - // stats: RESISTANCES_INFO.filter((info) => - // info.elements.includes("fire"), - // ).map((info) => ({ ref: info.ref })), - // }, - // { - // pseudo: stat("+#% total to Cold Resistance"), - // group: "to_x_ele_res", - // stats: RESISTANCES_INFO.filter((info) => - // info.elements.includes("cold"), - // ).map((info) => ({ ref: info.ref })), - // }, - // { - // pseudo: stat("+#% total to Lightning Resistance"), - // group: "to_x_ele_res", - // stats: RESISTANCES_INFO.filter((info) => - // info.elements.includes("lightning"), - // ).map((info) => ({ ref: info.ref })), - // }, + { + pseudo: stat("+#% total Elemental Resistance"), + disabled: false, + stats: RESISTANCES_INFO.filter((info) => info.elements.length).map( + (info) => ({ ref: info.ref, multiplier: info.elements.length }), + ), + }, + { + pseudo: stat("+#% total to Fire Resistance"), + group: "to_x_ele_res", + stats: RESISTANCES_INFO.filter((info) => + info.elements.includes("fire"), + ).map((info) => ({ ref: info.ref })), + }, + { + pseudo: stat("+#% total to Cold Resistance"), + group: "to_x_ele_res", + stats: RESISTANCES_INFO.filter((info) => + info.elements.includes("cold"), + ).map((info) => ({ ref: info.ref })), + }, + { + pseudo: stat("+#% total to Lightning Resistance"), + group: "to_x_ele_res", + stats: RESISTANCES_INFO.filter((info) => + info.elements.includes("lightning"), + ).map((info) => ({ ref: info.ref })), + }, // { // pseudo: stat("+#% total to Chaos Resistance"), // stats: RESISTANCES_INFO.filter((info) => info.chaos === true).map(