diff --git a/src/client/src/modules/game/CardComponent.tsx b/src/client/src/modules/game/CardComponent.tsx index 0b82d07..9d2c110 100644 --- a/src/client/src/modules/game/CardComponent.tsx +++ b/src/client/src/modules/game/CardComponent.tsx @@ -59,11 +59,14 @@ export const CardComponent: React.FC = ({ card, onDragStart, onMouseLeave={onMouseLeave} className={` relative rounded-lg shadow-md cursor-pointer transition-transform hover:scale-105 select-none - ${card.tapped ? 'rotate-45' : ''} ${card.zone === 'hand' ? 'w-32 h-44 -ml-12 first:ml-0 hover:z-10 hover:-translate-y-4' : (viewMode === 'cutout' ? 'w-24 h-24' : 'w-24 h-32')} ${className || ''} `} - style={style} + style={{ + ...style, + transform: card.tapped ? 'rotate(10deg)' : style?.transform, + opacity: card.tapped ? 0.5 : style?.opacity ?? 1 + }} >
= ({ gameState, currentPlayerId } const allLands = myBattlefield.filter(c => c.types?.includes('Land') && !c.types?.includes('Creature')); const others = myBattlefield.filter(c => !c.types?.includes('Creature') && !c.types?.includes('Land')); - const untappedLands = allLands.filter(c => !c.tapped); - const tappedLands = allLands.filter(c => c.tapped); + const renderCard = (card: CardInstance) => { const isAttacking = proposedAttackers.has(card.instanceId); @@ -792,35 +791,13 @@ export const GameView: React.FC = ({ gameState, currentPlayerId }
)} -
+
{allLands.length === 0 && (
Lands
)} - - {/* Tapped Lands Stack */} - {tappedLands.length > 0 && ( -
- {tappedLands.map((card, i) => ( -
- {renderCard(card)} -
- ))} -
- )} - - {/* Untapped Lands */} -
- {untappedLands.map(renderCard)} -
+ {allLands.map(renderCard)}
);