aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMinteck <contact@minteck.org>2022-03-15 19:16:19 +0100
committerMinteck <contact@minteck.org>2022-03-15 19:16:19 +0100
commit88fb0fbfc9f58dc93420b31ee5a5201d1a37ca85 (patch)
treeea0e146857fd5d73e5c4308954a4fb593a4f608e
parent4d65dc9603db87ce2cfdbf68b0783807d9ccb6e6 (diff)
downloadponyfind-88fb0fbfc9f58dc93420b31ee5a5201d1a37ca85.tar.gz
ponyfind-88fb0fbfc9f58dc93420b31ee5a5201d1a37ca85.tar.bz2
ponyfind-88fb0fbfc9f58dc93420b31ee5a5201d1a37ca85.zip
Fix: fixes issue #21
-rw-r--r--.DS_Storebin8196 -> 10244 bytes
-rwxr-xr-x.gitignore4
-rwxr-xr-x.idea/dictionaries/Minteck.xml3
-rwxr-xr-xconfig/version.txt2
-rw-r--r--modules/colorlib.js1
-rwxr-xr-xupdate/ponies/parse.js24
6 files changed, 23 insertions, 11 deletions
diff --git a/.DS_Store b/.DS_Store
index a68536f..28e0e5d 100644
--- a/.DS_Store
+++ b/.DS_Store
Binary files differ
diff --git a/.gitignore b/.gitignore
index f01ab20..6f5ac63 100755
--- a/.gitignore
+++ b/.gitignore
@@ -20,4 +20,6 @@ demo.json
modules/translate.php
reports
beta
-stats \ No newline at end of file
+stats
+data (copy)
+data copy \ No newline at end of file
diff --git a/.idea/dictionaries/Minteck.xml b/.idea/dictionaries/Minteck.xml
deleted file mode 100755
index c3fcce8..0000000
--- a/.idea/dictionaries/Minteck.xml
+++ /dev/null
@@ -1,3 +0,0 @@
-<component name="ProjectDictionaryState">
- <dictionary name="minteck" />
-</component> \ No newline at end of file
diff --git a/config/version.txt b/config/version.txt
index 7c226a8..1ac9117 100755
--- a/config/version.txt
+++ b/config/version.txt
@@ -1 +1 @@
-2.2.65 \ No newline at end of file
+2.3.66 \ No newline at end of file
diff --git a/modules/colorlib.js b/modules/colorlib.js
index ec99d00..bc3fba5 100644
--- a/modules/colorlib.js
+++ b/modules/colorlib.js
@@ -40,6 +40,7 @@
const Color = require('color');
module.exports = (hex, debug) => {
+ console.log(hex);
const color = Color(hex);
const h = color.hsl().color[0];
diff --git a/update/ponies/parse.js b/update/ponies/parse.js
index c4cc1d4..28ba1d8 100755
--- a/update/ponies/parse.js
+++ b/update/ponies/parse.js
@@ -93,27 +93,39 @@ global.ponies = {};
if (typeof box.coat !== "undefined") data.color = box.coat.trim().replace(/<( ||(|| )\/)( ||(|| )\/)(b|B)(r|R)( ||(|| )\/)( ||(|| )\/)>/gm, "|").split("|").map((i) => { return i.replace(/<!--[\s\S]*?-->/g, "").trim().replace(/\[([a-z.\/ \nA-Z0-9:]*)\/(.{6})\/ (.*)\]/gm, "$2").replace(/{{perbang\|([0-9A-Fa-f].{5})(.*)/g, "$1").replace(/\[(.*)\/(.*)\/ (.*)\]/g, "$2"); })[0];
try {
- if (typeof box.coat !== "undefined") data.search.coat = box.coat.trim().replace(/<( ||(|| )\/)( ||(|| )\/)(b|B)(r|R)( ||(|| )\/)( ||(|| )\/)>/gm, "|").split("|").map((i) => {
+ index = 0;
+ cdata = box.coat.trim().replace(/<( ||(|| )\/)( ||(|| )\/)(b|B)(r|R)( ||(|| )\/)( ||(|| )\/)>/gm, "|").split("|").map((i) => {
try {
+ console.log("eyes", index);
return colorlib("#" + i.replace(/<!--[\s\S]*?-->/g, "").trim().replace(/\[([a-z.\/ \nA-Z0-9:]*)\/(.{6})\/ (.*)\]/gm, "$2").replace(/{{perbang\|([0-9A-Fa-f].{5})(.*)/g, "$1").replace(/\[(.*)\/(.*)\/ (.*)\]/g, "$2"));
} catch (e) {}
- }).filter(i => typeof i !== "number");
+ index++;
+ }).filter(i => typeof i === "number");
+ if (typeof box.coat !== "undefined") data.search.coat = [...new Set(cdata)];
} catch (e) {}
try {
- if (typeof box.eyes !== "undefined") data.search.eyes = box.eyes.trim().replace(/<( ||(|| )\/)( ||(|| )\/)(b|B)(r|R)( ||(|| )\/)( ||(|| )\/)>/gm, "|").split("|").map((i) => {
+ index = 0;
+ cdata = box.eyes.trim().replace(/<( ||(|| )\/)( ||(|| )\/)(b|B)(r|R)( ||(|| )\/)( ||(|| )\/)>/gm, "|").split("|").map((i) => {
try {
+ console.log("eyes", index);
return colorlib("#" + i.replace(/<!--[\s\S]*?-->/g, "").trim().replace(/\[([a-z.\/ \nA-Z0-9:]*)\/(.{6})\/ (.*)\]/gm, "$2").replace(/{{perbang\|([0-9A-Fa-f].{5})(.*)/g, "$1").replace(/\[(.*)\/(.*)\/ (.*)\]/g, "$2"));
} catch (e) {}
- }).filter(i => typeof i !== "number");
+ index++;
+ }).filter(i => typeof i === "number")
+ if (typeof box.eyes !== "undefined") data.search.eyes = [...new Set(cdata)];
} catch (e) {}
try {
- if (typeof box.mane !== "undefined") data.search.mane = box.mane.trim().replace(/<( ||(|| )\/)( ||(|| )\/)(b|B)(r|R)( ||(|| )\/)( ||(|| )\/)>/gm, "|").split("|").map((i) => {
+ index = 0;
+ cdata = box.mane.trim().replace(/<( ||(|| )\/)( ||(|| )\/)(b|B)(r|R)( ||(|| )\/)( ||(|| )\/)>/gm, "|").split("|").map((i) => {
try {
+ console.log("eyes", index);
return colorlib("#" + i.replace(/<!--[\s\S]*?-->/g, "").trim().replace(/\[([a-z.\/ \nA-Z0-9:]*)\/(.{6})\/ (.*)\]/gm, "$2").replace(/{{perbang\|([0-9A-Fa-f].{5})(.*)/g, "$1").replace(/\[(.*)\/(.*)\/ (.*)\]/g, "$2"));
} catch (e) {}
- }).filter(i => typeof i !== "number");
+ index++;
+ }).filter(i => typeof i === "number");
+ if (typeof box.mane !== "undefined") data.search.mane = [...new Set(cdata)];
} catch (e) {}
try {