From 84e64c76e09d6c4dde51a3288a8ce9d02bb8fe9f Mon Sep 17 00:00:00 2001 From: aozhiwei Date: Wed, 4 Sep 2019 11:57:36 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E5=9D=A6=E5=85=8B=E5=8D=8A?= =?UTF-8?q?=E5=BE=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- server/gameserver/human.cc | 3 +++ server/tools/protobuild/metatable.proto | 1 + 2 files changed, 4 insertions(+) diff --git a/server/gameserver/human.cc b/server/gameserver/human.cc index 64a4845..f0081c1 100644 --- a/server/gameserver/human.cc +++ b/server/gameserver/human.cc @@ -1998,6 +1998,8 @@ int Human::SkinLv() void Human::CheckSkinTank() { if (tank_weapon.meta) { + float old_rad = self_collider_->rad; + self_collider_->rad = tank_weapon.meta->i->rad2(); std::set objects; for (auto& grid : grid_list) { for (Human* hum: grid->human_list) { @@ -2012,6 +2014,7 @@ void Human::CheckSkinTank() for (Human* hum : objects) { hum->BeKill(entity_uniid, name, VW_Tank); } + self_collider_->rad = old_rad; } } diff --git a/server/tools/protobuild/metatable.proto b/server/tools/protobuild/metatable.proto index 7dcfd4f..09aea6b 100755 --- a/server/tools/protobuild/metatable.proto +++ b/server/tools/protobuild/metatable.proto @@ -78,6 +78,7 @@ message Equip optional float bullet_angle = 34; //子弹浮动方向 optional string name = 35; //装备名字 optional float rad = 36; //半径 + optional float rad2 = 37; optional string inventory_slot = 31; //库存槽位 optional int32 _inventory_slot = 32; //库存槽位