From 21a04fd567cf549420b226f233ceb56f7dd01af7 Mon Sep 17 00:00:00 2001 From: aozhiwei Date: Thu, 2 Sep 2021 15:21:05 +0800 Subject: [PATCH] 1 --- server/gameserver/killmgr.cc | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/server/gameserver/killmgr.cc b/server/gameserver/killmgr.cc index f224112..8c11b64 100644 --- a/server/gameserver/killmgr.cc +++ b/server/gameserver/killmgr.cc @@ -94,7 +94,7 @@ void KillMgr::FillHintInfo(Human* dead_hum, KillInfo* info, RollMsgHintInfo& hin { hint_info.killer_name = ""; hint_info.hint_template = MetaMgr::Instance()->GetTextElements - (a8::Format("battle_server_dead_text_buff_%d", {1})); + (a8::Format("battle_server_dead_text_buff_%d", {info->weapon_id})); if (!hint_info.hint_template) { hint_info.hint_template = MetaMgr::Instance()->GetTextElements ("battle_server_dead_text_buff_default"); @@ -105,7 +105,7 @@ void KillMgr::FillHintInfo(Human* dead_hum, KillInfo* info, RollMsgHintInfo& hin { hint_info.killer_name = ""; hint_info.hint_template = MetaMgr::Instance()->GetTextElements - (a8::Format("battle_server_dead_text_explosion_%d", {1})); + (a8::Format("battle_server_dead_text_explosion_%d", {info->weapon_id})); if (!hint_info.hint_template) { hint_info.hint_template = MetaMgr::Instance()->GetTextElements ("battle_server_dead_text_explosion_default"); @@ -116,6 +116,10 @@ void KillMgr::FillHintInfo(Human* dead_hum, KillInfo* info, RollMsgHintInfo& hin { Entity* killer = dead_hum->room->GetEntityByUniId(info->killer_id); if (killer) { + MetaData::Equip* equip_meta = MetaMgr::Instance()->GetEquip(info->weapon_id); + if (equip_meta) { + hint_info.weapon_text_icon = equip_meta->i->text_icon(); + } hint_info.killer_name = killer->GetName(); if (info->killer_id == dead_hum->GetUniId()) { //${dead.name} 自杀