Skip to content

Commit

Permalink
Didn't commit all the files...
Browse files Browse the repository at this point in the history
  • Loading branch information
mjmjelde committed Jul 23, 2016
1 parent 5e30454 commit 8615fa6
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -16,16 +16,17 @@
package com.pokegoapi.api.map.pokemon;

import POGOProtos.Networking.Responses.EvolvePokemonResponseOuterClass;
import com.pokegoapi.api.PokemonGo;
import com.pokegoapi.api.pokemon.Pokemon;

public class EvolutionResult {

private EvolvePokemonResponseOuterClass.EvolvePokemonResponse proto;
private Pokemon pokemon;

public EvolutionResult(EvolvePokemonResponseOuterClass.EvolvePokemonResponse proto) {
public EvolutionResult(PokemonGo api, EvolvePokemonResponseOuterClass.EvolvePokemonResponse proto) {
this.proto = proto;
this.pokemon = new Pokemon(proto.getEvolvedPokemonData());
this.pokemon = new Pokemon(api, proto.getEvolvedPokemonData());
}

public EvolvePokemonResponseOuterClass.EvolvePokemonResponse.Result getResult() {
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/com/pokegoapi/api/pokemon/Pokemon.java
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ public EvolutionResult evolve() throws LoginFailedException, RemoteServerExcepti
return null;
}

EvolutionResult result = new EvolutionResult(response);
EvolutionResult result = new EvolutionResult(pgo, response);

pgo.getInventories().getPokebank().removePokemon(this);

Expand Down

0 comments on commit 8615fa6

Please sign in to comment.