Add names to default team generating

This commit is contained in:
memetrollsXD 2022-08-03 04:49:23 +02:00
parent 35b2131a05
commit 5128c904b8
No known key found for this signature in database
GPG Key ID: 105C2F3417AC32CD
2 changed files with 3 additions and 0 deletions

View File

@ -163,6 +163,7 @@ export default class Player {
for (let i = 0; i <= LINEUPS; i++) {
const copy = baseLineup;
copy.index = 0;
copy.name = `Team ${i}`;
dataObj.lineup.lineups[i] = copy;
}

View File

@ -62,6 +62,8 @@ export default async function handle(session: Session, packet: Packet) {
lineups: {}
}
for (let i = 0; i <= LINEUPS; i++) {
let copy = baseLineup;
copy.name = `Team ${i}`;
plr.db.lineup.lineups[i] = baseLineup;
}
plr.save();