1
This commit is contained in:
parent
3909891484
commit
814abfe4d0
@ -119,3 +119,8 @@ bool CustomBattle::AllIsJoined()
|
||||
}
|
||||
return ok;
|
||||
}
|
||||
|
||||
int CustomBattle::GetMemberNum()
|
||||
{
|
||||
return member_id_hash_.size();
|
||||
}
|
||||
|
@ -25,6 +25,7 @@ class CustomBattle
|
||||
std::shared_ptr<CustomMember> GetMemberByAccountId(const std::string& account_id);
|
||||
std::shared_ptr<CustomTeam> GetTeamByTeamUuid(const std::string& team_uuid);
|
||||
bool AllIsJoined();
|
||||
int GetMemberNum();
|
||||
|
||||
private:
|
||||
bool parse_ok_ = false;
|
||||
|
@ -2696,6 +2696,9 @@ size_t Room::GetRoomMaxPlayerNum()
|
||||
if (IsNewBieRoom()) {
|
||||
return 1;
|
||||
}
|
||||
if (custom_battle_) {
|
||||
return custom_battle_->GetMemberNum();
|
||||
}
|
||||
return map_meta_->player();
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user