mirror of
https://github.com/blitzkit/blitzkit.git
synced 2026-11-28 12:23:24 +01:00
Feature: Switch all shells in Compare
This commit is contained in:
1 parent
7234c39ad8
commit
d93b202ee8
4 files changed
+53
-5
No files matched your search
@@ -8,6 +8,7 @@ export interface CompareMember extends DuelMember {
|
||||
export interface CompareEphemeral {
|
||||
crewSkills: Record<string, number>;
|
||||
equalize: boolean;
|
||||
syncShells: boolean;
|
||||
members: CompareMember[];
|
||||
sorting?: {
|
||||
direction: "ascending" | "descending";
|
||||
@@ -21,5 +22,14 @@ export const CompareEphemeral = new Varuna<
|
||||
>((crewSkills) => ({
|
||||
crewSkills,
|
||||
equalize: false,
|
||||
syncShells: false,
|
||||
members: [],
|
||||
}));
|
||||
|
||||
export function syncShellSlot(members: CompareMember[], slot: number) {
|
||||
for (const member of members) {
|
||||
const shell = member.gun.shells[slot];
|
||||
|
||||
if (shell) member.shell = shell;
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user