1
This commit is contained in:
parent
8dc95b3b39
commit
a841871924
@ -481,6 +481,13 @@ namespace MetaData
|
|||||||
metatable::MapTplThingJson* mutable_i = (metatable::MapTplThingJson*)i;
|
metatable::MapTplThingJson* mutable_i = (metatable::MapTplThingJson*)i;
|
||||||
if (mutable_i->object_type() == "spawn_point") {
|
if (mutable_i->object_type() == "spawn_point") {
|
||||||
mutable_i->set__object_type(kMOT_SpawnPoint);
|
mutable_i->set__object_type(kMOT_SpawnPoint);
|
||||||
|
} else if (mutable_i->object_type() == "mon_spawn_point") {
|
||||||
|
mutable_i->set__object_type(kMOT_MonsterSpawnPoint);
|
||||||
|
std::vector<std::string> strings;
|
||||||
|
a8::Split(i->things(), strings, '\n');
|
||||||
|
for (auto& str : strings) {
|
||||||
|
heros.push_back(a8::XValue(str));
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
mutable_i->set__object_type(kMOT_Object);
|
mutable_i->set__object_type(kMOT_Object);
|
||||||
rand_space = 0;
|
rand_space = 0;
|
||||||
|
@ -144,6 +144,7 @@ namespace MetaData
|
|||||||
int RandThing();
|
int RandThing();
|
||||||
|
|
||||||
std::vector<std::tuple<int, int>> things;
|
std::vector<std::tuple<int, int>> things;
|
||||||
|
std::vector<int> heros;
|
||||||
int rand_space = 0;
|
int rand_space = 0;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -77,6 +77,7 @@ void Room::Init()
|
|||||||
xtimer_attacher_.xtimer = &xtimer;
|
xtimer_attacher_.xtimer = &xtimer;
|
||||||
|
|
||||||
CreateSpawnPoints();
|
CreateSpawnPoints();
|
||||||
|
CreateMonsterSpawnPoints();
|
||||||
CreateLoots();
|
CreateLoots();
|
||||||
CreateDropObjs();
|
CreateDropObjs();
|
||||||
InitObstacleDatas();
|
InitObstacleDatas();
|
||||||
@ -2082,6 +2083,13 @@ void Room::CreateSpawnPoints()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void Room::CreateMonsterSpawnPoints()
|
||||||
|
{
|
||||||
|
if (room_monster_spawn_points_) {
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
void Room::CreateLoots()
|
void Room::CreateLoots()
|
||||||
{
|
{
|
||||||
for (auto& thing_tpl : *loots_) {
|
for (auto& thing_tpl : *loots_) {
|
||||||
|
@ -205,6 +205,7 @@ private:
|
|||||||
BornPoint* AllocBornPoint(Human* hum);
|
BornPoint* AllocBornPoint(Human* hum);
|
||||||
BornPoint* GetBornPoint(int point_uniid);
|
BornPoint* GetBornPoint(int point_uniid);
|
||||||
void CreateSpawnPoints();
|
void CreateSpawnPoints();
|
||||||
|
void CreateMonsterSpawnPoints();
|
||||||
void CreateLoots();
|
void CreateLoots();
|
||||||
void CreateDropObjs();
|
void CreateDropObjs();
|
||||||
void IncBornPointHumanNum(BornPoint* point, Human* hum);
|
void IncBornPointHumanNum(BornPoint* point, Human* hum);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user