1
This commit is contained in:
parent
711e253f18
commit
6412497e86
@ -1485,5 +1485,30 @@ void Room::NotifyWxVoip()
|
|||||||
|
|
||||||
BornPoint* Room::AllocBornPoint(Human* hum)
|
BornPoint* Room::AllocBornPoint(Human* hum)
|
||||||
{
|
{
|
||||||
return nullptr;
|
BornPoint* born_point = nullptr;
|
||||||
|
for (auto& pair : born_point_hash_) {
|
||||||
|
if (pair.second.player_num + pair.second.android_num < 6) {
|
||||||
|
born_point = &pair.second;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (born_point) {
|
||||||
|
switch (hum->entity_subtype) {
|
||||||
|
case EST_Player:
|
||||||
|
{
|
||||||
|
++born_point->player_num;
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
case EST_Android:
|
||||||
|
{
|
||||||
|
++born_point->android_num;
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
{
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return born_point;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user