Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feature/client-room-implementation #168

Merged
merged 28 commits into from
May 31, 2022
Merged

Conversation

MarkTheHopeful
Copy link
Contributor

Клиент адаптирован под соответствующую ветку из сервера: #161

protoroomview разбит на roomview и sessionview.

Теперь на клиенте можно создать комнату и стать её хостом, в комнате можно, выбрав игру, создать сессию с этой игрой. Остальным участникам комнаты будет дана возможность присоединиться к новой сессии. В сессии всё почти как и раньше, но без invite-code. Хотя можно отобразить для удобства.

После закрытия QML-приложения пользователя возвращает на экран комнаты.

Баги на текущий момент: проблемы с созданием следующей сессии (у пользователей есть возможность зайти в закончившуюся сессию, а у хоста комнаты есть возможность создать новую сессию всегда).

@MarkTheHopeful MarkTheHopeful added enhancement New feature or request client labels May 30, 2022
@MarkTheHopeful MarkTheHopeful requested review from petrtsv and waleko May 30, 2022 15:41
@MarkTheHopeful MarkTheHopeful self-assigned this May 30, 2022
@gitpod-io
Copy link

gitpod-io bot commented May 30, 2022

@MarkTheHopeful
Copy link
Contributor Author

Пока ещё вносятся исправления, вариант не конечный

@MarkTheHopeful
Copy link
Contributor Author

Нет, теперь вторую сессию хоть и можно создать, работать полноценно она пока не будет. Причины выясняются...

Copy link
Member

@waleko waleko left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔥 с кайфом

Comment on lines 263 to 265
roomInfo.isHost = roomInfo.host_id ==
queryUserId; // using explicitly query user_id, as in
// prod mode it is returned from the server
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

повторение meh, но ладно


public slots:
void updateRoomInfo(const RoomInfo &roomInfo);
void updateSessionInfo(const SessionInfo &sessionInfo); // Temporary
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

в чем temporary?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

По сути, уже даже в текущей версии сервера в RoomInfo есть сама SessionInfo, и отдельно её запрашивать по session_id не нужно, так что updateSessionInfo тут лежит до тех пор, пока я не перепишу (немного, на самом деле) на получение SessionInfo напрямую из RoomInfo

@MarkTheHopeful MarkTheHopeful force-pushed the feature/client-room-implementation branch from f9be121 to d582c16 Compare May 31, 2022 21:34
@waleko waleko merged commit 62cdc31 into develop May 31, 2022
@waleko waleko deleted the feature/client-room-implementation branch May 31, 2022 21:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
client enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants