Skip to content

Commit

Permalink
Better inventory: attacks & movesets, IV CP perfection, pokemon level…
Browse files Browse the repository at this point in the history
…, etc.. (#3455)

* Add "level to CP multiplier" data

Data is from justinleewells/pogo-optimizer:
https://github.com/justinleewells/pogo-optimizer/blob/edd692d/data/game/level-to-cpm.json

* Many improvements & additions for the inventory logic

 - LevelToCPm, FastAttacks, ChargedAttacks, Movesets
 - More info for each pokemon:  attacks data,  percent to max cp,  IV CP perfection

* Add PyCharm/IDEA *.iml (project file) to ignored

* Fixes, improvements & refactoring for inventory.py

 - Return inadvertently deleted pieces of code (thanks to @achretien)
 - Evolution logic fixes
 - Other minor fixes
 - Moveset logic moved to Moveset class

* Fix data for pokemons & charged moves

* Inventory tests:  pokemon data,  LevelToCPm,  attacks

* Fix travis build

* Fix info for Hitmonlee & Hitmonchan
  • Loading branch information
amal authored and elicwhite committed Aug 11, 2016
1 parent e60da10 commit 00a5b2f
Show file tree
Hide file tree
Showing 6 changed files with 907 additions and 69 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,7 @@ share/

# PyCharm IDE settings
.idea/
*.iml

# Personal load details
src/
Expand Down
3 changes: 1 addition & 2 deletions data/charged_moves.json
Original file line number Diff line number Diff line change
Expand Up @@ -84,9 +84,8 @@
{"id":101,"name":"Flame Charge","type":"Fire","damage":25,"duration":3100,"energy":20,"dps":8.06},
{"id":34,"name":"Heart Stamp","type":"Psychic","damage":20,"duration":2550,"energy":25,"dps":7.84},
{"id":75,"name":"Parabolic Charge","type":"Electric","damage":15,"duration":2100,"energy":20,"dps":7.14},
{"id":13,"name":"Wrap","type":"Normal","damage":25,"duration":3700,"energy":20,"dps":6.75},
{"id":111,"name":"Icy Wind","type":"Ice","damage":25,"duration":3800,"energy":20,"dps":6.57},
{"id":84,"name":"Disarming Voice","type":"Fairy","damage":25,"duration":3900,"energy":20,"dps":6.41},
{"id":13,"name":"Wrap","type":"Normal","damage":25,"duration":4000,"energy":20,"dps":6.25},
{"id":66,"name":"Shadow Sneak","type":"Ghost","damage":15,"duration":3100,"energy":20,"dps":4.83},
{"id":48,"name":"Mega Drain","type":"Grass","damage":15,"duration":3200,"energy":20,"dps":4.68}]
{"id":48,"name":"Mega Drain","type":"Grass","damage":15,"duration":3200,"energy":20,"dps":4.68}]
81 changes: 81 additions & 0 deletions data/level_to_cpm.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
{
"1": 0.094,
"1.5": 0.135137432,
"2": 0.16639787,
"2.5": 0.192650919,
"3": 0.21573247,
"3.5": 0.236572661,
"4": 0.25572005,
"4.5": 0.273530381,
"5": 0.29024988,
"5.5": 0.306057377,
"6": 0.3210876,
"6.5": 0.335445036,
"7": 0.34921268,
"7.5": 0.362457751,
"8": 0.37523559,
"8.5": 0.387592406,
"9": 0.39956728,
"9.5": 0.411193551,
"10": 0.42250001,
"10.5": 0.432926419,
"11": 0.44310755,
"11.5": 0.4530599578,
"12": 0.46279839,
"12.5": 0.472336083,
"13": 0.48168495,
"13.5": 0.4908558,
"14": 0.49985844,
"14.5": 0.508701765,
"15": 0.51739395,
"15.5": 0.525942511,
"16": 0.53435433,
"16.5": 0.542635767,
"17": 0.55079269,
"17.5": 0.558830576,
"18": 0.56675452,
"18.5": 0.574569153,
"19": 0.58227891,
"19.5": 0.589887917,
"20": 0.59740001,
"20.5": 0.604818814,
"21": 0.61215729,
"21.5": 0.619399365,
"22": 0.62656713,
"22.5": 0.633644533,
"23": 0.64065295,
"23.5": 0.647576426,
"24": 0.65443563,
"24.5": 0.661214806,
"25": 0.667934,
"25.5": 0.674577537,
"26": 0.68116492,
"26.5": 0.687680648,
"27": 0.69414365,
"27.5": 0.700538673,
"28": 0.70688421,
"28.5": 0.713164996,
"29": 0.71939909,
"29.5": 0.725571552,
"30": 0.7317,
"30.5": 0.734741009,
"31": 0.73776948,
"31.5": 0.740785574,
"32": 0.74378943,
"32.5": 0.746781211,
"33": 0.74976104,
"33.5": 0.752729087,
"34": 0.75568551,
"34.5": 0.758630378,
"35": 0.76156384,
"35.5": 0.764486065,
"36": 0.76739717,
"36.5": 0.770297266,
"37": 0.7731865,
"37.5": 0.776064962,
"38": 0.77893275,
"38.5": 0.781790055,
"39": 0.78463697,
"39.5": 0.787473578,
"40": 0.79030001
}
32 changes: 15 additions & 17 deletions data/pokemon.json
Original file line number Diff line number Diff line change
Expand Up @@ -1232,7 +1232,7 @@
"Previous evolution(s)": [
{
"Number": "029",
"Name": "Nidoran F"
"Name": "Nidoran F"
}
],
"Next Evolution Requirements": {
Expand Down Expand Up @@ -4326,20 +4326,14 @@
],
"Weight": "49.8 kg",
"Height": "1.5 m",
"Next evolution(s)": [
{
"Number": "107",
"Name": "Hitmonchan"
}
],
"Special Attack(s)": [
"Low Sweep",
"Stomp",
"Stone Edge"
],
"BaseAttack": 148,
"BaseDefense": 100,
"BaseStamina": 172,
"BaseDefense": 172,
"BaseStamina": 100,
"CaptureRate": 0.16,
"FleeRate": 0.09
},
Expand All @@ -4361,21 +4355,15 @@
],
"Weight": "50.2 kg",
"Height": "1.4 m",
"Previous evolution(s)": [
{
"Number": "106",
"Name": "Hitmonlee"
}
],
"Special Attack(s)": [
"Brick Break",
"Fire Punch",
"Ice Punch",
"Thunder Punch"
],
"BaseAttack": 138,
"BaseDefense": 100,
"BaseStamina": 204,
"BaseDefense": 204,
"BaseStamina": 100,
"CaptureRate": 0.16,
"FleeRate": 0.09
},
Expand Down Expand Up @@ -5729,6 +5717,16 @@
"Family": 147,
"Name": "Dratini candies"
},
"Next evolution(s)": [
{
"Number": "148",
"Name": "Dragonair"
},
{
"Number": "149",
"Name": "Dragonite"
}
],
"Special Attack(s)": [
"Aqua Tail",
"Twister",
Expand Down
Loading

0 comments on commit 00a5b2f

Please sign in to comment.