This commit is contained in:
aozhiwei 2023-03-16 19:10:45 +08:00
parent 11bc27b177
commit b0baa38b6f

View File

@ -1455,6 +1455,7 @@ void Human::GenBattleReportData(a8::MutableXObject* params)
}
}
params->SetVal("is_team_statemented", GetTeam()->GetAliveNum() <= 0 ? 1 : 0);
params->SetVal("team_rank", GetTeam()->GetAliveNum() <= 0 ? GetTeam()->team_rank : 0);
{
std::shared_ptr<a8::MutableXObject> post_data = a8::MutableXObject::CreateObject();
std::shared_ptr<a8::MutableXObject> team_list = a8::MutableXObject::CreateArray();
@ -1471,6 +1472,9 @@ void Human::GenBattleReportData(a8::MutableXObject* params)
{
std::shared_ptr<a8::MutableXObject> member = a8::MutableXObject::CreateObject();
member->SetVal("account_id", hum->account_id);
if (hum->GetTeam()->GetAliveNum() <= 0) {
member->SetVal("kills", hum->stats.kills);
}
members_list->Push(*member.get());
return true;
});