diff --git a/Release/Plugins/RenX.Core.lib b/Release/Plugins/RenX.Core.lib index 86862dc..0695e17 100644 Binary files a/Release/Plugins/RenX.Core.lib and b/Release/Plugins/RenX.Core.lib differ diff --git a/RenX.Core/RenX_Tags.cpp b/RenX.Core/RenX_Tags.cpp index 257b4c6..a78ae62 100644 --- a/RenX.Core/RenX_Tags.cpp +++ b/RenX.Core/RenX_Tags.cpp @@ -155,6 +155,7 @@ TagsImp::TagsImp() this->INTERNAL_VICTIM_TEAM_LONG_TAG = this->getUniqueInternalTag(); this->INTERNAL_VICTIM_PING_TAG = this->getUniqueInternalTag(); this->INTERNAL_VICTIM_SCORE_TAG = this->getUniqueInternalTag(); + this->INTERNAL_VICTIM_SCORE_PER_MINUTE_TAG = this->getUniqueInternalTag(); this->INTERNAL_VICTIM_CREDITS_TAG = this->getUniqueInternalTag(); this->INTERNAL_VICTIM_KILLS_TAG = this->getUniqueInternalTag(); this->INTERNAL_VICTIM_DEATHS_TAG = this->getUniqueInternalTag(); @@ -348,7 +349,7 @@ TagsImp::TagsImp() this->newNameTag = Jupiter::IRC::Client::Config->get(configSection, "NewNameTag"_jrs, "{NNAME}"_jrs); this->winScoreTag = Jupiter::IRC::Client::Config->get(configSection, "WinScoreTag"_jrs, "{WINSCORE}"_jrs); this->loseScoreTag = Jupiter::IRC::Client::Config->get(configSection, "LoseScoreTag"_jrs, "{LOSESCORE}"_jrs); - this->lastGameTag = Jupiter::IRC::Client::Config->get(configSection, "LastScoreTag"_jrs, "{LOSESCORE}"_jrs); + this->lastGameTag = Jupiter::IRC::Client::Config->get(configSection, "LastGameTag"_jrs, "{LASTGAME}"_jrs); this->rankTag = Jupiter::IRC::Client::Config->get(configSection, "RankTag"_jrs, "{RANK}"_jrs); } @@ -443,7 +444,7 @@ void TagsImp::processTags(Jupiter::StringType &msg, const RenX::Server *server, PROCESS_TAG(this->INTERNAL_CREDITS_TAG, Jupiter::StringS::Format("%.0f", player->credits)); PROCESS_TAG(this->INTERNAL_KILLS_TAG, Jupiter::StringS::Format("%u", player->kills)); PROCESS_TAG(this->INTERNAL_DEATHS_TAG, Jupiter::StringS::Format("%u", player->deaths)); - PROCESS_TAG(this->INTERNAL_KDR_TAG, Jupiter::StringS::Format("%.2f", static_cast(player->kills) / (player->deaths == 0 ? 1.0f : static_cast(player->deaths)))); + PROCESS_TAG(this->INTERNAL_KDR_TAG, Jupiter::StringS::Format("%.2f", get_ratio(static_cast(player->kills), static_cast(player->deaths)))); PROCESS_TAG(this->INTERNAL_SUICIDES_TAG, Jupiter::StringS::Format("%u", player->suicides)); PROCESS_TAG(this->INTERNAL_HEADSHOTS_TAG, Jupiter::StringS::Format("%u", player->headshots)); PROCESS_TAG(this->INTERNAL_VEHICLE_KILLS_TAG, Jupiter::StringS::Format("%u", player->vehicleKills)); @@ -480,7 +481,7 @@ void TagsImp::processTags(Jupiter::StringType &msg, const RenX::Server *server, PROCESS_TAG(this->INTERNAL_VICTIM_CREDITS_TAG, Jupiter::StringS::Format("%.0f", victim->credits)); PROCESS_TAG(this->INTERNAL_VICTIM_KILLS_TAG, Jupiter::StringS::Format("%u", victim->kills)); PROCESS_TAG(this->INTERNAL_VICTIM_DEATHS_TAG, Jupiter::StringS::Format("%u", victim->deaths)); - PROCESS_TAG(this->INTERNAL_VICTIM_KDR_TAG, Jupiter::StringS::Format("%.2f", static_cast(victim->kills) / (victim->deaths == 0 ? 1.0f : static_cast(victim->deaths)))); + PROCESS_TAG(this->INTERNAL_VICTIM_KDR_TAG, Jupiter::StringS::Format("%.2f", get_ratio(static_cast(victim->kills), static_cast(victim->deaths)))); PROCESS_TAG(this->INTERNAL_VICTIM_SUICIDES_TAG, Jupiter::StringS::Format("%u", victim->suicides)); PROCESS_TAG(this->INTERNAL_VICTIM_HEADSHOTS_TAG, Jupiter::StringS::Format("%u", victim->headshots)); PROCESS_TAG(this->INTERNAL_VICTIM_VEHICLE_KILLS_TAG, Jupiter::StringS::Format("%u", victim->vehicleKills)); @@ -660,7 +661,7 @@ void TagsImp::sanitizeTags(Jupiter::StringType &fmt) fmt.replace(this->victimTeamLongTag, this->INTERNAL_VICTIM_TEAM_LONG_TAG); fmt.replace(this->victimPingTag, this->INTERNAL_VICTIM_PING_TAG); fmt.replace(this->victimScoreTag, this->INTERNAL_VICTIM_SCORE_TAG); - fmt.replace(this->victimScorePerMinuteTag, this->INTERNAL_SCORE_PER_MINUTE_TAG); + fmt.replace(this->victimScorePerMinuteTag, this->INTERNAL_VICTIM_SCORE_PER_MINUTE_TAG); fmt.replace(this->victimCreditsTag, this->INTERNAL_VICTIM_CREDITS_TAG); fmt.replace(this->victimKillsTag, this->INTERNAL_VICTIM_KILLS_TAG); fmt.replace(this->victimDeathsTag, this->INTERNAL_VICTIM_DEATHS_TAG); diff --git a/RenX.Ladder.Web/RenX_Ladder_Web.cpp b/RenX.Ladder.Web/RenX_Ladder_Web.cpp index ee90699..3982630 100644 --- a/RenX.Ladder.Web/RenX_Ladder_Web.cpp +++ b/RenX.Ladder.Web/RenX_Ladder_Web.cpp @@ -188,6 +188,7 @@ Jupiter::String RenX_Ladder_WebPlugin::generate_entry_table(size_t index, size_t row = RenX_Ladder_WebPlugin::entry_table_row; RenX::processTags(row, *node); result += row; + node = node->next; --count; }