Card render testing dialog improves:

* Added chooseable render testing (click by mouse on cards);
* Added column style render testing (many cards mode);
* Added tapped, face down and manifested render testing for permanents;
* CardView: fixed missing copy data (NPE for transformed cards);
* CardArea: added support to draw permanents;
* CardArea: added support of offsets between cards/columns;
This commit is contained in:
Oleg Agafonov 2020-01-22 00:44:25 +04:00
parent a072d8275f
commit eaaa37db11
27 changed files with 306 additions and 138 deletions

View file

@ -1,5 +1,6 @@
package mage.util;
import java.awt.*;
import java.util.Random;
/**
@ -32,6 +33,10 @@ public final class RandomUtil {
return random.nextDouble();
}
public static Color nextColor() {
return new Color(RandomUtil.nextInt(256), RandomUtil.nextInt(256), RandomUtil.nextInt(256));
}
public static void setSeed(long newSeed) {
random.setSeed(newSeed);
}

View file

@ -5,7 +5,6 @@ import mage.constants.SubType;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collections;
import java.util.List;
import java.util.stream.Collectors;
public class SubTypeList extends ArrayList<SubType> {
@ -20,6 +19,10 @@ public class SubTypeList extends ArrayList<SubType> {
Collections.addAll(this, subTypesList);
}
public SubTypeList(final SubTypeList list) {
this.addAll(list);
}
public boolean add(SubType... subTypes) {
return Collections.addAll(this, subTypes);
}