fix(katana): detect 4 cards dropping
I forgor
This commit is contained in:
parent
0f9331ba60
commit
56e51c8d2f
@ -257,14 +257,12 @@ pub async fn analyze_card_libtesseract(card: image::DynamicImage, count: u32) ->
|
|||||||
Some(c) => {
|
Some(c) => {
|
||||||
card = c;
|
card = c;
|
||||||
}
|
}
|
||||||
None => {
|
None => match db::query_card_regex(&card.name, &card.series).await {
|
||||||
match db::query_card_regex(&card.name, &card.series).await {
|
|
||||||
Some(c) => {
|
Some(c) => {
|
||||||
card = c;
|
card = c;
|
||||||
}
|
}
|
||||||
None => {}
|
None => {}
|
||||||
}
|
},
|
||||||
}
|
|
||||||
}
|
}
|
||||||
card
|
card
|
||||||
}
|
}
|
||||||
@ -323,14 +321,12 @@ pub async fn analyze_card_subprocess(card: image::DynamicImage, count: u32) -> C
|
|||||||
Some(c) => {
|
Some(c) => {
|
||||||
card = c;
|
card = c;
|
||||||
}
|
}
|
||||||
None => {
|
None => match db::query_card_regex(&card.name, &card.series).await {
|
||||||
match db::query_card_regex(&card.name, &card.series).await {
|
|
||||||
Some(c) => {
|
Some(c) => {
|
||||||
card = c;
|
card = c;
|
||||||
}
|
}
|
||||||
None => {}
|
None => {}
|
||||||
}
|
},
|
||||||
}
|
|
||||||
}
|
}
|
||||||
card
|
card
|
||||||
}
|
}
|
||||||
|
@ -123,7 +123,7 @@ async fn parse_katana_event(ctx: &Context, event: MessageUpdateEvent) -> Result<
|
|||||||
}
|
}
|
||||||
|
|
||||||
async fn parse_katana(ctx: &Context, msg: &Message) -> Result<(), String> {
|
async fn parse_katana(ctx: &Context, msg: &Message) -> Result<(), String> {
|
||||||
if msg.content.contains("is dropping 3 cards!")
|
if (msg.content.contains("is dropping") && msg.content.contains("cards!"))
|
||||||
|| msg
|
|| msg
|
||||||
.content
|
.content
|
||||||
.contains("I'm dropping 3 cards since this server is currently active!")
|
.contains("I'm dropping 3 cards since this server is currently active!")
|
||||||
|
Loading…
Reference in New Issue
Block a user