encounter.useItem always returns ACTIVE_ITEM_EXISTS
Qudyjac opened this issue · 2 comments
Qudyjac commented
It is not possible to use berries when catching a pokemon.
encounter.useItem always returns ACTIVE_ITEM_EXISTS
You can check this with the CatchPokemonAtEreaExample
I changed line 178 from
encounter.useItem(ItemId.ITEM_RAZZ_BERRY);
to
System.out.println(encounter.useItem(ItemId.ITEM_RAZZ_BERRY).toString());
to get the result.
btremote999 commented
logic bug:
file: Encounter.java
line : 192
bug - if (activeItem == null) {
change to if (getActiveItem() == null) {
Qudyjac commented
That did the trick, thx.
Now someone has to fix it in the repo.