enefel 2.9.1 → 2.11.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (77) hide show
  1. package/.claude/settings.local.json +7 -0
  2. package/2025/newSkills.ts +769 -0
  3. package/2025/raceMigration.ts +66 -0
  4. package/2025/rawTeamsData.ts +1726 -0
  5. package/2025/skillMigration.ts +155 -0
  6. package/avatarsSeason.ts +61 -0
  7. package/career.ts +64 -8
  8. package/career2025.ts +2752 -0
  9. package/dice.ts +40 -8
  10. package/dist/2025/newSkills.d.ts +10 -0
  11. package/dist/2025/newSkills.js +663 -0
  12. package/dist/2025/raceMigration.d.ts +10 -0
  13. package/dist/2025/raceMigration.js +53 -0
  14. package/dist/2025/rawTeamsData.d.ts +12 -0
  15. package/dist/2025/rawTeamsData.js +1699 -0
  16. package/dist/2025/skillMigration.d.ts +31 -0
  17. package/dist/2025/skillMigration.js +95 -0
  18. package/dist/avatarsSeason.d.ts +22 -0
  19. package/dist/avatarsSeason.js +54 -0
  20. package/dist/career.d.ts +13 -4
  21. package/dist/career.js +36 -7
  22. package/dist/career2025.d.ts +192 -0
  23. package/dist/career2025.js +2611 -0
  24. package/dist/dice.d.ts +10 -2
  25. package/dist/dice.js +31 -8
  26. package/dist/index.d.ts +17 -2
  27. package/dist/index.js +44 -5
  28. package/dist/move.d.ts +6 -2
  29. package/dist/move.js +35 -0
  30. package/dist/package-lock.json +913 -7
  31. package/dist/package.json +6 -2
  32. package/dist/pitch.d.ts +10 -1
  33. package/dist/pitch.js +16 -0
  34. package/dist/player.d.ts +8 -4
  35. package/dist/player.js +104 -20
  36. package/dist/position.d.ts +4 -0
  37. package/dist/position.js +17 -1
  38. package/dist/race.d.ts +23 -12
  39. package/dist/race.js +210 -2
  40. package/dist/skill.d.ts +26 -3
  41. package/dist/skill.js +199 -81
  42. package/dist/skills/hitAndRun.d.ts +10 -0
  43. package/dist/skills/hitAndRun.js +12 -0
  44. package/dist/skills/safePairOfHands.d.ts +28 -0
  45. package/dist/skills/safePairOfHands.js +18 -0
  46. package/dist/skills/sidestep.d.ts +21 -0
  47. package/dist/skills/sidestep.js +20 -0
  48. package/dist/status.d.ts +4 -1
  49. package/dist/status.js +14 -4
  50. package/dist/store.d.ts +3 -0
  51. package/dist/store.js +3 -0
  52. package/dist/teams/career_v2025.d.ts +246 -0
  53. package/dist/teams/career_v2025.js +3512 -0
  54. package/dist/teams/convert-csv-to-career.d.ts +1 -0
  55. package/dist/teams/convert-csv-to-career.js +1085 -0
  56. package/dist/types/models.d.ts +4 -0
  57. package/index.ts +57 -4
  58. package/jest.config.js +3 -0
  59. package/move.ts +50 -2
  60. package/npm-login.sh +0 -0
  61. package/package.json +6 -2
  62. package/pitch.ts +22 -0
  63. package/player.ts +105 -22
  64. package/position.ts +16 -0
  65. package/race.ts +227 -13
  66. package/skill.ts +217 -83
  67. package/skills/hitAndRun.ts +14 -0
  68. package/skills/safePairOfHands.ts +33 -0
  69. package/skills/sidestep.ts +25 -0
  70. package/status.ts +15 -3
  71. package/store.ts +3 -0
  72. package/teams/README.md +53 -0
  73. package/teams/clean-stats.js +54 -0
  74. package/teams/convert-csv-to-career.ts +1209 -0
  75. package/teams/players_clean.csv +107 -0
  76. package/teams/players_next.csv +21 -0
  77. package/types/models.ts +4 -0
package/dice.ts CHANGED
@@ -1,12 +1,44 @@
1
- const DICE = {
2
- default: {
3
- color: "#000000",
4
- background: "#ffffff",
5
- },
1
+ import { AVATAR_RARITY } from "./career";
2
+
3
+ export type DiceSkin = {
4
+ id: string;
5
+ color: string;
6
+ background: string;
7
+ price: number;
8
+ season?: number;
9
+ rarity?: AVATAR_RARITY;
6
10
  };
7
11
 
8
- const getPlayerDice = () => {
9
- return DICE.default;
12
+ const DICE_LIST: DiceSkin[] = [
13
+ { id: "default", color: "#000000", background: "#ffffff", price: 0 },
14
+ {
15
+ id: "s17-blood-debug",
16
+ color: "#ffffff",
17
+ background: "#cc0000",
18
+ price: 30,
19
+ season: 17,
20
+ rarity: AVATAR_RARITY.COMMUN,
21
+ },
22
+ {
23
+ id: "s19-blood",
24
+ color: "#ffffff",
25
+ background: "#cc0000",
26
+ price: 30,
27
+ season: 19,
28
+ rarity: AVATAR_RARITY.COMMUN,
29
+ },
30
+ ];
31
+
32
+ const getDiceById = (id: string | null | undefined): DiceSkin => {
33
+ if (!id) return DICE_LIST[0];
34
+ return DICE_LIST.find((d) => d.id === id) ?? DICE_LIST[0];
10
35
  };
11
36
 
12
- export { getPlayerDice };
37
+ // kept for backwards compatibility
38
+ const getPlayerDice = () => DICE_LIST[0];
39
+
40
+ export { DICE_LIST, getDiceById, getPlayerDice };
41
+
42
+ // TODO: when RARE or UNIQUE dice are added, add access conditions:
43
+ // - StoreDice.tsx: filter dice based on player eligibility before displaying
44
+ // - BuyService.js: enforce the same check server-side before allowing purchase
@@ -0,0 +1,10 @@
1
+ export type SkillFamily = "Agility" | "Devious" | "General" | "Mutation" | "Passing" | "Strength" | "Traits";
2
+ export type SkillMode = "Active" | "Passive";
3
+ export type NewSkill = {
4
+ name: string;
5
+ family: SkillFamily;
6
+ mode: SkillMode;
7
+ summary: string;
8
+ elite?: boolean;
9
+ };
10
+ export declare const newSkills: NewSkill[];