Commit graph

82 commits

Author SHA1 Message Date
Pesakitan22
27279b9114 new mode 2018-04-16 15:11:42 +07:00
1c713de46d Add /kick command and remove botan support (#38)
* kick handler test

* Add authentication and fix bugs

* Add help text

* minor fix

* Remove useless comments

* Get user object from reply first.

* Update bot.py

* minor fix

* update help text

* Update AUTHORS.md

* Remove old /kick implementation

* minor fix

* Manually merge upstream changes

* No need to accept args

* remove unused chat_setting.py

* botan

* import botan from submodule for compatibility with python-telegram-bot 8.1+

* fix typo

* Update requirements.txt

* delete submodule

* Drop botan support completely

* Refine the way of getting config

* Bug fix
2017-12-07 09:27:51 +01:00
Jarv
ea881cf520 Added gamemodes. New mode: Fast. (#44)
* Changes for possible bug

* New sanic mode wip

* More changes for fast mode, WIP

* Fast mode is playable (code is ugly tho)

* Fixed skip error

* Fixed fast mode error

* Bug fixing

* Possible fix for the /leave bug before the game starts

* Update README to include Codacy badge

* Fixing error prone code

* Removing code smells

* Removing more code smells

* How long can this go on? (More smells according to Codacy)

* Compile locale fixed for Linux. Small es_ES fix.

* Major refactoring

* Wild mode finished. Changed emojis for text in log.

* Removing test prints, back to emojis

* Code cleaning and fix for player time in fast mode

* Changing help to not override builtin function

* Decreased bot.py's complexity

* Default gamemode is now Fast. Added a bot configuration file

* back to random

* Moved logger to shared_vars

* Added MIN_FAST_TURN_TIME to config and fixed 'skipped 4 times' message

* Pull review changes

* More review changes

* Removing codacy badge linked to my account for pull request

* Fixed first special card issue, logger back to how it was (with just one logging init)

* Renamed gameplay config file to gameplay_config.py.
2017-11-27 17:59:19 +01:00
Jannes Höke
09d01d001b add cached admin check 2017-08-19 00:08:55 +02:00
Simon Shi
783e010956 python-telegram-bot v7 compatability + more (#35)
* Remove import of telegram.Emoji

* Using a list of filters in MessageHandler is getting deprecated

* Update requirements

Proudly upgrades to latest python-telegram-bot

* Refine readme

* Test kill command

* Another implement

* Add /kill command

* initial config support

* json config

* Add token into json

* Typo

* Add Admin list

* Refine admin & starter

* Fix an exception

* Fix typo

* refine readme

* Update help
2017-08-18 23:36:30 +02:00
Jannes Höke
f1b241d808 correct command handler 2016-07-05 00:40:36 +02:00
Jannes Höke
ba81ab614a use set instead of list for notify_me command 2016-07-05 00:38:02 +02:00
TiagoDanin
a5eefdc1d0 Update and Fix Translation 2016-07-02 14:34:06 -05:00
Jannes Höke
b136bdf997 formatting, exception handling, documentation 2016-07-02 20:37:35 +02:00
qubitnerd
2a710145f6 added next_game , get a pm from when next game starts 2016-07-02 21:23:34 +05:30
Jannes Höke
7f15aac773 missing arg in funciton call 2016-06-04 12:44:21 +02:00
Jannes Höke
5c87e74ae2 small fixes 2016-06-02 15:03:33 +02:00
Jannes Höke
beaa46f8e4 translation issues 2016-05-27 14:03:12 +02:00
Jannes Höke
569850fade get game before ending it 2016-05-27 11:31:06 +02:00
Jannes Höke
7c250c6f79 don't record played cards if stats not enabled 2016-05-25 03:01:25 +02:00
Jannes Höke
6901e7f4d0 implement plurals, update de_DE translation to use plurals 2016-05-24 15:49:23 +02:00
Jannes Höke
72515e37ed fix games first place stats 2016-05-24 09:58:04 +02:00
Jannes Höke
4a51c7bfb6 change loglevel to INFO 2016-05-23 13:30:57 +02:00
Jannes Höke
0c3f623cd9 small fixes & translation updates 2016-05-23 01:54:56 +02:00
Jannes Höke
ba47f4c19e final version? 2016-05-22 19:21:51 +02:00
Jannes Höke
4cdffffa5f Optional multi-translations 2016-05-22 17:02:27 +02:00
Jannes Höke
6c610c1aeb settings UI added, save locale to database 2016-05-22 14:45:51 +02:00
Jannes Höke
cddf13dc5d add __ function to translate complete stack, add dummy decorators to pull locales from db 2016-05-22 03:13:05 +02:00
Jannes Höke
5ece46527a locales are working, added de_DE locale 2016-05-21 21:41:38 +02:00
Jannes Höke
becc7e28dc fix broken method call 2016-05-21 18:56:58 +02:00
Jannes Höke
aee310ec9c handle empty decks on player join 2016-05-20 18:34:27 +02:00
Jannes Höke
204b057810 add encoding 2016-05-19 23:15:46 +02:00
Jannes Höke
6204868a18 separate game logic from bot interface,
introduce exceptions instead of boolean returns,
remove repetitive code,
begin unit tests,
improve docstrings,
update to python-telegram-bot==4.1.1,
add ponyorm settings classes (unused)
2016-05-19 20:56:52 +02:00
Jannes Höke
a6f2c07403 increase workers to 32 2016-05-08 19:40:58 +02:00
Jannes Höke
f82b9ce6c0 hint on close command on game start 2016-05-08 18:52:10 +02:00
Jannes Höke
9b62f9b116 limit timer resetting even further 2016-05-08 18:38:31 +02:00
Jannes Höke
ae311ea0cf next.user 2016-05-08 17:52:06 +02:00
Jannes Höke
b75667bb86 reset at correct position and display right name 2016-05-08 17:46:41 +02:00
Jannes Höke
d85934b789 actually check for waiting time, not always 90sex 2016-05-08 17:17:51 +02:00
Jannes Höke
4c1a5537eb fix waiting time display and reset 2016-05-08 17:13:01 +02:00
Jannes Höke
1d10388d8e reduce waiting time for repeated skipping and remove after four successive skips 2016-05-08 17:03:29 +02:00
Jannes Höke
686cf3facb move to AGPL (#4) 2016-05-08 14:37:25 +02:00
Jannes Höke
9b4f4a43ea on skip, add card to players hand 2016-05-02 12:10:35 +02:00
Jannes Höke
1b1edf508d change time limit to 90 seconds 2016-05-01 18:41:40 +02:00
Jannes Höke
0cf7b70454 use actual game creator, make skip available to every player 2016-05-01 18:23:59 +02:00
Jannes Höke
27fff4b2e1 game endings cleaner, time limit on skip command 2016-04-30 13:26:50 +02:00
Jannes Höke
dde30a14d7 answer async with timeout 2016-04-30 12:20:36 +02:00
Jannes Höke
281511e0fd display next player on leave 2016-04-30 11:43:26 +02:00
Jannes Höke
1844d1d40a move result builders and utility functions to seperate files 2016-04-29 17:03:02 +02:00
Jannes Höke
3b590d9fca adjust for python-telegram-bot 4.0.1 2016-04-29 11:13:03 +02:00
imlonghao
971fe8ef88
Kicked out of games once he win 2016-04-29 00:17:14 +08:00
imlonghao
0ecf3370e3
Fix issue when joining a closed game, send message via send_async, send message to the sender in same case. 2016-04-27 21:47:11 +08:00
Jannes Höke
67daa82ece moar commands, leave always, asynchronous sending, game switching [untested] 2016-04-26 17:53:29 +02:00
Jannes Höke
c1ef321cc3 experimental: multiple games 2016-04-24 02:11:37 +02:00
Jannes Höke
c22e91eafa allow leaving game if two or less players are in game 2016-04-23 22:31:07 +02:00