Change default slot to 0 (index out of range)
This commit is contained in:
parent
d8397bdc97
commit
76f9578016
@ -57,15 +57,12 @@ export default async function handle(session: Session, packet: Packet) {
|
|||||||
planeId: 10001
|
planeId: 10001
|
||||||
}
|
}
|
||||||
const LINEUPS = 6;
|
const LINEUPS = 6;
|
||||||
let slot = 0;
|
|
||||||
plr.db.lineup = {
|
plr.db.lineup = {
|
||||||
curIndex: 0,
|
curIndex: 0,
|
||||||
lineups: {}
|
lineups: {}
|
||||||
}
|
}
|
||||||
for (let i = 0; i <= LINEUPS; i++) {
|
for (let i = 0; i <= LINEUPS; i++) {
|
||||||
const copy = baseLineup;
|
plr.db.lineup.lineups[i] = baseLineup;
|
||||||
copy.index = slot++;
|
|
||||||
plr.db.lineup.lineups[i] = copy;
|
|
||||||
}
|
}
|
||||||
plr.save();
|
plr.save();
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user