@dchighs/dc-config-mapper 0.0.1 → 0.0.2

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.
@@ -2631,7 +2631,7 @@ export declare class ItemsMapper {
2631
2631
  rarity: string;
2632
2632
  elements: import("@dchighs/dc-core").DragonElement[];
2633
2633
  description: string | undefined;
2634
- description_key: string | null;
2634
+ description_key: string;
2635
2635
  buy_price: {
2636
2636
  type: string;
2637
2637
  amount: number;
@@ -2648,6 +2648,7 @@ export declare class ItemsMapper {
2648
2648
  trainable_attack_ids: number[];
2649
2649
  passive_skill_ids: number[] | null;
2650
2650
  post_skill_ids: number[] | null;
2651
+ category: number;
2651
2652
  stats: {
2652
2653
  attack: number;
2653
2654
  life: number;
@@ -2669,7 +2670,6 @@ export declare class ItemsMapper {
2669
2670
  breeding_ngu_soft: number;
2670
2671
  };
2671
2672
  };
2672
- deity_breeding: boolean;
2673
2673
  production: {
2674
2674
  coins_added: number;
2675
2675
  starting_coins: number;
@@ -105,10 +105,7 @@ export declare class MazeIslandsMapper {
105
105
  }>[];
106
106
  nodes: import("@dchighs/dc-localization/dist/types").Translated<{
107
107
  id: number;
108
- position: number[];
109
- cost: {
110
- ep: number;
111
- } | undefined;
108
+ cost: number;
112
109
  reward_id: number | undefined;
113
110
  reward: ({
114
111
  type: import("../enums/reward-resource-type").RewardResourceType;
@@ -129,7 +126,7 @@ export declare class MazeIslandsMapper {
129
126
  is_highlighted: boolean | undefined;
130
127
  key_path_id: number | undefined;
131
128
  encounter_id: number | undefined;
132
- encounter_skip_cost: number | undefined;
129
+ encounter_skip_cost: number | null;
133
130
  }>[];
134
131
  parameters: {
135
132
  id: number;
@@ -21,10 +21,7 @@ export declare const mazeIslandsNodeSchema: z.ZodPipe<z.ZodObject<{
21
21
  }, z.core.$strip>>;
22
22
  }, z.core.$strict>, z.ZodTransform<{
23
23
  id: number;
24
- position: number[];
25
- cost: {
26
- ep: number;
27
- } | undefined;
24
+ cost: number;
28
25
  reward_id: number | undefined;
29
26
  reward: ({
30
27
  type: RewardResourceType;
@@ -45,7 +42,7 @@ export declare const mazeIslandsNodeSchema: z.ZodPipe<z.ZodObject<{
45
42
  is_highlighted: boolean | undefined;
46
43
  key_path_id: number | undefined;
47
44
  encounter_id: number | undefined;
48
- encounter_skip_cost: number | undefined;
45
+ encounter_skip_cost: number | null;
49
46
  }, {
50
47
  id: number;
51
48
  position: number[];
@@ -50,18 +50,15 @@ exports.mazeIslandsNodeSchema = zod_1.z.object({
50
50
  ep: zod_1.z.number(),
51
51
  }).optional(),
52
52
  }).strict().transform(data => {
53
- var _a;
53
+ var _a, _b, _c, _d;
54
54
  return {
55
55
  id: data.id,
56
- position: data.position,
57
- cost: data.cost ? {
58
- ep: data.cost.ep,
59
- } : undefined,
56
+ cost: (_b = (_a = data.cost) === null || _a === void 0 ? void 0 : _a.ep) !== null && _b !== void 0 ? _b : 0,
60
57
  reward_id: data.reward_id,
61
58
  reward: data.reward ? data.reward.map(processReward) : undefined,
62
59
  is_highlighted: data.highlighted,
63
60
  key_path_id: data.key,
64
61
  encounter_id: data.encounter,
65
- encounter_skip_cost: (_a = data.encounter_skip_cost) === null || _a === void 0 ? void 0 : _a.ep,
62
+ encounter_skip_cost: (_d = (_c = data.encounter_skip_cost) === null || _c === void 0 ? void 0 : _c.ep) !== null && _d !== void 0 ? _d : null,
66
63
  };
67
64
  });
@@ -78,7 +78,7 @@ export declare const dragonSchema: z.ZodPipe<z.ZodObject<{
78
78
  rarity: string;
79
79
  elements: import("@dchighs/dc-core").DragonElement[];
80
80
  description: string | undefined;
81
- description_key: string | null;
81
+ description_key: string;
82
82
  buy_price: {
83
83
  type: string;
84
84
  amount: number;
@@ -95,6 +95,7 @@ export declare const dragonSchema: z.ZodPipe<z.ZodObject<{
95
95
  trainable_attack_ids: number[];
96
96
  passive_skill_ids: number[] | null;
97
97
  post_skill_ids: number[] | null;
98
+ category: number;
98
99
  stats: {
99
100
  attack: number;
100
101
  life: number;
@@ -116,7 +117,6 @@ export declare const dragonSchema: z.ZodPipe<z.ZodObject<{
116
117
  breeding_ngu_soft: number;
117
118
  };
118
119
  };
119
- deity_breeding: boolean;
120
120
  production: {
121
121
  coins_added: number;
122
122
  starting_coins: number;
@@ -107,9 +107,7 @@ exports.dragonSchema = zod_1.z.object({
107
107
  rarity: data.dragon_rarity,
108
108
  elements: data.attributes.map((element) => element_map_1.elementMap[element]),
109
109
  description: data.description,
110
- description_key: data.description
111
- ? `tid_unit_${data.id}_description`
112
- : null,
110
+ description_key: `tid_unit_${data.id}_description`,
113
111
  buy_price: processPrice(data.costs),
114
112
  sell_price: processPrice(data.sell_price),
115
113
  is_breedable: (0, number_to_boolean_1.numberToBoolean)(data.breedable),
@@ -120,6 +118,7 @@ exports.dragonSchema = zod_1.z.object({
120
118
  trainable_attack_ids: data.trainable_attacks,
121
119
  passive_skill_ids: (_a = data.passive_skills) !== null && _a !== void 0 ? _a : null,
122
120
  post_skill_ids: (_b = data.post_skills) !== null && _b !== void 0 ? _b : null,
121
+ category: data.category,
123
122
  stats: {
124
123
  attack: data.base_attack,
125
124
  life: data.base_life,
@@ -141,7 +140,6 @@ exports.dragonSchema = zod_1.z.object({
141
140
  breeding_ngu_soft: data.breeding_time_ngu_soft,
142
141
  },
143
142
  },
144
- deity_breeding: (0, number_to_boolean_1.numberToBoolean)(data.deity_breeding),
145
143
  production: {
146
144
  coins_added: data.coins_added,
147
145
  starting_coins: data.starting_coins,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dchighs/dc-config-mapper",
3
- "version": "0.0.1",
3
+ "version": "0.0.2",
4
4
  "description": "A opined library to restructure and populate configuration for Dragon City.",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.js",
@@ -39,4 +39,4 @@
39
39
  "@dchighs/dc-config": "^0.0.1",
40
40
  "@dchighs/dc-localization": "^0.0.3"
41
41
  }
42
- }
42
+ }