mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-20 20:58:03 +00:00
Fix bug in chooseEntitiesforEffect in Mobile GUI
This commit is contained in:
@@ -517,7 +517,9 @@ public class MatchController extends AbstractGuiGame {
|
||||
|
||||
@Override
|
||||
public List<GameEntityView> chooseEntitiesForEffect(String title, List<? extends GameEntityView> optionList, int min, int max, DelayedReveal delayedReveal) {
|
||||
return SGuiChoose.order(title, "Selected", min, max, (List<GameEntityView>) optionList, null);
|
||||
final int m1 = max >= 0 ? optionList.size() - max : -1;
|
||||
final int m2 = min >= 0 ? optionList.size() - min : -1;
|
||||
return SGuiChoose.order(title, "Selected", m1, m2, (List<GameEntityView>) optionList, null);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -244,8 +244,8 @@ public class GuiChoose {
|
||||
}
|
||||
|
||||
public static <T> void many(final String title, final String topCaption, int min, int max, final List<T> sourceChoices, CardView referenceCard, final Callback<List<T>> callback) {
|
||||
int m2 = min >= 0 ? sourceChoices.size() - min : -1;
|
||||
int m1 = max >= 0 ? sourceChoices.size() - max : -1;
|
||||
int m2 = min >= 0 ? sourceChoices.size() - min : -1;
|
||||
order(title, topCaption, m1, m2, sourceChoices, null, referenceCard, callback);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user