bastion-siege-logic
Advanced tools
Comparing version 1.4.0 to 1.4.1
@@ -37,3 +37,3 @@ "use strict"; | ||
const basicRaw = getBattlereportBasicRaw(content); | ||
const won = /Поздравляю/.test(content); | ||
const won = content.includes('Поздравляю'); | ||
const me = regexHelper.getStrict(content, won ? | ||
@@ -40,0 +40,0 @@ /Поздравляю, ([^!]+)! / : |
@@ -21,3 +21,3 @@ "use strict"; | ||
} | ||
const isEnglish = contentFilter.includes(content, ' joined the siege '); | ||
const isEnglish = contentFilter.includesAny(content, ' joined the siege ', ' go against the siege '); | ||
const isRussian = contentFilter.includesAny(content, ' присоединился к осаде на ', ' выступил против осады на '); | ||
@@ -46,3 +46,3 @@ if (!(isEnglish || isRussian)) { | ||
if (isEnglish) { | ||
const regex = `${emojis}(?: The leader of your alliance)? (.+) joined the siege `; | ||
const regex = `${emojis}(?: The leader of your alliance)? (.+) (?:(?:joined)|(?:go against)) the siege `; | ||
return { castleSiegePlayerJoined: regexHelper.getPlayer(content, regex) }; | ||
@@ -49,0 +49,0 @@ } |
@@ -37,3 +37,3 @@ "use strict"; | ||
const regex = /союзник.? (.+) атаковал (.+)$/; | ||
const attack = /Твой/.test(content); | ||
const attack = content.includes('Твой'); | ||
const ally = regexHelper.getPlayer(shortenedContent, regex, 1); | ||
@@ -40,0 +40,0 @@ const enemy = regexHelper.getPlayer(shortenedContent, regex, 2); |
{ | ||
"name": "bastion-siege-logic", | ||
"version": "1.4.0", | ||
"version": "1.4.1", | ||
"description": "", | ||
@@ -40,3 +40,3 @@ "license": "MIT", | ||
"del-cli": "^1.1.0", | ||
"eslint-config-xo-typescript": "^0.9.0", | ||
"eslint-config-xo-typescript": "^0.10.1", | ||
"nyc": "^14.0.0", | ||
@@ -43,0 +43,0 @@ "ts-node": "^8.0.2", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
116783