This commit is contained in:
aozhiwei 2021-06-01 11:43:13 +08:00
parent 2d0c9ba3c1
commit b916e16fde
2 changed files with 5 additions and 3 deletions

View File

@ -3734,17 +3734,18 @@ void Human::SendRollMsgEx(KillInfo& info,
break;
}
} else if (*p == '$' && *(p+1)) {
char* p1 = strstr((char*)p, "${weapon_id}");
char* p1 = strstr((char*)p, "${weapon_text_icon}");
if (p1) {
if (!result.empty()) {
auto element = pb_msg->add_elements();
element->set_element_type(1);
element->mutable_union_obj_1()->set_text(result);
}
{
MetaData::Equip* equip_meta = MetaMgr::Instance()->GetEquip(info.weapon_id);
if (equip_meta) {
auto element = pb_msg->add_elements();
element->set_element_type(2);
element->mutable_union_obj_2()->set_id(info.weapon_id);
element->mutable_union_obj_2()->set_id(equip_meta->i->text_icon());
}
result = "";
} else {

View File

@ -121,6 +121,7 @@ message Equip
optional string power_gun = 52;
optional string power_buff = 53;
optional int32 through_teammate = 54;
optional int32 text_icon = 55;
optional string inventory_slot = 31; //
optional int32 _inventory_slot = 32; //