stack-the-deck (#1)
Allow for redrawing or explicitly selecting a card for replacement. Co-authored-by: Gavin McDonald <gavinmcdoh@gmail.com> Reviewed-on: #1
This commit was merged in pull request #1.
This commit is contained in:
@@ -11,7 +11,7 @@ export default function getTooltip(
|
||||
|
||||
let text: string[] = [];
|
||||
|
||||
if (flipped) {
|
||||
if (dm || flipped) {
|
||||
if (dm || settings.positionFront) text.push(position.text);
|
||||
|
||||
if (dm) text.push(`${cardName}: ${description}`);
|
||||
@@ -33,11 +33,9 @@ export default function getTooltip(
|
||||
|
||||
// Low deck: Tome, Ravenkind, or Sunsword
|
||||
if (isLowCard(card)) {
|
||||
if (dm) text.push(card.prophecy.dmText);
|
||||
if (dm || settings.prophecy) text.push(card.prophecy.playerText);
|
||||
if (dm) text.push(card.prophecy.dmText);
|
||||
}
|
||||
} else {
|
||||
if (dm || settings.positionBack) text.push(position.text);
|
||||
}
|
||||
|
||||
return text;
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { cardStyles, standardMap } from '@/constants/tarokka';
|
||||
import { Settings, TarokkaGameCard } from '@/types';
|
||||
import { Settings, TarokkaCard, TarokkaGameCard } from '@/types';
|
||||
|
||||
export default function getURL(card: TarokkaGameCard, settings: Settings) {
|
||||
export default function getURL(card: TarokkaCard | TarokkaGameCard, settings: Settings) {
|
||||
const styleConfig = cardStyles[settings.cardStyle];
|
||||
const fileBase = settings.cardStyle === 'standard' ? standardMap[card.id] : card.id;
|
||||
return `${styleConfig.baseURL}${fileBase}${card.extension || styleConfig.extension}`;
|
||||
|
||||
Reference in New Issue
Block a user