-
-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(roles): eligible additional card recipients for each role (#714)
Closes #707
- Loading branch information
1 parent
f3277db
commit 0b75987
Showing
15 changed files
with
20,282 additions
and
20,412 deletions.
There are no files selected for viewing
5 changes: 2 additions & 3 deletions
5
src/modules/game/constants/game-additional-card/game-additional-card.constant.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,5 @@ | ||
import { ROLES } from "@/modules/role/constants/role.constant"; | ||
import { RoleNames } from "@/modules/role/enums/role.enum"; | ||
|
||
const GAME_ADDITIONAL_CARDS_THIEF_ROLE_NAMES: Readonly<RoleNames[]> = Object.freeze(ROLES.filter(({ minInGame, name }) => name !== RoleNames.THIEF && minInGame === undefined).map(({ name }) => name)); | ||
const GAME_ADDITIONAL_CARDS_RECIPIENTS = [RoleNames.THIEF] as const satisfies Readonly<(RoleNames)[]>; | ||
|
||
export { GAME_ADDITIONAL_CARDS_THIEF_ROLE_NAMES }; | ||
export { GAME_ADDITIONAL_CARDS_RECIPIENTS }; |
7 changes: 4 additions & 3 deletions
7
...s/game/dto/base/decorators/additional-cards/additional-cards-for-thief-roles.decorator.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
import type { TupleToUnion } from "type-fest"; | ||
|
||
import type { GAME_ADDITIONAL_CARDS_RECIPIENTS } from "@/modules/game/constants/game-additional-card/game-additional-card.constant"; | ||
|
||
type GameAdditionalCardRecipientRoleName = TupleToUnion<typeof GAME_ADDITIONAL_CARDS_RECIPIENTS>; | ||
|
||
export type { GameAdditionalCardRecipientRoleName }; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.