Skip to content

Commit

Permalink
правки
Browse files Browse the repository at this point in the history
  • Loading branch information
HamletSargsyan committed Sep 8, 2024
1 parent 8f0f4f5 commit 664969e
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Новые поля в модели пользователя
- Добавлены команды для модераторов [#38](https://github.com/HamletSargsyan/livebot/issues/38)

### Изменено

- Мобы теперь встретиться только спустя 15–20 минут с начала прогулки

## [7.1.0] - 2024-08-31

### Добавлено
Expand Down
5 changes: 4 additions & 1 deletion src/base/actions.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,10 @@ def street(call: CallbackQuery, user: UserModel):
time_left = user.action.end - current_time
mess = f"<b>Улица</b>\n\nГуляешь\nОсталось: {get_time_difference_string(time_left)}"

if not user.met_mob:
walk_duration = current_time - user.action.start
if not user.met_mob and walk_duration >= timedelta(
minutes=random.randint(15, 20)
):
mob = generate_mob()
if mob:
mob.init(user, call.message)
Expand Down

0 comments on commit 664969e

Please sign in to comment.