1
This commit is contained in:
parent
4dd05a2b0c
commit
d3fd4a2d00
@ -520,22 +520,12 @@ void Room::ScatterDrop(const glm::vec3& center, int drop_id)
|
|||||||
const glm::vec3 pos = center;
|
const glm::vec3 pos = center;
|
||||||
const mt::Equip* equip_meta = mt::Equip::GetById(std::get<0>(item));
|
const mt::Equip* equip_meta = mt::Equip::GetById(std::get<0>(item));
|
||||||
if (equip_meta) {
|
if (equip_meta) {
|
||||||
if (equip_meta->equip_type() == EQUIP_TYPE_CAR) {
|
DropItemEx(center + dir * (5.0f + rand() % 50),
|
||||||
int car_uniid = AllocUniid();
|
pos,
|
||||||
Car* c = CreateCar(nullptr,
|
std::get<0>(item),
|
||||||
car_uniid,
|
std::get<1>(item),
|
||||||
equip_meta,
|
std::get<2>(item),
|
||||||
center,
|
true);
|
||||||
0,
|
|
||||||
nullptr);
|
|
||||||
} else {
|
|
||||||
DropItemEx(center + dir * (5.0f + rand() % 50),
|
|
||||||
pos,
|
|
||||||
std::get<0>(item),
|
|
||||||
std::get<1>(item),
|
|
||||||
std::get<2>(item),
|
|
||||||
true);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -606,16 +596,6 @@ int Room::CreateLootEx(int equip_id, const glm::vec3& born_pos, const glm::vec3&
|
|||||||
{
|
{
|
||||||
const mt::Equip* equip_meta = mt::Equip::GetById(equip_id);
|
const mt::Equip* equip_meta = mt::Equip::GetById(equip_id);
|
||||||
if (equip_meta) {
|
if (equip_meta) {
|
||||||
#ifdef DEBUG
|
|
||||||
if (GetGasData().GetGasMode() == GasWaiting || GetGasData().GetGasMode() == GasMoving) {
|
|
||||||
#if 0
|
|
||||||
if (equip_id == 30908) {
|
|
||||||
A8_ABORT();
|
|
||||||
a8::XPrintf("CreateLootEx %d\n", {equip_id});
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
Loot* entity = EntityFactory::Instance()->MakeLoot(AllocUniid());
|
Loot* entity = EntityFactory::Instance()->MakeLoot(AllocUniid());
|
||||||
entity->room = this;
|
entity->room = this;
|
||||||
entity->meta = equip_meta;
|
entity->meta = equip_meta;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user