Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions src/main/java/com/pokegoapi/api/pokemon/Pokemon.java
Original file line number Diff line number Diff line change
Expand Up @@ -267,6 +267,14 @@ public int getIndividualDefense() {
public int getIndividualStamina() {
return proto.getIndividualStamina();
}

/**
* Calculates the pokemons IV ratio
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Doesn't this break checkstyleMain because it does not contain a dot?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can't get checkstyle to run. If I need to change it I will. I can also start working on annotating more of the classes.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just change Calculates the pokemons IV ratio to Calculates the pokemons IV ratio.

* @return the pokemons IV ratio as a double between 0 and 1.0, 1.0 being perfect IVs
*/
public double getIVRatio() {
return (this.getIndividualAttack() + this.getIndividualDefense() + this.getIndividualStamina()) / 45.0;
}

public float getCpMultiplier() {
return proto.getCpMultiplier();
Expand Down