🌊 The Obstacle List

🎴 Deck: {state.game.deck_cards ? JSON.parse(state.game.deck_cards).length : 0} cards left
{#if captain} 🏴‍☠️ Captain: {captain.name} (Rank {captain.rank}){isCaptain ? ' — You!' : ''} {:else} 🏴‍☠️ Captain: None{state.game.completed_crew_1 ? '' : ' (steal a ship first!)'} {/if}
Active Roster: {#each state.players as p} {#if p.role === 'deep'} 🌊 {p.name} (Deep) {:else if p.role === 'pirat'} {#if p.is_ghost}👻{:else if p.is_dead}💀{:else}🐀{/if} {p.name} (Rank {p.rank}){p.id === state.game.captain_player_id ? ' ⭐' : ''} {/if} {/each}
{#if state.player.role === "deep"} {/if}

🃏 Your Hand

Keep your cards secret! {#if state.player.role !== "deep"}When the Deep challenges you (or you assist a crewmate), drag a card onto an applied obstacle to play it. Jokers can hit any obstacle, any time.{/if}

{#each hand as card} { e.dataTransfer.setData('text/plain', card); e.currentTarget.classList.add("dragging"); }} on:dragend={(e) => { e.currentTarget.classList.remove("dragging"); }} /> {:else}

Your hand is empty! (You draw cards when playing cards that match the suit color of the obstacle.)

{/each}
{#if state.player.role !== "deep"} {/if}