Onlinelist add faction remove level

This commit is contained in:
CroniX
2021-01-21 19:37:32 +01:00
parent fe1916c60a
commit 9b5fcffdf6
4 changed files with 14 additions and 14 deletions

View File

@@ -9,7 +9,7 @@ export default function playerList(globalData: IGlobalData): void {
var playerlistBrowser: BrowserMp = null;
var pList;
mp.events.add("showPlayerlist", (playersJson) => {
mp.events.add("showPlayerlist", (playersJson, factionname) => {
if (playerlistBrowser !== null) {
playerlistBrowser.destroy();
@@ -25,7 +25,7 @@ export default function playerList(globalData: IGlobalData): void {
mp.gui.cursor.show(true, true);
pList = JSON.parse(playersJson);
pList.forEach((player) => {
playerlistBrowser.execute(`ad_row('${JSON.stringify(player.Id)}','${JSON.stringify(player.Name)}',0,0,'${JSON.stringify(player.Ping)}');`);
playerlistBrowser.execute(`ad_row('${JSON.stringify(player.Id)}','${JSON.stringify(player.Name)}',${JSON.stringify(factionname)},'${JSON.stringify(player.Ping)}');`);
});
}
});