死亡时普通子弹不掉落

This commit is contained in:
aozhiwei 2020-06-12 19:53:16 +08:00
parent 56716dbc4b
commit ef1faddfed

View File

@ -2080,13 +2080,17 @@ void Human::DeadDrop()
if (inventory_[slot] > 0) {
MetaData::Equip* equip_meta = MetaMgr::Instance()->GetEquipBySlotId(slot);
if (equip_meta) {
if (equip_meta->i->equip_type() == 2 &&
MetaMgr::Instance()->fighting_mode) {
return;
}
switch (equip_meta->i->_inventory_slot()) {
case 4:
case 5:
case 6:
{
a8::Vec2 drop_pos = GetPos();
room->DropItem(drop_pos, equip_meta->i->id(), inventory_[slot], 1);
}
break;
}
}
}
}
}