aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorjani270 <69345714+jani270@users.noreply.github.com>2024-12-13 23:30:23 +0100
committerLinnea Gräf <nea@nea.moe>2024-12-14 22:01:21 +0100
commit0a4cf1fbcc897462f31aaadc5c868d12d13e1abb (patch)
tree919ca9e68a2e3edc3fdf0624ff754b752260907a /src
parenta7e27bb4609997a2efc9b102aee3b71d99d2c5fd (diff)
downloadLocalTransactionLedger-0a4cf1fbcc897462f31aaadc5c868d12d13e1abb.tar.gz
LocalTransactionLedger-0a4cf1fbcc897462f31aaadc5c868d12d13e1abb.tar.bz2
LocalTransactionLedger-0a4cf1fbcc897462f31aaadc5c868d12d13e1abb.zip
fix: NPC Buy/Sell Pattern not working for 1 Coin Items
Diffstat (limited to 'src')
-rw-r--r--src/main/kotlin/moe/nea/ledger/modules/NpcDetection.kt4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/main/kotlin/moe/nea/ledger/modules/NpcDetection.kt b/src/main/kotlin/moe/nea/ledger/modules/NpcDetection.kt
index f129113..cbafe02 100644
--- a/src/main/kotlin/moe/nea/ledger/modules/NpcDetection.kt
+++ b/src/main/kotlin/moe/nea/ledger/modules/NpcDetection.kt
@@ -17,9 +17,9 @@ import java.util.regex.Pattern
class NpcDetection @Inject constructor(val ledger: LedgerLogger, val ids: ItemIdProvider) {
val npcBuyPattern =
- Pattern.compile("You bought (back )?(?<what>.*?) (x(?<count>$SHORT_NUMBER_PATTERN) )?for (?<coins>$SHORT_NUMBER_PATTERN) Coins!")
+ Pattern.compile("You bought (back )?(?<what>.*?) (x(?<count>$SHORT_NUMBER_PATTERN) )?for (?<coins>$SHORT_NUMBER_PATTERN) Coins?!")
val npcSellPattern =
- Pattern.compile("You sold (?<what>.*) (x(?<count>$SHORT_NUMBER_PATTERN) )?for (?<coins>$SHORT_NUMBER_PATTERN) Coins!")
+ Pattern.compile("You sold (?<what>.*) (x(?<count>$SHORT_NUMBER_PATTERN) )?for (?<coins>$SHORT_NUMBER_PATTERN) Coins?!")
// TODO: IMPROVE BUYING FROM NPC TO INCLUDE ITEMS OTHER THAN COINS (KUUDRA KEYS ARE CHEAP)