Add a settings option to toggle displaying a player's donation history when clicking on their name in the leaderboard

dev
peshomir 2025-03-22 23:25:10 +02:00
parent a979274238
commit d3aea584c6
3 changed files with 9 additions and 1 deletions

View File

@ -144,7 +144,7 @@ canvas.font=aY.g0.g1(1,fontSize),canvas.fillStyle="rgba("+gR+","+tD+","+hj+",0.6
// variable in the modified leaderboard click handler from the leaderboard filter)
// match , 0 !== dG[x]) && fq.hB(x, 800, false, 0),
replaceOne(/,(0!==\w+\.\w+\[(\w+)\])(\)&&\w+\.\w+\(\2,800,!1,0\),)/g,
`, ${dict.game}.${dict.gIsTeamGame} && __fx.donationsTracker.displayHistory($2, ${rawPlayerNames}, ${gIsSingleplayer}), $1 && !isEmptySpace $3`);
`, ${dict.game}.${dict.gIsTeamGame} && __fx.settings.openDonationHistoryFromLb && __fx.donationsTracker.displayHistory($2, ${rawPlayerNames}, ${gIsSingleplayer}), $1 && !isEmptySpace $3`);
// Reset donation history and leaderboard filter when a new game is started
replaceRawCode(",ab.dP(),ad.a10(),b5.nZ.oJ=[],bc.dP(),this.wE=1,",

View File

@ -21,6 +21,7 @@ var settings = {
hideBotNames: false,
highlightClanSpawns: false,
detailedTeamPercentage: false,
openDonationHistoryFromLb: true,
//"customMapFileBtn": true
customBackgroundUrl: "",
keybindButtons: false,
@ -96,6 +97,12 @@ const settingsManager = new (function () {
label: "Detailed team pie chart percentage",
note: "For example: this would show 25.82% instead of 26% on the pie chart in team games"
},
{
for: "openDonationHistoryFromLb",
type: "checkbox",
label: "Open donation history from the leaderboard",
note: "Changes whether or not clicking on a player's name in the in-game leaderboard in team games will open their donation history",
},
{
for: "customBackgroundUrl",
type: "textInput",

View File

@ -5,6 +5,7 @@
"Added a \"What's new\" screen (the one you're looking at right now!) which displays a changelog of the latest version",
"Added custom lobby join links - to get one, click on the new \"Copy link\" button while in a lobby.",
"Added version information at the bottom of the setting page along with a link to the FX Client Discord server and GitHub repository. Previously this was shown only in the vanilla version menu.",
"Added a settings option to toggle displaying a player's donation history when clicking on their name in the leaderboard (applies to team games only)",
"The custom lobby server no longer tries to verify the compatibility of the client's protocol version. This will make custom lobbies usable immediately after an update, provided that the communication protocol has not changed significantly."
]
}