修复坦克半径问题
This commit is contained in:
parent
83a972ba4f
commit
84e64c76e0
@ -1998,6 +1998,8 @@ int Human::SkinLv()
|
|||||||
void Human::CheckSkinTank()
|
void Human::CheckSkinTank()
|
||||||
{
|
{
|
||||||
if (tank_weapon.meta) {
|
if (tank_weapon.meta) {
|
||||||
|
float old_rad = self_collider_->rad;
|
||||||
|
self_collider_->rad = tank_weapon.meta->i->rad2();
|
||||||
std::set<Human*> objects;
|
std::set<Human*> objects;
|
||||||
for (auto& grid : grid_list) {
|
for (auto& grid : grid_list) {
|
||||||
for (Human* hum: grid->human_list) {
|
for (Human* hum: grid->human_list) {
|
||||||
@ -2012,6 +2014,7 @@ void Human::CheckSkinTank()
|
|||||||
for (Human* hum : objects) {
|
for (Human* hum : objects) {
|
||||||
hum->BeKill(entity_uniid, name, VW_Tank);
|
hum->BeKill(entity_uniid, name, VW_Tank);
|
||||||
}
|
}
|
||||||
|
self_collider_->rad = old_rad;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -78,6 +78,7 @@ message Equip
|
|||||||
optional float bullet_angle = 34; //子弹浮动方向
|
optional float bullet_angle = 34; //子弹浮动方向
|
||||||
optional string name = 35; //装备名字
|
optional string name = 35; //装备名字
|
||||||
optional float rad = 36; //半径
|
optional float rad = 36; //半径
|
||||||
|
optional float rad2 = 37;
|
||||||
|
|
||||||
optional string inventory_slot = 31; //库存槽位
|
optional string inventory_slot = 31; //库存槽位
|
||||||
optional int32 _inventory_slot = 32; //库存槽位
|
optional int32 _inventory_slot = 32; //库存槽位
|
||||||
|
Loading…
x
Reference in New Issue
Block a user