pokemon-io-core 0.0.21 → 0.0.23
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.
- package/dist/core/items.d.ts +2 -1
- package/dist/core/moves.d.ts +20 -3
- package/dist/skins/pokemon/fighters.js +6 -7
- package/dist/skins/pokemon/index.d.ts +0 -2
- package/dist/skins/pokemon/index.js +0 -2
- package/dist/skins/pokemon/items.js +114 -25
- package/dist/skins/pokemon/statuses.js +26 -6
- package/package.json +1 -1
package/dist/core/items.d.ts
CHANGED
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import type { ItemId } from "./ids";
|
|
2
|
-
import type { EffectDefinition } from "./moves";
|
|
2
|
+
import type { EffectDefinition, TargetKind } from "./moves";
|
|
3
3
|
export type ItemCategory = "damage" | "heal_shield" | "status_buff";
|
|
4
4
|
export interface ItemDefinition {
|
|
5
5
|
id: ItemId;
|
|
6
6
|
name: string;
|
|
7
7
|
category: ItemCategory;
|
|
8
|
+
target: TargetKind;
|
|
8
9
|
maxUses: number;
|
|
9
10
|
image: string;
|
|
10
11
|
effects: EffectDefinition[];
|
package/dist/core/moves.d.ts
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import type { MoveId,
|
|
1
|
+
import type { MoveId, StatusId, TypeId } from "./ids";
|
|
2
|
+
import { StatusKind } from "./status";
|
|
2
3
|
export type MoveKind = "damage" | "heal" | "status" | "hybrid";
|
|
3
4
|
export type TargetKind = "self" | "enemy";
|
|
4
|
-
export type EffectKind = "damage" | "heal" | "shield" | "modify_stats" | "apply_status" | "modify_hit_chance" | "modify_crit_chance" | "modify_priority" | "modify_effective_speed";
|
|
5
|
+
export type EffectKind = "damage" | "heal" | "shield" | "modify_stats" | "apply_status" | "clear_status" | "modify_hit_chance" | "modify_crit_chance" | "modify_priority" | "modify_effective_speed";
|
|
5
6
|
export interface DamageEffect {
|
|
6
7
|
kind: "damage";
|
|
7
8
|
amount: number;
|
|
@@ -28,6 +29,22 @@ export interface ApplyStatusEffect {
|
|
|
28
29
|
kind: "apply_status";
|
|
29
30
|
statusId: StatusId;
|
|
30
31
|
}
|
|
32
|
+
export interface ClearStatusEffect {
|
|
33
|
+
kind: "clear_status";
|
|
34
|
+
statusIds?: StatusId[];
|
|
35
|
+
/**
|
|
36
|
+
* Filtros opcionales por tipo de estado (hard_cc / soft).
|
|
37
|
+
* Ejemplo: una berry que limpia solo debuffs “soft”.
|
|
38
|
+
*/
|
|
39
|
+
kinds?: StatusKind[];
|
|
40
|
+
/**
|
|
41
|
+
* Si quieres que limpie TODO sin importar id ni tipo:
|
|
42
|
+
* - statusIds === undefined
|
|
43
|
+
* - kinds === undefined
|
|
44
|
+
* - clearAll === true
|
|
45
|
+
*/
|
|
46
|
+
clearAll?: boolean;
|
|
47
|
+
}
|
|
31
48
|
export interface ModifyHitChanceEffect {
|
|
32
49
|
kind: "modify_hit_chance";
|
|
33
50
|
delta: number;
|
|
@@ -44,7 +61,7 @@ export interface ModifyEffectiveSpeedEffect {
|
|
|
44
61
|
kind: "modify_effective_speed";
|
|
45
62
|
multiplier: number;
|
|
46
63
|
}
|
|
47
|
-
export type EffectDefinition = DamageEffect | HealEffect | ShieldEffect | ModifyStatsEffect | ApplyStatusEffect | ModifyHitChanceEffect | ModifyCritChanceEffect | ModifyPriorityEffect | ModifyEffectiveSpeedEffect;
|
|
64
|
+
export type EffectDefinition = DamageEffect | HealEffect | ShieldEffect | ClearStatusEffect | ModifyStatsEffect | ApplyStatusEffect | ModifyHitChanceEffect | ModifyCritChanceEffect | ModifyPriorityEffect | ModifyEffectiveSpeedEffect;
|
|
48
65
|
export interface MoveDefinition {
|
|
49
66
|
id: MoveId;
|
|
50
67
|
name: string;
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { pokemonImages } from "./img/pokemons";
|
|
2
1
|
import { POKEMON_TYPE_IDS } from "./types";
|
|
3
2
|
const makeStats = (offense, defense, speed, crit) => ({
|
|
4
3
|
offense,
|
|
@@ -11,7 +10,7 @@ export const POKEMON_FIGHTERS = [
|
|
|
11
10
|
id: "pikachu",
|
|
12
11
|
name: "Pikachu",
|
|
13
12
|
description: "Rápido y agresivo, castiga con críticos frecuentes.",
|
|
14
|
-
img:
|
|
13
|
+
img: 'pikachu',
|
|
15
14
|
classId: POKEMON_TYPE_IDS.electric,
|
|
16
15
|
baseStats: makeStats(55, 40, 90, 15),
|
|
17
16
|
recommendedMoves: ["tackle", "thunder_shock"]
|
|
@@ -20,7 +19,7 @@ export const POKEMON_FIGHTERS = [
|
|
|
20
19
|
id: "charizard",
|
|
21
20
|
name: "Charizard",
|
|
22
21
|
description: "Burst de fuego muy alto, algo frágil.",
|
|
23
|
-
img:
|
|
22
|
+
img: 'charizard',
|
|
24
23
|
classId: POKEMON_TYPE_IDS.fire,
|
|
25
24
|
baseStats: makeStats(84, 78, 100, 10),
|
|
26
25
|
recommendedMoves: ["tackle", "ember"]
|
|
@@ -29,7 +28,7 @@ export const POKEMON_FIGHTERS = [
|
|
|
29
28
|
id: "blastoise",
|
|
30
29
|
name: "Blastoise",
|
|
31
30
|
description: "Tanque defensivo con presión constante de agua.",
|
|
32
|
-
img:
|
|
31
|
+
img: 'blastoise',
|
|
33
32
|
classId: POKEMON_TYPE_IDS.water,
|
|
34
33
|
baseStats: makeStats(83, 100, 78, 8),
|
|
35
34
|
recommendedMoves: ["tackle", "water_gun"]
|
|
@@ -38,7 +37,7 @@ export const POKEMON_FIGHTERS = [
|
|
|
38
37
|
id: "venusaur",
|
|
39
38
|
name: "Venusaur",
|
|
40
39
|
description: "Juego de desgaste con grandes golpes de hierba.",
|
|
41
|
-
img:
|
|
40
|
+
img: 'venusaur',
|
|
42
41
|
classId: POKEMON_TYPE_IDS.grass,
|
|
43
42
|
baseStats: makeStats(82, 83, 80, 8),
|
|
44
43
|
recommendedMoves: ["tackle", "vine_whip"]
|
|
@@ -47,7 +46,7 @@ export const POKEMON_FIGHTERS = [
|
|
|
47
46
|
id: "mew",
|
|
48
47
|
name: "Mew",
|
|
49
48
|
description: "Juego de desgaste con grandes golpes de hierba.",
|
|
50
|
-
img:
|
|
49
|
+
img: 'mew',
|
|
51
50
|
classId: POKEMON_TYPE_IDS.psychic,
|
|
52
51
|
baseStats: makeStats(82, 83, 80, 8),
|
|
53
52
|
recommendedMoves: ["tackle", "vine_whip"]
|
|
@@ -56,7 +55,7 @@ export const POKEMON_FIGHTERS = [
|
|
|
56
55
|
id: "groudon",
|
|
57
56
|
name: "Groudon",
|
|
58
57
|
description: "Juego de desgaste con grandes golpes de hierba.",
|
|
59
|
-
img:
|
|
58
|
+
img: 'groudon',
|
|
60
59
|
classId: POKEMON_TYPE_IDS.rock,
|
|
61
60
|
baseStats: makeStats(82, 83, 80, 8),
|
|
62
61
|
recommendedMoves: ["tackle", "vine_whip"]
|
|
@@ -1,54 +1,143 @@
|
|
|
1
|
-
import { itemsImages } from "./img/items";
|
|
2
1
|
export const POKEMON_ITEMS = [
|
|
3
|
-
{
|
|
4
|
-
id: "potion",
|
|
5
|
-
name: "Poción",
|
|
6
|
-
category: "heal_shield",
|
|
7
|
-
maxUses: 2,
|
|
8
|
-
effects: [{ kind: "heal", amount: 30 }],
|
|
9
|
-
image: itemsImages.antidote,
|
|
10
|
-
},
|
|
11
2
|
{
|
|
12
3
|
id: "super_potion",
|
|
13
4
|
name: "Super Poción",
|
|
14
5
|
category: "heal_shield",
|
|
6
|
+
target: "self",
|
|
15
7
|
maxUses: 1,
|
|
16
|
-
effects: [{ kind: "heal", amount:
|
|
17
|
-
image:
|
|
8
|
+
effects: [{ kind: "heal", amount: 50 }],
|
|
9
|
+
image: "hiper-potion",
|
|
10
|
+
},
|
|
11
|
+
{
|
|
12
|
+
id: "potion",
|
|
13
|
+
name: "Poción",
|
|
14
|
+
category: "heal_shield",
|
|
15
|
+
target: "self",
|
|
16
|
+
maxUses: 2,
|
|
17
|
+
effects: [{ kind: "heal", amount: 25 }],
|
|
18
|
+
image: "potion",
|
|
18
19
|
},
|
|
19
20
|
{
|
|
20
21
|
id: "apple",
|
|
21
22
|
name: "Manzana",
|
|
22
23
|
category: "heal_shield",
|
|
24
|
+
target: "self",
|
|
23
25
|
maxUses: 3,
|
|
24
|
-
effects: [{ kind: "heal", amount:
|
|
25
|
-
image:
|
|
26
|
+
effects: [{ kind: "heal", amount: 17 }],
|
|
27
|
+
image: "fancy-apple",
|
|
26
28
|
},
|
|
27
29
|
{
|
|
28
30
|
id: "mushroom",
|
|
29
31
|
name: "Seta",
|
|
30
32
|
category: "heal_shield",
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
33
|
+
target: "self",
|
|
34
|
+
maxUses: 4,
|
|
35
|
+
effects: [{ kind: "heal", amount: 14 }],
|
|
36
|
+
image: "mushroom",
|
|
34
37
|
},
|
|
35
38
|
{
|
|
36
|
-
id: "
|
|
37
|
-
name: "
|
|
38
|
-
|
|
39
|
+
id: "shotgun",
|
|
40
|
+
name: "Escopeta",
|
|
41
|
+
target: "enemy",
|
|
42
|
+
category: "damage",
|
|
43
|
+
maxUses: 2,
|
|
44
|
+
effects: [
|
|
45
|
+
{ kind: "damage", amount: 15 },
|
|
46
|
+
{ kind: "apply_status", statusId: "burn" },
|
|
47
|
+
],
|
|
48
|
+
image: "shotgun",
|
|
49
|
+
},
|
|
50
|
+
{
|
|
51
|
+
id: "pistol",
|
|
52
|
+
name: "Pistola",
|
|
53
|
+
category: "damage",
|
|
54
|
+
target: "enemy",
|
|
55
|
+
maxUses: 4,
|
|
56
|
+
effects: [
|
|
57
|
+
{ kind: "damage", amount: 8 },
|
|
58
|
+
{ kind: "apply_status", statusId: "burn" },
|
|
59
|
+
],
|
|
60
|
+
image: "pistol",
|
|
61
|
+
},
|
|
62
|
+
{
|
|
63
|
+
id: "riffle",
|
|
64
|
+
name: "Rifle",
|
|
65
|
+
target: "enemy",
|
|
66
|
+
category: "damage",
|
|
39
67
|
maxUses: 3,
|
|
40
|
-
effects: [
|
|
41
|
-
|
|
68
|
+
effects: [
|
|
69
|
+
{ kind: "damage", amount: 10 },
|
|
70
|
+
{ kind: "apply_status", statusId: "burn" },
|
|
71
|
+
],
|
|
72
|
+
image: "riffle",
|
|
42
73
|
},
|
|
43
74
|
{
|
|
44
|
-
id: "
|
|
45
|
-
name: "
|
|
75
|
+
id: "sniper",
|
|
76
|
+
name: "Sniper",
|
|
77
|
+
target: "enemy",
|
|
46
78
|
category: "damage",
|
|
47
79
|
maxUses: 1,
|
|
48
80
|
effects: [
|
|
49
|
-
{ kind: "damage", amount:
|
|
81
|
+
{ kind: "damage", amount: 30 },
|
|
50
82
|
{ kind: "apply_status", statusId: "burn" },
|
|
51
83
|
],
|
|
52
|
-
image:
|
|
84
|
+
image: "sniper",
|
|
85
|
+
},
|
|
86
|
+
{
|
|
87
|
+
id: "blue-berry",
|
|
88
|
+
name: "Baya azul",
|
|
89
|
+
category: "status_buff",
|
|
90
|
+
maxUses: 1,
|
|
91
|
+
target: "self",
|
|
92
|
+
effects: [
|
|
93
|
+
{
|
|
94
|
+
kind: "clear_status",
|
|
95
|
+
statusIds: ["burn"], // cura QUEMADURA
|
|
96
|
+
},
|
|
97
|
+
],
|
|
98
|
+
image: "blue-berry",
|
|
99
|
+
},
|
|
100
|
+
{
|
|
101
|
+
id: "pink-berry",
|
|
102
|
+
name: "Baya rosa",
|
|
103
|
+
category: "status_buff",
|
|
104
|
+
maxUses: 1,
|
|
105
|
+
target: "self",
|
|
106
|
+
effects: [
|
|
107
|
+
{
|
|
108
|
+
kind: "clear_status",
|
|
109
|
+
statusIds: ["poison"], // cura VENENO
|
|
110
|
+
},
|
|
111
|
+
],
|
|
112
|
+
image: "pink-berry",
|
|
113
|
+
},
|
|
114
|
+
{
|
|
115
|
+
id: "yellow-berry",
|
|
116
|
+
name: "Baya amarilla",
|
|
117
|
+
category: "status_buff",
|
|
118
|
+
maxUses: 1,
|
|
119
|
+
target: "self",
|
|
120
|
+
effects: [
|
|
121
|
+
{
|
|
122
|
+
kind: "clear_status",
|
|
123
|
+
statusIds: ["paralysis"], // cura PARÁLISIS
|
|
124
|
+
},
|
|
125
|
+
],
|
|
126
|
+
image: "yellow-berry",
|
|
127
|
+
},
|
|
128
|
+
{
|
|
129
|
+
id: "green-berry",
|
|
130
|
+
name: "Baya verde",
|
|
131
|
+
category: "status_buff",
|
|
132
|
+
maxUses: 1,
|
|
133
|
+
target: "self",
|
|
134
|
+
effects: [
|
|
135
|
+
{
|
|
136
|
+
kind: "clear_status",
|
|
137
|
+
statusIds: ["burn", "poison"], // por ejemplo: limpia quemadura o veneno
|
|
138
|
+
kinds: ["soft"], // redundante pero semántico
|
|
139
|
+
},
|
|
140
|
+
],
|
|
141
|
+
image: "green-berry",
|
|
53
142
|
},
|
|
54
143
|
];
|
|
@@ -3,19 +3,39 @@ export const POKEMON_STATUSES = [
|
|
|
3
3
|
id: "burn",
|
|
4
4
|
name: "Quemado",
|
|
5
5
|
kind: "soft",
|
|
6
|
+
minDurationTurns: 3,
|
|
7
|
+
maxDurationTurns: 5,
|
|
8
|
+
effectsPerStack: [
|
|
9
|
+
{ kind: "damage", amount: 6 }, // DoT
|
|
10
|
+
{ kind: "modify_stats", offenseDelta: -10 } // pega menos
|
|
11
|
+
]
|
|
12
|
+
},
|
|
13
|
+
{
|
|
14
|
+
id: "poison",
|
|
15
|
+
name: "Envenenado",
|
|
16
|
+
kind: "soft",
|
|
17
|
+
minDurationTurns: 3,
|
|
18
|
+
maxDurationTurns: 5,
|
|
19
|
+
effectsPerStack: [
|
|
20
|
+
{ kind: "damage", amount: 8 }
|
|
21
|
+
]
|
|
22
|
+
},
|
|
23
|
+
{
|
|
24
|
+
id: "paralysis",
|
|
25
|
+
name: "Paralizado",
|
|
26
|
+
kind: "soft",
|
|
6
27
|
minDurationTurns: 2,
|
|
7
28
|
maxDurationTurns: 4,
|
|
8
29
|
effectsPerStack: [
|
|
9
|
-
|
|
10
|
-
{ kind: "damage", amount: 10 }
|
|
30
|
+
{ kind: "modify_effective_speed", multiplier: 0.5 }
|
|
11
31
|
]
|
|
12
32
|
},
|
|
13
33
|
{
|
|
14
|
-
id: "
|
|
15
|
-
name: "
|
|
34
|
+
id: "sleep",
|
|
35
|
+
name: "Dormido",
|
|
16
36
|
kind: "hard_cc",
|
|
17
37
|
minDurationTurns: 1,
|
|
18
|
-
maxDurationTurns:
|
|
19
|
-
effectsPerStack: []
|
|
38
|
+
maxDurationTurns: 3,
|
|
39
|
+
effectsPerStack: [] // el hard_cc lo interpreta el motor
|
|
20
40
|
}
|
|
21
41
|
];
|