1
This commit is contained in:
parent
8316bc6d52
commit
d2cfdc64b2
@ -427,9 +427,13 @@ void Room::AddPlayer(Player* hum, std::shared_ptr<BornPoint> init_born_point, bo
|
||||
App::Instance()->verify_set_pos = 1;
|
||||
if (!hum->GetBornPoint()) {
|
||||
abort();
|
||||
} else {
|
||||
if (!IsMobaModeRoom() && !IsSandTableRoom()) {
|
||||
hum->SetPos(hum->GetBornPoint()->NewRandPoint(hum->room, 10, 100));
|
||||
} else {
|
||||
hum->SetPos(hum->GetBornPoint()->RandPoint(this));
|
||||
}
|
||||
}
|
||||
App::Instance()->verify_set_pos = 0;
|
||||
glm::vec3 attack_dir = hum->GetPos().ToGlmVec3();
|
||||
GlmHelper::Normalize(attack_dir);
|
||||
@ -528,9 +532,13 @@ void Room::CreateAndroid(int robot_num, std::shared_ptr<Team> team)
|
||||
App::Instance()->verify_set_pos = 1;
|
||||
if (!hum->GetBornPoint()) {
|
||||
abort();
|
||||
} else {
|
||||
if (!IsMobaModeRoom() && !IsSandTableRoom()) {
|
||||
hum->SetPos(hum->GetBornPoint()->NewRandPoint(hum->room, 10, 100));
|
||||
} else {
|
||||
hum->SetPos(hum->GetBornPoint()->RandPoint(this));
|
||||
}
|
||||
}
|
||||
App::Instance()->verify_set_pos = 0;
|
||||
glm::vec3 attack_dir = hum->GetPos().ToGlmVec3();
|
||||
GlmHelper::Normalize(attack_dir);
|
||||
|
Loading…
x
Reference in New Issue
Block a user