3
0
mirror of https://github.com/pragma-/pbot.git synced 2024-12-26 04:32:35 +01:00

Plugin/Wordle: preserve correct letters in list; add american-uncommon

This commit is contained in:
Pragmatic Software 2024-05-16 13:33:10 -07:00
parent c62b6b9a75
commit c6e1da1706
No known key found for this signature in database
GPG Key ID: CC916B6E3C84ECCE
3 changed files with 365667 additions and 3 deletions

365656
data/wordle/american-uncommon Normal file

File diff suppressed because it is too large Load Diff

View File

@ -53,6 +53,12 @@ my %wordlists = (
prompt => 'Guess the American English (Insanely Huge List) word!',
list => '/wordle/american-insane',
},
uncommon => {
name => 'American English (Uncommon)',
prompt => 'Guess the American English (Uncommon) word!',
list => '/wordle/american-uncommon',
supp => 'insane',
},
british => {
name => 'British English',
prompt => 'Guess the British English word!',
@ -443,7 +449,9 @@ sub guess_wordle($self, $channel, $guess) {
if ($present) {
$result .= "$color{present} $guess[$i]$color{present_a}?";
$self->{$channel}->{letters}->{$guess[$i]} = LETTER_PRESENT;
if ($self->{$channel}->{letters}->{$guess[$i]} != LETTER_CORRECT) {
$self->{$channel}->{letters}->{$guess[$i]} = LETTER_PRESENT;
}
} else {
$result .= "$color{invalid} $guess[$i] ";

View File

@ -25,8 +25,8 @@ use PBot::Imports;
# These are set by the /misc/update_version script
use constant {
BUILD_NAME => "PBot",
BUILD_REVISION => 4753,
BUILD_DATE => "2024-05-09",
BUILD_REVISION => 4754,
BUILD_DATE => "2024-05-16",
};
sub initialize {}