-
Notifications
You must be signed in to change notification settings - Fork 1
/
poke_types.py
35 lines (31 loc) · 1.21 KB
/
poke_types.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
all_types = ["Bug", "Dark", "Dragon", "Electric", "Fighting", "Fire",
"Flying", "Ghost", "Grass", "Ground", "Ice", "Normal",
"Poison", "Psychic", "Rock", "Steel", "Water", None]
supes = {
"Normal": [],
"Fire": ["Grass", "Ice", "Bug", "Steel"],
"Water": ["Fire", "Ground", "Rock"],
"Electric": ["Water", "Flying"],
"Grass": ["Water", "Ground", "Rock"],
"Ice": ["Grass", "Ground", "Flying", "Dragon"],
"Fighting": ["Normal", "Ice", "Rock", "Dark", "Steel"],
"Poison": ["Grass"],
"Ground": ["Fire", "Electric", "Poison", "Rock", "Steel"],
"Flying": ["Grass, Fighting, Bug"],
"Psychic": ["Fighting", "Poison"],
"Bug": ["Grass", "Psychic", "Dark"],
"Rock": ["Fire", "Ice", "Flying", "Bug"],
"Ghost": ["Psychic", "Ghost"],
"Dragon": ["Dragon"],
"Dark": ["Psychic", "Ghost"],
"Steel": ["Ice", "Rock"]
}
def isSuperEffective(attacker_type, victim_type):
return True if victim_type in supes[attacker_type] else False
def getSECoverage(move_type):
return supes[move_type]
def getUsageDict():
types = {}
for type in all_types:
types[type] = 0
return types