1
This commit is contained in:
parent
224e22dd95
commit
d527c83638
@ -19,6 +19,24 @@ void Incubator::Init()
|
|||||||
incubator->AutoAllocAndroid();
|
incubator->AutoAllocAndroid();
|
||||||
},
|
},
|
||||||
&xtimer_attacher_.timer_list_);
|
&xtimer_attacher_.timer_list_);
|
||||||
|
if (room->IsPveRoom()) {
|
||||||
|
int wave = 0;
|
||||||
|
for (int time : room->pve_mode_meta->mode_time) {
|
||||||
|
room->xtimer.AddDeadLineTimerAndAttach
|
||||||
|
(
|
||||||
|
time * SERVER_FRAME_RATE,
|
||||||
|
a8::XParams()
|
||||||
|
.SetSender(this)
|
||||||
|
.SetParam1(wave),
|
||||||
|
[] (const a8::XParams& param)
|
||||||
|
{
|
||||||
|
Incubator* incubator = (Incubator*)param.sender.GetUserData();
|
||||||
|
incubator->SpawnWaveMon(param.param1.GetInt());
|
||||||
|
},
|
||||||
|
&xtimer_attacher_.timer_list_);
|
||||||
|
++wave;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void Incubator::UnInit()
|
void Incubator::UnInit()
|
||||||
@ -218,3 +236,8 @@ void Incubator::ActiveAndroid(Human* hum, Human* android)
|
|||||||
}));
|
}));
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void Incubator::SpawnWaveMon(int wave)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
@ -18,6 +18,7 @@ class Incubator
|
|||||||
private:
|
private:
|
||||||
bool CanSee(Human* hum, Human* exclude_hum);
|
bool CanSee(Human* hum, Human* exclude_hum);
|
||||||
void AutoAllocAndroid();
|
void AutoAllocAndroid();
|
||||||
|
void SpawnWaveMon(int wave);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
std::vector<Human*> hold_humans_;
|
std::vector<Human*> hold_humans_;
|
||||||
|
@ -1637,7 +1637,7 @@ namespace MetaData
|
|||||||
|
|
||||||
float PveGemini::GetHpMul()
|
float PveGemini::GetHpMul()
|
||||||
{
|
{
|
||||||
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
void PveGeminiContent::Init()
|
void PveGeminiContent::Init()
|
||||||
@ -1647,7 +1647,20 @@ namespace MetaData
|
|||||||
|
|
||||||
void PveGeminiMode::Init()
|
void PveGeminiMode::Init()
|
||||||
{
|
{
|
||||||
|
{
|
||||||
|
std::vector<std::string> strings;
|
||||||
|
a8::Split(pb->mode_time(), strings, '|');
|
||||||
|
for (auto& str : strings) {
|
||||||
|
int time = a8::XValue(str);
|
||||||
|
if (time <= 0) {
|
||||||
|
abort();
|
||||||
|
}
|
||||||
|
if (time > 200) {
|
||||||
|
abort();
|
||||||
|
}
|
||||||
|
mode_time.push_back(time);
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user