fix NPE when trying to draw PT on an emblem.
@@ -622,6 +622,7 @@ public class CardPanelComponentImpl extends CardPanel {
fullImageText.setBounds(titleText.getX(), titleText.getY(), titleText.getBounds().width, titleText.getBounds().height);
// PT (font as title)
+ if (getGameCard().getOriginalCard() != null) {
prepareGlowFont(ptText1, Math.max(CARD_PT_FONT_MIN_SIZE, fontSize), getGameCard().getOriginalCard().getPower(), false);
prepareGlowFont(ptText2, Math.max(CARD_PT_FONT_MIN_SIZE, fontSize), null, false);
prepareGlowFont(ptText3, Math.max(CARD_PT_FONT_MIN_SIZE, fontSize), getGameCard().getOriginalCard().getToughness(), CardRendererUtils.isCardWithDamage(getGameCard()));
@@ -635,6 +636,7 @@ public class CardPanelComponentImpl extends CardPanel {
int ptX = cardXOffset + ptMarginRight;
int ptY = cardYOffset + cardHeight - ptMarginBottom - ptHeight;
ptPanel.setBounds(ptX, ptY, ptWidth, ptHeight);
+ }
// old version was with TEXT_GLOW_SIZE
//ptText.setLocation(cardXOffset + ptX - TEXT_GLOW_SIZE / 2 - offsetX, cardYOffset + ptY - TEXT_GLOW_SIZE / 2);
