commit 90acbcb4e6cf783ccf2ee92c40a47d89ba12609d Author: TMC Date: Sun Nov 15 20:40:57 2026 +0100 Bela v0: local game against bots, counting training, settings with self-update - engine: Croatian Bela rules (deal, trump call, declarations, play rules, scoring), heuristic bot, counting drill; unit tests and a 1000-game simulation - app: Jetpack Compose table with partner and two bot opponents, Hungarian deck, card-counting training, settings with in-app update and a QR code for sharing - tools: card import/render/upscale scripts and the launcher icon generator Co-Authored-By: Claude Opus 5.5 diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..9520b09 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,8 @@ +* text=auto +gradlew text eol=lf +*.bat text eol=crlf +*.ps1 text eol=crlf +*.png binary +*.webp binary +*.ttf binary +*.jar binary diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..50b1f25 --- /dev/null +++ b/.gitignore @@ -0,0 +1,18 @@ +.gradle/ +.kotlin/ +build/ +local.properties +.idea/ +*.iml +.DS_Store +captures/ + +# Release signing and publishing secrets: never commit (this repository is public). +keystore.properties +*.jks +*.keystore +.gitea-token +*.apk + +# IDE build output +bin/ diff --git a/README.md b/README.md new file mode 100644 index 0000000..931cbb8 --- /dev/null +++ b/README.md @@ -0,0 +1,63 @@ +# Bela + +Android aplikacija za Belu: ti i bot partner protiv dva bota, do 1001 boda. Ovo je verzija 0: lokalna igra, bez mreže i računa. + +## Struktura + +| Modul | Što je u njemu | +| --- | --- | +| `engine/` | Čisti Kotlin, bez Androida: karte, pravila, zvanja, bodovanje, bot. Kasnije se može prebaciti u Kotlin Multiplatform za server ili iOS. | +| `app/` | Android aplikacija (Jetpack Compose): početni ekran, stol, dijalozi. | + +Važne datoteke: + +- `engine/.../Game.kt`: tijek partije (dijeljenje, zvanje aduta, štihovi, obračun). +- `engine/.../Trick.kt`: dozvoljeni potezi (praćenje boje, iber, sječenje). +- `engine/.../Declarations.kt`: zvanja. +- `engine/.../RuleSet.kt`: kućna pravila (do koliko se igra, štiglja, iber, belot, "visi"). +- `engine/.../Bot.kt`: heuristički bot. +- `app/.../ui/CardArt.kt`: **sve što crta kartu**, vidi niže. + +## Build i pokretanje + +``` +gradlew :engine:test # testovi pravila + simulacija 1000 partija +gradlew :app:assembleDebug # APK u app/build/outputs/apk/debug/ +gradlew :app:installDebug # instalacija na spojeni uređaj ili emulator +``` + +Projekt koristi AGP 9.4.1, Kotlin 2.4.21, Gradle 9.8.2 i compileSdk 36, iste verzije kao AndroidTV projekt. + +## Karte + +Aplikacija koristi slike iz `app/src/main/res/drawable-nodpi/` (`card__.webp`, `suit_.webp`). Postoje dva izvora, a skripta odabranog izvora prepisuje te slike: + +| Izvor | Naredba | Napomena | +| --- | --- | --- | +| **PNG špil** (trenutno u upotrebi): [tomasdrus/hungarian-playing-cards](https://github.com/tomasdrus/hungarian-playing-cards), kopiran u `card_assets/hungarian-playing-cards/` | `python tools/import_png_cards.py` | 363×585 px, WebP bez gubitaka. **Repozitorij nema licencu**, vidi `NOTICE.md` u toj mapi. Prije objave aplikacije treba dopuštenje autora. | +| Naši SVG-ovi u `card_assets/*.svg` | `python tools/render_cards.py` | Treba Inkscape 1.x. Renderira 720 px. | + +Poleđina je naša i crta se vektorski u kodu (`CardBack`). + +**Pravilo oštrine:** karta se nikad ne crta šire od svoje slike. Svaka veličina karte ograničava se s `maxCardWidth()` (za PNG špil to je 363 px, na ovom emulatoru ~138dp). Slike se dekodiraju u rezoluciji u kojoj se crtaju, s mipmapama. U debug buildu svako povećanje slike zapisuje se u logcat pod oznakom `BelaCards`, pa se provjerava s `adb logcat -s BelaCards`. + +Sve što crta kartu nalazi se u `app/src/main/kotlin/hr/bela/app/ui/CardArt.kt` (`CardFace`, `CardBack`, `SuitIcon`, `maxCardWidth`). + +U kodu se boje zovu `HERC`, `KARO`, `PIK` i `TREF` (= srce, zvono, list, žir), a vrijednosti `SEDAM` … `AS`. + +## Trening brojanja + +S početnog ekrana ("Trening brojanja"). Svaka runda je hrpa osvojenih štihova (po 4 karte) s izmišljenim adutom i ponekad zadnjim štihom (+10). Karte se pokazuju jedna po jedna, a zatim igrač bira jedan od četiri zbroja. Netočni odgovori nastaju iz tipičnih grešaka (dečko ili devetka u adutu, zaboravljen zadnji štih, propuštena desetka ili as…). Nakon odgovora vidi se svaka karta s bodovima i objašnjenje greške. + +- Logika runde: `engine/.../CountingDrill.kt` (s testovima). +- Razine (Lako 8 karata, Srednje 12–16, Teško 20–28) i stanje: `app/.../TrainingViewModel.kt`. +- Ekran: `app/.../ui/TrainingScreen.kt`. + +## Izgled + +- Fontovi: **Cinzel** (naslovi, rezultat, oznake) i **Inter** (tekst), u `app/src/main/res/font/`. Oba su pod licencom SIL Open Font License, tekst licence je u `licenses/`. +- Boje, prijelazi i filc stola su u `ui/Theme.kt`, zajednički gumbi i ukrasi u `ui/Components.kt`. + +## Spremanje partije + +Partija se sprema nakon svakog poteza kao seed i popis poteza (`GameRecord`), pa se nakon zatvaranja aplikacije vraća točno gdje je stala. diff --git a/app/build.gradle.kts b/app/build.gradle.kts new file mode 100644 index 0000000..0a66825 --- /dev/null +++ b/app/build.gradle.kts @@ -0,0 +1,89 @@ +import java.util.Properties + +plugins { + alias(libs.plugins.android.application) + alias(libs.plugins.compose.compiler) +} + +// versionCode is the git commit count (monotonic, no manual bumps), so every release is strictly +// newer than the last, which is what the in-app updater compares. A build without .git can pass it in: +// -PbelaVersionCode=. +val gitCommitCount: Int = providers.gradleProperty("belaVersionCode").orNull?.toIntOrNull() + ?: runCatching { + providers.exec { commandLine("git", "rev-list", "--count", "HEAD") } + .standardOutput.asText.get().trim().toInt() + }.getOrDefault(1) + +// versionName is the commit count as a base-10 odometer (commit #13 -> 0.1.3, #100 -> 1.0.0), so the +// updater can turn a release tag back into its versionCode. Same scheme as the Keep app. +val versionNameFromGit = "${gitCommitCount / 100}.${(gitCommitCount / 10) % 10}.${gitCommitCount % 10}" + +// Release signing reads keystore.properties in the project root (gitignored, made by +// tools/build-release.ps1 on first run). Without it the release build stays unsigned. +val keystorePropsFile = rootProject.file("keystore.properties") +val keystoreProps = Properties().apply { + if (keystorePropsFile.exists()) keystorePropsFile.inputStream().use { load(it) } +} + +android { + namespace = "hr.bela.app" + compileSdk = 36 + + defaultConfig { + applicationId = "hr.bela.app" + minSdk = 26 + targetSdk = 36 + versionCode = gitCommitCount + versionName = versionNameFromGit + } + + signingConfigs { + create("release") { + if (keystorePropsFile.exists()) { + storeFile = rootProject.file(keystoreProps.getProperty("storeFile")) + storePassword = keystoreProps.getProperty("storePassword") + keyAlias = keystoreProps.getProperty("keyAlias") + keyPassword = keystoreProps.getProperty("keyPassword") + } + } + } + + buildTypes { + debug { + isMinifyEnabled = false + } + release { + isMinifyEnabled = true + isShrinkResources = true + proguardFiles(getDefaultProguardFile("proguard-android-optimize.txt")) + if (keystorePropsFile.exists()) signingConfig = signingConfigs.getByName("release") + } + } + + compileOptions { + sourceCompatibility = JavaVersion.VERSION_17 + targetCompatibility = JavaVersion.VERSION_17 + } + + buildFeatures { + compose = true + buildConfig = true + } +} + +dependencies { + implementation(project(":engine")) + + implementation(platform(libs.compose.bom)) + implementation(libs.compose.ui) + implementation(libs.compose.foundation) + implementation(libs.compose.material3) + implementation(libs.compose.ui.tooling.preview) + debugImplementation(libs.compose.ui.tooling) + + implementation(libs.activity.compose) + implementation(libs.lifecycle.runtime.compose) + implementation(libs.lifecycle.viewmodel.compose) + implementation(libs.coroutines.android) + implementation(libs.zxing.core) +} diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml new file mode 100644 index 0000000..58f75ec --- /dev/null +++ b/app/src/main/AndroidManifest.xml @@ -0,0 +1,39 @@ + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/app/src/main/kotlin/hr/bela/app/GameViewModel.kt b/app/src/main/kotlin/hr/bela/app/GameViewModel.kt new file mode 100644 index 0000000..736d32d --- /dev/null +++ b/app/src/main/kotlin/hr/bela/app/GameViewModel.kt @@ -0,0 +1,178 @@ +package hr.bela.app + +import android.app.Application +import android.content.Context +import androidx.lifecycle.AndroidViewModel +import androidx.lifecycle.viewModelScope +import hr.bela.engine.Action +import hr.bela.engine.Bela +import hr.bela.engine.BotStrategy +import hr.bela.engine.Card +import hr.bela.engine.CompletedTrick +import hr.bela.engine.GameRecord +import hr.bela.engine.GameState +import hr.bela.engine.HeuristicBot +import hr.bela.engine.Phase +import hr.bela.engine.Suit +import kotlinx.coroutines.Job +import kotlinx.coroutines.delay +import kotlinx.coroutines.flow.MutableStateFlow +import kotlinx.coroutines.flow.StateFlow +import kotlinx.coroutines.flow.asStateFlow +import kotlinx.coroutines.flow.update +import kotlinx.coroutines.launch + +/** The person holding the phone always sits at seat 0; the partner bot is seat 2. */ +const val HUMAN = 0 + +data class UiState( + /** Null on the home screen. */ + val game: GameState? = null, + /** A finished trick kept on the table for a moment before it is gathered. */ + val shownTrick: CompletedTrick? = null, + /** Short speech bubble over a seat, such as "Bela!". */ + val bubble: Pair? = null, + val hasSavedGame: Boolean = false, + val showScoreSheet: Boolean = false, + val showLastTrick: Boolean = false, +) { + /** The table is busy showing a trick; the player cannot act yet. */ + val inputLocked: Boolean get() = shownTrick != null +} + +class GameViewModel(app: Application) : AndroidViewModel(app) { + private val prefs = app.getSharedPreferences("bela", Context.MODE_PRIVATE) + private val bot: BotStrategy = HeuristicBot + + private val _ui = MutableStateFlow(UiState(hasSavedGame = savedRecord() != null)) + val ui: StateFlow = _ui.asStateFlow() + + /** Seed plus every action so far; saved after each move so a game survives the app being closed. */ + private var record: GameRecord? = null + private var botLoop: Job? = null + private var bubbleJob: Job? = null + + fun newGame() { + val game = Bela.newGame() + record = GameRecord(game.seed) + _ui.value = UiState(game = game, hasSavedGame = true) + save() + driveBots() + } + + fun continueGame() { + val saved = savedRecord() + val game = saved?.let { runCatching { it.replay() }.getOrNull() } + if (saved == null || game == null) return newGame() + record = saved + _ui.value = UiState(game = game, hasSavedGame = true) + driveBots() + } + + fun leaveTable() { + botLoop?.cancel() + bubbleJob?.cancel() + _ui.value = UiState(hasSavedGame = savedRecord() != null) + } + + fun callTrump(suit: Suit?) { + val game = _ui.value.game ?: return + if (game.phase != Phase.BIDDING || game.toAct != HUMAN) return + if (suit == null && !game.canPass(HUMAN)) return + act(Action.Call(HUMAN, suit)) + driveBots() + } + + fun playCard(card: Card) { + val state = _ui.value + val game = state.game ?: return + if (state.inputLocked || card !in game.legalMoves(HUMAN)) return + act(Action.Play(HUMAN, card)) + driveBots() + } + + fun nextHand() { + val state = _ui.value + if (state.game?.phase != Phase.HAND_OVER || state.inputLocked) return + act(Action.NextHand) + driveBots() + } + + fun showScoreSheet(show: Boolean) = _ui.update { it.copy(showScoreSheet = show) } + + fun showLastTrick(show: Boolean) = _ui.update { it.copy(showLastTrick = show) } + + private fun act(action: Action) { + val before = _ui.value.game ?: return + val after = before.apply(action) + record = record?.plus(action) + + val finishedTrick = (action as? Action.Play) + ?.takeIf { after.hand.tricks.size > before.hand.tricks.size } + ?.let { after.hand.tricks.last() } + _ui.update { + it.copy( + game = after, + shownTrick = finishedTrick ?: it.shownTrick, + showLastTrick = it.showLastTrick && action !is Action.NextHand, + ) + } + + if (action is Action.Play && !before.hand.belaAnnounced && after.hand.belaAnnounced) { + showBubble(action.seat, "Bela!") + } + if (after.phase == Phase.GAME_OVER) clearSave() else save() + } + + /** Let the bots act, with short pauses so the player can follow, until it is the player's turn. */ + private fun driveBots() { + botLoop?.cancel() + botLoop = viewModelScope.launch { + while (true) { + if (_ui.value.shownTrick != null) { + delay(TRICK_PAUSE_MS) + _ui.update { it.copy(shownTrick = null) } + } + val game = _ui.value.game ?: return@launch + val seat = game.toAct ?: return@launch + if (seat == HUMAN) return@launch + delay(if (game.phase == Phase.BIDDING) BID_DELAY_MS else PLAY_DELAY_MS) + val action = if (game.phase == Phase.BIDDING) { + Action.Call(seat, bot.chooseTrump(game, seat)) + } else { + Action.Play(seat, bot.chooseCard(game, seat)) + } + act(action) + } + } + } + + private fun showBubble(seat: Int, text: String) { + bubbleJob?.cancel() + _ui.update { it.copy(bubble = seat to text) } + bubbleJob = viewModelScope.launch { + delay(BUBBLE_MS) + _ui.update { it.copy(bubble = null) } + } + } + + private fun save() { + record?.let { prefs.edit().putString(KEY_GAME, it.encode()).apply() } + } + + private fun clearSave() { + prefs.edit().remove(KEY_GAME).apply() + _ui.update { it.copy(hasSavedGame = false) } + } + + private fun savedRecord(): GameRecord? = prefs.getString(KEY_GAME, null)?.let(GameRecord::decode) + + private companion object { + const val KEY_GAME = "saved_game" + const val BID_DELAY_MS = 700L + const val PLAY_DELAY_MS = 600L + /** How long a finished trick stays on the table; the UI slides it to the winner near the end (TrickArea). */ + const val TRICK_PAUSE_MS = 1500L + const val BUBBLE_MS = 1600L + } +} diff --git a/app/src/main/kotlin/hr/bela/app/MainActivity.kt b/app/src/main/kotlin/hr/bela/app/MainActivity.kt new file mode 100644 index 0000000..ea1e312 --- /dev/null +++ b/app/src/main/kotlin/hr/bela/app/MainActivity.kt @@ -0,0 +1,69 @@ +package hr.bela.app + +import android.graphics.Color +import android.os.Bundle +import androidx.activity.ComponentActivity +import androidx.activity.SystemBarStyle +import androidx.activity.compose.setContent +import androidx.activity.enableEdgeToEdge +import androidx.compose.runtime.Composable +import androidx.compose.runtime.getValue +import androidx.compose.runtime.mutableStateOf +import androidx.compose.runtime.saveable.rememberSaveable +import androidx.compose.runtime.setValue +import androidx.lifecycle.compose.collectAsStateWithLifecycle +import androidx.lifecycle.viewmodel.compose.viewModel +import hr.bela.app.ui.BelaTheme +import hr.bela.app.ui.HomeScreen +import hr.bela.app.ui.SettingsScreen +import hr.bela.app.ui.TableScreen +import hr.bela.app.ui.TrainingScreen + +class MainActivity : ComponentActivity() { + override fun onCreate(savedInstanceState: Bundle?) { + super.onCreate(savedInstanceState) + // The felt is always dark, so system bar icons stay light whatever the system theme. + enableEdgeToEdge( + statusBarStyle = SystemBarStyle.dark(Color.TRANSPARENT), + navigationBarStyle = SystemBarStyle.dark(Color.TRANSPARENT), + ) + setContent { + BelaTheme { + BelaApp() + } + } + } +} + +/** Screens reached from the home screen; a running game is shown whenever one is open. */ +private enum class Screen { HOME, TRAINING, SETTINGS } + +@Composable +private fun BelaApp(vm: GameViewModel = viewModel()) { + val state by vm.ui.collectAsStateWithLifecycle() + var screen by rememberSaveable { mutableStateOf(Screen.HOME) } + if (screen == Screen.TRAINING) { + TrainingScreen(onExit = { screen = Screen.HOME }) + } else if (screen == Screen.SETTINGS) { + SettingsScreen(onExit = { screen = Screen.HOME }) + } else if (state.game == null) { + HomeScreen( + hasSavedGame = state.hasSavedGame, + onContinue = vm::continueGame, + onNewGame = vm::newGame, + onTraining = { screen = Screen.TRAINING }, + onSettings = { screen = Screen.SETTINGS }, + ) + } else { + TableScreen( + state = state, + onCall = vm::callTrump, + onPlay = vm::playCard, + onNextHand = vm::nextHand, + onNewGame = vm::newGame, + onLeave = vm::leaveTable, + onScoreSheet = vm::showScoreSheet, + onLastTrick = vm::showLastTrick, + ) + } +} diff --git a/app/src/main/kotlin/hr/bela/app/SettingsViewModel.kt b/app/src/main/kotlin/hr/bela/app/SettingsViewModel.kt new file mode 100644 index 0000000..b461155 --- /dev/null +++ b/app/src/main/kotlin/hr/bela/app/SettingsViewModel.kt @@ -0,0 +1,81 @@ +package hr.bela.app + +import android.app.Application +import androidx.lifecycle.AndroidViewModel +import androidx.lifecycle.viewModelScope +import hr.bela.app.update.ReleaseInfo +import hr.bela.app.update.UpdateCheck +import hr.bela.app.update.Updates +import kotlinx.coroutines.flow.MutableStateFlow +import kotlinx.coroutines.flow.StateFlow +import kotlinx.coroutines.flow.asStateFlow +import kotlinx.coroutines.launch +import java.io.File + +/** Where the update flow in Settings stands. */ +sealed interface UpdateState { + data object Checking : UpdateState + data class UpToDate(val latest: String) : UpdateState + data object NoReleases : UpdateState + data class Available(val release: ReleaseInfo) : UpdateState + data class Downloading(val release: ReleaseInfo, val progress: Float) : UpdateState + + /** Downloaded, but Android needs "install unknown apps" allowed for Bela first. */ + data class NeedsPermission(val release: ReleaseInfo, val apk: File) : UpdateState + + /** The system installer was opened. */ + data class Installing(val release: ReleaseInfo, val apk: File) : UpdateState + data class Failed(val message: String) : UpdateState +} + +class SettingsViewModel(app: Application) : AndroidViewModel(app) { + private val updates = Updates(app) + private val _update = MutableStateFlow(UpdateState.Checking) + val update: StateFlow = _update.asStateFlow() + + init { + check() + } + + fun check() { + _update.value = UpdateState.Checking + viewModelScope.launch { + _update.value = when (val result = updates.check()) { + is UpdateCheck.Available -> UpdateState.Available(result.release) + is UpdateCheck.UpToDate -> UpdateState.UpToDate(result.latest.versionName) + UpdateCheck.NoReleases -> UpdateState.NoReleases + is UpdateCheck.Failed -> UpdateState.Failed(result.message) + } + } + } + + fun download(release: ReleaseInfo) { + _update.value = UpdateState.Downloading(release, 0f) + viewModelScope.launch { + try { + val apk = updates.download(release) { progress -> _update.value = UpdateState.Downloading(release, progress) } + install(release, apk) + } catch (e: Exception) { + _update.value = UpdateState.Failed(e.message ?: "Preuzimanje nije uspjelo") + } + } + } + + /** Opens the installer, or asks for the "install unknown apps" permission first. */ + fun install(release: ReleaseInfo, apk: File) { + if (updates.canInstall()) { + updates.install(apk) + _update.value = UpdateState.Installing(release, apk) + } else { + _update.value = UpdateState.NeedsPermission(release, apk) + } + } + + fun openInstallPermission() = updates.openInstallPermissionSettings() + + /** Back from the system settings: continue if the permission was granted. */ + fun onResume() { + val state = _update.value + if (state is UpdateState.NeedsPermission && updates.canInstall()) install(state.release, state.apk) + } +} diff --git a/app/src/main/kotlin/hr/bela/app/TrainingViewModel.kt b/app/src/main/kotlin/hr/bela/app/TrainingViewModel.kt new file mode 100644 index 0000000..825bb35 --- /dev/null +++ b/app/src/main/kotlin/hr/bela/app/TrainingViewModel.kt @@ -0,0 +1,102 @@ +package hr.bela.app + +import android.app.Application +import android.content.Context +import androidx.lifecycle.AndroidViewModel +import hr.bela.engine.AnswerOption +import hr.bela.engine.CountingDrill +import hr.bela.engine.CountingRound +import kotlinx.coroutines.flow.MutableStateFlow +import kotlinx.coroutines.flow.StateFlow +import kotlinx.coroutines.flow.asStateFlow +import kotlinx.coroutines.flow.update +import kotlin.random.Random + +/** How big the pile is: number of won tricks (4 cards each) and how often the last trick (+10) is included. */ +enum class DrillLevel(val label: String, val tricks: IntRange, val lastTrickChance: Double) { + LAKO("Lako", 2..2, 0.0), + SREDNJE("Srednje", 3..4, 0.5), + TESKO("Teško", 5..7, 0.5), +} + +enum class DrillPhase { + /** Cards are shown one at a time. */ + COUNTING, + + /** All cards seen; pick one of four totals. */ + ANSWERING, + + /** Answer given; show the verdict and the breakdown. */ + RESULT, +} + +data class TrainingState( + val level: DrillLevel, + val round: CountingRound, + /** How many cards of the pile have been shown so far (the last of them is on screen). */ + val shown: Int = 1, + val phase: DrillPhase = DrillPhase.COUNTING, + val chosen: AnswerOption? = null, + val answered: Int = 0, + val correct: Int = 0, + val streak: Int = 0, + val bestStreak: Int = 0, +) { + val isLastCard: Boolean get() = shown >= round.cards.size + val wasCorrect: Boolean get() = chosen?.value == round.total +} + +/** Card-counting practice: count a pile card by card, then pick the right total of four. */ +class TrainingViewModel(app: Application) : AndroidViewModel(app) { + private val prefs = app.getSharedPreferences("bela_training", Context.MODE_PRIVATE) + private val random = Random.Default + + private val _state = MutableStateFlow( + TrainingState( + level = DrillLevel.SREDNJE, + round = newRound(DrillLevel.SREDNJE), + bestStreak = prefs.getInt(KEY_BEST_STREAK, 0), + ), + ) + val state: StateFlow = _state.asStateFlow() + + /** Show the next card, or move on to the answers after the last one. */ + fun next() = _state.update { s -> + when { + s.phase != DrillPhase.COUNTING -> s + s.isLastCard -> s.copy(phase = DrillPhase.ANSWERING) + else -> s.copy(shown = s.shown + 1) + } + } + + fun answer(option: AnswerOption) = _state.update { s -> + if (s.phase != DrillPhase.ANSWERING) return@update s + val right = option.value == s.round.total + val streak = if (right) s.streak + 1 else 0 + val best = maxOf(s.bestStreak, streak) + if (best > s.bestStreak) prefs.edit().putInt(KEY_BEST_STREAK, best).apply() + s.copy( + phase = DrillPhase.RESULT, + chosen = option, + answered = s.answered + 1, + correct = s.correct + if (right) 1 else 0, + streak = streak, + bestStreak = best, + ) + } + + fun nextRound() = _state.update { s -> + s.copy(round = newRound(s.level), shown = 1, phase = DrillPhase.COUNTING, chosen = null) + } + + fun setLevel(level: DrillLevel) = _state.update { s -> + if (level == s.level) s else s.copy(level = level, round = newRound(level), shown = 1, phase = DrillPhase.COUNTING, chosen = null) + } + + private fun newRound(level: DrillLevel): CountingRound = + CountingDrill.round(random, level.tricks.random(random), lastTrick = random.nextDouble() < level.lastTrickChance) + + private companion object { + const val KEY_BEST_STREAK = "best_streak" + } +} diff --git a/app/src/main/kotlin/hr/bela/app/ui/CardArt.kt b/app/src/main/kotlin/hr/bela/app/ui/CardArt.kt new file mode 100644 index 0000000..d9fbed8 --- /dev/null +++ b/app/src/main/kotlin/hr/bela/app/ui/CardArt.kt @@ -0,0 +1,260 @@ +package hr.bela.app.ui + +import android.content.res.Resources +import android.graphics.BitmapFactory +import android.util.Log +import android.util.LruCache +import androidx.annotation.DrawableRes +import androidx.compose.foundation.Canvas +import androidx.compose.foundation.background +import androidx.compose.foundation.border +import androidx.compose.foundation.layout.Box +import androidx.compose.foundation.layout.aspectRatio +import androidx.compose.foundation.layout.fillMaxSize +import androidx.compose.foundation.layout.size +import androidx.compose.foundation.shape.RoundedCornerShape +import androidx.compose.runtime.Composable +import androidx.compose.ui.Modifier +import androidx.compose.ui.draw.clip +import androidx.compose.ui.draw.drawWithCache +import androidx.compose.ui.draw.shadow +import androidx.compose.ui.geometry.CornerRadius +import androidx.compose.ui.geometry.Offset +import androidx.compose.ui.geometry.Size +import androidx.compose.ui.graphics.Brush +import androidx.compose.ui.graphics.Color +import androidx.compose.ui.graphics.FilterQuality +import androidx.compose.ui.graphics.ImageBitmap +import androidx.compose.ui.graphics.Path +import androidx.compose.ui.graphics.asImageBitmap +import androidx.compose.ui.graphics.drawscope.Stroke +import androidx.compose.ui.graphics.drawscope.clipRect +import androidx.compose.ui.platform.LocalContext +import androidx.compose.ui.platform.LocalDensity +import androidx.compose.ui.semantics.contentDescription +import androidx.compose.ui.semantics.semantics +import androidx.compose.ui.unit.Dp +import androidx.compose.ui.unit.IntOffset +import androidx.compose.ui.unit.IntSize +import androidx.compose.ui.unit.dp +import hr.bela.app.BuildConfig +import hr.bela.app.R +import hr.bela.engine.Card +import hr.bela.engine.Suit +import kotlin.math.min +import kotlin.math.roundToInt + +/* + * Card artwork. Every card on screen is drawn by CardFace, CardBack or SuitIcon in this file. + * + * The images are WebP files in res/drawable-nodpi (card__, suit_), produced by + * tools/import_png_cards.py (the PNG deck in card_assets/hungarian-playing-cards) or tools/render_cards.py + * (our own SVG cards). Cards are never drawn wider than their image: use maxCardWidth() when sizing them. + * The back is our own design, drawn as vectors (CardBack). + */ + +/** Card width divided by height (363 x 585 for the PNG deck, 175 x 282 for the SVG deck: the same shape). */ +const val CARD_ASPECT = 363f / 585f + +/** Same corner radius as the artwork (22 px on a 363 px card), so its own outline is not cut. */ +private val CardShape = RoundedCornerShape(6) + +/** + * Decodes card images for the size they are drawn at: the smallest power-of-two reduction that is still at least + * as wide as on screen, with mipmaps, so they stay sharp from tiny (declarations) to full size (training) without + * keeping full-size bitmaps of the whole deck in memory. + */ +private object CardBitmaps { + private val cache = object : LruCache(32 * 1024 * 1024) { + override fun sizeOf(key: Long, value: ImageBitmap) = value.width * value.height * 4 + } + private val sizes = HashMap() + + /** Pixel size of the image file, read without decoding it. */ + fun sourceSize(resources: Resources, @DrawableRes id: Int): IntSize = sizes.getOrPut(id) { + val bounds = BitmapFactory.Options().apply { + inJustDecodeBounds = true + inScaled = false + } + BitmapFactory.decodeResource(resources, id, bounds) + IntSize(bounds.outWidth, bounds.outHeight) + } + + fun get(resources: Resources, @DrawableRes id: Int, widthPx: Int): ImageBitmap { + val source = sourceSize(resources, id).width + if (BuildConfig.DEBUG && widthPx > source) { + Log.w("BelaCards", "Upscaled: ${resources.getResourceEntryName(id)} drawn $widthPx px wide, image is $source px") + } + var sample = 1 + while (source / (sample * 2) >= widthPx) sample *= 2 + val key = (id.toLong() shl 8) or sample.toLong() + cache.get(key)?.let { return it } + val options = BitmapFactory.Options().apply { + inSampleSize = sample + inScaled = false + } + val bitmap = BitmapFactory.decodeResource(resources, id, options) + bitmap.setHasMipMap(true) + return bitmap.asImageBitmap().also { cache.put(key, it) } + } +} + +/** The widest a card may be drawn without enlarging its image (363 px of artwork, in dp for this screen). */ +@Composable +fun maxCardWidth(): Dp { + val width = CardBitmaps.sourceSize(LocalContext.current.resources, R.drawable.card_srce_as).width + return with(LocalDensity.current) { width.toDp() } +} + +/** Card images per suit, in rank order 7, 8, 9, 10, dečko, dama, kralj, as (the order of [hr.bela.engine.Rank]). */ +private val CARD_IMAGES: Map> = mapOf( + Suit.HERC to listOf( + R.drawable.card_srce_7, R.drawable.card_srce_8, R.drawable.card_srce_9, R.drawable.card_srce_10, + R.drawable.card_srce_decko, R.drawable.card_srce_dama, R.drawable.card_srce_kralj, R.drawable.card_srce_as, + ), + Suit.KARO to listOf( + R.drawable.card_zvono_7, R.drawable.card_zvono_8, R.drawable.card_zvono_9, R.drawable.card_zvono_10, + R.drawable.card_zvono_decko, R.drawable.card_zvono_dama, R.drawable.card_zvono_kralj, R.drawable.card_zvono_as, + ), + Suit.PIK to listOf( + R.drawable.card_list_7, R.drawable.card_list_8, R.drawable.card_list_9, R.drawable.card_list_10, + R.drawable.card_list_decko, R.drawable.card_list_dama, R.drawable.card_list_kralj, R.drawable.card_list_as, + ), + Suit.TREF to listOf( + R.drawable.card_zir_7, R.drawable.card_zir_8, R.drawable.card_zir_9, R.drawable.card_zir_10, + R.drawable.card_zir_decko, R.drawable.card_zir_dama, R.drawable.card_zir_kralj, R.drawable.card_zir_as, + ), +) + +@DrawableRes +fun cardImage(card: Card): Int = CARD_IMAGES.getValue(card.suit)[card.rank.ordinal] + +@DrawableRes +fun suitImage(suit: Suit): Int = when (suit) { + Suit.HERC -> R.drawable.suit_srce + Suit.KARO -> R.drawable.suit_zvono + Suit.PIK -> R.drawable.suit_list + Suit.TREF -> R.drawable.suit_zir +} + +/** Draws the image [id] over the whole element, decoded for the element's pixel size. */ +private fun Modifier.cardImage(resources: Resources, @DrawableRes id: Int): Modifier = drawWithCache { + val w = size.width.roundToInt().coerceAtLeast(1) + val h = size.height.roundToInt().coerceAtLeast(1) + val bitmap = CardBitmaps.get(resources, id, w) + onDrawBehind { drawImage(bitmap, dstSize = IntSize(w, h), filterQuality = FilterQuality.High) } +} + +/** + * [elevation] sets the drop shadow. A highlighted card (the trick winner) gets a gold frame; + * [glow] casts a gold shadow instead of a black one (cards the player may play). + */ +@Composable +fun CardFace( + card: Card, + modifier: Modifier = Modifier, + dimmed: Boolean = false, + highlighted: Boolean = false, + glow: Boolean = false, + elevation: Dp = 2.dp, +) { + val resources = LocalContext.current.resources + val name = cardName(card) + Box( + modifier + .aspectRatio(CARD_ASPECT) + .shadow( + elevation = if (highlighted) elevation + 6.dp else elevation, + shape = CardShape, + ambientColor = if (glow) Gold else Color.Black, + spotColor = if (highlighted || glow) Gold else Color.Black, + ) + .clip(CardShape) + .cardImage(resources, cardImage(card)) + .then(if (highlighted) Modifier.border(3.dp, Gold, CardShape) else Modifier) + .semantics { contentDescription = name }, + ) { + if (dimmed) Box(Modifier.fillMaxSize().background(Color(0x73000000))) + } +} + +private val BackBase = Brush.linearGradient(listOf(Color(0xFF8E2530), Color(0xFF5A1019), Color(0xFF3E0A11))) + +/** + * Our own card back, drawn as vectors so it is sharp at any size: burgundy with a gold lattice, frame and centre + * medallion. [small] is for the bots' fans (thinner edge); [landscape] lays the card on its side. + */ +@Composable +fun CardBack(modifier: Modifier = Modifier, small: Boolean = false, landscape: Boolean = false) { + Canvas( + modifier + .aspectRatio(if (landscape) 1f / CARD_ASPECT else CARD_ASPECT) + .shadow(if (small) 3.dp else 4.dp, CardShape) + .clip(CardShape) + .background(BackBase) + .border(if (small) 0.75.dp else 1.dp, Cream.copy(alpha = 0.9f), CardShape), + ) { + val w = size.width + val h = size.height + val short = minOf(w, h) + val inset = short * 0.09f + // Diagonal gold lattice inside the frame. + clipRect(inset, inset, w - inset, h - inset) { + val step = short / 5f + var x = -h + while (x < w + h) { + drawLine(Gold.copy(alpha = 0.22f), Offset(x, 0f), Offset(x + h, h), strokeWidth = short * 0.012f) + drawLine(Gold.copy(alpha = 0.22f), Offset(x + h, 0f), Offset(x, h), strokeWidth = short * 0.012f) + x += step + } + } + drawRoundRect( + Gold.copy(alpha = 0.75f), + topLeft = Offset(inset, inset), + size = Size(w - 2 * inset, h - 2 * inset), + cornerRadius = CornerRadius(short * 0.04f), + style = Stroke(width = short * 0.02f), + ) + // Medallion: a gold diamond with a burgundy centre. + val c = Offset(w / 2, h / 2) + val r = short * 0.2f + val outer = Path().apply { + moveTo(c.x, c.y - r); lineTo(c.x + r, c.y); lineTo(c.x, c.y + r); lineTo(c.x - r, c.y); close() + } + drawPath(outer, GoldBrush) + val ri = r * 0.55f + val inner = Path().apply { + moveTo(c.x, c.y - ri); lineTo(c.x + ri, c.y); lineTo(c.x, c.y + ri); lineTo(c.x - ri, c.y); close() + } + drawPath(inner, Color(0xFF5A1019)) + } +} + +/** A suit symbol, kept at its own proportions and centred in a [size] square. */ +@Composable +fun SuitIcon(suit: Suit, size: Dp, modifier: Modifier = Modifier) { + val resources = LocalContext.current.resources + val id = suitImage(suit) + val name = suitName(suit) + Box( + modifier + .size(size) + .drawWithCache { + val source = CardBitmaps.sourceSize(resources, id) + val scale = min(this.size.width / source.width, this.size.height / source.height) + val w = (source.width * scale).roundToInt().coerceAtLeast(1) + val h = (source.height * scale).roundToInt().coerceAtLeast(1) + val bitmap = CardBitmaps.get(resources, id, w) + val offset = Offset((this.size.width - w) / 2, (this.size.height - h) / 2) + onDrawBehind { + drawImage( + bitmap, + dstOffset = IntOffset(offset.x.roundToInt(), offset.y.roundToInt()), + dstSize = IntSize(w, h), + filterQuality = FilterQuality.High, + ) + } + } + .semantics { contentDescription = name }, + ) +} diff --git a/app/src/main/kotlin/hr/bela/app/ui/Components.kt b/app/src/main/kotlin/hr/bela/app/ui/Components.kt new file mode 100644 index 0000000..71bbf6a --- /dev/null +++ b/app/src/main/kotlin/hr/bela/app/ui/Components.kt @@ -0,0 +1,214 @@ +package hr.bela.app.ui + +import androidx.compose.animation.core.animateFloatAsState +import androidx.compose.animation.core.tween +import androidx.compose.foundation.background +import androidx.compose.foundation.border +import androidx.compose.foundation.clickable +import androidx.compose.foundation.interaction.MutableInteractionSource +import androidx.compose.foundation.interaction.collectIsPressedAsState +import androidx.compose.foundation.layout.Box +import androidx.compose.foundation.layout.Row +import androidx.compose.foundation.layout.WindowInsets +import androidx.compose.foundation.layout.safeDrawing +import androidx.compose.foundation.layout.Spacer +import androidx.compose.foundation.layout.fillMaxWidth +import androidx.compose.foundation.layout.height +import androidx.compose.foundation.layout.padding +import androidx.compose.foundation.layout.size +import androidx.compose.foundation.layout.width +import androidx.compose.foundation.shape.CircleShape +import androidx.compose.foundation.shape.RoundedCornerShape +import androidx.compose.material3.Icon +import androidx.compose.material3.Text +import androidx.compose.material3.ripple +import androidx.compose.runtime.Composable +import androidx.compose.runtime.getValue +import androidx.compose.runtime.remember +import androidx.compose.ui.Alignment +import androidx.compose.ui.Modifier +import androidx.compose.ui.draw.clip +import androidx.compose.ui.draw.rotate +import androidx.compose.ui.draw.shadow +import androidx.compose.ui.graphics.Brush +import androidx.compose.ui.graphics.Color +import androidx.compose.ui.graphics.graphicsLayer +import androidx.compose.ui.graphics.vector.ImageVector +import androidx.compose.ui.platform.LocalDensity +import androidx.compose.ui.text.font.FontWeight +import androidx.compose.ui.unit.Dp +import androidx.compose.ui.unit.dp +import androidx.compose.ui.unit.sp +import hr.bela.engine.Suit + +private val ButtonShape = RoundedCornerShape(16.dp) + +/** How far from the physical top edge top-centre content must start to clear a punch-hole camera. */ +private val CameraZoneBottom = 66.dp + +/** + * Extra top space for screens whose top bar holds content in the centre, so a punch-hole camera never covers it. + * Many phones (and emulators) do not report the hole, so this does not rely on the cutout insets alone: + * it tops up whatever the system insets already give to [CameraZoneBottom]. + */ +@Composable +fun cameraClearance(): Dp { + val top = with(LocalDensity.current) { WindowInsets.safeDrawing.getTop(this).toDp() } + return (CameraZoneBottom - top).coerceAtLeast(0.dp) +} + +/** Shrinks slightly while pressed. */ +@Composable +private fun pressScale(interaction: MutableInteractionSource): Float { + val pressed by interaction.collectIsPressedAsState() + val scale by animateFloatAsState(if (pressed) 0.97f else 1f, tween(120), label = "press") + return scale +} + +/** Main call to action: polished gold, engraved capitals. */ +@Composable +fun GoldButton(text: String, onClick: () -> Unit, modifier: Modifier = Modifier) { + val interaction = remember { MutableInteractionSource() } + val scale = pressScale(interaction) + Box( + modifier + .fillMaxWidth() + .height(54.dp) + .graphicsLayer { + scaleX = scale + scaleY = scale + } + .shadow(12.dp, ButtonShape, ambientColor = GoldDeep, spotColor = GoldDeep) + .clip(ButtonShape) + .background(GoldVertical) + .border(1.dp, Brush.verticalGradient(listOf(Color(0xFFFFF6D2), Color(0x00FFF6D2))), ButtonShape) + .clickable(interaction, ripple(color = Ink), onClick = onClick), + contentAlignment = Alignment.Center, + ) { + Text(text.uppercase(), color = Ink, fontFamily = Cinzel, fontWeight = FontWeight.Bold, fontSize = 15.sp, letterSpacing = 1.5.sp) + } +} + +/** Secondary action: smoked glass with a faint edge. */ +@Composable +fun GlassButton(text: String, onClick: () -> Unit, modifier: Modifier = Modifier, enabled: Boolean = true) { + val interaction = remember { MutableInteractionSource() } + val scale = pressScale(interaction) + Box( + modifier + .fillMaxWidth() + .height(50.dp) + .graphicsLayer { + scaleX = scale + scaleY = scale + } + .clip(ButtonShape) + .background(Glass) + .border(1.dp, if (enabled) Cream.copy(alpha = 0.3f) else CreamFaint, ButtonShape) + .clickable(interaction, ripple(color = Cream), enabled = enabled, onClick = onClick), + contentAlignment = Alignment.Center, + ) { + Text( + text.uppercase(), + color = if (enabled) Cream else CreamMuted, + fontFamily = Cinzel, + fontWeight = FontWeight.SemiBold, + fontSize = 14.sp, + letterSpacing = 1.5.sp, + ) + } +} + +/** Round glass button holding a line icon. */ +@Composable +fun GlassIconButton(icon: ImageVector, description: String, onClick: () -> Unit, modifier: Modifier = Modifier, tint: Color = Cream) { + val interaction = remember { MutableInteractionSource() } + val scale = pressScale(interaction) + Box( + modifier + .size(42.dp) + .graphicsLayer { + scaleX = scale + scaleY = scale + } + .clip(CircleShape) + .background(Glass) + .border(1.dp, CreamFaint, CircleShape) + .clickable(interaction, ripple(color = Cream), onClick = onClick), + contentAlignment = Alignment.Center, + ) { + Icon(icon, contentDescription = description, tint = tint, modifier = Modifier.size(20.dp)) + } +} + +/** A small gold diamond. */ +@Composable +fun Diamond(size: Dp = 6.dp, modifier: Modifier = Modifier) { + Box(modifier.size(size).rotate(45f).background(GoldBrush)) +} + +/** Hairline — diamond — hairline, the divider used under titles. */ +@Composable +fun Ornament(modifier: Modifier = Modifier, lineWidth: Dp = 44.dp) { + Row(modifier, verticalAlignment = Alignment.CenterVertically) { + Box(Modifier.width(lineWidth).height(1.dp).background(Brush.horizontalGradient(listOf(Color.Transparent, Gold)))) + Spacer(Modifier.width(8.dp)) + Diamond() + Spacer(Modifier.width(8.dp)) + Box(Modifier.width(lineWidth).height(1.dp).background(Brush.horizontalGradient(listOf(Gold, Color.Transparent)))) + } +} + +/** Spaced small capitals used for labels ("ADUT", "RUKA 3"). */ +@Composable +fun Overline(text: String, modifier: Modifier = Modifier, color: Color = CreamMuted) { + Text( + text.uppercase(), + modifier = modifier, + color = color, + fontFamily = Cinzel, + fontWeight = FontWeight.Bold, + fontSize = 11.sp, + letterSpacing = 2.5.sp, + ) +} + +/** A suit on a cream coin with a gold rim; an empty glass rim with "?" when [suit] is null. */ +@Composable +fun SuitMedallion(suit: Suit?, size: Dp, modifier: Modifier = Modifier) { + Box( + modifier + .size(size) + .shadow(if (suit != null) 8.dp else 0.dp, CircleShape) + .clip(CircleShape) + .background( + if (suit != null) { + Brush.radialGradient(listOf(Color(0xFFFFFDF6), Color(0xFFE8E0C8))) + } else { + Brush.radialGradient(listOf(Glass, Glass)) + }, + ) + .border(size * 0.05f, if (suit != null) GoldBrush else Brush.linearGradient(listOf(CreamFaint, CreamFaint)), CircleShape), + contentAlignment = Alignment.Center, + ) { + if (suit != null) { + SuitIcon(suit, size * 0.62f) + } else { + Text("?", color = CreamMuted, fontFamily = Cinzel, fontWeight = FontWeight.Bold, fontSize = 18.sp) + } + } +} + +/** Name in a small smoked-glass capsule. */ +@Composable +fun NamePlate(name: String, modifier: Modifier = Modifier) { + Box( + modifier + .clip(RoundedCornerShape(50)) + .background(Glass) + .border(1.dp, CreamFaint, RoundedCornerShape(50)) + .padding(horizontal = 10.dp, vertical = 2.dp), + ) { + Text(name, color = Cream, fontSize = 12.sp, fontWeight = FontWeight.SemiBold) + } +} diff --git a/app/src/main/kotlin/hr/bela/app/ui/Dialogs.kt b/app/src/main/kotlin/hr/bela/app/ui/Dialogs.kt new file mode 100644 index 0000000..a46cceb --- /dev/null +++ b/app/src/main/kotlin/hr/bela/app/ui/Dialogs.kt @@ -0,0 +1,277 @@ +package hr.bela.app.ui + +import androidx.compose.foundation.background +import androidx.compose.foundation.border +import androidx.compose.foundation.layout.Arrangement +import androidx.compose.foundation.layout.Box +import androidx.compose.foundation.layout.Column +import androidx.compose.foundation.layout.ColumnScope +import androidx.compose.foundation.layout.Row +import androidx.compose.foundation.layout.Spacer +import androidx.compose.foundation.layout.fillMaxWidth +import androidx.compose.foundation.layout.height +import androidx.compose.foundation.layout.heightIn +import androidx.compose.foundation.layout.padding +import androidx.compose.foundation.layout.width +import androidx.compose.foundation.lazy.LazyColumn +import androidx.compose.foundation.lazy.itemsIndexed +import androidx.compose.foundation.shape.RoundedCornerShape +import androidx.compose.material3.Text +import androidx.compose.runtime.Composable +import androidx.compose.ui.Alignment +import androidx.compose.ui.Modifier +import androidx.compose.ui.draw.clip +import androidx.compose.ui.draw.shadow +import androidx.compose.ui.graphics.Brush +import androidx.compose.ui.graphics.Color +import androidx.compose.ui.text.TextStyle +import androidx.compose.ui.text.font.FontWeight +import androidx.compose.ui.text.style.TextAlign +import androidx.compose.ui.unit.dp +import androidx.compose.ui.unit.sp +import androidx.compose.ui.window.Dialog +import androidx.compose.ui.window.DialogProperties +import hr.bela.app.HUMAN +import hr.bela.engine.GameState +import hr.bela.engine.HandResult +import hr.bela.engine.Outcome +import hr.bela.engine.Suit +import hr.bela.engine.points + +private val Tabular = TextStyle(fontFeatureSettings = "tnum") +private val DialogShape = RoundedCornerShape(28.dp) + +/** The app's dialog frame: deep green with a polished gold edge. Content is centred. */ +@Composable +private fun BelaDialog(onDismiss: () -> Unit, dismissable: Boolean = true, content: @Composable ColumnScope.() -> Unit) { + Dialog( + onDismissRequest = { if (dismissable) onDismiss() }, + properties = DialogProperties(dismissOnBackPress = dismissable, dismissOnClickOutside = dismissable), + ) { + Column( + Modifier + .fillMaxWidth() + .shadow(24.dp, DialogShape) + .clip(DialogShape) + .background(DialogBrush) + .border(1.dp, GoldBrush, DialogShape) + .padding(horizontal = 24.dp, vertical = 24.dp), + horizontalAlignment = Alignment.CenterHorizontally, + content = content, + ) + } +} + +/** Overline, ornament and a title in Cinzel: the head of every dialog. */ +@Composable +private fun DialogHeader(overline: String?, title: String, titleColor: Color = Cream, titleBrush: Brush? = null) { + if (overline != null) Overline(overline) + Text( + title, + color = titleColor, + style = if (titleBrush != null) TextStyle(brush = titleBrush) else TextStyle.Default, + fontFamily = Cinzel, + fontWeight = FontWeight.Bold, + fontSize = 32.sp, + textAlign = TextAlign.Center, + modifier = Modifier.padding(top = 2.dp), + ) + Ornament(Modifier.padding(top = 6.dp, bottom = 14.dp)) +} + +/** A row of the score tables: label (optionally followed by a suit icon and [trailing] text), then Mi and Vi. */ +@Composable +private fun ScoreLine( + label: String, + mi: String, + vi: String, + strong: Boolean = false, + header: Boolean = false, + suit: Suit? = null, + trailing: String = "", +) { + val weight = if (strong) FontWeight.Bold else FontWeight.Normal + val color = if (header) CreamMuted else Cream + val size = if (strong) 16.sp else 14.sp + val numberStyle = if (header) { + TextStyle(fontFamily = Cinzel, fontWeight = FontWeight.Bold, fontSize = 11.sp, letterSpacing = 2.sp) + } else { + Tabular.copy(fontWeight = weight, fontSize = size) + } + Row(Modifier.fillMaxWidth().padding(vertical = 3.dp), verticalAlignment = Alignment.CenterVertically) { + Row(Modifier.weight(1f), verticalAlignment = Alignment.CenterVertically) { + Text(label, color = color, fontWeight = weight, fontSize = size) + suit?.let { + Spacer(Modifier.width(6.dp)) + SuitIcon(it, 16.dp) + } + if (trailing.isNotEmpty()) Text(trailing, color = CreamMuted, fontSize = 13.sp) + } + Text(mi, Modifier.width(60.dp), color = color, textAlign = TextAlign.End, style = numberStyle) + Text(vi, Modifier.width(60.dp), color = color, textAlign = TextAlign.End, style = numberStyle) + } +} + +@Composable +private fun ScoreLine(label: String, values: List, strong: Boolean = false, suit: Suit? = null, trailing: String = "") = + ScoreLine(label, values[0].toString(), values[1].toString(), strong = strong, suit = suit, trailing = trailing) + +@Composable +private fun Rule() { + Box( + Modifier + .fillMaxWidth() + .padding(vertical = 6.dp) + .height(1.dp) + .background(Brush.horizontalGradient(listOf(Color.Transparent, Gold.copy(alpha = 0.45f), Color.Transparent))), + ) +} + +@Composable +fun HandResultDialog(game: GameState, result: HandResult, onNextHand: () -> Unit) { + val we = result.callerTeam == 0 + val (headline, color) = when (result.outcome) { + Outcome.PASSED -> "Prolaz" to (if (we) WinGreen else LossRed) + Outcome.FELL -> "Pad" to (if (we) LossRed else WinGreen) + Outcome.TIED -> "Visi" to Gold + } + BelaDialog(onDismiss = {}, dismissable = false) { + DialogHeader("Ruka ${game.results.size}", headline, titleColor = color) + Row(verticalAlignment = Alignment.CenterVertically) { + Text(if (result.caller == HUMAN) "Zvao si" else "${seatName(result.caller)} je zvao", color = Cream, fontSize = 14.sp) + Spacer(Modifier.width(6.dp)) + SuitIcon(result.trump, 18.dp) + Text(" ${suitName(result.trump)}", color = Cream, fontSize = 14.sp, fontWeight = FontWeight.SemiBold) + } + Text( + when (result.outcome) { + Outcome.PASSED -> if (we) "Prošli smo s više od pola bodova." else "Protivnici su prošli s više od pola bodova." + Outcome.FELL -> if (we) "Pali smo: svi bodovi idu protivnicima." else "Protivnici su pali: svi bodovi idu nama." + Outcome.TIED -> if (we) "Izjednačeno: naši bodovi vise do sljedeće ruke." else "Izjednačeno: bodovi protivnika vise do sljedeće ruke." + }, + color = CreamMuted, + fontSize = 13.sp, + textAlign = TextAlign.Center, + modifier = Modifier.padding(top = 4.dp, bottom = 14.dp), + ) + ScoreLine("", "MI", "VI", header = true) + ScoreLine("Karte i zadnji štih", result.cardPoints) + ScoreLine("Zvanja", result.declarationPoints) + ScoreLine("Bela", result.belaPoints) + if (result.stigljaPoints.sum() > 0) ScoreLine("Štiglja", result.stigljaPoints) + Rule() + ScoreLine("Upisano", result.awarded, strong = true) + if (result.settledHanging > 0) { + Text("Uključeno ${pointsText(result.settledHanging)} koji su visjeli.", color = CreamMuted, fontSize = 12.sp) + } + Rule() + ScoreLine("Stanje", game.scores, strong = true) + Spacer(Modifier.height(20.dp)) + GoldButton("Sljedeća ruka", onNextHand) + } +} + +@Composable +fun GameOverDialog(game: GameState, onNewGame: () -> Unit, onLeave: () -> Unit) { + val won = game.winnerTeam == 0 + BelaDialog(onDismiss = {}, dismissable = false) { + DialogHeader("Kraj partije", if (won) "Pobjeda" else "Poraz", titleBrush = if (won) GoldVertical else null) + game.belotSeat?.let { seat -> + Text( + if (seat == HUMAN) { + "Belot! Imaš svih 8 karata iste boje i odmah dobivate partiju." + } else { + "Belot! ${seatName(seat)} ima svih 8 karata iste boje i odmah dobiva partiju." + }, + color = Cream, + textAlign = TextAlign.Center, + modifier = Modifier.padding(bottom = 12.dp), + ) + } + Row(verticalAlignment = Alignment.CenterVertically) { + FinalScore("Mi", game.scores[0], won) + Diamond(7.dp, Modifier.padding(horizontal = 22.dp)) + FinalScore("Vi", game.scores[1], !won) + } + Text("Odigrano ruku: ${game.results.size}", color = CreamMuted, fontSize = 13.sp, modifier = Modifier.padding(top = 10.dp)) + Spacer(Modifier.height(22.dp)) + GoldButton("Nova partija", onNewGame) + Spacer(Modifier.height(10.dp)) + GlassButton("Izbornik", onLeave) + } +} + +@Composable +private fun FinalScore(label: String, score: Int, winner: Boolean) { + Column(horizontalAlignment = Alignment.CenterHorizontally) { + Overline(label) + Text( + "$score", + color = if (winner) Gold else Cream, + fontFamily = Cinzel, + fontWeight = FontWeight.Bold, + fontSize = 32.sp, + ) + } +} + +/** The "blok": what each hand wrote for both teams. */ +@Composable +fun ScoreSheetDialog(game: GameState, onDismiss: () -> Unit) { + BelaDialog(onDismiss = onDismiss) { + DialogHeader(null, "Blok") + ScoreLine("", "MI", "VI", header = true) + Rule() + if (game.results.isEmpty()) { + Text("Još nema odigranih ruku.", color = CreamMuted, modifier = Modifier.padding(vertical = 8.dp)) + } + LazyColumn(Modifier.heightIn(max = 340.dp)) { + itemsIndexed(game.results) { i, r -> + val mark = when (r.outcome) { + Outcome.PASSED -> "" + Outcome.FELL -> " pad" + Outcome.TIED -> " visi" + } + ScoreLine("${i + 1}. ${seatName(r.caller)}", r.awarded, suit = r.trump, trailing = mark) + } + } + Rule() + ScoreLine("Ukupno", game.scores, strong = true) + if (game.hanging > 0) Text("Visi: ${pointsText(game.hanging)}", color = Gold, fontSize = 13.sp) + Spacer(Modifier.height(18.dp)) + GlassButton("Zatvori", onDismiss) + } +} + +@Composable +fun LastTrickDialog(game: GameState, onDismiss: () -> Unit) { + val last = game.hand.tricks.lastOrNull() + val trump = game.hand.trump + if (last == null || trump == null) return + BelaDialog(onDismiss = onDismiss) { + DialogHeader(null, "Zadnji štih") + Row(horizontalArrangement = Arrangement.spacedBy(8.dp)) { + last.trick.cards.forEachIndexed { i, card -> + val seat = last.trick.seatAt(i) + Column(horizontalAlignment = Alignment.CenterHorizontally) { + CardFace(card, Modifier.width(60.dp), highlighted = seat == last.winner, elevation = 6.dp) + Text( + seatName(seat), + color = if (seat == last.winner) Gold else CreamMuted, + fontSize = 12.sp, + fontWeight = if (seat == last.winner) FontWeight.SemiBold else FontWeight.Normal, + modifier = Modifier.padding(top = 8.dp), + ) + } + } + } + Text( + "Štih nosi ${seatName(last.winner)} · ${pointsText(last.trick.points(trump))}", + color = Cream, + textAlign = TextAlign.Center, + modifier = Modifier.padding(top = 16.dp), + ) + Spacer(Modifier.height(18.dp)) + GlassButton("Zatvori", onDismiss) + } +} diff --git a/app/src/main/kotlin/hr/bela/app/ui/HomeScreen.kt b/app/src/main/kotlin/hr/bela/app/ui/HomeScreen.kt new file mode 100644 index 0000000..def3342 --- /dev/null +++ b/app/src/main/kotlin/hr/bela/app/ui/HomeScreen.kt @@ -0,0 +1,99 @@ +package hr.bela.app.ui + +import androidx.compose.animation.core.RepeatMode +import androidx.compose.animation.core.animateFloat +import androidx.compose.animation.core.infiniteRepeatable +import androidx.compose.animation.core.rememberInfiniteTransition +import androidx.compose.animation.core.tween +import androidx.compose.foundation.Image +import androidx.compose.foundation.border +import androidx.compose.foundation.layout.Box +import androidx.compose.foundation.layout.BoxWithConstraints +import androidx.compose.foundation.layout.Column +import androidx.compose.foundation.layout.Spacer +import androidx.compose.foundation.layout.fillMaxSize +import androidx.compose.foundation.layout.fillMaxWidth +import androidx.compose.foundation.layout.height +import androidx.compose.foundation.layout.padding +import androidx.compose.foundation.layout.safeDrawingPadding +import androidx.compose.foundation.layout.size +import androidx.compose.foundation.shape.RoundedCornerShape +import androidx.compose.material3.Text +import androidx.compose.runtime.Composable +import androidx.compose.runtime.getValue +import androidx.compose.ui.Alignment +import androidx.compose.ui.Modifier +import androidx.compose.ui.draw.clip +import androidx.compose.ui.draw.shadow +import androidx.compose.ui.graphics.FilterQuality +import androidx.compose.ui.graphics.ImageBitmap +import androidx.compose.ui.graphics.graphicsLayer +import androidx.compose.ui.res.imageResource +import androidx.compose.ui.text.style.TextAlign +import androidx.compose.ui.unit.dp +import androidx.compose.ui.unit.sp +import hr.bela.app.R + +@Composable +fun HomeScreen( + hasSavedGame: Boolean, + onContinue: () -> Unit, + onNewGame: () -> Unit, + onTraining: () -> Unit, + onSettings: () -> Unit, +) { + Box(Modifier.fillMaxSize().feltBackground().safeDrawingPadding().padding(horizontal = 28.dp, vertical = 24.dp)) { + GlassIconButton(BelaIcons.Settings, "Postavke", onSettings, Modifier.align(Alignment.TopEnd)) + Column( + Modifier.align(Alignment.Center).fillMaxWidth(), + horizontalAlignment = Alignment.CenterHorizontally, + ) { + Logo() + Ornament(Modifier.padding(top = 22.dp, bottom = 10.dp), lineWidth = 60.dp) + Overline("Ti i partner protiv računala") + Spacer(Modifier.height(40.dp)) + if (hasSavedGame) { + GoldButton("Nastavi partiju", onContinue) + Spacer(Modifier.height(12.dp)) + GlassButton("Nova partija", onNewGame) + } else { + GoldButton("Nova partija", onNewGame) + } + Spacer(Modifier.height(12.dp)) + GlassButton("Trening brojanja", onTraining) + } + Text( + "Do 1001 · štiglja 90 · obvezno pobijanje", + color = CreamMuted, + fontSize = 12.sp, + textAlign = TextAlign.Center, + modifier = Modifier.align(Alignment.BottomCenter).fillMaxWidth(), + ) + } +} + +/** The app's logo (icon.png) as a gold-edged tile, floating gently. */ +@Composable +private fun Logo() { + val float by rememberInfiniteTransition(label = "logo").animateFloat( + initialValue = 0f, + targetValue = 1f, + animationSpec = infiniteRepeatable(tween(2800), RepeatMode.Reverse), + label = "float", + ) + BoxWithConstraints(Modifier.fillMaxWidth(), contentAlignment = Alignment.Center) { + val size = minOf(240.dp, maxWidth * 0.66f) + val shape = RoundedCornerShape(22) + Image( + bitmap = ImageBitmap.imageResource(R.drawable.logo), + contentDescription = "Bela", + filterQuality = FilterQuality.High, + modifier = Modifier + .size(size) + .graphicsLayer { translationY = -4.dp.toPx() * float } + .shadow(22.dp, shape, spotColor = GoldDeep) + .clip(shape) + .border(1.5.dp, GoldBrush, shape), + ) + } +} diff --git a/app/src/main/kotlin/hr/bela/app/ui/Icons.kt b/app/src/main/kotlin/hr/bela/app/ui/Icons.kt new file mode 100644 index 0000000..2a99d4d --- /dev/null +++ b/app/src/main/kotlin/hr/bela/app/ui/Icons.kt @@ -0,0 +1,63 @@ +package hr.bela.app.ui + +import androidx.compose.ui.graphics.Color +import androidx.compose.ui.graphics.SolidColor +import androidx.compose.ui.graphics.StrokeCap +import androidx.compose.ui.graphics.StrokeJoin +import androidx.compose.ui.graphics.vector.ImageVector +import androidx.compose.ui.graphics.vector.addPathNodes +import androidx.compose.ui.unit.dp + +/** A few line icons (24 x 24, 2 px stroke), drawn here so the app needs no icon library. Tint them with Icon(tint = …). */ +object BelaIcons { + val Back: ImageVector = strokeIcon("back", "M15 18l-6-6 6-6") + + val ScoreSheet: ImageVector = strokeIcon( + "score_sheet", + "M8 3h8a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H8a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z", + "M9.5 8h5", + "M9.5 12h5", + "M9.5 16h3", + ) + + val LastTrick: ImageVector = strokeIcon( + "last_trick", + "M3 12a9 9 0 1 0 2.64-6.36", + "M3 4v5h5", + "M12 8v4l3 2", + ) + + /** A gear: ring, hub and eight teeth. */ + val Settings: ImageVector = strokeIcon( + "settings", + "M12 5.5a6.5 6.5 0 1 0 0 13a6.5 6.5 0 1 0 0-13z", + "M12 9.5a2.5 2.5 0 1 0 0 5a2.5 2.5 0 1 0 0-5z", + "M12 2.5v3", "M12 18.5v3", "M2.5 12h3", "M18.5 12h3", + "M5.3 5.3l2.1 2.1", "M16.6 16.6l2.1 2.1", "M18.7 5.3l-2.1 2.1", "M5.3 18.7l2.1-2.1", + ) + + val Download: ImageVector = strokeIcon("download", "M12 3v12", "M7 10l5 5 5-5", "M5 21h14") + + val Share: ImageVector = strokeIcon( + "share", + "M18 2.5a3 3 0 1 0 0 6a3 3 0 1 0 0-6z", + "M6 9a3 3 0 1 0 0 6a3 3 0 1 0 0-6z", + "M18 15.5a3 3 0 1 0 0 6a3 3 0 1 0 0-6z", + "M8.6 13.5l6.8 4", "M15.4 6.5l-6.8 4", + ) + + val External: ImageVector = strokeIcon("external", "M14 4h6v6", "M20 4l-9 9", "M18 14v5a1 1 0 0 1-1 1H5a1 1 0 0 1-1-1V7a1 1 0 0 1 1-1h5") + + private fun strokeIcon(name: String, vararg paths: String): ImageVector = + ImageVector.Builder(name, 24.dp, 24.dp, 24f, 24f).apply { + paths.forEach { d -> + addPath( + pathData = addPathNodes(d), + stroke = SolidColor(Color.White), + strokeLineWidth = 2f, + strokeLineCap = StrokeCap.Round, + strokeLineJoin = StrokeJoin.Round, + ) + } + }.build() +} diff --git a/app/src/main/kotlin/hr/bela/app/ui/SettingsScreen.kt b/app/src/main/kotlin/hr/bela/app/ui/SettingsScreen.kt new file mode 100644 index 0000000..ef33d35 --- /dev/null +++ b/app/src/main/kotlin/hr/bela/app/ui/SettingsScreen.kt @@ -0,0 +1,308 @@ +package hr.bela.app.ui + +import android.content.Intent +import android.net.Uri +import androidx.activity.compose.BackHandler +import androidx.compose.foundation.Canvas +import androidx.compose.foundation.Image +import androidx.compose.foundation.background +import androidx.compose.foundation.border +import androidx.compose.foundation.clickable +import androidx.compose.foundation.layout.Arrangement +import androidx.compose.foundation.layout.Box +import androidx.compose.foundation.layout.Column +import androidx.compose.foundation.layout.ColumnScope +import androidx.compose.foundation.layout.Row +import androidx.compose.foundation.layout.Spacer +import androidx.compose.foundation.layout.aspectRatio +import androidx.compose.foundation.layout.fillMaxHeight +import androidx.compose.foundation.layout.fillMaxSize +import androidx.compose.foundation.layout.fillMaxWidth +import androidx.compose.foundation.layout.height +import androidx.compose.foundation.layout.padding +import androidx.compose.foundation.layout.safeDrawingPadding +import androidx.compose.foundation.layout.size +import androidx.compose.foundation.layout.width +import androidx.compose.foundation.rememberScrollState +import androidx.compose.foundation.shape.RoundedCornerShape +import androidx.compose.foundation.verticalScroll +import androidx.compose.material3.Text +import androidx.compose.runtime.Composable +import androidx.compose.runtime.getValue +import androidx.compose.runtime.remember +import androidx.compose.ui.Alignment +import androidx.compose.ui.Modifier +import androidx.compose.ui.draw.clip +import androidx.compose.ui.draw.shadow +import androidx.compose.ui.geometry.Offset +import androidx.compose.ui.geometry.Size +import androidx.compose.ui.graphics.Color +import androidx.compose.ui.graphics.FilterQuality +import androidx.compose.ui.graphics.ImageBitmap +import androidx.compose.ui.platform.LocalContext +import androidx.compose.ui.res.imageResource +import androidx.compose.ui.text.font.FontWeight +import androidx.compose.ui.text.style.TextAlign +import androidx.compose.ui.unit.dp +import androidx.compose.ui.unit.sp +import androidx.lifecycle.Lifecycle +import androidx.lifecycle.compose.LifecycleEventEffect +import androidx.lifecycle.compose.collectAsStateWithLifecycle +import androidx.lifecycle.viewmodel.compose.viewModel +import com.google.zxing.BarcodeFormat +import com.google.zxing.EncodeHintType +import com.google.zxing.qrcode.QRCodeWriter +import com.google.zxing.qrcode.decoder.ErrorCorrectionLevel +import hr.bela.app.BuildConfig +import hr.bela.app.R +import hr.bela.app.SettingsViewModel +import hr.bela.app.UpdateState +import hr.bela.app.update.ReleaseChannel + +/** Settings: about the app, updating it, and a QR code that shares the newest APK. */ +@Composable +fun SettingsScreen(onExit: () -> Unit, vm: SettingsViewModel = viewModel()) { + val update by vm.update.collectAsStateWithLifecycle() + val context = LocalContext.current + BackHandler(onBack = onExit) + LifecycleEventEffect(Lifecycle.Event.ON_RESUME) { vm.onResume() } + + fun open(url: String) = runCatching { context.startActivity(Intent(Intent.ACTION_VIEW, Uri.parse(url))) } + + Box(Modifier.fillMaxSize().feltBackground()) { + Column(Modifier.fillMaxSize().safeDrawingPadding().padding(horizontal = 16.dp)) { + Box(Modifier.fillMaxWidth().padding(top = cameraClearance()).height(68.dp)) { + GlassIconButton(BelaIcons.Back, "Natrag", onExit, Modifier.align(Alignment.CenterStart)) + Column(Modifier.align(Alignment.Center), horizontalAlignment = Alignment.CenterHorizontally) { + Overline("Bela", color = Gold) + Text("Postavke", color = Cream, fontFamily = Cinzel, fontWeight = FontWeight.Bold, fontSize = 22.sp) + } + } + Column( + Modifier.fillMaxSize().verticalScroll(rememberScrollState()).padding(top = 8.dp, bottom = 24.dp), + verticalArrangement = Arrangement.spacedBy(14.dp), + ) { + AboutSection() + Section("Ažuriranje") { UpdateSection(update, vm, open = ::open) } + Section("Podijeli aplikaciju") { ShareSection(open = ::open) } + CreditsSection(open = ::open) + } + } + } +} + +/** A titled glass panel with a gold hairline edge. */ +@Composable +private fun Section(title: String, content: @Composable ColumnScope.() -> Unit) { + val shape = RoundedCornerShape(22.dp) + Column( + Modifier + .fillMaxWidth() + .clip(shape) + .background(Glass) + .border(1.dp, GoldBrush, shape) + .padding(18.dp), + horizontalAlignment = Alignment.CenterHorizontally, + ) { + Overline(title, color = Gold) + Ornament(Modifier.padding(top = 6.dp, bottom = 14.dp), lineWidth = 30.dp) + content() + } +} + +@Composable +private fun AboutSection() { + Section("O aplikaciji") { + Row(Modifier.fillMaxWidth(), verticalAlignment = Alignment.CenterVertically) { + val shape = RoundedCornerShape(22) + Image( + bitmap = ImageBitmap.imageResource(R.drawable.logo), + contentDescription = "Bela", + filterQuality = FilterQuality.High, + modifier = Modifier.size(72.dp).shadow(8.dp, shape).clip(shape).border(1.dp, GoldBrush, shape), + ) + Spacer(Modifier.width(14.dp)) + Column { + Text("Bela", color = Cream, fontFamily = Cinzel, fontWeight = FontWeight.Bold, fontSize = 24.sp) + Text( + "Verzija ${BuildConfig.VERSION_NAME} (${BuildConfig.VERSION_CODE})", + color = CreamMuted, + fontSize = 13.sp, + ) + } + } + Text( + "Hrvatska Bela za četvero: ti i partner protiv računala, do 1001. " + + "Uz partiju tu je i trening brojanja karata.", + color = Cream, + fontSize = 14.sp, + modifier = Modifier.fillMaxWidth().padding(top = 14.dp), + ) + Text( + "Pravila: do 1001 · štiglja 90 · djelitelj mora zvati · obvezno pobijanje · belot dobiva partiju.", + color = CreamMuted, + fontSize = 12.sp, + modifier = Modifier.fillMaxWidth().padding(top = 8.dp), + ) + } +} + +@Composable +private fun UpdateSection(update: UpdateState, vm: SettingsViewModel, open: (String) -> Unit) { + val status = when (update) { + UpdateState.Checking -> "Provjeravam ima li nova verzija…" + is UpdateState.UpToDate -> "Imaš najnoviju verziju (${update.latest})." + UpdateState.NoReleases -> "Još nema objavljenih verzija." + is UpdateState.Available -> "Dostupna je nova verzija ${update.release.versionName}." + is UpdateState.Downloading -> "Preuzimam verziju ${update.release.versionName}…" + is UpdateState.NeedsPermission -> + "Za instalaciju dopusti Beli instaliranje aplikacija (\"Instaliranje nepoznatih aplikacija\"), pa se vrati ovamo." + is UpdateState.Installing -> "Potvrdi instalaciju verzije ${update.release.versionName}." + is UpdateState.Failed -> update.message + } + Text( + status, + color = if (update is UpdateState.Failed) LossRed else Cream, + fontSize = 14.sp, + textAlign = TextAlign.Center, + modifier = Modifier.fillMaxWidth(), + ) + if (update is UpdateState.Available) { + update.release.notes?.let { + Text(it, color = CreamMuted, fontSize = 12.sp, textAlign = TextAlign.Center, modifier = Modifier.fillMaxWidth().padding(top = 6.dp)) + } + } + if (update is UpdateState.Downloading) { + Box(Modifier.padding(top = 12.dp).fillMaxWidth().height(6.dp).clip(RoundedCornerShape(3.dp)).background(CreamFaint)) { + if (update.progress >= 0f) Box(Modifier.fillMaxHeight().fillMaxWidth(update.progress).background(GoldBrush)) + } + } + Spacer(Modifier.height(14.dp)) + when (update) { + is UpdateState.Available -> GoldButton("Preuzmi i instaliraj", { vm.download(update.release) }) + is UpdateState.NeedsPermission -> GoldButton("Dopusti instalaciju", vm::openInstallPermission) + is UpdateState.Installing -> GlassButton("Ponovno otvori instalaciju", { vm.install(update.release, update.apk) }) + is UpdateState.Downloading, UpdateState.Checking -> Unit + else -> GlassButton("Provjeri ponovno", vm::check) + } + Spacer(Modifier.height(10.dp)) + LinkRow("Sva izdanja", BelaIcons.External) { open(ReleaseChannel.RELEASES_PAGE) } +} + +@Composable +private fun ShareSection(open: (String) -> Unit) { + val context = LocalContext.current + Text( + "Skeniraj kod mobitelom za preuzimanje najnovije verzije.", + color = Cream, + fontSize = 14.sp, + textAlign = TextAlign.Center, + modifier = Modifier.fillMaxWidth(), + ) + Spacer(Modifier.height(14.dp)) + QrCode(ReleaseChannel.LATEST_APK_URL, Modifier.width(220.dp)) + Spacer(Modifier.height(16.dp)) + GlassButton("Podijeli poveznicu", { + val send = Intent(Intent.ACTION_SEND) + .setType("text/plain") + .putExtra(Intent.EXTRA_SUBJECT, "Bela") + .putExtra(Intent.EXTRA_TEXT, "Igraj Belu sa mnom! Preuzmi aplikaciju: ${ReleaseChannel.LATEST_APK_URL}") + context.startActivity(Intent.createChooser(send, "Podijeli Belu")) + }) + Spacer(Modifier.height(10.dp)) + LinkRow("Preuzmi APK u pregledniku", BelaIcons.Download) { open(ReleaseChannel.LATEST_APK_URL) } +} + +@Composable +private fun CreditsSection(open: (String) -> Unit) { + Section("Zasluge") { + Credit("Karte", "Mađarske karte iz projekta tomasdrus/hungarian-playing-cards") { + open("https://github.com/tomasdrus/hungarian-playing-cards") + } + Credit("Fontovi", "Cinzel i Inter, SIL Open Font License 1.1") { open("https://openfontlicense.org") } + Credit("QR kod", "ZXing, Apache License 2.0") { open("https://github.com/zxing/zxing") } + } +} + +@Composable +private fun Credit(title: String, text: String, onClick: () -> Unit) { + Row( + Modifier + .fillMaxWidth() + .clip(RoundedCornerShape(12.dp)) + .clickable(onClick = onClick) + .padding(vertical = 6.dp), + verticalAlignment = Alignment.CenterVertically, + ) { + Column(Modifier.weight(1f)) { + Text(title, color = Gold, fontSize = 13.sp, fontWeight = FontWeight.SemiBold) + Text(text, color = CreamMuted, fontSize = 12.sp) + } + androidx.compose.material3.Icon(BelaIcons.External, contentDescription = null, tint = CreamMuted, modifier = Modifier.size(16.dp)) + } +} + +@Composable +private fun LinkRow(text: String, icon: androidx.compose.ui.graphics.vector.ImageVector, onClick: () -> Unit) { + Row( + Modifier.clip(RoundedCornerShape(50)).clickable(onClick = onClick).padding(horizontal = 12.dp, vertical = 8.dp), + verticalAlignment = Alignment.CenterVertically, + ) { + androidx.compose.material3.Icon(icon, contentDescription = null, tint = Gold, modifier = Modifier.size(16.dp)) + Spacer(Modifier.width(8.dp)) + Text(text, color = Gold, fontSize = 13.sp, fontWeight = FontWeight.SemiBold) + } +} + +/** + * QR code for [text] on a white tile, with the app icon in the middle. Error correction level H lets + * the code lose up to ~30% of its modules, so the small logo does not stop it from scanning. + */ +@Composable +fun QrCode(text: String, modifier: Modifier = Modifier) { + val matrix = remember(text) { + QRCodeWriter().encode( + text, + BarcodeFormat.QR_CODE, + 0, + 0, + mapOf(EncodeHintType.ERROR_CORRECTION to ErrorCorrectionLevel.H, EncodeHintType.MARGIN to 0), + ) + } + val shape = RoundedCornerShape(18.dp) + Box( + modifier + .aspectRatio(1f) + .shadow(12.dp, shape) + .clip(shape) + .background(Color.White) + .border(1.5.dp, GoldBrush, shape) + .padding(14.dp), + contentAlignment = Alignment.Center, + ) { + Canvas(Modifier.fillMaxSize()) { + val n = matrix.width + val cell = size.width / n + for (y in 0 until n) { + for (x in 0 until n) { + if (matrix[x, y]) { + // Slight overlap so neighbouring modules join without hairline gaps. + drawRect(Color(0xFF14261C), topLeft = Offset(x * cell, y * cell), size = Size(cell + 0.6f, cell + 0.6f)) + } + } + } + } + val logoShape = RoundedCornerShape(22) + Image( + bitmap = ImageBitmap.imageResource(R.drawable.logo), + contentDescription = null, + filterQuality = FilterQuality.High, + modifier = Modifier + .fillMaxWidth(0.22f) + .aspectRatio(1f) + .clip(logoShape) + .background(Color.White) + .border(3.dp, Color.White, logoShape), + ) + } +} diff --git a/app/src/main/kotlin/hr/bela/app/ui/TableScreen.kt b/app/src/main/kotlin/hr/bela/app/ui/TableScreen.kt new file mode 100644 index 0000000..ac90c07 --- /dev/null +++ b/app/src/main/kotlin/hr/bela/app/ui/TableScreen.kt @@ -0,0 +1,818 @@ +package hr.bela.app.ui + +import androidx.activity.compose.BackHandler +import androidx.compose.animation.core.Animatable +import androidx.compose.animation.core.FastOutSlowInEasing +import androidx.compose.animation.core.RepeatMode +import androidx.compose.animation.core.animateDpAsState +import androidx.compose.animation.core.animateFloat +import androidx.compose.animation.core.animateFloatAsState +import androidx.compose.animation.core.animateIntAsState +import androidx.compose.animation.core.infiniteRepeatable +import androidx.compose.animation.core.rememberInfiniteTransition +import androidx.compose.animation.core.tween +import androidx.compose.foundation.BorderStroke +import androidx.compose.foundation.Canvas +import androidx.compose.foundation.background +import androidx.compose.foundation.border +import androidx.compose.foundation.clickable +import androidx.compose.foundation.interaction.MutableInteractionSource +import androidx.compose.foundation.interaction.collectIsPressedAsState +import androidx.compose.foundation.layout.Arrangement +import androidx.compose.foundation.layout.Box +import androidx.compose.foundation.layout.BoxWithConstraints +import androidx.compose.foundation.layout.Column +import androidx.compose.foundation.layout.Row +import androidx.compose.foundation.layout.Spacer +import androidx.compose.foundation.layout.fillMaxHeight +import androidx.compose.foundation.layout.fillMaxSize +import androidx.compose.foundation.layout.fillMaxWidth +import androidx.compose.foundation.layout.height +import androidx.compose.foundation.layout.offset +import androidx.compose.foundation.layout.padding +import androidx.compose.foundation.layout.safeDrawingPadding +import androidx.compose.foundation.layout.size +import androidx.compose.foundation.layout.width +import androidx.compose.foundation.shape.CircleShape +import androidx.compose.foundation.shape.RoundedCornerShape +import androidx.compose.material3.Text +import androidx.compose.material3.ripple +import androidx.compose.runtime.Composable +import androidx.compose.runtime.LaunchedEffect +import androidx.compose.runtime.getValue +import androidx.compose.runtime.key +import androidx.compose.runtime.remember +import androidx.compose.ui.Alignment +import androidx.compose.ui.Modifier +import androidx.compose.ui.draw.clip +import androidx.compose.ui.draw.shadow +import androidx.compose.ui.geometry.CornerRadius +import androidx.compose.ui.geometry.Offset +import androidx.compose.ui.geometry.Size +import androidx.compose.ui.graphics.Brush +import androidx.compose.ui.graphics.Color +import androidx.compose.ui.graphics.TransformOrigin +import androidx.compose.ui.graphics.drawscope.Stroke +import androidx.compose.ui.graphics.graphicsLayer +import androidx.compose.ui.hapticfeedback.HapticFeedbackType +import androidx.compose.ui.platform.LocalHapticFeedback +import androidx.compose.ui.text.TextStyle +import androidx.compose.ui.text.font.FontWeight +import androidx.compose.ui.unit.Dp +import androidx.compose.ui.unit.DpOffset +import androidx.compose.ui.unit.dp +import androidx.compose.ui.unit.sp +import androidx.compose.ui.zIndex +import hr.bela.app.HUMAN +import hr.bela.app.UiState +import hr.bela.engine.Card +import hr.bela.engine.GameState +import hr.bela.engine.Phase +import hr.bela.engine.Rank +import hr.bela.engine.Suit +import hr.bela.engine.points +import hr.bela.engine.teamOf +import kotlinx.coroutines.delay +import kotlin.math.sin + +/** Width of the left and right player columns. */ +private val SideColumnWidth = 70.dp + +@Composable +fun TableScreen( + state: UiState, + onCall: (Suit?) -> Unit, + onPlay: (Card) -> Unit, + onNextHand: () -> Unit, + onNewGame: () -> Unit, + onLeave: () -> Unit, + onScoreSheet: (Boolean) -> Unit, + onLastTrick: (Boolean) -> Unit, +) { + val game = state.game ?: return + BackHandler(onBack = onLeave) + + Box(Modifier.fillMaxSize().feltBackground()) { + Column(Modifier.fillMaxSize().safeDrawingPadding()) { + TopBar(game, onLeave = onLeave, onScoreSheet = { onScoreSheet(true) }) + InfoChips(game, onLastTrick = { onLastTrick(true) }) + BoxWithConstraints(Modifier.weight(1f).fillMaxWidth().padding(horizontal = 6.dp)) { + val cardWidth = minOf( + minOf(96.dp, maxCardWidth()), + (maxWidth - SideColumnWidth * 2 - 8.dp) / 2.9f, + (maxHeight - 150.dp) / 2.2f * CARD_ASPECT, + ) + TableMarkings(ringWidth = maxWidth - SideColumnWidth * 2 + 4.dp, ringHeight = cardWidth / CARD_ASPECT * 2.25f) + PartnerSeat(game, state, Modifier.align(Alignment.TopCenter)) + SideSeat(game, state, seat = 3, modifier = Modifier.align(Alignment.CenterStart)) + SideSeat(game, state, seat = 1, modifier = Modifier.align(Alignment.CenterEnd)) + TrickArea(game, state, cardWidth, Modifier.align(Alignment.Center)) + val bidding = game.phase == Phase.BIDDING && game.toAct == HUMAN + Column(Modifier.align(Alignment.BottomCenter), horizontalAlignment = Alignment.CenterHorizontally) { + DeclarationBanner(game) + if (!bidding) MySeat(game, state) + } + if (bidding) BiddingPanel(game.canPass(HUMAN), onCall, Modifier.align(Alignment.BottomCenter)) + } + HandRow(game, state, onPlay) + } + + if (state.shownTrick == null) { + when (game.phase) { + Phase.HAND_OVER -> game.lastResult?.let { HandResultDialog(game, it, onNextHand) } + Phase.GAME_OVER -> GameOverDialog(game, onNewGame = onNewGame, onLeave = onLeave) + else -> Unit + } + } + if (state.showScoreSheet) ScoreSheetDialog(game, onDismiss = { onScoreSheet(false) }) + if (state.showLastTrick) LastTrickDialog(game, onDismiss = { onLastTrick(false) }) + } +} + +// ---------------------------------------------------------------- top + +@Composable +private fun TopBar(game: GameState, onLeave: () -> Unit, onScoreSheet: () -> Unit) { + Box(Modifier.fillMaxWidth().padding(top = cameraClearance()).height(76.dp).padding(horizontal = 12.dp)) { + GlassIconButton(BelaIcons.Back, "Izbornik", onLeave, Modifier.align(Alignment.CenterStart)) + Scoreboard(game, Modifier.align(Alignment.Center)) + Row(Modifier.align(Alignment.CenterEnd), verticalAlignment = Alignment.CenterVertically) { + TrumpMedallion(game.hand.trump) + Spacer(Modifier.width(8.dp)) + GlassIconButton(BelaIcons.ScoreSheet, "Blok", onScoreSheet) + } + } +} + +/** MI and VI with a thin bar showing how far each team is towards the target. */ +@Composable +private fun Scoreboard(game: GameState, modifier: Modifier) { + val shape = RoundedCornerShape(20.dp) + Row( + modifier + .shadow(10.dp, shape) + .clip(shape) + .background(Brush.verticalGradient(listOf(Color(0xCC0B2016), Color(0xE6061510)))) + .border(1.dp, GoldBrush, shape) + .padding(horizontal = 16.dp, vertical = 6.dp), + verticalAlignment = Alignment.CenterVertically, + ) { + TeamScore("MI", game.scores[0], game.rules.targetScore, ours = true, leading = game.scores[0] > game.scores[1]) + Column(Modifier.padding(horizontal = 12.dp), horizontalAlignment = Alignment.CenterHorizontally) { + Diamond(5.dp) + Text( + "${game.rules.targetScore}", + color = CreamMuted, + fontFamily = Cinzel, + fontSize = 9.sp, + letterSpacing = 1.sp, + modifier = Modifier.padding(top = 4.dp), + ) + } + TeamScore("VI", game.scores[1], game.rules.targetScore, ours = false, leading = game.scores[1] > game.scores[0]) + } +} + +@Composable +private fun TeamScore(label: String, score: Int, target: Int, ours: Boolean, leading: Boolean) { + val shown by animateIntAsState(score, tween(durationMillis = 800), label = "score") + val progress by animateFloatAsState((score.toFloat() / target).coerceIn(0f, 1f), tween(800), label = "progress") + Column(horizontalAlignment = Alignment.CenterHorizontally, modifier = Modifier.width(58.dp)) { + Text(label, color = CreamMuted, fontFamily = Cinzel, fontWeight = FontWeight.Bold, fontSize = 10.sp, letterSpacing = 3.sp) + Text( + "$shown", + color = if (leading) Gold else Cream, + fontFamily = Cinzel, + fontWeight = FontWeight.Bold, + fontSize = 24.sp, + lineHeight = 26.sp, + ) + Box(Modifier.padding(top = 3.dp).width(52.dp).height(3.dp).clip(RoundedCornerShape(2.dp)).background(CreamFaint)) { + Box(Modifier.fillMaxHeight().fillMaxWidth(progress).background(if (ours) GoldBrush else SilverBrush)) + } + } +} + +@Composable +private fun TrumpMedallion(trump: Suit?) { + Column(horizontalAlignment = Alignment.CenterHorizontally) { + SuitMedallion(trump, 42.dp) + Text( + "ADUT", + color = if (trump != null) Gold else CreamMuted, + fontFamily = Cinzel, + fontWeight = FontWeight.Bold, + fontSize = 8.sp, + letterSpacing = 1.5.sp, + modifier = Modifier.padding(top = 2.dp), + ) + } +} + +@Composable +private fun InfoChip(label: String, value: String, valueColor: Color = Cream) { + Row( + Modifier + .clip(RoundedCornerShape(50)) + .background(Glass) + .border(1.dp, CreamFaint, RoundedCornerShape(50)) + .padding(horizontal = 10.dp, vertical = 3.dp), + verticalAlignment = Alignment.CenterVertically, + ) { + Text(label, color = CreamMuted, fontFamily = Cinzel, fontWeight = FontWeight.Bold, fontSize = 9.sp, letterSpacing = 1.5.sp) + Spacer(Modifier.width(6.dp)) + Text(value, color = valueColor, fontSize = 12.sp, fontWeight = FontWeight.SemiBold, style = TextStyle(fontFeatureSettings = "tnum")) + } +} + +/** Dealer during bidding; tricks and card points during play. */ +@Composable +private fun InfoChips(game: GameState, onLastTrick: () -> Unit) { + val hand = game.hand + val trump = hand.trump + Box(Modifier.fillMaxWidth().height(38.dp).padding(horizontal = 12.dp)) { + Row(Modifier.align(Alignment.Center), horizontalArrangement = Arrangement.spacedBy(8.dp)) { + if (game.phase == Phase.BIDDING || trump == null) { + InfoChip("DIJELI", seatName(hand.dealer)) + } else { + val tricks = IntArray(2) + val points = IntArray(2) + hand.tricks.forEach { + tricks[teamOf(it.winner)]++ + points[teamOf(it.winner)] += it.trick.points(trump) + } + InfoChip("ŠTIHOVI", "${tricks[0]} : ${tricks[1]}") + InfoChip("BODOVI", "${points[0]} : ${points[1]}") + } + if (game.hanging > 0) InfoChip("VISI", "${game.hanging}", Gold) + } + if (game.phase != Phase.BIDDING && hand.tricks.isNotEmpty()) { + GlassIconButton( + BelaIcons.LastTrick, + "Zadnji štih", + onLastTrick, + Modifier.align(Alignment.CenterEnd).size(34.dp), + tint = Gold, + ) + } + } +} + +/** What is printed on the felt: a pool of light, a double gold ring round the play area and the name in the middle. */ +@Composable +private fun TableMarkings(ringWidth: Dp, ringHeight: Dp) { + Canvas(Modifier.fillMaxSize()) { + val c = Offset(size.width / 2, size.height / 2) + drawCircle( + Brush.radialGradient(listOf(Color(0x24FFFFFF), Color.Transparent), center = c, radius = size.minDimension * 0.62f), + radius = size.minDimension * 0.62f, + center = c, + ) + val w = ringWidth.toPx() + val h = ringHeight.toPx() + val gap = 6.dp.toPx() + drawRoundRect( + Gold.copy(alpha = 0.2f), + topLeft = Offset(c.x - w / 2, c.y - h / 2), + size = Size(w, h), + cornerRadius = CornerRadius(w / 2, w / 2), + style = Stroke(width = 1.2.dp.toPx()), + ) + drawRoundRect( + Gold.copy(alpha = 0.09f), + topLeft = Offset(c.x - w / 2 + gap, c.y - h / 2 + gap), + size = Size(w - 2 * gap, h - 2 * gap), + cornerRadius = CornerRadius(w / 2 - gap, w / 2 - gap), + style = Stroke(width = 1.dp.toPx()), + ) + } + Column(Modifier.fillMaxSize(), verticalArrangement = Arrangement.Center, horizontalAlignment = Alignment.CenterHorizontally) { + Text( + "BELA", + color = Gold.copy(alpha = 0.13f), + fontFamily = Cinzel, + fontWeight = FontWeight.Bold, + fontSize = 34.sp, + letterSpacing = 10.sp, + ) + } +} + +// ---------------------------------------------------------------- seats + +private enum class Tone { QUIET, ACTIVE, BUBBLE } + +private data class SeatStatus(val text: String, val tone: Tone, val suit: Suit? = null) + +private fun seatStatus(game: GameState, state: UiState, seat: Int): SeatStatus? { + state.bubble?.takeIf { it.first == seat }?.let { return SeatStatus(it.second, Tone.BUBBLE) } + val active = game.toAct == seat && !state.inputLocked + if (game.phase == Phase.BIDDING) { + game.hand.bids.lastOrNull { it.seat == seat }?.let { + return if (it.suit == null) SeatStatus("dalje", Tone.QUIET) else SeatStatus("zove", Tone.QUIET, it.suit) + } + if (active) return SeatStatus(if (seat == HUMAN) "tvoj red" else "zove…", Tone.ACTIVE) + return null + } + if (active) return SeatStatus(if (seat == HUMAN) "Tvoj potez" else "igra…", Tone.ACTIVE) + return null +} + +/** A seat's status in a fixed-height slot, so nothing around it jumps when it changes. */ +@Composable +private fun StatusSlot(status: SeatStatus?) { + Box(Modifier.height(22.dp), contentAlignment = Alignment.Center) { + if (status == null) return@Box + when (status.tone) { + Tone.BUBBLE -> Box( + Modifier + .shadow(6.dp, RoundedCornerShape(11.dp), spotColor = GoldDeep) + .clip(RoundedCornerShape(11.dp)) + .background(GoldVertical) + .padding(horizontal = 10.dp, vertical = 1.dp), + ) { + Text(status.text, color = Ink, fontFamily = Cinzel, fontWeight = FontWeight.Bold, fontSize = 12.sp) + } + Tone.ACTIVE -> { + val pulse by rememberInfiniteTransition(label = "status").animateFloat( + initialValue = 0.55f, + targetValue = 1f, + animationSpec = infiniteRepeatable(tween(700), RepeatMode.Reverse), + label = "status-alpha", + ) + Text(status.text, color = Gold.copy(alpha = pulse), fontSize = 12.sp, fontWeight = FontWeight.SemiBold) + } + Tone.QUIET -> Row(verticalAlignment = Alignment.CenterVertically) { + Text(status.text, color = CreamMuted, fontSize = 12.sp) + status.suit?.let { + Spacer(Modifier.width(4.dp)) + SuitIcon(it, 16.dp) + } + } + } + } +} + +/** + * Round portrait with a team-coloured rim (gold for us, silver for them). The player whose turn it is + * gets a breathing gold halo. Dealer and caller chips sit on the rim. + */ +@Composable +private fun Avatar(game: GameState, state: UiState, seat: Int, size: Dp = 48.dp) { + val active = game.toAct == seat && !state.inputLocked + val halo = if (active) { + val pulse by rememberInfiniteTransition(label = "turn").animateFloat( + initialValue = 0.25f, + targetValue = 0.7f, + animationSpec = infiniteRepeatable(tween(800), RepeatMode.Reverse), + label = "halo", + ) + pulse + } else { + 0f + } + val ours = teamOf(seat) == 0 + Box(Modifier.size(size + 16.dp), contentAlignment = Alignment.Center) { + if (halo > 0f) { + Canvas(Modifier.fillMaxSize()) { + drawCircle(Brush.radialGradient(listOf(Gold.copy(alpha = halo), Color.Transparent))) + } + } + Box( + Modifier + .size(size) + .shadow(8.dp, CircleShape) + .clip(CircleShape) + .background(Brush.linearGradient(listOf(Color(0xFF1F4A36), Color(0xFF0B2219)))) + .border(2.dp, if (ours) GoldBrush else SilverBrush, CircleShape), + contentAlignment = Alignment.Center, + ) { + Silhouette(if (ours) GoldBrush else SilverBrush) + } + if (seat == game.hand.dealer) DealerChip(Modifier.align(Alignment.BottomEnd).padding(end = 6.dp, bottom = 6.dp)) + if (seat == game.hand.caller) { + game.hand.trump?.let { CallerChip(it, Modifier.align(Alignment.TopEnd).padding(end = 4.dp, top = 4.dp)) } + } + } +} + +/** Head and shoulders, cut off by the round frame. */ +@Composable +private fun Silhouette(brush: Brush) { + Canvas(Modifier.fillMaxSize()) { + val w = size.width + val h = size.height + drawCircle(brush, radius = w * 0.17f, center = Offset(w / 2, h * 0.4f), alpha = 0.9f) + drawOval(brush, topLeft = Offset(w * 0.2f, h * 0.64f), size = Size(w * 0.6f, h * 0.56f), alpha = 0.9f) + } +} + +@Composable +private fun DealerChip(modifier: Modifier = Modifier) { + Box( + modifier.size(18.dp).shadow(3.dp, CircleShape).clip(CircleShape).background(GoldVertical), + contentAlignment = Alignment.Center, + ) { + Text("D", color = Ink, fontFamily = Cinzel, fontSize = 10.sp, fontWeight = FontWeight.Black) + } +} + +@Composable +private fun CallerChip(suit: Suit, modifier: Modifier = Modifier) { + Box( + modifier.size(22.dp).shadow(3.dp, CircleShape).clip(CircleShape).background(Cream).border(1.5.dp, GoldBrush, CircleShape), + contentAlignment = Alignment.Center, + ) { + SuitIcon(suit, 14.dp) + } +} + +/** Left and right players: portrait, name, status and their fanned cards, all in a narrow column. */ +@Composable +private fun SideSeat(game: GameState, state: UiState, seat: Int, modifier: Modifier) { + Column(modifier.width(SideColumnWidth), horizontalAlignment = Alignment.CenterHorizontally) { + Avatar(game, state, seat) + NamePlate(seatName(seat)) + StatusSlot(seatStatus(game, state, seat)) + BotFan(game.hand.cards[seat].size + game.hand.talon[seat].size, if (seat == 3) FanSide.LEFT else FanSide.RIGHT) + } +} + +@Composable +private fun PartnerSeat(game: GameState, state: UiState, modifier: Modifier) { + val seat = 2 + Column(modifier, horizontalAlignment = Alignment.CenterHorizontally) { + Row(verticalAlignment = Alignment.CenterVertically) { + Avatar(game, state, seat) + Column(Modifier.padding(start = 2.dp)) { + NamePlate(seatName(seat)) + StatusSlot(seatStatus(game, state, seat)) + } + } + BotFan(game.hand.cards[seat].size + game.hand.talon[seat].size, FanSide.TOP) + } +} + +/** The player's own plate, just above the hand. */ +@Composable +private fun MySeat(game: GameState, state: UiState) { + val active = game.toAct == HUMAN && !state.inputLocked + val shape = RoundedCornerShape(50) + Row( + Modifier + .padding(bottom = 4.dp) + .clip(shape) + .background(Glass) + .border(1.dp, if (active) GoldBrush else Brush.linearGradient(listOf(CreamFaint, CreamFaint)), shape) + .padding(start = 12.dp, end = 12.dp, top = 3.dp, bottom = 3.dp), + verticalAlignment = Alignment.CenterVertically, + horizontalArrangement = Arrangement.spacedBy(6.dp), + ) { + Text("Ti", color = Cream, fontSize = 13.sp, fontWeight = FontWeight.SemiBold) + if (game.hand.dealer == HUMAN) DealerChip() + if (game.hand.caller == HUMAN) game.hand.trump?.let { CallerChip(it) } + StatusSlot(seatStatus(game, state, HUMAN)) + } +} + +private enum class FanSide { LEFT, RIGHT, TOP } + +/** A bot's cards held in a fan that opens towards the middle of the table. */ +@Composable +private fun BotFan(count: Int, side: FanSide) { + if (count == 0) { + Spacer(Modifier.height(if (side == FanSide.TOP) 52.dp else 80.dp)) + return + } + val middle = (count - 1) / 2f + when (side) { + FanSide.LEFT, FanSide.RIGHT -> Box(Modifier.width(62.dp).height(80.dp)) { + val left = side == FanSide.LEFT + repeat(count) { i -> + CardBack( + Modifier + .align(if (left) Alignment.CenterStart else Alignment.CenterEnd) + .width(42.dp) + .graphicsLayer { + rotationZ = (if (left) i - middle else middle - i) * 7f + transformOrigin = TransformOrigin(if (left) 0.1f else 0.9f, 0.5f) + }, + small = true, + landscape = true, + ) + } + } + FanSide.TOP -> Box(Modifier.width(110.dp).height(52.dp)) { + repeat(count) { i -> + CardBack( + Modifier + .align(Alignment.TopCenter) + .width(26.dp) + .graphicsLayer { + rotationZ = (middle - i) * 8f + transformOrigin = TransformOrigin(0.5f, 0.1f) + }, + small = true, + ) + } + } + } +} + +// ---------------------------------------------------------------- middle + +/** Where each seat's card lands in the trick, relative to the centre. */ +private fun trickOffset(seat: Int, dx: Dp, dy: Dp): DpOffset = when (seat) { + 0 -> DpOffset(0.dp, dy) + 1 -> DpOffset(dx, 0.dp) + 2 -> DpOffset(0.dp, -dy) + else -> DpOffset(-dx, 0.dp) +} + +/** The current trick, each card in front of its player. A finished trick slides off towards its winner. */ +@Composable +private fun TrickArea(game: GameState, state: UiState, cardWidth: Dp, modifier: Modifier) { + val shown = state.shownTrick + val trick = shown?.trick ?: game.hand.trick.takeIf { game.phase == Phase.PLAYING } ?: return + val cardHeight = cardWidth / CARD_ASPECT + val dx = cardWidth * 0.94f + val dy = cardHeight * 0.58f + + // The finished trick stays still for a second (winner framed in gold), then slides off. + // Keep 1000 + 380 ms below GameViewModel.TRICK_PAUSE_MS. + val gather = remember(shown) { Animatable(0f) } + LaunchedEffect(shown) { + if (shown != null) { + delay(1000) + gather.animateTo(1f, tween(durationMillis = 380, easing = FastOutSlowInEasing)) + } + } + val gatherTo = shown?.let { trickOffset(it.winner, dx * 2.6f, dy * 2.6f) } + + Box(modifier.width(cardWidth + dx * 2 + 16.dp).height(cardHeight + dy * 2 + 16.dp)) { + trick.cards.forEachIndexed { i, card -> + val seat = trick.seatAt(i) + key(card) { + PlayedCard( + card = card, + width = cardWidth, + target = trickOffset(seat, dx, dy), + tilt = seatTilt(seat) + ((card.suit.ordinal * 8 + card.rank.ordinal) * 37 % 5 - 2) * 1.3f, + gatherTo = gatherTo, + gather = { gather.value }, + highlighted = shown?.winner == seat, + modifier = Modifier.align(Alignment.Center).zIndex(i.toFloat()), + ) + } + } + } +} + +private fun seatTilt(seat: Int): Float = when (seat) { + 0 -> 2f + 1 -> -7f + 2 -> -2f + else -> 7f +} + +@Composable +private fun PlayedCard( + card: Card, + width: Dp, + target: DpOffset, + tilt: Float, + gatherTo: DpOffset?, + gather: () -> Float, + highlighted: Boolean, + modifier: Modifier, +) { + val appear = remember { Animatable(0f) } + LaunchedEffect(Unit) { appear.animateTo(1f, tween(durationMillis = 280, easing = FastOutSlowInEasing)) } + CardFace( + card = card, + highlighted = highlighted, + elevation = 10.dp, + modifier = modifier + .offset(x = target.x, y = target.y) + .width(width) + .graphicsLayer { + val p = appear.value + val g = gather() + // Fly in from the player's side of the table, then (when the trick is done) off towards the winner. + var tx = target.x.toPx() * 1.7f * (1 - p) + var ty = target.y.toPx() * 1.7f * (1 - p) + if (gatherTo != null) { + tx += (gatherTo.x - target.x).toPx() * g + ty += (gatherTo.y - target.y).toPx() * g + } + translationX = tx + translationY = ty + alpha = p * (1 - g) + val scale = (0.86f + 0.14f * p) * (1 - 0.4f * g) + scaleX = scale + scaleY = scale + rotationZ = tilt * p + }, + ) +} + +/** The declarations that count, shown during the first trick. */ +@Composable +private fun DeclarationBanner(game: GameState) { + val hand = game.hand + val team = hand.declarationTeam + if (game.phase != Phase.PLAYING || hand.tricks.isNotEmpty() || team == null) return + val list = hand.scoringDeclarations + val shape = RoundedCornerShape(14.dp) + Column( + Modifier + .padding(bottom = 8.dp) + .shadow(8.dp, shape) + .clip(shape) + .background(Color(0xD90B2016)) + .border(1.dp, GoldBrush, shape) + .padding(horizontal = 12.dp, vertical = 6.dp), + ) { + Overline("Zvanja · ${teamName(team)} ${list.sumOf { it.points }}", color = Gold) + list.forEach { d -> + Row( + Modifier.padding(top = 4.dp), + verticalAlignment = Alignment.CenterVertically, + horizontalArrangement = Arrangement.spacedBy(3.dp), + ) { + Text(seatName(d.seat), color = Cream, fontSize = 12.sp, modifier = Modifier.width(54.dp)) + d.cards.forEach { CardFace(it, Modifier.width(20.dp), elevation = 1.dp) } + Text("${d.points}", color = Cream, fontSize = 12.sp, fontWeight = FontWeight.SemiBold, modifier = Modifier.padding(start = 6.dp)) + } + } + } +} + +@Composable +private fun BiddingPanel(canPass: Boolean, onCall: (Suit?) -> Unit, modifier: Modifier) { + val shape = RoundedCornerShape(24.dp) + Column( + modifier + .fillMaxWidth() + .padding(horizontal = 8.dp, vertical = 4.dp) + .shadow(16.dp, shape) + .clip(shape) + .background(DialogBrush) + .border(1.dp, GoldBrush, shape) + .padding(16.dp), + horizontalAlignment = Alignment.CenterHorizontally, + ) { + Overline("Zovi adut", color = Gold) + Ornament(Modifier.padding(top = 6.dp), lineWidth = 36.dp) + Row( + Modifier.fillMaxWidth().padding(top = 12.dp), + horizontalArrangement = Arrangement.spacedBy(10.dp), + ) { + Suit.entries.forEach { suit -> SuitTile(suit, Modifier.weight(1f)) { onCall(suit) } } + } + GlassButton( + if (canPass) "Dalje" else "Djelitelj mora zvati", + onClick = { onCall(null) }, + enabled = canPass, + modifier = Modifier.padding(top = 12.dp), + ) + } +} + +@Composable +private fun SuitTile(suit: Suit, modifier: Modifier, onClick: () -> Unit) { + val interaction = remember { MutableInteractionSource() } + val pressed by interaction.collectIsPressedAsState() + val scale by animateFloatAsState(if (pressed) 0.94f else 1f, tween(120), label = "tile") + val shape = RoundedCornerShape(16.dp) + Column( + modifier + .height(82.dp) + .graphicsLayer { + scaleX = scale + scaleY = scale + } + .shadow(6.dp, shape) + .clip(shape) + .background(Brush.verticalGradient(listOf(Color(0xFFFFFDF6), Color(0xFFEAE2CB)))) + .border(1.dp, GoldBrush, shape) + .clickable(interaction, ripple(color = GoldDeep), onClick = onClick), + horizontalAlignment = Alignment.CenterHorizontally, + verticalArrangement = Arrangement.Center, + ) { + SuitIcon(suit, 40.dp) + Text(suitName(suit), color = Color(0xFF3B3324), fontFamily = Cinzel, fontWeight = FontWeight.Bold, fontSize = 11.sp) + } +} + +// ---------------------------------------------------------------- hand + +/** + * The player's cards as a gentle fan. Number cards keep about two thirds of their width visible so the value mark + * (VII…X, in the middle of the top edge) stays readable; picture cards are recognised from their left half and + * overlap more. New cards are dealt in with a flip; legal cards rise and glow gold when it is the player's turn. + */ +@Composable +private fun HandRow(game: GameState, state: UiState, onPlay: (Card) -> Unit) { + val hand = game.hand + val cards = sortHand(hand.cards[HUMAN], hand.trump) + val talon = hand.talon[HUMAN].size + val myTurn = game.phase == Phase.PLAYING && game.toAct == HUMAN && !state.inputLocked + val legal = if (myTurn) game.legalMoves(HUMAN).toSet() else emptySet() + val items: List = cards + List(talon) { null } // null = a face-down talon card + val haptic = LocalHapticFeedback.current + // Cards already shown this hand; anything new (the deal, the talon) gets the deal-in animation, staggered. + val dealt = remember(hand.number) { mutableSetOf() } + + BoxWithConstraints( + Modifier + .fillMaxWidth() + .background(Brush.verticalGradient(listOf(Color.Transparent, Color(0x80000000)))) + .padding(horizontal = 4.dp), + ) { + val width = minOf(96.dp, maxWidth / 4.5f, maxCardWidth()) + val height = width / CARD_ASPECT + val count = items.size + val fanStep = 1.6f // degrees between neighbouring cards + val maxAngle = fanStep * (count - 1) / 2 + val spill = height * sin(Math.toRadians(maxAngle.toDouble())).toFloat() + + // How much of each card must stay uncovered, from where its value can be read on this deck: + // VII and IX carry the numeral in the top-left corner, VIII and X in the middle of the top edge + // (up to ~60% of the width); picture cards are recognised by their suit mark and figure on the left. + val gaps = items.dropLast(1).map { card -> + width * when (card?.rank) { + Rank.SEDAM, Rank.DEVET -> 0.42f + Rank.OSAM, Rank.DESET -> 0.63f + else -> 0.47f + } + } + val wanted = gaps.fold(0.dp) { sum, gap -> sum + gap } + val room = maxWidth - width - spill * 2 + val squeeze = if (wanted > room && wanted > 0.dp) room / wanted else 1f + val start = (maxWidth - width - wanted * squeeze) / 2 + val lefts = items.indices.map { i -> start + gaps.take(i).fold(0.dp) { sum, gap -> sum + gap } * squeeze } + val middle = (count - 1) / 2f + var entering = 0 + + Box(Modifier.fillMaxWidth().height(height + 52.dp)) { + items.forEachIndexed { i, card -> + val angle = (i - middle) * fanStep + val drop = 1.0.dp * ((i - middle) * (i - middle)) + val place = Modifier + .align(Alignment.BottomStart) + .offset(x = lefts[i], y = drop - 18.dp) + .width(width) + if (card == null) { + CardBack( + place.graphicsLayer { + rotationZ = angle + transformOrigin = TransformOrigin(0.5f, 1f) + }, + ) + } else { + val order = if (card in dealt) -1 else entering++ + key(card) { + val enter = remember { Animatable(if (order < 0) 1f else 0f) } + LaunchedEffect(Unit) { + if (order >= 0) { + delay(order * 70L) + enter.animateTo(1f, tween(durationMillis = 420, easing = FastOutSlowInEasing)) + } + dealt += card + } + val playable = card in legal + val lift by animateDpAsState(if (playable) 20.dp else 0.dp, tween(180), label = "lift") + CardFace( + card = card, + dimmed = myTurn && !playable, + glow = playable, + elevation = if (playable) 16.dp else 8.dp, + modifier = place + .graphicsLayer { + val e = enter.value + rotationZ = angle + rotationY = (1 - e) * 90f + translationY = (1 - e) * 140.dp.toPx() + alpha = if (e < 0.01f) 0f else 1f + cameraDistance = 14f * density + transformOrigin = TransformOrigin(0.5f, 1f) + } + .offset(y = -lift) + .then( + if (playable) { + Modifier.clickable { + haptic.performHapticFeedback(HapticFeedbackType.TextHandleMove) + onPlay(card) + } + } else { + Modifier + }, + ), + ) + } + } + } + } + } +} diff --git a/app/src/main/kotlin/hr/bela/app/ui/Texts.kt b/app/src/main/kotlin/hr/bela/app/ui/Texts.kt new file mode 100644 index 0000000..35e19e9 --- /dev/null +++ b/app/src/main/kotlin/hr/bela/app/ui/Texts.kt @@ -0,0 +1,74 @@ +package hr.bela.app.ui + +import hr.bela.engine.Card +import hr.bela.engine.Outcome +import hr.bela.engine.Rank +import hr.bela.engine.Suit +import hr.bela.engine.strength + +/** Suit names for the Hungarian deck the app uses (herc = srce, karo = zvono, pik = list, tref = žir). */ +fun suitName(suit: Suit): String = when (suit) { + Suit.HERC -> "Srce" + Suit.KARO -> "Zvono" + Suit.PIK -> "List" + Suit.TREF -> "Žir" +} + +fun rankName(rank: Rank): String = when (rank) { + Rank.SEDAM -> "sedmica" + Rank.OSAM -> "osmica" + Rank.DEVET -> "devetka" + Rank.DESET -> "desetka" + Rank.DECKO -> "dečko" + Rank.DAMA -> "dama" + Rank.KRALJ -> "kralj" + Rank.AS -> "as" +} + +/** Spoken name of a card, e.g. "Srce kralj"; used for accessibility. */ +fun cardName(card: Card): String = "${suitName(card.suit)} ${rankName(card.rank)}" + +/** Seat names as seen from the player (seat 0). Play goes counterclockwise: you, right, partner, left. */ +fun seatName(seat: Int): String = when (seat) { + 0 -> "Ti" + 1 -> "Desni" + 2 -> "Partner" + else -> "Lijevi" +} + +fun teamName(team: Int): String = if (team == 0) "Mi" else "Vi" + +/** "1 bod", "2 boda", "5 bodova", with Croatian number agreement. */ +fun pointsText(n: Int): String { + val word = when { + n % 10 == 1 && n % 100 != 11 -> "bod" + n % 10 in 2..4 && n % 100 !in 12..14 -> "boda" + else -> "bodova" + } + return "$n $word" +} + +fun outcomeLabel(outcome: Outcome): String = when (outcome) { + Outcome.PASSED -> "Prolaz" + Outcome.FELL -> "Pad" + Outcome.TIED -> "Visi" +} + +private val SUIT_ORDER = listOf(Suit.HERC, Suit.PIK, Suit.KARO, Suit.TREF) + +/** + * The player's hand grouped by suit, strongest card first within a suit. Trump comes first once it is known, + * and the suits alternate red and black wherever the hand allows it. + */ +fun sortHand(cards: List, trump: Suit?): List { + val remaining = SUIT_ORDER.filter { suit -> cards.any { it.suit == suit } }.toMutableList() + val order = mutableListOf() + if (trump != null && remaining.remove(trump)) order += trump + while (remaining.isNotEmpty()) { + val last = order.lastOrNull() + val next = remaining.firstOrNull { last == null || it.isRed != last.isRed } ?: remaining.first() + order += next + remaining.remove(next) + } + return cards.sortedWith(compareBy({ order.indexOf(it.suit) }, { -it.strength(trump) })) +} diff --git a/app/src/main/kotlin/hr/bela/app/ui/Theme.kt b/app/src/main/kotlin/hr/bela/app/ui/Theme.kt new file mode 100644 index 0000000..18f1046 --- /dev/null +++ b/app/src/main/kotlin/hr/bela/app/ui/Theme.kt @@ -0,0 +1,138 @@ +package hr.bela.app.ui + +import android.graphics.Bitmap +import androidx.compose.material3.MaterialTheme +import androidx.compose.material3.Typography +import androidx.compose.material3.darkColorScheme +import androidx.compose.runtime.Composable +import androidx.compose.ui.Modifier +import androidx.compose.ui.draw.drawBehind +import androidx.compose.ui.geometry.Offset +import androidx.compose.ui.graphics.Brush +import androidx.compose.ui.graphics.Color +import androidx.compose.ui.graphics.ImageShader +import androidx.compose.ui.graphics.ShaderBrush +import androidx.compose.ui.graphics.TileMode +import androidx.compose.ui.graphics.asImageBitmap +import androidx.compose.ui.text.ExperimentalTextApi +import androidx.compose.ui.text.font.Font +import androidx.compose.ui.text.font.FontFamily +import androidx.compose.ui.text.font.FontVariation +import androidx.compose.ui.text.font.FontWeight +import hr.bela.app.R + +// ---------------------------------------------------------------- colours + +val FeltLight = Color(0xFF2F7F57) +val Felt = Color(0xFF1D5C3D) +val FeltDeep = Color(0xFF0A281B) +val Gold = Color(0xFFE9C46A) +val GoldLight = Color(0xFFF8E7AE) +val GoldDeep = Color(0xFFB0812C) +val Cream = Color(0xFFF7F3E8) +val CreamMuted = Color(0xB3F7F3E8) +val CreamFaint = Color(0x33F7F3E8) +val Ink = Color(0xFF2A1E02) +val Shade = Color(0x59000000) +val Glass = Color(0x5C000000) +val PanelGreen = Color(0xFF0E271B) +val DialogTop = Color(0xFF184432) +val DialogBottom = Color(0xFF0D2A1E) +val SuitBlack = Color(0xFF1B1B1B) +val WinGreen = Color(0xFF8FD3A4) +val LossRed = Color(0xFFF0958C) +val Silver = Color(0xFFC7D0D8) + +/** Polished gold: light at the top-left, deep at the bottom-right. */ +val GoldBrush: Brush = Brush.linearGradient(listOf(GoldLight, Gold, GoldDeep)) +val GoldVertical: Brush = Brush.verticalGradient(listOf(GoldLight, Gold, GoldDeep)) +val SilverBrush: Brush = Brush.linearGradient(listOf(Color(0xFFF1F4F7), Silver, Color(0xFF7E8B97))) +val DialogBrush: Brush = Brush.verticalGradient(listOf(DialogTop, DialogBottom)) + +// ---------------------------------------------------------------- type + +/** Classic Roman capitals; matches the Roman numerals on the cards. Used for titles, scores and labels. */ +@OptIn(ExperimentalTextApi::class) +val Cinzel = FontFamily( + Font(R.font.cinzel, FontWeight.Normal, variationSettings = FontVariation.Settings(FontVariation.weight(400))), + Font(R.font.cinzel, FontWeight.SemiBold, variationSettings = FontVariation.Settings(FontVariation.weight(600))), + Font(R.font.cinzel, FontWeight.Bold, variationSettings = FontVariation.Settings(FontVariation.weight(700))), + Font(R.font.cinzel, FontWeight.Black, variationSettings = FontVariation.Settings(FontVariation.weight(900))), +) + +/** Body text. */ +@OptIn(ExperimentalTextApi::class) +val Inter = FontFamily( + Font(R.font.inter, FontWeight.Normal, variationSettings = FontVariation.Settings(FontVariation.weight(400))), + Font(R.font.inter, FontWeight.Medium, variationSettings = FontVariation.Settings(FontVariation.weight(500))), + Font(R.font.inter, FontWeight.SemiBold, variationSettings = FontVariation.Settings(FontVariation.weight(600))), + Font(R.font.inter, FontWeight.Bold, variationSettings = FontVariation.Settings(FontVariation.weight(700))), +) + +private fun Typography.withFont(family: FontFamily) = Typography( + displayLarge = displayLarge.copy(fontFamily = family), + displayMedium = displayMedium.copy(fontFamily = family), + displaySmall = displaySmall.copy(fontFamily = family), + headlineLarge = headlineLarge.copy(fontFamily = family), + headlineMedium = headlineMedium.copy(fontFamily = family), + headlineSmall = headlineSmall.copy(fontFamily = family), + titleLarge = titleLarge.copy(fontFamily = family), + titleMedium = titleMedium.copy(fontFamily = family), + titleSmall = titleSmall.copy(fontFamily = family), + bodyLarge = bodyLarge.copy(fontFamily = family), + bodyMedium = bodyMedium.copy(fontFamily = family), + bodySmall = bodySmall.copy(fontFamily = family), + labelLarge = labelLarge.copy(fontFamily = family), + labelMedium = labelMedium.copy(fontFamily = family), + labelSmall = labelSmall.copy(fontFamily = family), +) + +@Composable +fun BelaTheme(content: @Composable () -> Unit) { + MaterialTheme( + colorScheme = darkColorScheme( + primary = Gold, + onPrimary = Ink, + secondary = Cream, + background = FeltDeep, + surface = DialogBottom, + onSurface = Cream, + surfaceContainerHigh = DialogBottom, + ), + typography = Typography().withFont(Inter), + content = content, + ) +} + +// ---------------------------------------------------------------- felt + +/** Fine random grain, tiled over the felt so it reads as cloth rather than a flat gradient. */ +private val FeltGrain: ShaderBrush by lazy { + val size = 128 + val random = java.util.Random(7) + val pixels = IntArray(size * size) { + val alpha = random.nextInt(16) + if (random.nextBoolean()) (alpha shl 24) or 0xFFFFFF else alpha shl 24 + } + val bitmap = Bitmap.createBitmap(pixels, size, size, Bitmap.Config.ARGB_8888).asImageBitmap() + ShaderBrush(ImageShader(bitmap, TileMode.Repeated, TileMode.Repeated)) +} + +/** Card-table felt: lit in the middle, grain on top, dark vignette at the rim. */ +fun Modifier.feltBackground(): Modifier = drawBehind { + drawRect( + Brush.radialGradient( + colors = listOf(FeltLight, Felt, FeltDeep), + center = Offset(size.width / 2, size.height * 0.45f), + radius = size.maxDimension * 0.72f, + ), + ) + drawRect(FeltGrain) + drawRect( + Brush.radialGradient( + colors = listOf(Color.Transparent, Color.Transparent, Color(0x8C000000)), + center = Offset(size.width / 2, size.height / 2), + radius = size.maxDimension * 0.68f, + ), + ) +} diff --git a/app/src/main/kotlin/hr/bela/app/ui/TrainingScreen.kt b/app/src/main/kotlin/hr/bela/app/ui/TrainingScreen.kt new file mode 100644 index 0000000..8735226 --- /dev/null +++ b/app/src/main/kotlin/hr/bela/app/ui/TrainingScreen.kt @@ -0,0 +1,384 @@ +package hr.bela.app.ui + +import androidx.activity.compose.BackHandler +import androidx.compose.animation.core.Animatable +import androidx.compose.animation.core.FastOutSlowInEasing +import androidx.compose.animation.core.animateFloatAsState +import androidx.compose.animation.core.tween +import androidx.compose.foundation.background +import androidx.compose.foundation.border +import androidx.compose.foundation.clickable +import androidx.compose.foundation.interaction.MutableInteractionSource +import androidx.compose.foundation.interaction.collectIsPressedAsState +import androidx.compose.foundation.layout.Arrangement +import androidx.compose.foundation.layout.Box +import androidx.compose.foundation.layout.BoxWithConstraints +import androidx.compose.foundation.layout.Column +import androidx.compose.foundation.layout.Row +import androidx.compose.foundation.layout.Spacer +import androidx.compose.foundation.layout.fillMaxHeight +import androidx.compose.foundation.layout.fillMaxSize +import androidx.compose.foundation.layout.fillMaxWidth +import androidx.compose.foundation.layout.height +import androidx.compose.foundation.layout.padding +import androidx.compose.foundation.layout.safeDrawingPadding +import androidx.compose.foundation.layout.width +import androidx.compose.foundation.shape.RoundedCornerShape +import androidx.compose.material3.Text +import androidx.compose.material3.ripple +import androidx.compose.runtime.Composable +import androidx.compose.runtime.LaunchedEffect +import androidx.compose.runtime.getValue +import androidx.compose.runtime.key +import androidx.compose.runtime.remember +import androidx.compose.ui.Alignment +import androidx.compose.ui.Modifier +import androidx.compose.ui.draw.clip +import androidx.compose.ui.draw.shadow +import androidx.compose.ui.graphics.Brush +import androidx.compose.ui.graphics.Color +import androidx.compose.ui.graphics.graphicsLayer +import androidx.compose.ui.text.font.FontWeight +import androidx.compose.ui.text.style.TextAlign +import androidx.compose.ui.unit.Dp +import androidx.compose.ui.unit.dp +import androidx.compose.ui.unit.sp +import androidx.lifecycle.compose.collectAsStateWithLifecycle +import androidx.lifecycle.viewmodel.compose.viewModel +import hr.bela.app.DrillLevel +import hr.bela.app.DrillPhase +import hr.bela.app.TrainingState +import hr.bela.app.TrainingViewModel +import hr.bela.engine.AnswerOption +import hr.bela.engine.Card +import hr.bela.engine.CountingMistake +import hr.bela.engine.CountingRound +import hr.bela.engine.points + +/** Card-counting practice: a pile of won cards is shown one by one, then the player picks the total. */ +@Composable +fun TrainingScreen(onExit: () -> Unit, vm: TrainingViewModel = viewModel()) { + val s by vm.state.collectAsStateWithLifecycle() + BackHandler(onBack = onExit) + + Box(Modifier.fillMaxSize().feltBackground()) { + Column(Modifier.fillMaxSize().safeDrawingPadding().padding(horizontal = 16.dp)) { + TrainingHeader(s, onExit) + LevelPicker(s.level, vm::setLevel) + TrumpBanner(s.round) + Box(Modifier.weight(1f).fillMaxWidth(), contentAlignment = Alignment.Center) { + when (s.phase) { + DrillPhase.COUNTING -> CountingStage(s, vm::next) + DrillPhase.ANSWERING -> AnswerStage(s.round, vm::answer) + DrillPhase.RESULT -> ResultStage(s) + } + } + Box(Modifier.fillMaxWidth().height(78.dp), contentAlignment = Alignment.Center) { + when (s.phase) { + DrillPhase.COUNTING -> GoldButton(if (s.isLastCard) "Zbroji" else "Sljedeća karta", vm::next) + DrillPhase.ANSWERING -> Text("Odaberi zbroj", color = CreamMuted, fontSize = 13.sp) + DrillPhase.RESULT -> GoldButton("Nova runda", vm::nextRound) + } + } + } + } +} + +@Composable +private fun TrainingHeader(s: TrainingState, onExit: () -> Unit) { + Box(Modifier.fillMaxWidth().padding(top = cameraClearance()).height(68.dp)) { + GlassIconButton(BelaIcons.Back, "Natrag", onExit, Modifier.align(Alignment.CenterStart)) + Column(Modifier.align(Alignment.Center), horizontalAlignment = Alignment.CenterHorizontally) { + Overline("Trening", color = Gold) + Text("Brojanje", color = Cream, fontFamily = Cinzel, fontWeight = FontWeight.Bold, fontSize = 22.sp) + } + Column(Modifier.align(Alignment.CenterEnd), horizontalAlignment = Alignment.End) { + Row( + Modifier + .clip(RoundedCornerShape(50)) + .background(Glass) + .border(1.dp, if (s.streak > 0) GoldBrush else Brush.linearGradient(listOf(CreamFaint, CreamFaint)), RoundedCornerShape(50)) + .padding(horizontal = 10.dp, vertical = 3.dp), + verticalAlignment = Alignment.CenterVertically, + ) { + Text("NIZ", color = CreamMuted, fontFamily = Cinzel, fontWeight = FontWeight.Bold, fontSize = 9.sp, letterSpacing = 1.5.sp) + Spacer(Modifier.width(6.dp)) + Text("${s.streak}", color = if (s.streak > 0) Gold else Cream, fontFamily = Cinzel, fontWeight = FontWeight.Bold, fontSize = 15.sp) + } + Text( + "${s.correct}/${s.answered} · rekord ${s.bestStreak}", + color = CreamMuted, + fontSize = 11.sp, + modifier = Modifier.padding(top = 3.dp, end = 2.dp), + ) + } + } +} + +@Composable +private fun LevelPicker(current: DrillLevel, onPick: (DrillLevel) -> Unit) { + Row( + Modifier.fillMaxWidth().padding(top = 4.dp), + horizontalArrangement = Arrangement.spacedBy(8.dp, Alignment.CenterHorizontally), + ) { + DrillLevel.entries.forEach { level -> + val selected = level == current + val shape = RoundedCornerShape(50) + Box( + Modifier + .clip(shape) + .then(if (selected) Modifier.background(GoldVertical) else Modifier.background(Glass)) + .border(1.dp, if (selected) GoldBrush else Brush.linearGradient(listOf(CreamFaint, CreamFaint)), shape) + .clickable { onPick(level) } + .padding(horizontal = 16.dp, vertical = 6.dp), + ) { + Text( + level.label.uppercase(), + color = if (selected) Ink else Cream, + fontFamily = Cinzel, + fontWeight = FontWeight.Bold, + fontSize = 12.sp, + letterSpacing = 1.sp, + ) + } + } + } +} + +/** The made-up trump for this pile, with a reminder of the two cards that change value. */ +@Composable +private fun TrumpBanner(round: CountingRound) { + Column(Modifier.fillMaxWidth().padding(top = 16.dp), horizontalAlignment = Alignment.CenterHorizontally) { + Row(verticalAlignment = Alignment.CenterVertically) { + SuitMedallion(round.trump, 56.dp) + Spacer(Modifier.width(12.dp)) + Column { + Overline("Adut", color = Gold) + Text(suitName(round.trump), color = Cream, fontFamily = Cinzel, fontWeight = FontWeight.Bold, fontSize = 22.sp) + Text("dečko 20 · devetka 14", color = CreamMuted, fontSize = 12.sp) + } + } + if (round.lastTrick) { + Row( + Modifier + .padding(top = 10.dp) + .clip(RoundedCornerShape(50)) + .background(Glass) + .border(1.dp, GoldBrush, RoundedCornerShape(50)) + .padding(horizontal = 12.dp, vertical = 4.dp), + verticalAlignment = Alignment.CenterVertically, + ) { + Text("+10", color = Gold, fontFamily = Cinzel, fontWeight = FontWeight.Bold, fontSize = 13.sp) + Spacer(Modifier.width(8.dp)) + Text("Zadnji štih je vaš", color = Cream, fontSize = 12.sp) + } + } + } +} + +/** One card at a time; the cards already counted lie face down behind it. Tap the card (or the button) for the next. */ +@Composable +private fun CountingStage(s: TrainingState, onNext: () -> Unit) { + val cards = s.round.cards + BoxWithConstraints(Modifier.fillMaxSize()) { + // As large as the space allows, but never wider than the artwork itself, so it is never enlarged. + val width = minOf(maxCardWidth(), maxWidth * 0.7f, (maxHeight - 70.dp) * CARD_ASPECT) + Column(Modifier.fillMaxSize(), horizontalAlignment = Alignment.CenterHorizontally, verticalArrangement = Arrangement.Center) { + Overline("Karta ${s.shown} / ${cards.size}") + Box(Modifier.padding(top = 6.dp, bottom = 18.dp).width(160.dp).height(3.dp).clip(RoundedCornerShape(2.dp)).background(CreamFaint)) { + Box(Modifier.fillMaxHeight().fillMaxWidth(s.shown / cards.size.toFloat()).background(GoldBrush)) + } + Box( + Modifier.clickable(remember { MutableInteractionSource() }, indication = null, onClick = onNext), + contentAlignment = Alignment.Center, + ) { + val counted = (s.shown - 1).coerceAtMost(3) + for (depth in counted downTo 1) { + CardBack( + Modifier + .width(width) + .graphicsLayer { + translationX = -depth * 14.dp.toPx() + translationY = depth * 4.dp.toPx() + rotationZ = -depth * 4f + alpha = 1f - depth * 0.2f + }, + ) + } + key(s.shown) { RevealedCard(cards[s.shown - 1], width) } + } + } + } +} + +@Composable +private fun RevealedCard(card: Card, width: Dp) { + val flip = remember { Animatable(0f) } + LaunchedEffect(Unit) { flip.animateTo(1f, tween(durationMillis = 340, easing = FastOutSlowInEasing)) } + CardFace( + card = card, + elevation = 18.dp, + modifier = Modifier + .width(width) + .graphicsLayer { + val p = flip.value + rotationY = (1 - p) * -90f + translationX = (1 - p) * 90.dp.toPx() + cameraDistance = 16f * density + }, + ) +} + +@Composable +private fun AnswerStage(round: CountingRound, onAnswer: (AnswerOption) -> Unit) { + Column(horizontalAlignment = Alignment.CenterHorizontally, verticalArrangement = Arrangement.Center) { + Text("Koliko bodova?", color = Cream, fontFamily = Cinzel, fontWeight = FontWeight.Bold, fontSize = 26.sp) + Text( + "${round.cards.size} karata" + if (round.lastTrick) " i zadnji štih" else "", + color = CreamMuted, + fontSize = 13.sp, + modifier = Modifier.padding(top = 4.dp, bottom = 24.dp), + ) + round.options.chunked(2).forEach { pair -> + Row(Modifier.fillMaxWidth().padding(bottom = 12.dp), horizontalArrangement = Arrangement.spacedBy(12.dp)) { + pair.forEach { option -> OptionTile(option.value, Modifier.weight(1f)) { onAnswer(option) } } + } + } + } +} + +@Composable +private fun OptionTile(value: Int, modifier: Modifier, onClick: () -> Unit) { + val interaction = remember { MutableInteractionSource() } + val pressed by interaction.collectIsPressedAsState() + val scale by animateFloatAsState(if (pressed) 0.95f else 1f, tween(120), label = "option") + val shape = RoundedCornerShape(18.dp) + Box( + modifier + .height(88.dp) + .graphicsLayer { + scaleX = scale + scaleY = scale + } + .shadow(8.dp, shape) + .clip(shape) + .background(Brush.verticalGradient(listOf(Color(0xFFFFFDF6), Color(0xFFEAE2CB)))) + .border(1.dp, GoldBrush, shape) + .clickable(interaction, ripple(color = GoldDeep), onClick = onClick), + contentAlignment = Alignment.Center, + ) { + Text("$value", color = Color(0xFF2E2717), fontFamily = Cinzel, fontWeight = FontWeight.Bold, fontSize = 34.sp) + } +} + +private fun mistakeText(mistake: CountingMistake?): String = when (mistake) { + CountingMistake.TRUMP_JACK_AS_PLAIN -> "Dečko u adutu vrijedi 20 bodova, a ne 2." + CountingMistake.TRUMP_NINE_AS_PLAIN -> "Devetka u adutu vrijedi 14 bodova, a ne 0." + CountingMistake.PLAIN_JACK_AS_TRUMP -> "Dečko izvan aduta vrijedi samo 2 boda." + CountingMistake.PLAIN_NINE_AS_TRUMP -> "Devetka izvan aduta ne nosi bodove." + CountingMistake.FORGOT_LAST_TRICK -> "Zadnji štih nosi još 10 bodova." + CountingMistake.ADDED_LAST_TRICK -> "Zadnji štih ovaj put nije bio vaš." + CountingMistake.MISSED_TEN -> "Jedna desetka nije ubrojena: svaka vrijedi 10." + CountingMistake.MISSED_ACE -> "Jedan as nije ubrojen: svaki vrijedi 11." + CountingMistake.KING_QUEEN_MIXUP -> "Kralj vrijedi 4, a dama 3." + null -> "Zbroj se ne slaže. Pogledaj vrijednosti karata ispod." +} + +private val GridGap = 8.dp +private val GridRowGap = 10.dp +private val PointsLabel = 22.dp + +/** + * Column count that makes [count] cards (each with its points label underneath) as large as possible in + * [width] x [height], and the card width that gives. Never wider than [maxCard]. + */ +private fun bestGrid(count: Int, width: Dp, height: Dp, maxCard: Dp): Pair { + var best = 1 to 0.dp + for (columns in 2..10) { + val rows = (count + columns - 1) / columns + val byWidth = (width - GridGap * (columns - 1)) / columns + val byHeight = ((height - GridRowGap * (rows - 1)) / rows - PointsLabel) * CARD_ASPECT + val card = minOf(byWidth, byHeight, maxCard) + if (card > best.second) best = columns to card + } + return best +} + +/** Verdict, then every card with its value and the sum, so the player sees where the count went wrong. */ +@Composable +private fun ResultStage(s: TrainingState) { + val round = s.round + val right = s.wasCorrect + Column( + Modifier.fillMaxSize().padding(top = 8.dp), + horizontalAlignment = Alignment.CenterHorizontally, + ) { + Text( + if (right) "Točno!" else "Netočno", + color = if (right) WinGreen else LossRed, + fontFamily = Cinzel, + fontWeight = FontWeight.Black, + fontSize = 34.sp, + ) + if (right) { + Text( + if (s.streak > 1) "Niz od ${s.streak} točnih odgovora." else "Bravo, zbroj je ${round.total}.", + color = Cream, + fontSize = 14.sp, + textAlign = TextAlign.Center, + ) + } else { + Text("Točno je ${round.total}, odabrano ${s.chosen?.value}.", color = Cream, fontSize = 15.sp, fontWeight = FontWeight.SemiBold) + Text( + mistakeText(s.chosen?.mistake), + color = CreamMuted, + fontSize = 14.sp, + textAlign = TextAlign.Center, + modifier = Modifier.padding(top = 4.dp), + ) + } + Ornament(Modifier.padding(vertical = 12.dp)) + // The cards fill whatever room is left, as large as they fit. + BoxWithConstraints(Modifier.weight(1f).fillMaxWidth(), contentAlignment = Alignment.Center) { + val cards = sortHand(round.cards, round.trump) + val (columns, cardWidth) = bestGrid(cards.size, maxWidth, maxHeight, maxCardWidth()) + Column(verticalArrangement = Arrangement.spacedBy(GridRowGap)) { + cards.chunked(columns).forEach { row -> + Row(horizontalArrangement = Arrangement.spacedBy(GridGap), modifier = Modifier.align(Alignment.CenterHorizontally)) { + row.forEach { card -> + val points = card.points(round.trump) + val isTrump = card.suit == round.trump + Column(horizontalAlignment = Alignment.CenterHorizontally) { + CardFace(card, Modifier.width(cardWidth), highlighted = isTrump && points >= 14, elevation = 4.dp) + Text( + "$points", + color = when { + isTrump && points > 0 -> Gold + points > 0 -> Cream + else -> CreamMuted + }, + fontFamily = Cinzel, + fontWeight = FontWeight.Bold, + fontSize = 14.sp, + modifier = Modifier.height(PointsLabel).padding(top = 3.dp), + ) + } + } + } + } + } + } + Text( + buildString { + append("Karte ${round.cardPoints}") + if (round.lastTrick) append(" + zadnji štih 10") + append(" = ${round.total}") + }, + color = Gold, + fontFamily = Cinzel, + fontWeight = FontWeight.Bold, + fontSize = 16.sp, + modifier = Modifier.padding(top = 12.dp, bottom = 4.dp), + ) + } +} diff --git a/app/src/main/kotlin/hr/bela/app/update/Updates.kt b/app/src/main/kotlin/hr/bela/app/update/Updates.kt new file mode 100644 index 0000000..9ac65a2 --- /dev/null +++ b/app/src/main/kotlin/hr/bela/app/update/Updates.kt @@ -0,0 +1,163 @@ +package hr.bela.app.update + +import android.content.Context +import android.content.Intent +import android.net.Uri +import android.provider.Settings +import androidx.core.content.FileProvider +import hr.bela.app.BuildConfig +import kotlinx.coroutines.Dispatchers +import kotlinx.coroutines.withContext +import org.json.JSONObject +import java.io.File +import java.io.IOException +import java.net.HttpURLConnection +import java.net.URL +import java.security.MessageDigest + +/** The public repository the app is released to (one Gitea release per version, APK attached as [APK_NAME]). */ +object ReleaseChannel { + const val REPO_URL = "https://git.mariosem.es/msemes/Bela-Release-Android" + const val API_LATEST = "https://git.mariosem.es/api/v1/repos/msemes/Bela-Release-Android/releases/latest" + + /** Every release attaches the APK under this same name, so [LATEST_APK_URL] never changes. */ + const val APK_NAME = "bela.apk" + + /** Always the newest APK: the server resolves "latest" to the newest release. Used for the QR code. */ + const val LATEST_APK_URL = "$REPO_URL/releases/download/latest/$APK_NAME" + const val RELEASES_PAGE = "$REPO_URL/releases" +} + +data class ReleaseInfo( + val versionName: String, + val versionCode: Int, + val apkUrl: String, + val notes: String?, + val sha256: String?, +) + +sealed interface UpdateCheck { + data class Available(val release: ReleaseInfo) : UpdateCheck + data class UpToDate(val latest: ReleaseInfo) : UpdateCheck + data object NoReleases : UpdateCheck + data class Failed(val message: String) : UpdateCheck +} + +/** + * In-app self-update, same scheme as the Keep app: read the latest release from the public release repo, + * compare its version with the running build, download the APK (checking the published SHA-256) and hand it + * to the system installer, which asks the user to confirm. + */ +class Updates(private val context: Context) { + + suspend fun check(): UpdateCheck = withContext(Dispatchers.IO) { + try { + val connection = open(ReleaseChannel.API_LATEST).apply { setRequestProperty("Accept", "application/json") } + val code = connection.responseCode + if (code == HttpURLConnection.HTTP_NOT_FOUND) return@withContext UpdateCheck.NoReleases + if (code !in 200..299) return@withContext UpdateCheck.Failed("Server je odgovorio $code") + val json = JSONObject(connection.inputStream.bufferedReader().use { it.readText() }) + + val versionName = json.optString("tag_name").removePrefix("v") + val versionCode = versionCodeOf(versionName) + ?: return@withContext UpdateCheck.Failed("Nepoznata oznaka verzije: ${json.optString("tag_name")}") + val assets = json.optJSONArray("assets") + val apk = (0 until (assets?.length() ?: 0)).map { assets!!.getJSONObject(it) } + .firstOrNull { it.optString("name") == ReleaseChannel.APK_NAME } + ?: return@withContext UpdateCheck.Failed("Izdanje nema APK") + val body = json.optString("body") + val release = ReleaseInfo( + versionName = versionName, + versionCode = versionCode, + apkUrl = apk.optString("browser_download_url"), + notes = SHA256_LINE.replace(body, "").trim().takeIf { it.isNotBlank() }, + sha256 = SHA256_LINE.find(body)?.groupValues?.get(1)?.lowercase(), + ) + if (versionCode > BuildConfig.VERSION_CODE) UpdateCheck.Available(release) else UpdateCheck.UpToDate(release) + } catch (e: IOException) { + UpdateCheck.Failed("Nema veze sa serverom") + } catch (e: Exception) { + UpdateCheck.Failed(e.message ?: "Provjera nije uspjela") + } + } + + /** Streams the APK to the app's cache, reporting progress 0..1 (or -1 when the size is unknown). */ + suspend fun download(release: ReleaseInfo, onProgress: (Float) -> Unit): File = withContext(Dispatchers.IO) { + val dir = File(context.externalCacheDir ?: context.cacheDir, "updates").apply { mkdirs() } + dir.listFiles()?.forEach { it.delete() } + val file = File(dir, "bela-${release.versionName}.apk") + val connection = open(release.apkUrl) + if (connection.responseCode !in 200..299) throw IOException("Preuzimanje nije uspjelo (${connection.responseCode})") + val total = connection.contentLengthLong + connection.inputStream.use { input -> + file.outputStream().use { output -> + val buffer = ByteArray(64 * 1024) + var done = 0L + while (true) { + val read = input.read(buffer) + if (read < 0) break + output.write(buffer, 0, read) + done += read + onProgress(if (total > 0) done.toFloat() / total else -1f) + } + } + } + val expected = release.sha256 + if (expected != null && !sha256Hex(file).equals(expected, ignoreCase = true)) { + file.delete() + throw IOException("Preuzeta datoteka nije ispravna (kontrolni zbroj se ne slaže)") + } + file + } + + /** Whether Android currently lets this app open the package installer. */ + fun canInstall(): Boolean = context.packageManager.canRequestPackageInstalls() + + /** The "install unknown apps" switch for this app. */ + fun openInstallPermissionSettings() { + val intent = Intent(Settings.ACTION_MANAGE_UNKNOWN_APP_SOURCES, Uri.parse("package:${context.packageName}")) + .addFlags(Intent.FLAG_ACTIVITY_NEW_TASK) + runCatching { context.startActivity(intent) } + } + + /** Opens the system installer for [apk]; Android asks the user to confirm the update. */ + fun install(apk: File) { + val uri = FileProvider.getUriForFile(context, "${context.packageName}.updates", apk) + val intent = Intent(Intent.ACTION_VIEW) + .setDataAndType(uri, "application/vnd.android.package-archive") + .addFlags(Intent.FLAG_GRANT_READ_URI_PERMISSION or Intent.FLAG_ACTIVITY_NEW_TASK) + context.startActivity(intent) + } + + private fun open(url: String): HttpURLConnection = + (URL(url).openConnection() as HttpURLConnection).apply { + connectTimeout = 15_000 + readTimeout = 60_000 + instanceFollowRedirects = true + } + + private fun sha256Hex(file: File): String { + val digest = MessageDigest.getInstance("SHA-256") + file.inputStream().use { input -> + val buffer = ByteArray(64 * 1024) + while (true) { + val read = input.read(buffer) + if (read < 0) break + digest.update(buffer, 0, read) + } + } + return digest.digest().joinToString("") { "%02x".format(it) } + } + + companion object { + /** Integrity line in the release notes, written by tools/build-release.ps1: "sha256:<64 hex>". */ + private val SHA256_LINE = Regex("(?im)^\\s*sha256:([0-9a-f]{64})\\s*$") + + /** Inverse of the odometer versionName in app/build.gradle.kts: "0.1.3" -> 13. */ + fun versionCodeOf(versionName: String): Int? { + val parts = versionName.split('.').map { it.toIntOrNull() ?: return null } + if (parts.size != 3 || parts[1] !in 0..9 || parts[2] !in 0..9) return null + return parts[0] * 100 + parts[1] * 10 + parts[2] + } + } +} diff --git a/app/src/main/res/drawable-nodpi/card_list_10.webp b/app/src/main/res/drawable-nodpi/card_list_10.webp new file mode 100644 index 0000000..a96363d Binary files /dev/null and b/app/src/main/res/drawable-nodpi/card_list_10.webp differ diff --git a/app/src/main/res/drawable-nodpi/card_list_7.webp b/app/src/main/res/drawable-nodpi/card_list_7.webp new file mode 100644 index 0000000..9f4f97b Binary files /dev/null and b/app/src/main/res/drawable-nodpi/card_list_7.webp differ diff --git a/app/src/main/res/drawable-nodpi/card_list_8.webp b/app/src/main/res/drawable-nodpi/card_list_8.webp new file mode 100644 index 0000000..8698cc1 Binary files /dev/null and b/app/src/main/res/drawable-nodpi/card_list_8.webp differ diff --git a/app/src/main/res/drawable-nodpi/card_list_9.webp b/app/src/main/res/drawable-nodpi/card_list_9.webp new file mode 100644 index 0000000..2ecc2b5 Binary files /dev/null and b/app/src/main/res/drawable-nodpi/card_list_9.webp differ diff --git a/app/src/main/res/drawable-nodpi/card_list_as.webp b/app/src/main/res/drawable-nodpi/card_list_as.webp new file mode 100644 index 0000000..06b6c2c Binary files /dev/null and b/app/src/main/res/drawable-nodpi/card_list_as.webp differ diff --git a/app/src/main/res/drawable-nodpi/card_list_dama.webp b/app/src/main/res/drawable-nodpi/card_list_dama.webp new file mode 100644 index 0000000..a76aa03 Binary files /dev/null and b/app/src/main/res/drawable-nodpi/card_list_dama.webp differ diff --git a/app/src/main/res/drawable-nodpi/card_list_decko.webp b/app/src/main/res/drawable-nodpi/card_list_decko.webp new file mode 100644 index 0000000..caad5f3 Binary files /dev/null and b/app/src/main/res/drawable-nodpi/card_list_decko.webp differ diff --git a/app/src/main/res/drawable-nodpi/card_list_kralj.webp b/app/src/main/res/drawable-nodpi/card_list_kralj.webp new file mode 100644 index 0000000..3a5b8d5 Binary files /dev/null and b/app/src/main/res/drawable-nodpi/card_list_kralj.webp differ diff --git a/app/src/main/res/drawable-nodpi/card_srce_10.webp b/app/src/main/res/drawable-nodpi/card_srce_10.webp new file mode 100644 index 0000000..2d88657 Binary files /dev/null and b/app/src/main/res/drawable-nodpi/card_srce_10.webp differ diff --git a/app/src/main/res/drawable-nodpi/card_srce_7.webp b/app/src/main/res/drawable-nodpi/card_srce_7.webp new file mode 100644 index 0000000..7b107e3 Binary files /dev/null and b/app/src/main/res/drawable-nodpi/card_srce_7.webp differ diff --git a/app/src/main/res/drawable-nodpi/card_srce_8.webp b/app/src/main/res/drawable-nodpi/card_srce_8.webp new file mode 100644 index 0000000..3f3e2ed Binary files /dev/null and b/app/src/main/res/drawable-nodpi/card_srce_8.webp differ diff --git a/app/src/main/res/drawable-nodpi/card_srce_9.webp b/app/src/main/res/drawable-nodpi/card_srce_9.webp new file mode 100644 index 0000000..6ae0b0c Binary files /dev/null and b/app/src/main/res/drawable-nodpi/card_srce_9.webp differ diff --git a/app/src/main/res/drawable-nodpi/card_srce_as.webp b/app/src/main/res/drawable-nodpi/card_srce_as.webp new file mode 100644 index 0000000..d6d0bf9 Binary files /dev/null and b/app/src/main/res/drawable-nodpi/card_srce_as.webp differ diff --git a/app/src/main/res/drawable-nodpi/card_srce_dama.webp b/app/src/main/res/drawable-nodpi/card_srce_dama.webp new file mode 100644 index 0000000..a1f1425 Binary files /dev/null and b/app/src/main/res/drawable-nodpi/card_srce_dama.webp differ diff --git a/app/src/main/res/drawable-nodpi/card_srce_decko.webp b/app/src/main/res/drawable-nodpi/card_srce_decko.webp new file mode 100644 index 0000000..512c875 Binary files /dev/null and b/app/src/main/res/drawable-nodpi/card_srce_decko.webp differ diff --git a/app/src/main/res/drawable-nodpi/card_srce_kralj.webp b/app/src/main/res/drawable-nodpi/card_srce_kralj.webp new file mode 100644 index 0000000..c6ffe09 Binary files /dev/null and b/app/src/main/res/drawable-nodpi/card_srce_kralj.webp differ diff --git a/app/src/main/res/drawable-nodpi/card_zir_10.webp b/app/src/main/res/drawable-nodpi/card_zir_10.webp new file mode 100644 index 0000000..ffb209a Binary files /dev/null and b/app/src/main/res/drawable-nodpi/card_zir_10.webp differ diff --git a/app/src/main/res/drawable-nodpi/card_zir_7.webp b/app/src/main/res/drawable-nodpi/card_zir_7.webp new file mode 100644 index 0000000..e2a4b8d Binary files /dev/null and b/app/src/main/res/drawable-nodpi/card_zir_7.webp differ diff --git a/app/src/main/res/drawable-nodpi/card_zir_8.webp b/app/src/main/res/drawable-nodpi/card_zir_8.webp new file mode 100644 index 0000000..7dfdf19 Binary files /dev/null and b/app/src/main/res/drawable-nodpi/card_zir_8.webp differ diff --git a/app/src/main/res/drawable-nodpi/card_zir_9.webp b/app/src/main/res/drawable-nodpi/card_zir_9.webp new file mode 100644 index 0000000..79b2f8d Binary files /dev/null and b/app/src/main/res/drawable-nodpi/card_zir_9.webp differ diff --git a/app/src/main/res/drawable-nodpi/card_zir_as.webp b/app/src/main/res/drawable-nodpi/card_zir_as.webp new file mode 100644 index 0000000..d32852d Binary files /dev/null and b/app/src/main/res/drawable-nodpi/card_zir_as.webp differ diff --git a/app/src/main/res/drawable-nodpi/card_zir_dama.webp b/app/src/main/res/drawable-nodpi/card_zir_dama.webp new file mode 100644 index 0000000..3a622ec Binary files /dev/null and b/app/src/main/res/drawable-nodpi/card_zir_dama.webp differ diff --git a/app/src/main/res/drawable-nodpi/card_zir_decko.webp b/app/src/main/res/drawable-nodpi/card_zir_decko.webp new file mode 100644 index 0000000..82312d7 Binary files /dev/null and b/app/src/main/res/drawable-nodpi/card_zir_decko.webp differ diff --git a/app/src/main/res/drawable-nodpi/card_zir_kralj.webp b/app/src/main/res/drawable-nodpi/card_zir_kralj.webp new file mode 100644 index 0000000..218bc43 Binary files /dev/null and b/app/src/main/res/drawable-nodpi/card_zir_kralj.webp differ diff --git a/app/src/main/res/drawable-nodpi/card_zvono_10.webp b/app/src/main/res/drawable-nodpi/card_zvono_10.webp new file mode 100644 index 0000000..7cfe7f2 Binary files /dev/null and b/app/src/main/res/drawable-nodpi/card_zvono_10.webp differ diff --git a/app/src/main/res/drawable-nodpi/card_zvono_7.webp b/app/src/main/res/drawable-nodpi/card_zvono_7.webp new file mode 100644 index 0000000..0deea82 Binary files /dev/null and b/app/src/main/res/drawable-nodpi/card_zvono_7.webp differ diff --git a/app/src/main/res/drawable-nodpi/card_zvono_8.webp b/app/src/main/res/drawable-nodpi/card_zvono_8.webp new file mode 100644 index 0000000..2e98c6e Binary files /dev/null and b/app/src/main/res/drawable-nodpi/card_zvono_8.webp differ diff --git a/app/src/main/res/drawable-nodpi/card_zvono_9.webp b/app/src/main/res/drawable-nodpi/card_zvono_9.webp new file mode 100644 index 0000000..54b7536 Binary files /dev/null and b/app/src/main/res/drawable-nodpi/card_zvono_9.webp differ diff --git a/app/src/main/res/drawable-nodpi/card_zvono_as.webp b/app/src/main/res/drawable-nodpi/card_zvono_as.webp new file mode 100644 index 0000000..14195d3 Binary files /dev/null and b/app/src/main/res/drawable-nodpi/card_zvono_as.webp differ diff --git a/app/src/main/res/drawable-nodpi/card_zvono_dama.webp b/app/src/main/res/drawable-nodpi/card_zvono_dama.webp new file mode 100644 index 0000000..4d6d607 Binary files /dev/null and b/app/src/main/res/drawable-nodpi/card_zvono_dama.webp differ diff --git a/app/src/main/res/drawable-nodpi/card_zvono_decko.webp b/app/src/main/res/drawable-nodpi/card_zvono_decko.webp new file mode 100644 index 0000000..10d7d74 Binary files /dev/null and b/app/src/main/res/drawable-nodpi/card_zvono_decko.webp differ diff --git a/app/src/main/res/drawable-nodpi/card_zvono_kralj.webp b/app/src/main/res/drawable-nodpi/card_zvono_kralj.webp new file mode 100644 index 0000000..252cf70 Binary files /dev/null and b/app/src/main/res/drawable-nodpi/card_zvono_kralj.webp differ diff --git a/app/src/main/res/drawable-nodpi/logo.webp b/app/src/main/res/drawable-nodpi/logo.webp new file mode 100644 index 0000000..46fa59b Binary files /dev/null and b/app/src/main/res/drawable-nodpi/logo.webp differ diff --git a/app/src/main/res/drawable-nodpi/suit_list.webp b/app/src/main/res/drawable-nodpi/suit_list.webp new file mode 100644 index 0000000..26f8d6b Binary files /dev/null and b/app/src/main/res/drawable-nodpi/suit_list.webp differ diff --git a/app/src/main/res/drawable-nodpi/suit_srce.webp b/app/src/main/res/drawable-nodpi/suit_srce.webp new file mode 100644 index 0000000..de70571 Binary files /dev/null and b/app/src/main/res/drawable-nodpi/suit_srce.webp differ diff --git a/app/src/main/res/drawable-nodpi/suit_zir.webp b/app/src/main/res/drawable-nodpi/suit_zir.webp new file mode 100644 index 0000000..be72415 Binary files /dev/null and b/app/src/main/res/drawable-nodpi/suit_zir.webp differ diff --git a/app/src/main/res/drawable-nodpi/suit_zvono.webp b/app/src/main/res/drawable-nodpi/suit_zvono.webp new file mode 100644 index 0000000..97ea8a5 Binary files /dev/null and b/app/src/main/res/drawable-nodpi/suit_zvono.webp differ diff --git a/app/src/main/res/font/cinzel.ttf b/app/src/main/res/font/cinzel.ttf new file mode 100644 index 0000000..d218a0b Binary files /dev/null and b/app/src/main/res/font/cinzel.ttf differ diff --git a/app/src/main/res/font/inter.ttf b/app/src/main/res/font/inter.ttf new file mode 100644 index 0000000..047c92f Binary files /dev/null and b/app/src/main/res/font/inter.ttf differ diff --git a/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml b/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml new file mode 100644 index 0000000..dc26a94 --- /dev/null +++ b/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml @@ -0,0 +1,6 @@ + + + + + + diff --git a/app/src/main/res/mipmap-hdpi/ic_launcher_foreground.webp b/app/src/main/res/mipmap-hdpi/ic_launcher_foreground.webp new file mode 100644 index 0000000..a45f3b5 Binary files /dev/null and b/app/src/main/res/mipmap-hdpi/ic_launcher_foreground.webp differ diff --git a/app/src/main/res/mipmap-mdpi/ic_launcher_foreground.webp b/app/src/main/res/mipmap-mdpi/ic_launcher_foreground.webp new file mode 100644 index 0000000..d151d7d Binary files /dev/null and b/app/src/main/res/mipmap-mdpi/ic_launcher_foreground.webp differ diff --git a/app/src/main/res/mipmap-xhdpi/ic_launcher_foreground.webp b/app/src/main/res/mipmap-xhdpi/ic_launcher_foreground.webp new file mode 100644 index 0000000..c361f21 Binary files /dev/null and b/app/src/main/res/mipmap-xhdpi/ic_launcher_foreground.webp differ diff --git a/app/src/main/res/mipmap-xxhdpi/ic_launcher_foreground.webp b/app/src/main/res/mipmap-xxhdpi/ic_launcher_foreground.webp new file mode 100644 index 0000000..7363bf9 Binary files /dev/null and b/app/src/main/res/mipmap-xxhdpi/ic_launcher_foreground.webp differ diff --git a/app/src/main/res/mipmap-xxxhdpi/ic_launcher_foreground.webp b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_foreground.webp new file mode 100644 index 0000000..52ddfa7 Binary files /dev/null and b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_foreground.webp differ diff --git a/app/src/main/res/values/colors.xml b/app/src/main/res/values/colors.xml new file mode 100644 index 0000000..46ccd03 --- /dev/null +++ b/app/src/main/res/values/colors.xml @@ -0,0 +1,4 @@ + + #1F5C3A + #123722 + diff --git a/app/src/main/res/values/ic_launcher_background.xml b/app/src/main/res/values/ic_launcher_background.xml new file mode 100644 index 0000000..809b333 --- /dev/null +++ b/app/src/main/res/values/ic_launcher_background.xml @@ -0,0 +1,4 @@ + + + #042608 + diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml new file mode 100644 index 0000000..acb4402 --- /dev/null +++ b/app/src/main/res/values/strings.xml @@ -0,0 +1,3 @@ + + Bela + diff --git a/app/src/main/res/values/themes.xml b/app/src/main/res/values/themes.xml new file mode 100644 index 0000000..1289412 --- /dev/null +++ b/app/src/main/res/values/themes.xml @@ -0,0 +1,8 @@ + + + + diff --git a/app/src/main/res/xml/update_paths.xml b/app/src/main/res/xml/update_paths.xml new file mode 100644 index 0000000..39eac47 --- /dev/null +++ b/app/src/main/res/xml/update_paths.xml @@ -0,0 +1,6 @@ + + + + + + diff --git a/build.gradle.kts b/build.gradle.kts new file mode 100644 index 0000000..59831f6 --- /dev/null +++ b/build.gradle.kts @@ -0,0 +1,5 @@ +plugins { + alias(libs.plugins.android.application) apply false + alias(libs.plugins.kotlin.jvm) apply false + alias(libs.plugins.compose.compiler) apply false +} diff --git a/card_assets/hungarian-playing-cards/NOTICE.md b/card_assets/hungarian-playing-cards/NOTICE.md new file mode 100644 index 0000000..0455419 --- /dev/null +++ b/card_assets/hungarian-playing-cards/NOTICE.md @@ -0,0 +1,8 @@ +# Source and licence + +Copied from https://github.com/tomasdrus/hungarian-playing-cards (commit in `SOURCE_COMMIT.txt`): +`cards-large/` (32 cards + back, 363 x 585 px PNG) and the large suit icons. + +**The repository has no licence.** Without one, all rights are reserved by the author. These images are fine for +local development, but before the app is published we need written permission from the author (or a licence +added to the repository), or we switch back to our own SVG cards (`python tools/render_cards.py`). diff --git a/card_assets/hungarian-playing-cards/README.md b/card_assets/hungarian-playing-cards/README.md new file mode 100644 index 0000000..a689b5e --- /dev/null +++ b/card_assets/hungarian-playing-cards/README.md @@ -0,0 +1,47 @@ +# Hungarian playing cards PNG images + +Images of each card from full deck of Hungarian playing cards (32 cards) also know as European / German type / Tell / Magyar kártya / Mariášové karty. +In addition back side of one of the cards => 32+1 images of cards. + +![preview of all cards](https://github.com/tomasdrus/hungarian-playing-cards/blob/master/all-cards-preview.jpg?raw=true) + +Every image has transparent background and PNG format. + +## 3 image sizes (300dpi) + +- Large / 363x585px / 271-423kB / all 11,4MB +- Medium / 181x293px / 75-112kB / all 3,1MB +- Small / 91x146px / 22-31kB / all 880kB + +## 3 suits icon sizes + +Every suit from cards has 3 icon sizes: small, medium and large. + +## Card suits + +- Hearts + + ![preview of all cards](https://github.com/tomasdrus/hungarian-playing-cards/blob/master/suit-icons/heart-icon%40small.png?raw=true) + +- Leaves + + ![preview of all cards](https://github.com/tomasdrus/hungarian-playing-cards/blob/master/suit-icons/leaf-icon%40small.png?raw=true) + +- Bells + + ![preview of all cards](https://github.com/tomasdrus/hungarian-playing-cards/blob/master/suit-icons/bell-icon%40small.png?raw=true) + +- Acorns + + ![preview of all cards](https://github.com/tomasdrus/hungarian-playing-cards/blob/master/suit-icons/acorn-icon%40small.png?raw=true) + +## Card values + +- Ace +- King +- Ober (Over-knave) +- Unter (Under-knave) +- X (10) +- IX (9) +- VII (8) +- VI (7) diff --git a/card_assets/hungarian-playing-cards/SOURCE_COMMIT.txt b/card_assets/hungarian-playing-cards/SOURCE_COMMIT.txt new file mode 100644 index 0000000..780efa3 --- /dev/null +++ b/card_assets/hungarian-playing-cards/SOURCE_COMMIT.txt @@ -0,0 +1 @@ +6c4c7252af5aef50e189bc033ca4f69feb469b69 Thu Sep 9 00:01:28 2021 +0200 diff --git a/card_assets/hungarian-playing-cards/cards-2x/acorn-ace.webp b/card_assets/hungarian-playing-cards/cards-2x/acorn-ace.webp new file mode 100644 index 0000000..4a5aea5 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-2x/acorn-ace.webp differ diff --git a/card_assets/hungarian-playing-cards/cards-2x/acorn-eight.webp b/card_assets/hungarian-playing-cards/cards-2x/acorn-eight.webp new file mode 100644 index 0000000..be14291 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-2x/acorn-eight.webp differ diff --git a/card_assets/hungarian-playing-cards/cards-2x/acorn-king.webp b/card_assets/hungarian-playing-cards/cards-2x/acorn-king.webp new file mode 100644 index 0000000..c7ff59d Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-2x/acorn-king.webp differ diff --git a/card_assets/hungarian-playing-cards/cards-2x/acorn-nine.webp b/card_assets/hungarian-playing-cards/cards-2x/acorn-nine.webp new file mode 100644 index 0000000..1ece255 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-2x/acorn-nine.webp differ diff --git a/card_assets/hungarian-playing-cards/cards-2x/acorn-ober.webp b/card_assets/hungarian-playing-cards/cards-2x/acorn-ober.webp new file mode 100644 index 0000000..aec105e Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-2x/acorn-ober.webp differ diff --git a/card_assets/hungarian-playing-cards/cards-2x/acorn-seven.webp b/card_assets/hungarian-playing-cards/cards-2x/acorn-seven.webp new file mode 100644 index 0000000..f4e4638 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-2x/acorn-seven.webp differ diff --git a/card_assets/hungarian-playing-cards/cards-2x/acorn-ten.webp b/card_assets/hungarian-playing-cards/cards-2x/acorn-ten.webp new file mode 100644 index 0000000..f2ca8f1 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-2x/acorn-ten.webp differ diff --git a/card_assets/hungarian-playing-cards/cards-2x/acorn-unter.webp b/card_assets/hungarian-playing-cards/cards-2x/acorn-unter.webp new file mode 100644 index 0000000..3ba21d8 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-2x/acorn-unter.webp differ diff --git a/card_assets/hungarian-playing-cards/cards-2x/bell-ace.webp b/card_assets/hungarian-playing-cards/cards-2x/bell-ace.webp new file mode 100644 index 0000000..0816ef2 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-2x/bell-ace.webp differ diff --git a/card_assets/hungarian-playing-cards/cards-2x/bell-eight.webp b/card_assets/hungarian-playing-cards/cards-2x/bell-eight.webp new file mode 100644 index 0000000..4109cca Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-2x/bell-eight.webp differ diff --git a/card_assets/hungarian-playing-cards/cards-2x/bell-king.webp b/card_assets/hungarian-playing-cards/cards-2x/bell-king.webp new file mode 100644 index 0000000..b7e01f3 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-2x/bell-king.webp differ diff --git a/card_assets/hungarian-playing-cards/cards-2x/bell-nine.webp b/card_assets/hungarian-playing-cards/cards-2x/bell-nine.webp new file mode 100644 index 0000000..8b4c91f Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-2x/bell-nine.webp differ diff --git a/card_assets/hungarian-playing-cards/cards-2x/bell-ober.webp b/card_assets/hungarian-playing-cards/cards-2x/bell-ober.webp new file mode 100644 index 0000000..6911609 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-2x/bell-ober.webp differ diff --git a/card_assets/hungarian-playing-cards/cards-2x/bell-seven.webp b/card_assets/hungarian-playing-cards/cards-2x/bell-seven.webp new file mode 100644 index 0000000..52efff0 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-2x/bell-seven.webp differ diff --git a/card_assets/hungarian-playing-cards/cards-2x/bell-ten.webp b/card_assets/hungarian-playing-cards/cards-2x/bell-ten.webp new file mode 100644 index 0000000..6835a01 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-2x/bell-ten.webp differ diff --git a/card_assets/hungarian-playing-cards/cards-2x/bell-unter.webp b/card_assets/hungarian-playing-cards/cards-2x/bell-unter.webp new file mode 100644 index 0000000..e1477fa Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-2x/bell-unter.webp differ diff --git a/card_assets/hungarian-playing-cards/cards-2x/heart-ace.webp b/card_assets/hungarian-playing-cards/cards-2x/heart-ace.webp new file mode 100644 index 0000000..b16485e Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-2x/heart-ace.webp differ diff --git a/card_assets/hungarian-playing-cards/cards-2x/heart-eight.webp b/card_assets/hungarian-playing-cards/cards-2x/heart-eight.webp new file mode 100644 index 0000000..b02fabe Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-2x/heart-eight.webp differ diff --git a/card_assets/hungarian-playing-cards/cards-2x/heart-king.webp b/card_assets/hungarian-playing-cards/cards-2x/heart-king.webp new file mode 100644 index 0000000..bd5ec4b Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-2x/heart-king.webp differ diff --git a/card_assets/hungarian-playing-cards/cards-2x/heart-nine.webp b/card_assets/hungarian-playing-cards/cards-2x/heart-nine.webp new file mode 100644 index 0000000..f0eb011 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-2x/heart-nine.webp differ diff --git a/card_assets/hungarian-playing-cards/cards-2x/heart-ober.webp b/card_assets/hungarian-playing-cards/cards-2x/heart-ober.webp new file mode 100644 index 0000000..15549d3 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-2x/heart-ober.webp differ diff --git a/card_assets/hungarian-playing-cards/cards-2x/heart-seven.webp b/card_assets/hungarian-playing-cards/cards-2x/heart-seven.webp new file mode 100644 index 0000000..e311511 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-2x/heart-seven.webp differ diff --git a/card_assets/hungarian-playing-cards/cards-2x/heart-ten.webp b/card_assets/hungarian-playing-cards/cards-2x/heart-ten.webp new file mode 100644 index 0000000..ec60e77 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-2x/heart-ten.webp differ diff --git a/card_assets/hungarian-playing-cards/cards-2x/heart-unter.webp b/card_assets/hungarian-playing-cards/cards-2x/heart-unter.webp new file mode 100644 index 0000000..9d22c3a Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-2x/heart-unter.webp differ diff --git a/card_assets/hungarian-playing-cards/cards-2x/leaf-ace.webp b/card_assets/hungarian-playing-cards/cards-2x/leaf-ace.webp new file mode 100644 index 0000000..45fd434 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-2x/leaf-ace.webp differ diff --git a/card_assets/hungarian-playing-cards/cards-2x/leaf-eight.webp b/card_assets/hungarian-playing-cards/cards-2x/leaf-eight.webp new file mode 100644 index 0000000..bdbbb72 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-2x/leaf-eight.webp differ diff --git a/card_assets/hungarian-playing-cards/cards-2x/leaf-king.webp b/card_assets/hungarian-playing-cards/cards-2x/leaf-king.webp new file mode 100644 index 0000000..6e767a7 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-2x/leaf-king.webp differ diff --git a/card_assets/hungarian-playing-cards/cards-2x/leaf-nine.webp b/card_assets/hungarian-playing-cards/cards-2x/leaf-nine.webp new file mode 100644 index 0000000..6b60828 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-2x/leaf-nine.webp differ diff --git a/card_assets/hungarian-playing-cards/cards-2x/leaf-ober.webp b/card_assets/hungarian-playing-cards/cards-2x/leaf-ober.webp new file mode 100644 index 0000000..f41e0ca Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-2x/leaf-ober.webp differ diff --git a/card_assets/hungarian-playing-cards/cards-2x/leaf-seven.webp b/card_assets/hungarian-playing-cards/cards-2x/leaf-seven.webp new file mode 100644 index 0000000..b06121f Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-2x/leaf-seven.webp differ diff --git a/card_assets/hungarian-playing-cards/cards-2x/leaf-ten.webp b/card_assets/hungarian-playing-cards/cards-2x/leaf-ten.webp new file mode 100644 index 0000000..8926474 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-2x/leaf-ten.webp differ diff --git a/card_assets/hungarian-playing-cards/cards-2x/leaf-unter.webp b/card_assets/hungarian-playing-cards/cards-2x/leaf-unter.webp new file mode 100644 index 0000000..5cd889a Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-2x/leaf-unter.webp differ diff --git a/card_assets/hungarian-playing-cards/cards-large/acorn-ace.png b/card_assets/hungarian-playing-cards/cards-large/acorn-ace.png new file mode 100644 index 0000000..5ca3dfb Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-large/acorn-ace.png differ diff --git a/card_assets/hungarian-playing-cards/cards-large/acorn-eight.png b/card_assets/hungarian-playing-cards/cards-large/acorn-eight.png new file mode 100644 index 0000000..2d952d0 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-large/acorn-eight.png differ diff --git a/card_assets/hungarian-playing-cards/cards-large/acorn-king.png b/card_assets/hungarian-playing-cards/cards-large/acorn-king.png new file mode 100644 index 0000000..28becdb Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-large/acorn-king.png differ diff --git a/card_assets/hungarian-playing-cards/cards-large/acorn-nine.png b/card_assets/hungarian-playing-cards/cards-large/acorn-nine.png new file mode 100644 index 0000000..4870ca4 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-large/acorn-nine.png differ diff --git a/card_assets/hungarian-playing-cards/cards-large/acorn-ober.png b/card_assets/hungarian-playing-cards/cards-large/acorn-ober.png new file mode 100644 index 0000000..55a6702 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-large/acorn-ober.png differ diff --git a/card_assets/hungarian-playing-cards/cards-large/acorn-seven.png b/card_assets/hungarian-playing-cards/cards-large/acorn-seven.png new file mode 100644 index 0000000..4013841 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-large/acorn-seven.png differ diff --git a/card_assets/hungarian-playing-cards/cards-large/acorn-ten.png b/card_assets/hungarian-playing-cards/cards-large/acorn-ten.png new file mode 100644 index 0000000..9f40dc2 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-large/acorn-ten.png differ diff --git a/card_assets/hungarian-playing-cards/cards-large/acorn-unter.png b/card_assets/hungarian-playing-cards/cards-large/acorn-unter.png new file mode 100644 index 0000000..885d6ec Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-large/acorn-unter.png differ diff --git a/card_assets/hungarian-playing-cards/cards-large/back.png b/card_assets/hungarian-playing-cards/cards-large/back.png new file mode 100644 index 0000000..3f2807a Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-large/back.png differ diff --git a/card_assets/hungarian-playing-cards/cards-large/bell-ace.png b/card_assets/hungarian-playing-cards/cards-large/bell-ace.png new file mode 100644 index 0000000..f4d304f Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-large/bell-ace.png differ diff --git a/card_assets/hungarian-playing-cards/cards-large/bell-eight.png b/card_assets/hungarian-playing-cards/cards-large/bell-eight.png new file mode 100644 index 0000000..6fb06bc Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-large/bell-eight.png differ diff --git a/card_assets/hungarian-playing-cards/cards-large/bell-king.png b/card_assets/hungarian-playing-cards/cards-large/bell-king.png new file mode 100644 index 0000000..fa70a79 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-large/bell-king.png differ diff --git a/card_assets/hungarian-playing-cards/cards-large/bell-nine.png b/card_assets/hungarian-playing-cards/cards-large/bell-nine.png new file mode 100644 index 0000000..715bf76 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-large/bell-nine.png differ diff --git a/card_assets/hungarian-playing-cards/cards-large/bell-ober.png b/card_assets/hungarian-playing-cards/cards-large/bell-ober.png new file mode 100644 index 0000000..9d85edb Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-large/bell-ober.png differ diff --git a/card_assets/hungarian-playing-cards/cards-large/bell-seven.png b/card_assets/hungarian-playing-cards/cards-large/bell-seven.png new file mode 100644 index 0000000..207ee83 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-large/bell-seven.png differ diff --git a/card_assets/hungarian-playing-cards/cards-large/bell-ten.png b/card_assets/hungarian-playing-cards/cards-large/bell-ten.png new file mode 100644 index 0000000..df17b91 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-large/bell-ten.png differ diff --git a/card_assets/hungarian-playing-cards/cards-large/bell-unter.png b/card_assets/hungarian-playing-cards/cards-large/bell-unter.png new file mode 100644 index 0000000..36887cb Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-large/bell-unter.png differ diff --git a/card_assets/hungarian-playing-cards/cards-large/heart-ace.png b/card_assets/hungarian-playing-cards/cards-large/heart-ace.png new file mode 100644 index 0000000..faf77da Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-large/heart-ace.png differ diff --git a/card_assets/hungarian-playing-cards/cards-large/heart-eight.png b/card_assets/hungarian-playing-cards/cards-large/heart-eight.png new file mode 100644 index 0000000..e5cbc4d Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-large/heart-eight.png differ diff --git a/card_assets/hungarian-playing-cards/cards-large/heart-king.png b/card_assets/hungarian-playing-cards/cards-large/heart-king.png new file mode 100644 index 0000000..46b4d17 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-large/heart-king.png differ diff --git a/card_assets/hungarian-playing-cards/cards-large/heart-nine.png b/card_assets/hungarian-playing-cards/cards-large/heart-nine.png new file mode 100644 index 0000000..19a3ed2 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-large/heart-nine.png differ diff --git a/card_assets/hungarian-playing-cards/cards-large/heart-ober.png b/card_assets/hungarian-playing-cards/cards-large/heart-ober.png new file mode 100644 index 0000000..c473cea Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-large/heart-ober.png differ diff --git a/card_assets/hungarian-playing-cards/cards-large/heart-seven.png b/card_assets/hungarian-playing-cards/cards-large/heart-seven.png new file mode 100644 index 0000000..20bacbc Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-large/heart-seven.png differ diff --git a/card_assets/hungarian-playing-cards/cards-large/heart-ten.png b/card_assets/hungarian-playing-cards/cards-large/heart-ten.png new file mode 100644 index 0000000..961f6a6 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-large/heart-ten.png differ diff --git a/card_assets/hungarian-playing-cards/cards-large/heart-unter.png b/card_assets/hungarian-playing-cards/cards-large/heart-unter.png new file mode 100644 index 0000000..49638d2 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-large/heart-unter.png differ diff --git a/card_assets/hungarian-playing-cards/cards-large/leaf-ace.png b/card_assets/hungarian-playing-cards/cards-large/leaf-ace.png new file mode 100644 index 0000000..1921aca Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-large/leaf-ace.png differ diff --git a/card_assets/hungarian-playing-cards/cards-large/leaf-eight.png b/card_assets/hungarian-playing-cards/cards-large/leaf-eight.png new file mode 100644 index 0000000..de92f58 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-large/leaf-eight.png differ diff --git a/card_assets/hungarian-playing-cards/cards-large/leaf-king.png b/card_assets/hungarian-playing-cards/cards-large/leaf-king.png new file mode 100644 index 0000000..117668c Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-large/leaf-king.png differ diff --git a/card_assets/hungarian-playing-cards/cards-large/leaf-nine.png b/card_assets/hungarian-playing-cards/cards-large/leaf-nine.png new file mode 100644 index 0000000..79f114a Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-large/leaf-nine.png differ diff --git a/card_assets/hungarian-playing-cards/cards-large/leaf-ober.png b/card_assets/hungarian-playing-cards/cards-large/leaf-ober.png new file mode 100644 index 0000000..70956a4 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-large/leaf-ober.png differ diff --git a/card_assets/hungarian-playing-cards/cards-large/leaf-seven.png b/card_assets/hungarian-playing-cards/cards-large/leaf-seven.png new file mode 100644 index 0000000..06531c5 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-large/leaf-seven.png differ diff --git a/card_assets/hungarian-playing-cards/cards-large/leaf-ten.png b/card_assets/hungarian-playing-cards/cards-large/leaf-ten.png new file mode 100644 index 0000000..e38aa55 Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-large/leaf-ten.png differ diff --git a/card_assets/hungarian-playing-cards/cards-large/leaf-unter.png b/card_assets/hungarian-playing-cards/cards-large/leaf-unter.png new file mode 100644 index 0000000..632ec8a Binary files /dev/null and b/card_assets/hungarian-playing-cards/cards-large/leaf-unter.png differ diff --git a/card_assets/hungarian-playing-cards/suit-icons/acorn-icon@large.png b/card_assets/hungarian-playing-cards/suit-icons/acorn-icon@large.png new file mode 100644 index 0000000..99eea2a Binary files /dev/null and b/card_assets/hungarian-playing-cards/suit-icons/acorn-icon@large.png differ diff --git a/card_assets/hungarian-playing-cards/suit-icons/bell-icon@large.png b/card_assets/hungarian-playing-cards/suit-icons/bell-icon@large.png new file mode 100644 index 0000000..83a1519 Binary files /dev/null and b/card_assets/hungarian-playing-cards/suit-icons/bell-icon@large.png differ diff --git a/card_assets/hungarian-playing-cards/suit-icons/heart-icon@large.png b/card_assets/hungarian-playing-cards/suit-icons/heart-icon@large.png new file mode 100644 index 0000000..d51a00a Binary files /dev/null and b/card_assets/hungarian-playing-cards/suit-icons/heart-icon@large.png differ diff --git a/card_assets/hungarian-playing-cards/suit-icons/leaf-icon@large.png b/card_assets/hungarian-playing-cards/suit-icons/leaf-icon@large.png new file mode 100644 index 0000000..1587b2f Binary files /dev/null and b/card_assets/hungarian-playing-cards/suit-icons/leaf-icon@large.png differ diff --git a/card_assets/list_10.svg b/card_assets/list_10.svg new file mode 100644 index 0000000..e1c1e1f --- /dev/null +++ b/card_assets/list_10.svg @@ -0,0 +1,1168 @@ + + + Bela — list — 10 + Vector paths traced from the approved source. Shared suit master; square corners. Source detail limited to approximately 175 x 282 pixels per card. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/card_assets/list_7.svg b/card_assets/list_7.svg new file mode 100644 index 0000000..8514963 --- /dev/null +++ b/card_assets/list_7.svg @@ -0,0 +1,66 @@ + + + Bela — list — 7 + Vector paths traced from the approved source. Shared suit master; square corners. Source detail limited to approximately 175 x 282 pixels per card. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/card_assets/list_8.svg b/card_assets/list_8.svg new file mode 100644 index 0000000..e4bcbfb --- /dev/null +++ b/card_assets/list_8.svg @@ -0,0 +1,1168 @@ + + + Bela — list — 8 + Vector paths traced from the approved source. Shared suit master; square corners. Source detail limited to approximately 175 x 282 pixels per card. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/card_assets/list_9.svg b/card_assets/list_9.svg new file mode 100644 index 0000000..a279be7 --- /dev/null +++ b/card_assets/list_9.svg @@ -0,0 +1,70 @@ + + + Bela — list — 9 + Vector paths traced from the approved source. Shared suit master; square corners. Source detail limited to approximately 175 x 282 pixels per card. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/card_assets/list_as.svg b/card_assets/list_as.svg new file mode 100644 index 0000000..3e4af58 --- /dev/null +++ b/card_assets/list_as.svg @@ -0,0 +1,5210 @@ + + + Bela — list — as + Vector paths traced from the approved source. Shared suit master; square corners. Source detail limited to approximately 175 x 282 pixels per card. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/card_assets/list_dama.svg b/card_assets/list_dama.svg new file mode 100644 index 0000000..bc31738 --- /dev/null +++ b/card_assets/list_dama.svg @@ -0,0 +1,5919 @@ + + + Bela — list — dama + Vector paths traced from the approved source. Shared suit master; square corners. Source detail limited to approximately 175 x 282 pixels per card. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/card_assets/list_decko.svg b/card_assets/list_decko.svg new file mode 100644 index 0000000..21f5329 --- /dev/null +++ b/card_assets/list_decko.svg @@ -0,0 +1,4083 @@ + + + Bela — list — decko + Vector paths traced from the approved source. Shared suit master; square corners. Source detail limited to approximately 175 x 282 pixels per card. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/card_assets/list_kralj.svg b/card_assets/list_kralj.svg new file mode 100644 index 0000000..17607d7 --- /dev/null +++ b/card_assets/list_kralj.svg @@ -0,0 +1,6873 @@ + + + Bela — list — kralj + Vector paths traced from the approved source. Shared suit master; square corners. Source detail limited to approximately 175 x 282 pixels per card. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/card_assets/srce_10.svg b/card_assets/srce_10.svg new file mode 100644 index 0000000..c4934c6 --- /dev/null +++ b/card_assets/srce_10.svg @@ -0,0 +1,612 @@ + + + Bela — srce — 10 + Vector paths traced from the approved source. Shared suit master; square corners. Source detail limited to approximately 175 x 282 pixels per card. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/card_assets/srce_7.svg b/card_assets/srce_7.svg new file mode 100644 index 0000000..8c047fa --- /dev/null +++ b/card_assets/srce_7.svg @@ -0,0 +1,64 @@ + + + Bela — srce — 7 + Vector paths traced from the approved source. Shared suit master; square corners. Source detail limited to approximately 175 x 282 pixels per card. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/card_assets/srce_8.svg b/card_assets/srce_8.svg new file mode 100644 index 0000000..83427f8 --- /dev/null +++ b/card_assets/srce_8.svg @@ -0,0 +1,69 @@ + + + Bela — srce — 8 + Vector paths traced from the approved source. Shared suit master; square corners. Source detail limited to approximately 175 x 282 pixels per card. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/card_assets/srce_9.svg b/card_assets/srce_9.svg new file mode 100644 index 0000000..57411e3 --- /dev/null +++ b/card_assets/srce_9.svg @@ -0,0 +1,68 @@ + + + Bela — srce — 9 + Vector paths traced from the approved source. Shared suit master; square corners. Source detail limited to approximately 175 x 282 pixels per card. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/card_assets/srce_as.svg b/card_assets/srce_as.svg new file mode 100644 index 0000000..2b6bb29 --- /dev/null +++ b/card_assets/srce_as.svg @@ -0,0 +1,3952 @@ + + + Bela — srce — as + Vector paths traced from the approved source. Shared suit master; square corners. Source detail limited to approximately 175 x 282 pixels per card. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/card_assets/srce_dama.svg b/card_assets/srce_dama.svg new file mode 100644 index 0000000..2e5c977 --- /dev/null +++ b/card_assets/srce_dama.svg @@ -0,0 +1,4467 @@ + + + Bela — srce — dama + Vector paths traced from the approved source. Shared suit master; square corners. Source detail limited to approximately 175 x 282 pixels per card. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/card_assets/srce_decko.svg b/card_assets/srce_decko.svg new file mode 100644 index 0000000..10fc708 --- /dev/null +++ b/card_assets/srce_decko.svg @@ -0,0 +1,4328 @@ + + + Bela — srce — decko + Vector paths traced from the approved source. Shared suit master; square corners. Source detail limited to approximately 175 x 282 pixels per card. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/card_assets/srce_kralj.svg b/card_assets/srce_kralj.svg new file mode 100644 index 0000000..a5a51e9 --- /dev/null +++ b/card_assets/srce_kralj.svg @@ -0,0 +1,7511 @@ + + + Bela — srce — kralj + Vector paths traced from the approved source. Shared suit master; square corners. Source detail limited to approximately 175 x 282 pixels per card. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/card_assets/zir_10.svg b/card_assets/zir_10.svg new file mode 100644 index 0000000..267b576 --- /dev/null +++ b/card_assets/zir_10.svg @@ -0,0 +1,965 @@ + + + Bela — zir — 10 + Vector paths traced from the approved source. Shared suit master; square corners. Source detail limited to approximately 175 x 282 pixels per card. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/card_assets/zir_7.svg b/card_assets/zir_7.svg new file mode 100644 index 0000000..b5c84ec --- /dev/null +++ b/card_assets/zir_7.svg @@ -0,0 +1,68 @@ + + + Bela — zir — 7 + Vector paths traced from the approved source. Shared suit master; square corners. Source detail limited to approximately 175 x 282 pixels per card. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/card_assets/zir_8.svg b/card_assets/zir_8.svg new file mode 100644 index 0000000..84a2b5a --- /dev/null +++ b/card_assets/zir_8.svg @@ -0,0 +1,965 @@ + + + Bela — zir — 8 + Vector paths traced from the approved source. Shared suit master; square corners. Source detail limited to approximately 175 x 282 pixels per card. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/card_assets/zir_9.svg b/card_assets/zir_9.svg new file mode 100644 index 0000000..6402648 --- /dev/null +++ b/card_assets/zir_9.svg @@ -0,0 +1,72 @@ + + + Bela — zir — 9 + Vector paths traced from the approved source. Shared suit master; square corners. Source detail limited to approximately 175 x 282 pixels per card. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/card_assets/zir_as.svg b/card_assets/zir_as.svg new file mode 100644 index 0000000..33b32b6 --- /dev/null +++ b/card_assets/zir_as.svg @@ -0,0 +1,3229 @@ + + + Bela — zir — as + Vector paths traced from the approved source. Shared suit master; square corners. Source detail limited to approximately 175 x 282 pixels per card. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/card_assets/zir_dama.svg b/card_assets/zir_dama.svg new file mode 100644 index 0000000..1598f7c --- /dev/null +++ b/card_assets/zir_dama.svg @@ -0,0 +1,5241 @@ + + + Bela — zir — dama + Vector paths traced from the approved source. Shared suit master; square corners. Source detail limited to approximately 175 x 282 pixels per card. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/card_assets/zir_decko.svg b/card_assets/zir_decko.svg new file mode 100644 index 0000000..8956699 --- /dev/null +++ b/card_assets/zir_decko.svg @@ -0,0 +1,4343 @@ + + + Bela — zir — decko + Vector paths traced from the approved source. Shared suit master; square corners. Source detail limited to approximately 175 x 282 pixels per card. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/card_assets/zir_kralj.svg b/card_assets/zir_kralj.svg new file mode 100644 index 0000000..851b62f --- /dev/null +++ b/card_assets/zir_kralj.svg @@ -0,0 +1,7133 @@ + + + Bela — zir — kralj + Vector paths traced from the approved source. Shared suit master; square corners. Source detail limited to approximately 175 x 282 pixels per card. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/card_assets/zvono_10.svg b/card_assets/zvono_10.svg new file mode 100644 index 0000000..dc55375 --- /dev/null +++ b/card_assets/zvono_10.svg @@ -0,0 +1,874 @@ + + + Bela — zvono — 10 + Vector paths traced from the approved source. Shared suit master; square corners. Source detail limited to approximately 175 x 282 pixels per card. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/card_assets/zvono_7.svg b/card_assets/zvono_7.svg new file mode 100644 index 0000000..07d48af --- /dev/null +++ b/card_assets/zvono_7.svg @@ -0,0 +1,68 @@ + + + Bela — zvono — 7 + Vector paths traced from the approved source. Shared suit master; square corners. Source detail limited to approximately 175 x 282 pixels per card. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/card_assets/zvono_8.svg b/card_assets/zvono_8.svg new file mode 100644 index 0000000..1f11ce7 --- /dev/null +++ b/card_assets/zvono_8.svg @@ -0,0 +1,73 @@ + + + Bela — zvono — 8 + Vector paths traced from the approved source. Shared suit master; square corners. Source detail limited to approximately 175 x 282 pixels per card. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/card_assets/zvono_9.svg b/card_assets/zvono_9.svg new file mode 100644 index 0000000..9324dc3 --- /dev/null +++ b/card_assets/zvono_9.svg @@ -0,0 +1,72 @@ + + + Bela — zvono — 9 + Vector paths traced from the approved source. Shared suit master; square corners. Source detail limited to approximately 175 x 282 pixels per card. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/card_assets/zvono_as.svg b/card_assets/zvono_as.svg new file mode 100644 index 0000000..b31b74a --- /dev/null +++ b/card_assets/zvono_as.svg @@ -0,0 +1,3537 @@ + + + Bela — zvono — as + Vector paths traced from the approved source. Shared suit master; square corners. Source detail limited to approximately 175 x 282 pixels per card. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/card_assets/zvono_dama.svg b/card_assets/zvono_dama.svg new file mode 100644 index 0000000..3781d3d --- /dev/null +++ b/card_assets/zvono_dama.svg @@ -0,0 +1,4621 @@ + + + Bela — zvono — dama + Vector paths traced from the approved source. Shared suit master; square corners. Source detail limited to approximately 175 x 282 pixels per card. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/card_assets/zvono_decko.svg b/card_assets/zvono_decko.svg new file mode 100644 index 0000000..bd2aabc --- /dev/null +++ b/card_assets/zvono_decko.svg @@ -0,0 +1,4431 @@ + + + Bela — zvono — decko + Vector paths traced from the approved source. Shared suit master; square corners. Source detail limited to approximately 175 x 282 pixels per card. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/card_assets/zvono_kralj.svg b/card_assets/zvono_kralj.svg new file mode 100644 index 0000000..7a53e23 --- /dev/null +++ b/card_assets/zvono_kralj.svg @@ -0,0 +1,6193 @@ + + + Bela — zvono — kralj + Vector paths traced from the approved source. Shared suit master; square corners. Source detail limited to approximately 175 x 282 pixels per card. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/engine/build.gradle.kts b/engine/build.gradle.kts new file mode 100644 index 0000000..db99fee --- /dev/null +++ b/engine/build.gradle.kts @@ -0,0 +1,20 @@ +import org.jetbrains.kotlin.gradle.dsl.JvmTarget + +plugins { + alias(libs.plugins.kotlin.jvm) +} + +java { + sourceCompatibility = JavaVersion.VERSION_17 + targetCompatibility = JavaVersion.VERSION_17 +} + +kotlin { + compilerOptions { + jvmTarget.set(JvmTarget.JVM_17) + } +} + +dependencies { + testImplementation(libs.junit) +} diff --git a/engine/src/main/kotlin/hr/bela/engine/Action.kt b/engine/src/main/kotlin/hr/bela/engine/Action.kt new file mode 100644 index 0000000..77a54d8 --- /dev/null +++ b/engine/src/main/kotlin/hr/bela/engine/Action.kt @@ -0,0 +1,40 @@ +package hr.bela.engine + +/** Everything a game can be advanced with. A game is fully described by its seed plus its list of actions. */ +sealed interface Action { + data class Call(val seat: Int, val suit: Suit?) : Action + data class Play(val seat: Int, val card: Card) : Action + data object NextHand : Action +} + +/** Saved game: seed and actions, encoded as one line of text. */ +data class GameRecord(val seed: Long, val actions: List = emptyList()) { + operator fun plus(action: Action): GameRecord = copy(actions = actions + action) + + fun replay(rules: RuleSet = RuleSet()): GameState = Bela.replay(rules, seed, actions) + + /** Format: `v1;;,,…` — `C0H` seat 0 calls herc, `C1-` seat 1 passes, `P2HA` seat 2 plays ace of herc, `N` next hand. */ + fun encode(): String = "v1;$seed;" + actions.joinToString(",") { action -> + when (action) { + is Action.Call -> "C${action.seat}${action.suit?.code ?: '-'}" + is Action.Play -> "P${action.seat}${action.card.code}" + Action.NextHand -> "N" + } + } + + companion object { + fun decode(text: String): GameRecord? = runCatching { + val parts = text.split(';', limit = 3) + require(parts.size == 3 && parts[0] == "v1") + val actions = parts[2].split(',').filter { it.isNotEmpty() }.map { token -> + when (token[0]) { + 'C' -> Action.Call(token[1].digitToInt(), token[2].takeIf { it != '-' }?.let(Suit::fromCode)) + 'P' -> Action.Play(token[1].digitToInt(), Card.parse(token.substring(2))) + 'N' -> Action.NextHand + else -> error("Unknown action $token") + } + } + GameRecord(parts[1].toLong(), actions) + }.getOrNull() + } +} diff --git a/engine/src/main/kotlin/hr/bela/engine/Bot.kt b/engine/src/main/kotlin/hr/bela/engine/Bot.kt new file mode 100644 index 0000000..8f08cbb --- /dev/null +++ b/engine/src/main/kotlin/hr/bela/engine/Bot.kt @@ -0,0 +1,169 @@ +package hr.bela.engine + +interface BotStrategy { + /** Suit to call, or null to pass. Must not return null when the seat may not pass. */ + fun chooseTrump(state: GameState, seat: Int): Suit? + + /** One of [GameState.legalMoves] for [seat]. */ + fun chooseCard(state: GameState, seat: Int): Card +} + +/** + * Rule-of-thumb bot. It only looks at its own cards and at what is public (played cards, trump, caller), + * so it never cheats. It plays with its partner: it does not fight a partner who is already winning, + * gives points ("šmira") to a partner's safe trick, and pulls trumps when its team called. + */ +object HeuristicBot : BotStrategy { + /** Hand value (see [trumpValue]) at which the bot names trump instead of passing. */ + private const val CALL_THRESHOLD = 5.0 + + override fun chooseTrump(state: GameState, seat: Int): Suit? { + val cards = state.hand.cards[seat] + val (best, value) = Suit.entries.map { it to trumpValue(cards, it) }.maxBy { it.second } + val trumps = cards.count { it.suit == best } + val mustCall = !state.canPass(seat) + return if (mustCall || (value >= CALL_THRESHOLD && trumps >= 2)) best else null + } + + /** How good [cards] (the six visible ones) are with [suit] as trump. */ + fun trumpValue(cards: List, suit: Suit): Double { + var value = 0.0 + var trumps = 0 + for (card in cards) { + if (card.suit == suit) { + trumps++ + value += when (card.rank) { + Rank.DECKO -> 3.0 + Rank.DEVET -> 2.2 + Rank.AS -> 1.4 + Rank.DESET -> 1.1 + Rank.KRALJ, Rank.DAMA -> 0.8 + else -> 0.5 + } + } else { + value += when (card.rank) { + Rank.AS -> 1.0 + Rank.DESET -> if (Card(card.suit, Rank.AS) in cards) 0.6 else 0.2 + else -> 0.0 + } + } + } + if (trumps >= 3) value += 0.6 * (trumps - 2) + if (Card(suit, Rank.KRALJ) in cards && Card(suit, Rank.DAMA) in cards) value += 0.5 + return value + } + + override fun chooseCard(state: GameState, seat: Int): Card { + val legal = state.legalMoves(seat) + require(legal.isNotEmpty()) { "Seat $seat has no legal move" } + if (legal.size == 1) return legal.first() + val view = View(state, seat) + return if (view.trick.cards.isEmpty()) view.lead(legal) else view.follow(legal) + } + + /** What [seat] can see: its own cards plus everything already played. */ + private class View(state: GameState, val seat: Int) { + val hand = state.hand + val trump = hand.trump!! + val trick = hand.trick + val myTeam = teamOf(seat) + val callerTeam = teamOf(hand.caller!!) + private val myCards = hand.cards[seat] + private val played: Set = hand.tricks.flatMap { it.trick.cards }.toSet() + trick.cards + + /** Cards not in my hand and not yet played: somewhere in the other three hands. */ + val unseen: List = Deck.all.filter { it !in played && it !in myCards } + + /** Suits each seat has shown it does not hold, read from the tricks so far. */ + private val voids: List> = run { + val result = List(4) { mutableSetOf() } + val tricks = hand.tricks.map { it.trick } + trick + for (t in tricks) { + val led = t.ledSuit ?: continue + t.cards.forEachIndexed { i, card -> + if (i > 0 && card.suit != led) { + result[t.seatAt(i)] += led + if (card.suit != trump) result[t.seatAt(i)] += trump + } + } + } + result + } + + fun cost(card: Card): Double = card.points(trump) + (if (card.suit == trump) 6.0 else 0.0) + card.power(trump) * 0.1 + + /** No unseen card of the same suit can beat it. */ + fun isBoss(card: Card): Boolean = unseen.none { it.suit == card.suit && it.power(trump) > card.power(trump) } + + /** Seats still to play after me in the current trick. */ + private fun seatsAfterMe(): List = (trick.cards.size + 1 until 4).map { trick.seatAt(it) } + + /** An opponent still to play is known to be out of [suit] and may still hold trumps. */ + private fun opponentMayCut(suit: Suit): Boolean = + suit != trump && seatsAfterMe().any { s -> + teamOf(s) != myTeam && suit in voids[s] && trump !in voids[s] + } + + /** Nobody still to play can beat [card], as far as I can tell. */ + fun holds(card: Card): Boolean = isBoss(card) && !opponentMayCut(card.suit) + + fun lead(legal: List): Card { + val trumps = legal.filter { it.suit == trump } + val plain = legal.filter { it.suit != trump } + + // The calling team draws trumps while it holds the top one. + if (myTeam == callerTeam && unseen.any { it.suit == trump }) { + trumps.filter { isBoss(it) }.maxByOrNull { it.power(trump) }?.let { return it } + } + // Cash a plain card nobody can beat. + plain.filter { isBoss(it) }.maxByOrNull { it.points(trump) * 10 + it.power(trump) }?.let { return it } + // Otherwise lead low, preferably not from a suit where I hold an unguarded 10. + if (plain.isNotEmpty()) { + return plain.minWith( + compareBy( + { card -> if (legal.any { it.suit == card.suit && it.rank == Rank.DESET && !isBoss(it) }) 1 else 0 }, + { it.points(trump) }, + { it.power(trump) }, + ), + ) + } + return trumps.minBy { it.power(trump) } + } + + fun follow(legal: List): Card { + val led = trick.ledSuit!! + val isLast = trick.cards.size == 3 + val winningIndex = trick.winningIndex(trump) + val winningCard = trick.cards[winningIndex] + val partnerWinning = teamOf(trick.seatAt(winningIndex)) == myTeam + + if (partnerWinning) { + return if (isLast || holds(winningCard)) smear(legal) else legal.minBy(::cost) + } + + val winners = legal.filter { beats(it, winningCard, led, trump) } + if (winners.isEmpty()) return legal.minBy(::cost) + if (isLast) return capture(winners) + + val sure = winners.filter(::holds) + if (sure.isNotEmpty()) return capture(sure) + // Worth fighting for: take it as cheaply as possible and hope it holds. + if (trick.points(trump) >= 10) return winners.minBy(::cost) + return legal.minBy(::cost) + } + + /** Partner wins this trick: give it the most points I can spare, keeping trumps. */ + private fun smear(legal: List): Card { + val plain = legal.filter { it.suit != trump } + if (plain.isNotEmpty()) return plain.maxWith(compareBy({ it.points(trump) }, { -it.power(trump) })) + return legal.minBy { it.power(trump) } + } + + /** I win this trick: with a plain card take the richest one, with trumps spend the lowest that wins. */ + private fun capture(winners: List): Card { + val plain = winners.filter { it.suit != trump } + if (plain.isNotEmpty()) return plain.maxBy { it.points(trump) } + return winners.minBy { it.power(trump) } + } + } +} diff --git a/engine/src/main/kotlin/hr/bela/engine/Cards.kt b/engine/src/main/kotlin/hr/bela/engine/Cards.kt new file mode 100644 index 0000000..5aa341d --- /dev/null +++ b/engine/src/main/kotlin/hr/bela/engine/Cards.kt @@ -0,0 +1,85 @@ +package hr.bela.engine + +/** The four suits. Names follow the French deck; with Hungarian cards herc = srce, karo = bundeva, pik = zelena, tref = žir. */ +enum class Suit(val symbol: String, val label: String, val code: Char) { + HERC("♥", "Herc", 'H'), + KARO("♦", "Karo", 'K'), + PIK("♠", "Pik", 'P'), + TREF("♣", "Tref", 'T'); + + val isRed: Boolean get() = this == HERC || this == KARO + + companion object { + fun fromCode(code: Char): Suit = entries.first { it.code == code } + } +} + +/** Ranks in natural order, 7 to ace. This order is the one sequences (zvanja) use. */ +enum class Rank(val label: String, val code: Char) { + SEDAM("7", '7'), + OSAM("8", '8'), + DEVET("9", '9'), + DESET("10", 'X'), + DECKO("J", 'J'), + DAMA("Q", 'Q'), + KRALJ("K", 'K'), + AS("A", 'A'); + + companion object { + fun fromCode(code: Char): Rank = entries.first { it.code == code } + } +} + +data class Card(val suit: Suit, val rank: Rank) { + /** Two-character code, suit then rank, e.g. "HA" = ace of hearts. Used for saving games. */ + val code: String get() = "${suit.code}${rank.code}" + + override fun toString(): String = "${rank.label}${suit.symbol}" + + companion object { + fun parse(code: String): Card = Card(Suit.fromCode(code[0]), Rank.fromCode(code[1])) + } +} + +object Deck { + /** All 32 cards in a fixed order. */ + val all: List = Suit.entries.flatMap { suit -> Rank.entries.map { rank -> Card(suit, rank) } } +} + +private val TRUMP_ORDER = listOf(Rank.SEDAM, Rank.OSAM, Rank.DAMA, Rank.KRALJ, Rank.DESET, Rank.AS, Rank.DEVET, Rank.DECKO) +private val PLAIN_ORDER = listOf(Rank.SEDAM, Rank.OSAM, Rank.DEVET, Rank.DECKO, Rank.DAMA, Rank.KRALJ, Rank.DESET, Rank.AS) + +/** Card points: trump J 20, 9 14, A 11, 10 10, K 4, Q 3; other suits A 11, 10 10, K 4, Q 3, J 2. */ +fun Card.points(trump: Suit): Int = + if (suit == trump) { + when (rank) { + Rank.DECKO -> 20 + Rank.DEVET -> 14 + Rank.AS -> 11 + Rank.DESET -> 10 + Rank.KRALJ -> 4 + Rank.DAMA -> 3 + else -> 0 + } + } else { + when (rank) { + Rank.AS -> 11 + Rank.DESET -> 10 + Rank.KRALJ -> 4 + Rank.DAMA -> 3 + Rank.DECKO -> 2 + else -> 0 + } + } + +/** Strength within the card's own suit (0..7, higher wins). Trump order is J 9 A 10 K Q 8 7; plain order is A 10 K Q J 9 8 7. */ +fun Card.power(trump: Suit): Int = strength(trump) + +/** Like [power], but works before trump is known (null = every suit ranks in plain order). */ +fun Card.strength(trump: Suit?): Int = + if (suit == trump) TRUMP_ORDER.indexOf(rank) else PLAIN_ORDER.indexOf(rank) + +/** Seats 0..3 go counterclockwise. Seats 0 and 2 are one team, 1 and 3 the other. */ +fun teamOf(seat: Int): Int = seat % 2 + +fun partnerOf(seat: Int): Int = (seat + 2) % 4 diff --git a/engine/src/main/kotlin/hr/bela/engine/CountingDrill.kt b/engine/src/main/kotlin/hr/bela/engine/CountingDrill.kt new file mode 100644 index 0000000..1cbebe5 --- /dev/null +++ b/engine/src/main/kotlin/hr/bela/engine/CountingDrill.kt @@ -0,0 +1,95 @@ +package hr.bela.engine + +import kotlin.random.Random + +/** A typical counting slip; each wrong answer in the drill is built from one of these. */ +enum class CountingMistake { + /** Jack of trump counted as a plain jack (2 instead of 20). */ + TRUMP_JACK_AS_PLAIN, + + /** Nine of trump counted as a plain nine (0 instead of 14). */ + TRUMP_NINE_AS_PLAIN, + + /** A plain jack counted as if it were trump (20 instead of 2). */ + PLAIN_JACK_AS_TRUMP, + + /** A plain nine counted as if it were trump (14 instead of 0). */ + PLAIN_NINE_AS_TRUMP, + + /** The 10 for the last trick left out. */ + FORGOT_LAST_TRICK, + + /** 10 for the last trick added although the team did not take it. */ + ADDED_LAST_TRICK, + + /** A ten skipped. */ + MISSED_TEN, + + /** An ace skipped. */ + MISSED_ACE, + + /** King and queen mixed up (4 and 3). */ + KING_QUEEN_MIXUP, +} + +/** One of the four answers offered. [mistake] says which slip produces it; null for the correct answer or a plain miscount. */ +data class AnswerOption(val value: Int, val mistake: CountingMistake?) + +/** A pile of won cards to count, with the trump that decides their values. */ +data class CountingRound( + val trump: Suit, + val cards: List, + /** The team also took the last trick: +10. */ + val lastTrick: Boolean, + /** Four distinct answers in random order; exactly one equals [total]. */ + val options: List, +) { + val cardPoints: Int get() = cards.sumOf { it.points(trump) } + val total: Int get() = cardPoints + if (lastTrick) 10 else 0 +} + +/** Card-counting practice: a random pile of won tricks and four answers built from typical mistakes. */ +object CountingDrill { + fun round(random: Random, tricks: Int, lastTrick: Boolean): CountingRound { + require(tricks in 1..8) { "tricks must be 1..8" } + val trump = Suit.entries.random(random) + val cards = Deck.all.shuffled(random).take(tricks * 4) + val partial = CountingRound(trump, cards, lastTrick, emptyList()) + return partial.copy(options = options(partial, random)) + } + + internal fun options(round: CountingRound, random: Random): List { + val total = round.total + val trump = round.trump + val cards = round.cards + fun has(rank: Rank, isTrump: Boolean) = cards.any { it.rank == rank && (it.suit == trump) == isTrump } + + val slips = buildList { + if (has(Rank.DECKO, true)) add(AnswerOption(total - 18, CountingMistake.TRUMP_JACK_AS_PLAIN)) + if (has(Rank.DEVET, true)) add(AnswerOption(total - 14, CountingMistake.TRUMP_NINE_AS_PLAIN)) + if (has(Rank.DECKO, false)) add(AnswerOption(total + 18, CountingMistake.PLAIN_JACK_AS_TRUMP)) + if (has(Rank.DEVET, false)) add(AnswerOption(total + 14, CountingMistake.PLAIN_NINE_AS_TRUMP)) + if (round.lastTrick) { + add(AnswerOption(total - 10, CountingMistake.FORGOT_LAST_TRICK)) + } else { + add(AnswerOption(total + 10, CountingMistake.ADDED_LAST_TRICK)) + } + if (cards.any { it.rank == Rank.DESET }) add(AnswerOption(total - 10, CountingMistake.MISSED_TEN)) + if (cards.any { it.rank == Rank.AS }) add(AnswerOption(total - 11, CountingMistake.MISSED_ACE)) + if (cards.any { it.rank == Rank.KRALJ || it.rank == Rank.DAMA }) { + add(AnswerOption(total + if (random.nextBoolean()) 1 else -1, CountingMistake.KING_QUEEN_MIXUP)) + } + }.shuffled(random) + + val picked = mutableListOf() + for (slip in slips) { + if (picked.size == 3) break + if (slip.value >= 0 && slip.value != total && picked.none { it.value == slip.value }) picked += slip + } + while (picked.size < 3) { + val value = total + (random.nextInt(1, 13) * if (random.nextBoolean()) 1 else -1) + if (value >= 0 && value != total && picked.none { it.value == value }) picked += AnswerOption(value, null) + } + return (picked + AnswerOption(total, null)).shuffled(random) + } +} diff --git a/engine/src/main/kotlin/hr/bela/engine/Declarations.kt b/engine/src/main/kotlin/hr/bela/engine/Declarations.kt new file mode 100644 index 0000000..de6b49f --- /dev/null +++ b/engine/src/main/kotlin/hr/bela/engine/Declarations.kt @@ -0,0 +1,83 @@ +package hr.bela.engine + +enum class DeclarationKind { SEQUENCE, FOUR_OF_A_KIND } + +/** A declaration (zvanje) held by [seat]. Bela (K+Q of trump) is not a declaration; it is scored separately. */ +data class Declaration(val seat: Int, val kind: DeclarationKind, val cards: List, val points: Int) { + /** Tie-break inside the same kind and value: the higher top card of a sequence, or the stronger rank of a four (A > 10 > K > Q). */ + internal val tieBreak: Int + get() = when (kind) { + DeclarationKind.SEQUENCE -> cards.maxOf { it.rank.ordinal } + DeclarationKind.FOUR_OF_A_KIND -> PLAIN_RANKING.indexOf(cards.first().rank) + } + + override fun toString(): String = "$points (${cards.joinToString(" ")})" + + private companion object { + val PLAIN_RANKING = listOf(Rank.SEDAM, Rank.OSAM, Rank.DEVET, Rank.DECKO, Rank.DAMA, Rank.KRALJ, Rank.DESET, Rank.AS) + } +} + +object Declarations { + /** Four jacks 200, four nines 150, four aces/tens/kings/queens 100. Fours of 8s and 7s count nothing. */ + fun fourOfAKindPoints(rank: Rank): Int = when (rank) { + Rank.DECKO -> 200 + Rank.DEVET -> 150 + Rank.AS, Rank.DESET, Rank.KRALJ, Rank.DAMA -> 100 + else -> 0 + } + + /** Three in a row 20, four 50, five or more 100. */ + fun sequencePoints(length: Int): Int = when { + length >= 5 -> 100 + length == 4 -> 50 + length == 3 -> 20 + else -> 0 + } + + /** Every declaration in an eight-card hand. A card may count in both a four of a kind and a sequence. */ + fun find(seat: Int, hand: List): List { + val result = mutableListOf() + + for (rank in Rank.entries) { + val points = fourOfAKindPoints(rank) + val same = hand.filter { it.rank == rank } + if (points > 0 && same.size == 4) { + result += Declaration(seat, DeclarationKind.FOUR_OF_A_KIND, same.sortedBy { it.suit }, points) + } + } + + for (suit in Suit.entries) { + val ordinals = hand.filter { it.suit == suit }.map { it.rank.ordinal }.sorted() + var runStart = 0 + for (i in 1..ordinals.size) { + if (i == ordinals.size || ordinals[i] != ordinals[i - 1] + 1) { + val length = i - runStart + if (length >= 3) { + val cards = ordinals.subList(runStart, i).map { Card(suit, Rank.entries[it]) } + result += Declaration(seat, DeclarationKind.SEQUENCE, cards, sequencePoints(length)) + } + runStart = i + } + } + } + return result + } + + private val strength: Comparator = compareBy( + { it.points }, + { if (it.kind == DeclarationKind.FOUR_OF_A_KIND) 1 else 0 }, + { it.cards.size }, + { it.tieBreak }, + ) + + /** + * The team whose declarations count: the one holding the single strongest declaration. + * Equal declarations go to the player nearer the first player (right of the dealer). + */ + fun winningTeam(all: List, firstSeat: Int): Int? { + if (all.isEmpty()) return null + val best = all.maxWith(strength.thenByDescending { (it.seat - firstSeat + 4) % 4 }) + return teamOf(best.seat) + } +} diff --git a/engine/src/main/kotlin/hr/bela/engine/Game.kt b/engine/src/main/kotlin/hr/bela/engine/Game.kt new file mode 100644 index 0000000..3c04437 --- /dev/null +++ b/engine/src/main/kotlin/hr/bela/engine/Game.kt @@ -0,0 +1,342 @@ +package hr.bela.engine + +import kotlin.random.Random + +enum class Phase { BIDDING, PLAYING, HAND_OVER, GAME_OVER } + +/** A trump call (suit) or a pass ("dalje", suit = null). */ +data class Bid(val seat: Int, val suit: Suit?) + +/** One hand (ruka): deal, trump call, eight tricks. */ +data class HandState( + /** Deal counter; also seeds the shuffle. Redeals take a new number, so it can skip ahead of the score sheet. */ + val number: Int, + val dealer: Int, + /** Cards each seat holds right now: 6 during bidding, then 8 minus what was played. */ + val cards: List>, + /** Each seat's two hidden talon cards; empty once trump is called. */ + val talon: List>, + val bids: List = emptyList(), + val trump: Suit? = null, + val caller: Int? = null, + /** Every declaration found once players took their talon. Only [declarationTeam]'s count. */ + val declarations: List = emptyList(), + val declarationTeam: Int? = null, + /** Seat holding king and queen of trump, if any. */ + val belaSeat: Int? = null, + /** True once that seat has played the first of the two cards (and said "bela"). */ + val belaAnnounced: Boolean = false, + val trick: Trick, + val tricks: List = emptyList(), +) { + /** The player right of the dealer: calls first and leads the first trick. */ + val firstSeat: Int get() = (dealer + 1) % 4 + + /** Declarations that count this hand. */ + val scoringDeclarations: List + get() = declarationTeam?.let { team -> declarations.filter { teamOf(it.seat) == team } } ?: emptyList() +} + +enum class Outcome { + /** Caller's team took more than half: both teams write their points. */ + PASSED, + + /** Caller's team took half or less: defenders write everything ("pad"). */ + FELL, + + /** Exactly half under [TieRule.HANGS]: the caller's points hang ("visi"). */ + TIED, +} + +/** The written result of a hand. All lists are indexed by team (0 = seats 0 and 2). */ +data class HandResult( + val handNumber: Int, + val caller: Int, + val trump: Suit, + val tricksWon: List, + /** Card points including 10 for the last trick. */ + val cardPoints: List, + val lastTrickTeam: Int, + val declarationPoints: List, + val belaPoints: List, + val stigljaPoints: List, + /** Points each team took before the pass/fall rule. */ + val raw: List, + val outcome: Outcome, + /** Points added to the score sheet this hand, including any hanging points this hand settled. */ + val awarded: List, + /** Hanging points from earlier ties that this hand settled, and which team got them. */ + val settledHanging: Int, + val settledHangingTeam: Int?, + /** Points still hanging after this hand. */ + val hangingAfter: Int, +) { + val callerTeam: Int get() = teamOf(caller) + val total: Int get() = raw.sum() +} + +data class GameState( + val rules: RuleSet, + val seed: Long, + val phase: Phase, + val hand: HandState, + /** Score sheet totals per team. */ + val scores: List = listOf(0, 0), + val results: List = emptyList(), + val hanging: Int = 0, + val winnerTeam: Int? = null, + /** Set when a player held belot (all eight cards of one suit) and won the game with it. */ + val belotSeat: Int? = null, +) { + /** Seat whose turn it is, or null when nobody needs to act. */ + val toAct: Int? + get() = when (phase) { + Phase.BIDDING -> (hand.firstSeat + hand.bids.size) % 4 + Phase.PLAYING -> hand.trick.nextSeat + Phase.HAND_OVER, Phase.GAME_OVER -> null + } + + val lastResult: HandResult? get() = results.lastOrNull() + + fun legalMoves(seat: Int): List { + if (phase != Phase.PLAYING || seat != toAct) return emptyList() + return PlayRules.legalMoves(hand.cards[seat], hand.trick, hand.trump!!, rules.mustBeat) + } + + /** Whether [seat] may pass right now (the dealer may not when the dealer must call). */ + fun canPass(seat: Int): Boolean = + phase == Phase.BIDDING && seat == toAct && !(seat == hand.dealer && rules.dealerMustCall) + + /** Name trump ([suit]) or pass (null). */ + fun call(seat: Int, suit: Suit?): GameState { + require(phase == Phase.BIDDING) { "Not bidding (phase $phase)" } + require(seat == toAct) { "Seat $seat called out of turn; waiting for $toAct" } + val bids = hand.bids + Bid(seat, suit) + + if (suit == null) { + require(canPass(seat)) { "The dealer must call trump" } + if (seat == hand.dealer) { + // Everyone passed and the rules allow it: redeal with the next dealer. + return copy(hand = Bela.deal(seed, hand.number + 1, (hand.dealer + 1) % 4)) + } + return copy(hand = hand.copy(bids = bids)) + } + + val cards = List(4) { hand.cards[it] + hand.talon[it] } + val noTalon = List(4) { emptyList() } + + if (rules.belotWinsGame) { + val belotSeat = (0..3).firstOrNull { s -> cards[s].all { it.suit == cards[s].first().suit } } + if (belotSeat != null) { + return copy( + phase = Phase.GAME_OVER, + hand = hand.copy(cards = cards, talon = noTalon, bids = bids, trump = suit, caller = seat), + winnerTeam = teamOf(belotSeat), + belotSeat = belotSeat, + ) + } + } + + val declarations = (0..3).flatMap { Declarations.find(it, cards[it]) } + val belaSeat = (0..3).firstOrNull { s -> + Card(suit, Rank.KRALJ) in cards[s] && Card(suit, Rank.DAMA) in cards[s] + } + return copy( + phase = Phase.PLAYING, + hand = hand.copy( + cards = cards, + talon = noTalon, + bids = bids, + trump = suit, + caller = seat, + declarations = declarations, + declarationTeam = Declarations.winningTeam(declarations, hand.firstSeat), + belaSeat = belaSeat, + trick = Trick(hand.firstSeat), + ), + ) + } + + fun play(seat: Int, card: Card): GameState { + require(phase == Phase.PLAYING) { "Not playing (phase $phase)" } + require(seat == toAct) { "Seat $seat played out of turn; waiting for $toAct" } + require(card in legalMoves(seat)) { "$card is not a legal move for seat $seat" } + + val trump = hand.trump!! + val announcesBela = seat == hand.belaSeat && card.suit == trump && + (card.rank == Rank.KRALJ || card.rank == Rank.DAMA) + val cards = hand.cards.toMutableList().also { it[seat] = it[seat] - card } + val trick = hand.trick.copy(cards = hand.trick.cards + card) + val belaAnnounced = hand.belaAnnounced || announcesBela + + if (!trick.isComplete) { + return copy(hand = hand.copy(cards = cards, trick = trick, belaAnnounced = belaAnnounced)) + } + + val winner = trick.winner(trump) + val finished = hand.copy( + cards = cards, + trick = Trick(winner), + tricks = hand.tricks + CompletedTrick(trick, winner), + belaAnnounced = belaAnnounced, + ) + if (finished.tricks.size < 8) return copy(hand = finished) + + val result = Scoring.score(finished, rules, hanging) + val scores = List(2) { scores[it] + result.awarded[it] } + val leader = if (scores[0] > scores[1]) 0 else 1 + val gameOver = scores[leader] >= rules.targetScore && scores[0] != scores[1] + return copy( + phase = if (gameOver) Phase.GAME_OVER else Phase.HAND_OVER, + hand = finished, + scores = scores, + results = results + result, + hanging = result.hangingAfter, + winnerTeam = if (gameOver) leader else null, + ) + } + + /** Deal the next hand after a finished one. The deal moves one seat counterclockwise. */ + fun nextHand(): GameState { + require(phase == Phase.HAND_OVER) { "Hand not finished (phase $phase)" } + return copy(phase = Phase.BIDDING, hand = Bela.deal(seed, hand.number + 1, (hand.dealer + 1) % 4)) + } + + fun apply(action: Action): GameState = when (action) { + is Action.Call -> call(action.seat, action.suit) + is Action.Play -> play(action.seat, action.card) + Action.NextHand -> nextHand() + } +} + +object Bela { + fun newGame(rules: RuleSet = RuleSet(), seed: Long = Random.nextLong()): GameState { + val dealer = Random(seed).nextInt(4) + return GameState(rules = rules, seed = seed, phase = Phase.BIDDING, hand = deal(seed, 1, dealer)) + } + + /** Shuffle and deal counterclockwise from the right of [dealer]: 6 cards each in two rounds of three, then 2 talon cards each. */ + fun deal(seed: Long, number: Int, dealer: Int): HandState { + val random = Random(seed + number * 1_000_003L) + val deck = Deck.all.shuffled(random) + val cards = List(4) { mutableListOf() } + val talon = List(4) { mutableListOf() } + val order = (1..4).map { (dealer + it) % 4 } + var next = 0 + repeat(2) { for (seat in order) repeat(3) { cards[seat] += deck[next++] } } + for (seat in order) repeat(2) { talon[seat] += deck[next++] } + return HandState( + number = number, + dealer = dealer, + cards = cards.map { it.toList() }, + talon = talon.map { it.toList() }, + trick = Trick((dealer + 1) % 4), + ) + } + + /** Rebuild a game from its seed and the actions taken so far. */ + fun replay(rules: RuleSet, seed: Long, actions: List): GameState = + actions.fold(newGame(rules, seed)) { state, action -> state.apply(action) } +} + +object Scoring { + fun score(hand: HandState, rules: RuleSet, hangingBefore: Int): HandResult { + val trump = hand.trump!! + val caller = hand.caller!! + val callerTeam = teamOf(caller) + + val tricksWon = IntArray(2) + val cardPoints = IntArray(2) + for (t in hand.tricks) { + val team = teamOf(t.winner) + tricksWon[team]++ + cardPoints[team] += t.trick.points(trump) + } + val lastTrickTeam = teamOf(hand.tricks.last().winner) + cardPoints[lastTrickTeam] += 10 + + val stiglja = IntArray(2) + (0..1).firstOrNull { tricksWon[it] == hand.tricks.size }?.let { stiglja[it] = rules.stigljaBonus } + + // Declarations and bela only count for a team that took at least one trick. + val declarations = IntArray(2) + hand.declarationTeam?.let { team -> + if (tricksWon[team] > 0) declarations[team] = hand.scoringDeclarations.sumOf { it.points } + } + val bela = IntArray(2) + hand.belaSeat?.let { seat -> + val team = teamOf(seat) + if (tricksWon[team] > 0) bela[team] = 20 + } + + val raw = List(2) { cardPoints[it] + stiglja[it] + declarations[it] + bela[it] } + val settlement = settle(raw, callerTeam, rules.tieRule, hangingBefore) + + return HandResult( + handNumber = hand.number, + caller = caller, + trump = trump, + tricksWon = tricksWon.toList(), + cardPoints = cardPoints.toList(), + lastTrickTeam = lastTrickTeam, + declarationPoints = declarations.toList(), + belaPoints = bela.toList(), + stigljaPoints = stiglja.toList(), + raw = raw, + outcome = settlement.outcome, + awarded = settlement.awarded, + settledHanging = settlement.settledHanging, + settledHangingTeam = settlement.settledHangingTeam, + hangingAfter = settlement.hangingAfter, + ) + } + + data class Settlement( + val outcome: Outcome, + val awarded: List, + val settledHanging: Int, + val settledHangingTeam: Int?, + val hangingAfter: Int, + ) + + /** + * Apply the pass/fall rule to the points each team took ([raw]): the caller's team must take more than half + * of everything. Points hanging from an earlier tie go to the team that wins this hand. + */ + fun settle(raw: List, callerTeam: Int, tieRule: TieRule, hangingBefore: Int): Settlement { + val defenders = 1 - callerTeam + val total = raw.sum() + val awarded = IntArray(2) + val outcome: Outcome + var hangingAfter = 0 + when { + raw[callerTeam] * 2 > total -> { + outcome = Outcome.PASSED + awarded[0] = raw[0] + awarded[1] = raw[1] + } + raw[callerTeam] * 2 == total && tieRule == TieRule.HANGS -> { + outcome = Outcome.TIED + awarded[defenders] = raw[defenders] + hangingAfter = hangingBefore + raw[callerTeam] + } + else -> { + outcome = Outcome.FELL + awarded[defenders] = total + } + } + + var settledTeam: Int? = null + if (outcome != Outcome.TIED && hangingBefore > 0) { + settledTeam = if (outcome == Outcome.PASSED) callerTeam else defenders + awarded[settledTeam] += hangingBefore + } + return Settlement( + outcome = outcome, + awarded = awarded.toList(), + settledHanging = if (settledTeam != null) hangingBefore else 0, + settledHangingTeam = settledTeam, + hangingAfter = hangingAfter, + ) + } +} diff --git a/engine/src/main/kotlin/hr/bela/engine/RuleSet.kt b/engine/src/main/kotlin/hr/bela/engine/RuleSet.kt new file mode 100644 index 0000000..19f96a7 --- /dev/null +++ b/engine/src/main/kotlin/hr/bela/engine/RuleSet.kt @@ -0,0 +1,24 @@ +package hr.bela.engine + +/** What happens when the calling team ends a hand with exactly half the points. */ +enum class TieRule { + /** Defenders score their half; the caller's half "hangs" and goes to whoever wins the next decided hand. */ + HANGS, + + /** Treated like a failed call: defenders take everything. */ + CALLER_FALLS, +} + +/** House rules a table can change before a game. Defaults follow the PRD. */ +data class RuleSet( + val targetScore: Int = 1001, + /** Bonus for taking all eight tricks; 0 turns it off. */ + val stigljaBonus: Int = 90, + /** When everyone passes, the dealer must name trump. If false the hand is redealt. */ + val dealerMustCall: Boolean = true, + /** "Iber": a player must beat the winning card when able (following suit, overtrumping, or cutting over a cut). */ + val mustBeat: Boolean = true, + /** Holding all eight cards of one suit wins the game on the spot. */ + val belotWinsGame: Boolean = true, + val tieRule: TieRule = TieRule.HANGS, +) diff --git a/engine/src/main/kotlin/hr/bela/engine/Trick.kt b/engine/src/main/kotlin/hr/bela/engine/Trick.kt new file mode 100644 index 0000000..d16ce71 --- /dev/null +++ b/engine/src/main/kotlin/hr/bela/engine/Trick.kt @@ -0,0 +1,66 @@ +package hr.bela.engine + +/** A trick in progress or finished. [cards] are in play order; the i-th card was played by [seatAt] (i). */ +data class Trick(val leader: Int, val cards: List = emptyList()) { + val isComplete: Boolean get() = cards.size == 4 + val ledSuit: Suit? get() = cards.firstOrNull()?.suit + val nextSeat: Int get() = seatAt(cards.size) + + fun seatAt(index: Int): Int = (leader + index) % 4 + + fun seatOf(card: Card): Int = seatAt(cards.indexOf(card)) + + fun points(trump: Suit): Int = cards.sumOf { it.points(trump) } + + /** Index of the card currently winning. The trick must not be empty. */ + fun winningIndex(trump: Suit): Int { + val led = cards.first().suit + var best = 0 + for (i in 1 until cards.size) { + if (beats(cards[i], cards[best], led, trump)) best = i + } + return best + } + + fun winner(trump: Suit): Int = seatAt(winningIndex(trump)) +} + +data class CompletedTrick(val trick: Trick, val winner: Int) + +/** Whether [challenger] beats [current] when [led] was led. Only a higher card of the same suit or a trump over a non-trump wins. */ +fun beats(challenger: Card, current: Card, led: Suit, trump: Suit): Boolean = when { + challenger.suit == current.suit -> challenger.power(trump) > current.power(trump) + challenger.suit == trump -> true + else -> false +} + +object PlayRules { + /** + * Cards [hand] may play into [trick]: + * follow suit; with [mustBeat] go higher than the winning card when able (not needed once a plain-suit trick + * has been cut); without the led suit, cut with a trump, over-cutting an earlier cut when able; + * with neither, any card. + */ + fun legalMoves(hand: List, trick: Trick, trump: Suit, mustBeat: Boolean): List { + if (trick.cards.isEmpty()) return hand + val led = trick.ledSuit!! + val winning = trick.cards[trick.winningIndex(trump)] + + val sameSuit = hand.filter { it.suit == led } + if (sameSuit.isNotEmpty()) { + if (!mustBeat) return sameSuit + if (led != trump && winning.suit == trump) return sameSuit + val higher = sameSuit.filter { it.power(trump) > winning.power(trump) } + return higher.ifEmpty { sameSuit } + } + + val trumps = hand.filter { it.suit == trump } + if (trumps.isNotEmpty()) { + if (!mustBeat || winning.suit != trump) return trumps + val higher = trumps.filter { it.power(trump) > winning.power(trump) } + return higher.ifEmpty { trumps } + } + + return hand + } +} diff --git a/engine/src/test/kotlin/hr/bela/engine/CountingDrillTest.kt b/engine/src/test/kotlin/hr/bela/engine/CountingDrillTest.kt new file mode 100644 index 0000000..9f075ec --- /dev/null +++ b/engine/src/test/kotlin/hr/bela/engine/CountingDrillTest.kt @@ -0,0 +1,41 @@ +package hr.bela.engine + +import org.junit.Assert.assertEquals +import org.junit.Assert.assertTrue +import org.junit.Test +import kotlin.random.Random + +class CountingDrillTest { + @Test + fun `every round offers four distinct answers with exactly one correct`() { + val random = Random(1) + repeat(5_000) { + val tricks = random.nextInt(1, 9) + val round = CountingDrill.round(random, tricks, lastTrick = random.nextBoolean()) + assertEquals(tricks * 4, round.cards.size) + assertEquals(round.cards.size, round.cards.toSet().size) + assertEquals(4, round.options.size) + assertEquals(4, round.options.map { it.value }.toSet().size) + assertEquals(1, round.options.count { it.value == round.total }) + assertTrue(round.options.all { it.value >= 0 }) + } + } + + @Test + fun `total counts trump values and the last trick`() { + val round = CountingRound(Suit.HERC, cards("HJ", "H9", "KJ", "K9", "PA", "TX"), lastTrick = true, options = emptyList()) + // 20 + 14 + 2 + 0 + 11 + 10 = 57, plus 10 for the last trick + assertEquals(57, round.cardPoints) + assertEquals(67, round.total) + } + + @Test + fun `wrong answers come from the slips the pile allows`() { + val round = CountingRound(Suit.HERC, cards("HJ", "K7", "P8", "T7"), lastTrick = false, options = emptyList()) + val options = CountingDrill.options(round, Random(3)) + val byMistake = options.filter { it.mistake != null }.associate { it.mistake to it.value } + byMistake[CountingMistake.TRUMP_JACK_AS_PLAIN]?.let { assertEquals(2, it) } + byMistake[CountingMistake.ADDED_LAST_TRICK]?.let { assertEquals(30, it) } + assertTrue(options.any { it.value == 20 }) + } +} diff --git a/engine/src/test/kotlin/hr/bela/engine/DeclarationsTest.kt b/engine/src/test/kotlin/hr/bela/engine/DeclarationsTest.kt new file mode 100644 index 0000000..1e92adb --- /dev/null +++ b/engine/src/test/kotlin/hr/bela/engine/DeclarationsTest.kt @@ -0,0 +1,59 @@ +package hr.bela.engine + +import org.junit.Assert.assertEquals +import org.junit.Assert.assertNull +import org.junit.Assert.assertTrue +import org.junit.Test + +class DeclarationsTest { + @Test + fun `finds sequences of three four and five`() { + val found = Declarations.find(0, cards("H7", "H8", "H9", "KJ", "KQ", "KK", "KA", "PA")) + assertEquals(listOf(20, 50), found.map { it.points }.sorted()) + + val five = Declarations.find(0, cards("P9", "PX", "PJ", "PQ", "PK", "H7", "K8", "TA")) + assertEquals(listOf(100), five.map { it.points }) + } + + @Test + fun `two short runs in one suit are two declarations`() { + val found = Declarations.find(0, cards("H7", "H8", "H9", "HQ", "HK", "HA", "K7", "P7")) + assertEquals(listOf(20, 20), found.map { it.points }) + } + + @Test + fun `finds fours and ignores fours of sevens and eights`() { + assertEquals(listOf(200), Declarations.find(0, cards("HJ", "KJ", "PJ", "TJ", "H7", "K8", "PA", "TX")).map { it.points }) + assertEquals(listOf(150), Declarations.find(0, cards("H9", "K9", "P9", "T9", "H7", "KA", "PK", "TX")).map { it.points }) + assertTrue(Declarations.find(0, cards("H7", "K7", "P7", "T7", "HA", "KX", "PQ", "TJ")).isEmpty()) + } + + @Test + fun `stronger declaration wins for its team`() { + val decls = Declarations.find(1, cards("H7", "H8", "H9", "HX", "KA", "PA", "TA", "K7")) + // 50 + Declarations.find(2, cards("PJ", "PQ", "PK", "KJ", "H7", "T8", "T9", "TX")) // 20 + 20 + assertEquals(1, Declarations.winningTeam(decls, firstSeat = 0)) + } + + @Test + fun `four of a kind beats a sequence of equal value`() { + val decls = Declarations.find(0, cards("H9", "HX", "HJ", "HQ", "HK", "K7", "P7", "T8")) + // 100 sequence + Declarations.find(1, cards("HA", "KA", "PA", "TA", "K8", "P8", "T7", "KX")) // four aces + assertEquals(1, Declarations.winningTeam(decls, firstSeat = 0)) + } + + @Test + fun `equal declarations go to the player nearer the first player`() { + val decls = listOf( + Declaration(3, DeclarationKind.SEQUENCE, cards("H7", "H8", "H9"), 20), + Declaration(2, DeclarationKind.SEQUENCE, cards("K7", "K8", "K9"), 20), + ) + assertEquals(1, Declarations.winningTeam(decls, firstSeat = 3)) + assertEquals(0, Declarations.winningTeam(decls, firstSeat = 2)) + } + + @Test + fun `no declarations, no team`() { + assertNull(Declarations.winningTeam(emptyList(), firstSeat = 0)) + } +} diff --git a/engine/src/test/kotlin/hr/bela/engine/PlayRulesTest.kt b/engine/src/test/kotlin/hr/bela/engine/PlayRulesTest.kt new file mode 100644 index 0000000..4c910c2 --- /dev/null +++ b/engine/src/test/kotlin/hr/bela/engine/PlayRulesTest.kt @@ -0,0 +1,96 @@ +package hr.bela.engine + +import org.junit.Assert.assertEquals +import org.junit.Test + +class PlayRulesTest { + private val trump = Suit.HERC + + private fun legal(hand: List, vararg trick: String, mustBeat: Boolean = true) = + PlayRules.legalMoves(hand, Trick(0, cards(*trick)), trump, mustBeat).toSet() + + @Test + fun `card points add up to 152 whatever the trump`() { + for (t in Suit.entries) assertEquals(152, Deck.all.sumOf { it.points(t) }) + } + + @Test + fun `leader may play anything`() { + val hand = cards("H7", "KA", "PX") + assertEquals(hand.toSet(), legal(hand)) + } + + @Test + fun `must follow suit and go higher when able`() { + val hand = cards("KA", "K7", "PA") + assertEquals(setOf(c("KA")), legal(hand, "KK")) + } + + @Test + fun `follows with any card of the suit when it cannot go higher`() { + val hand = cards("K7", "K8", "PA") + assertEquals(setOf(c("K7"), c("K8")), legal(hand, "KA")) + } + + @Test + fun `without iber any card of the led suit is fine`() { + val hand = cards("KA", "K7", "PA") + assertEquals(setOf(c("KA"), c("K7")), legal(hand, "KK", mustBeat = false)) + } + + @Test + fun `no need to go higher once a plain trick has been cut`() { + val hand = cards("KA", "K7") + assertEquals(setOf(c("KA"), c("K7")), legal(hand, "KK", "H7")) + } + + @Test + fun `must cut with trump when out of the led suit`() { + val hand = cards("H7", "HA", "PA") + assertEquals(setOf(c("H7"), c("HA")), legal(hand, "KK")) + } + + @Test + fun `must over-cut an earlier cut when able`() { + val hand = cards("H7", "HJ", "PA") + assertEquals(setOf(c("HJ")), legal(hand, "KK", "HA")) + } + + @Test + fun `plays any trump when it cannot over-cut`() { + val hand = cards("H7", "H8", "PA") + assertEquals(setOf(c("H7"), c("H8")), legal(hand, "KK", "HA")) + } + + @Test + fun `must go higher in trump when trump is led`() { + val hand = cards("H9", "H7", "PA") + assertEquals(setOf(c("H9")), legal(hand, "HA")) + } + + @Test + fun `must beat even the partner`() { + // Seat 0 leads, seat 1 plays, seat 2 (partner of 0) must still go higher. + val hand = cards("KA", "K7") + assertEquals(setOf(c("KA")), legal(hand, "KK", "K8")) + } + + @Test + fun `any card when out of the led suit and out of trumps`() { + val hand = cards("PA", "T7") + assertEquals(hand.toSet(), legal(hand, "KK")) + } + + @Test + fun `trump beats plain cards and the higher trump wins`() { + assertEquals(1, Trick(0, cards("KA", "H7", "KX", "PA")).winner(trump)) + assertEquals(3, Trick(0, cards("KA", "H7", "KX", "H9")).winner(trump)) + assertEquals(2, Trick(0, cards("K7", "PA", "KX", "K8")).winner(trump)) + } + + @Test + fun `nine beats ace in trump but not in a plain suit`() { + assertEquals(1, Trick(0, cards("HA", "H9")).winner(trump)) + assertEquals(0, Trick(0, cards("KA", "K9")).winner(trump)) + } +} diff --git a/engine/src/test/kotlin/hr/bela/engine/ScoringTest.kt b/engine/src/test/kotlin/hr/bela/engine/ScoringTest.kt new file mode 100644 index 0000000..ba9d7b5 --- /dev/null +++ b/engine/src/test/kotlin/hr/bela/engine/ScoringTest.kt @@ -0,0 +1,87 @@ +package hr.bela.engine + +import org.junit.Assert.assertEquals +import org.junit.Test + +class ScoringTest { + private val rules = RuleSet() + + /** + * Eight tricks of one suit each half, trump herc. Points per trick: + * 0: H7-HX 24, 1: HJ-HA 38, 2: K7-KX 10, 3: KJ-KA 20, 4: P low 10, 5: P high 20, 6: T low 10, 7: T high 20. + */ + private fun hand(caller: Int, winners: List, belaSeat: Int? = null, declarations: List = emptyList()): HandState { + val tricks = Deck.all.chunked(4).mapIndexed { i, cs -> CompletedTrick(Trick(0, cs), winners[i]) } + return HandState( + number = 1, + dealer = 3, + cards = List(4) { emptyList() }, + talon = List(4) { emptyList() }, + trump = Suit.HERC, + caller = caller, + declarations = declarations, + declarationTeam = Declarations.winningTeam(declarations, 0), + belaSeat = belaSeat, + trick = Trick(0), + tricks = tricks, + ) + } + + @Test + fun `caller with more than half passes and both teams write`() { + // Team 0: tricks 0, 1, 3 = 82. Team 1: 70 + 10 for the last trick = 80. + val result = Scoring.score(hand(caller = 0, winners = listOf(0, 2, 1, 0, 1, 3, 1, 3)), rules, 0) + assertEquals(listOf(82, 80), result.raw) + assertEquals(Outcome.PASSED, result.outcome) + assertEquals(listOf(82, 80), result.awarded) + } + + @Test + fun `caller with half or less falls and defenders take everything`() { + val result = Scoring.score(hand(caller = 1, winners = listOf(0, 2, 1, 0, 1, 3, 1, 3)), rules, 0) + assertEquals(Outcome.FELL, result.outcome) + assertEquals(listOf(162, 0), result.awarded) + } + + @Test + fun `all tricks earn the stiglja bonus`() { + val result = Scoring.score(hand(caller = 0, winners = List(8) { 0 }), rules, 0) + assertEquals(listOf(252, 0), result.raw) + assertEquals(listOf(90, 0), result.stigljaPoints) + } + + @Test + fun `bela and declarations count only with at least one trick`() { + val decl = listOf(Declaration(1, DeclarationKind.SEQUENCE, cards("K7", "K8", "K9"), 20)) + val result = Scoring.score(hand(caller = 0, winners = List(8) { 0 }, belaSeat = 1, declarations = decl), rules, 0) + assertEquals(listOf(0, 0), result.belaPoints) + assertEquals(listOf(0, 0), result.declarationPoints) + + val withTrick = Scoring.score(hand(caller = 0, winners = listOf(0, 0, 1, 0, 0, 0, 0, 0), belaSeat = 1, declarations = decl), rules, 0) + assertEquals(listOf(0, 20), withTrick.belaPoints) + assertEquals(listOf(0, 20), withTrick.declarationPoints) + } + + @Test + fun `a tie hangs the caller's points until the next decided hand`() { + val tie = Scoring.settle(listOf(81, 81), callerTeam = 0, tieRule = TieRule.HANGS, hangingBefore = 0) + assertEquals(Outcome.TIED, tie.outcome) + assertEquals(listOf(0, 81), tie.awarded) + assertEquals(81, tie.hangingAfter) + + val next = Scoring.settle(listOf(100, 62), callerTeam = 0, tieRule = TieRule.HANGS, hangingBefore = 81) + assertEquals(listOf(181, 62), next.awarded) + assertEquals(0, next.settledHangingTeam) + assertEquals(0, next.hangingAfter) + + val fell = Scoring.settle(listOf(60, 102), callerTeam = 0, tieRule = TieRule.HANGS, hangingBefore = 81) + assertEquals(listOf(0, 243), fell.awarded) + } + + @Test + fun `a tie falls under the caller-falls rule`() { + val tie = Scoring.settle(listOf(81, 81), callerTeam = 0, tieRule = TieRule.CALLER_FALLS, hangingBefore = 0) + assertEquals(Outcome.FELL, tie.outcome) + assertEquals(listOf(0, 162), tie.awarded) + } +} diff --git a/engine/src/test/kotlin/hr/bela/engine/SimulationTest.kt b/engine/src/test/kotlin/hr/bela/engine/SimulationTest.kt new file mode 100644 index 0000000..86e7f4e --- /dev/null +++ b/engine/src/test/kotlin/hr/bela/engine/SimulationTest.kt @@ -0,0 +1,73 @@ +package hr.bela.engine + +import org.junit.Assert.assertEquals +import org.junit.Assert.assertNotNull +import org.junit.Assert.assertTrue +import org.junit.Test + +/** Bots play whole games; the engine must never reach an invalid state and every hand must add up. */ +class SimulationTest { + private fun playOut(seed: Long, rules: RuleSet = RuleSet(), onAction: (Action) -> Unit = {}): GameState { + var state = Bela.newGame(rules, seed) + var steps = 0 + while (state.phase != Phase.GAME_OVER) { + val action = when (state.phase) { + Phase.BIDDING -> state.toAct!!.let { Action.Call(it, HeuristicBot.chooseTrump(state, it)) } + Phase.PLAYING -> state.toAct!!.let { Action.Play(it, HeuristicBot.chooseCard(state, it)) } + Phase.HAND_OVER -> Action.NextHand + Phase.GAME_OVER -> error("unreachable") + } + onAction(action) + state = state.apply(action) + check(++steps < 20_000) { "Game $seed did not finish" } + } + return state + } + + @Test + fun `bots finish a thousand games and every hand adds up`() { + var handsPlayed = 0 + var stiglje = 0 + var falls = 0 + for (seed in 1L..1000L) { + val end = playOut(seed) + assertNotNull(end.winnerTeam) + var hanging = 0 + for (r in end.results) { + val extras = r.declarationPoints.sum() + r.belaPoints.sum() + r.stigljaPoints.sum() + assertEquals("seed $seed hand ${r.handNumber}", 162 + extras, r.total) + assertEquals(8, r.tricksWon.sum()) + val written = r.awarded.sum() + when (r.outcome) { + Outcome.TIED -> assertEquals(r.raw[1 - r.callerTeam], written) + else -> assertEquals(r.total + hanging, written) + } + hanging = r.hangingAfter + handsPlayed++ + if (r.stigljaPoints.sum() > 0) stiglje++ + if (r.outcome == Outcome.FELL) falls++ + } + if (end.belotSeat == null) { + assertEquals(end.results.sumOf { it.awarded[0] }, end.scores[0]) + assertTrue(end.scores.max() >= end.rules.targetScore) + } + } + println("Simulated $handsPlayed hands: $falls falls, $stiglje stiglja") + } + + @Test + fun `a saved game replays to the same state`() { + val actions = mutableListOf() + val end = playOut(42L) { actions += it } + val record = GameRecord(42L, actions) + val decoded = GameRecord.decode(record.encode())!! + assertEquals(record, decoded) + assertEquals(end, decoded.replay()) + } + + @Test + fun `games finish with house rules switched`() { + val rules = RuleSet(targetScore = 501, stigljaBonus = 0, dealerMustCall = false, mustBeat = false, tieRule = TieRule.CALLER_FALLS) + for (seed in 1L..200L) assertNotNull(playOut(seed, rules).winnerTeam) + } +} diff --git a/engine/src/test/kotlin/hr/bela/engine/TestCards.kt b/engine/src/test/kotlin/hr/bela/engine/TestCards.kt new file mode 100644 index 0000000..d18ea17 --- /dev/null +++ b/engine/src/test/kotlin/hr/bela/engine/TestCards.kt @@ -0,0 +1,6 @@ +package hr.bela.engine + +/** Short card notation for tests: "HA" = ace of herc, "PX" = ten of pik (same as [Card.code]). */ +fun c(code: String): Card = Card.parse(code) + +fun cards(vararg codes: String): List = codes.map(::c) diff --git a/gradle.properties b/gradle.properties new file mode 100644 index 0000000..87dc527 --- /dev/null +++ b/gradle.properties @@ -0,0 +1,8 @@ +org.gradle.jvmargs=-Xmx4g -Dfile.encoding=UTF-8 +org.gradle.parallel=true +org.gradle.caching=true + +android.useAndroidX=true +android.nonTransitiveRClass=true + +kotlin.code.style=official diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml new file mode 100644 index 0000000..4ac47ad --- /dev/null +++ b/gradle/libs.versions.toml @@ -0,0 +1,32 @@ +[versions] +# Same toolchain as the AndroidTV project, so the build resolves from the local Gradle cache. +# AGP 9.4.1, not 9.5.x: 9.5.0/9.5.1 break `gradlew tasks` on a Compose Preview task. +# AGP 9 compiles Kotlin itself, so the app module has no kotlin-android plugin. +agp = "9.4.1" +kotlin = "2.4.21" +# Compose BOM 2026.06.01 (Compose 1.11) is the newest line that builds with compileSdk 36. +compose-bom = "2026.06.01" +activity-compose = "1.13.0" +lifecycle = "2.10.0" +coroutines = "1.11.0" +junit = "4.13.2" + +[libraries] +compose-bom = { module = "androidx.compose:compose-bom", version.ref = "compose-bom" } +compose-ui = { module = "androidx.compose.ui:ui" } +compose-foundation = { module = "androidx.compose.foundation:foundation" } +compose-material3 = { module = "androidx.compose.material3:material3" } +compose-ui-tooling = { module = "androidx.compose.ui:ui-tooling" } +compose-ui-tooling-preview = { module = "androidx.compose.ui:ui-tooling-preview" } +activity-compose = { module = "androidx.activity:activity-compose", version.ref = "activity-compose" } +lifecycle-runtime-compose = { module = "androidx.lifecycle:lifecycle-runtime-compose", version.ref = "lifecycle" } +lifecycle-viewmodel-compose = { module = "androidx.lifecycle:lifecycle-viewmodel-compose", version.ref = "lifecycle" } +coroutines-android = { module = "org.jetbrains.kotlinx:kotlinx-coroutines-android", version.ref = "coroutines" } +junit = { module = "junit:junit", version.ref = "junit" } +# QR code for the "share the app" link in Settings (Apache 2.0). +zxing-core = { module = "com.google.zxing:core", version = "3.5.3" } + +[plugins] +android-application = { id = "com.android.application", version.ref = "agp" } +kotlin-jvm = { id = "org.jetbrains.kotlin.jvm", version.ref = "kotlin" } +compose-compiler = { id = "org.jetbrains.kotlin.plugin.compose", version.ref = "kotlin" } diff --git a/gradle/wrapper/gradle-wrapper.jar b/gradle/wrapper/gradle-wrapper.jar new file mode 100644 index 0000000..9fa7f28 Binary files /dev/null and b/gradle/wrapper/gradle-wrapper.jar differ diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties new file mode 100644 index 0000000..91c4fc6 --- /dev/null +++ b/gradle/wrapper/gradle-wrapper.properties @@ -0,0 +1,9 @@ +distributionBase=GRADLE_USER_HOME +distributionPath=wrapper/dists +distributionUrl=https\://services.gradle.org/distributions/gradle-9.8.2-bin.zip +networkTimeout=10000 +retries=0 +retryBackOffMs=500 +validateDistributionUrl=true +zipStoreBase=GRADLE_USER_HOME +zipStorePath=wrapper/dists diff --git a/gradlew b/gradlew new file mode 100644 index 0000000..249efbb --- /dev/null +++ b/gradlew @@ -0,0 +1,248 @@ +#!/bin/sh + +# +# Copyright © 2015 the original authors. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# SPDX-License-Identifier: Apache-2.0 +# + +############################################################################## +# +# gradlew start up script for POSIX generated by Gradle. +# +# Important for running: +# +# (1) You need a POSIX-compliant shell to run this script. If your /bin/sh is +# noncompliant, but you have some other compliant shell such as ksh or +# bash, then to run this script, type that shell name before the whole +# command line, like: +# +# ksh gradlew +# +# Busybox and similar reduced shells will NOT work, because this script +# requires all of these POSIX shell features: +# * functions; +# * expansions «$var», «${var}», «${var:-default}», «${var+SET}», +# «${var#prefix}», «${var%suffix}», and «$( cmd )»; +# * compound commands having a testable exit status, especially «case»; +# * various built-in commands including «command», «set», and «ulimit». +# +# Important for patching: +# +# (2) This script targets any POSIX shell, so it avoids extensions provided +# by Bash, Ksh, etc; in particular arrays are avoided. +# +# The "traditional" practice of packing multiple parameters into a +# space-separated string is a well documented source of bugs and security +# problems, so this is (mostly) avoided, by progressively accumulating +# options in "$@", and eventually passing that to Java. +# +# Where the inherited environment variables (DEFAULT_JVM_OPTS, JAVA_OPTS, +# and GRADLE_OPTS) rely on word-splitting, this is performed explicitly; +# see the in-line comments for details. +# +# There are tweaks for specific operating systems such as AIX, CygWin, +# Darwin, MinGW, and NonStop. +# +# (3) This script is generated from the Groovy template +# https://github.com/gradle/gradle/blob/3d91ce3b8caaf77ad09f381f43615b715b53f72c/platforms/jvm/plugins-application/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt +# within the Gradle project. +# +# You can find Gradle at https://github.com/gradle/gradle/. +# +############################################################################## + +# Attempt to set APP_HOME + +# Resolve links: $0 may be a link +app_path=$0 + +# Need this for daisy-chained symlinks. +while + APP_HOME=${app_path%"${app_path##*/}"} # leaves a trailing /; empty if no leading path + [ -h "$app_path" ] +do + ls=$( ls -ld "$app_path" ) + link=${ls#*' -> '} + case $link in #( + /*) app_path=$link ;; #( + *) app_path=$APP_HOME$link ;; + esac +done + +# This is normally unused +# shellcheck disable=SC2034 +APP_BASE_NAME=${0##*/} +# Discard cd standard output in case $CDPATH is set (https://github.com/gradle/gradle/issues/25036) +APP_HOME=$( cd -P "${APP_HOME:-./}" > /dev/null && printf '%s\n' "$PWD" ) || exit + +# Use the maximum available, or set MAX_FD != -1 to use that value. +MAX_FD=maximum + +warn () { + echo "$*" +} >&2 + +die () { + echo + echo "$*" + echo + exit 1 +} >&2 + +# OS specific support (must be 'true' or 'false'). +cygwin=false +msys=false +darwin=false +nonstop=false +case "$( uname )" in #( + CYGWIN* ) cygwin=true ;; #( + Darwin* ) darwin=true ;; #( + MSYS* | MINGW* ) msys=true ;; #( + NONSTOP* ) nonstop=true ;; +esac + + + +# Determine the Java command to use to start the JVM. +if [ -n "$JAVA_HOME" ] ; then + if [ -x "$JAVA_HOME/jre/sh/java" ] ; then + # IBM's JDK on AIX uses strange locations for the executables + JAVACMD=$JAVA_HOME/jre/sh/java + else + JAVACMD=$JAVA_HOME/bin/java + fi + if [ ! -x "$JAVACMD" ] ; then + die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME + +Please set the JAVA_HOME variable in your environment to match the +location of your Java installation." + fi +else + JAVACMD=java + if ! command -v java >/dev/null 2>&1 + then + die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. + +Please set the JAVA_HOME variable in your environment to match the +location of your Java installation." + fi +fi + +# Increase the maximum file descriptors if we can. +if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then + case $MAX_FD in #( + max*) + # In POSIX sh, ulimit -H is undefined. That's why the result is checked to see if it worked. + # shellcheck disable=SC2039,SC3045 + MAX_FD=$( ulimit -H -n ) || + warn "Could not query maximum file descriptor limit" + esac + case $MAX_FD in #( + '' | soft) :;; #( + *) + # In POSIX sh, ulimit -n is undefined. That's why the result is checked to see if it worked. + # shellcheck disable=SC2039,SC3045 + ulimit -n "$MAX_FD" || + warn "Could not set maximum file descriptor limit to $MAX_FD" + esac +fi + +# Collect all arguments for the java command, stacking in reverse order: +# * args from the command line +# * the main class name +# * -classpath +# * -D...appname settings +# * --module-path (only if needed) +# * DEFAULT_JVM_OPTS, JAVA_OPTS, and GRADLE_OPTS environment variables. + +# For Cygwin or MSYS, switch paths to Windows format before running java +if "$cygwin" || "$msys" ; then + APP_HOME=$( cygpath --path --mixed "$APP_HOME" ) + + JAVACMD=$( cygpath --unix "$JAVACMD" ) + + # Now convert the arguments - kludge to limit ourselves to /bin/sh + for arg do + if + case $arg in #( + -*) false ;; # don't mess with options #( + /?*) t=${arg#/} t=/${t%%/*} # looks like a POSIX filepath + [ -e "$t" ] ;; #( + *) false ;; + esac + then + arg=$( cygpath --path --ignore --mixed "$arg" ) + fi + # Roll the args list around exactly as many times as the number of + # args, so each arg winds up back in the position where it started, but + # possibly modified. + # + # NB: a `for` loop captures its iteration list before it begins, so + # changing the positional parameters here affects neither the number of + # iterations, nor the values presented in `arg`. + shift # remove old arg + set -- "$@" "$arg" # push replacement arg + done +fi + + +# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. +DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"' + +# Collect all arguments for the java command: +# * DEFAULT_JVM_OPTS, JAVA_OPTS, and optsEnvironmentVar are not allowed to contain shell fragments, +# and any embedded shellness will be escaped. +# * For example: A user cannot expect ${Hostname} to be expanded, as it is an environment variable and will be +# treated as '${Hostname}' itself on the command line. + +set -- \ + "-Dorg.gradle.appname=$APP_BASE_NAME" \ + -jar "$APP_HOME/gradle/wrapper/gradle-wrapper.jar" \ + "$@" + +# Stop when "xargs" is not available. +if ! command -v xargs >/dev/null 2>&1 +then + die "xargs is not available" +fi + +# Use "xargs" to parse quoted args. +# +# With -n1 it outputs one arg per line, with the quotes and backslashes removed. +# +# In Bash we could simply go: +# +# readarray ARGS < <( xargs -n1 <<<"$var" ) && +# set -- "${ARGS[@]}" "$@" +# +# but POSIX shell has neither arrays nor command substitution, so instead we +# post-process each arg (as a line of input to sed) to backslash-escape any +# character that might be a shell metacharacter, then use eval to reverse +# that process (while maintaining the separation between arguments), and wrap +# the whole thing up as a single "set" statement. +# +# This will of course break if any of these variables contains a newline or +# an unmatched quote. +# + +eval "set -- $( + printf '%s\n' "$DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS" | + xargs -n1 | + sed ' s~[^-[:alnum:]+,./:=@_]~\\&~g; ' | + tr '\n' ' ' + )" '"$@"' + +exec "$JAVACMD" "$@" diff --git a/gradlew.bat b/gradlew.bat new file mode 100644 index 0000000..3185a43 --- /dev/null +++ b/gradlew.bat @@ -0,0 +1,112 @@ +@rem +@rem Copyright 2015 the original author or authors. +@rem +@rem Licensed under the Apache License, Version 2.0 (the "License"); +@rem you may not use this file except in compliance with the License. +@rem You may obtain a copy of the License at +@rem +@rem https://www.apache.org/licenses/LICENSE-2.0 +@rem +@rem Unless required by applicable law or agreed to in writing, software +@rem distributed under the License is distributed on an "AS IS" BASIS, +@rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +@rem See the License for the specific language governing permissions and +@rem limitations under the License. +@rem +@rem SPDX-License-Identifier: Apache-2.0 +@rem + +@if "%DEBUG%"=="" @echo off +@rem ########################################################################## +@rem +@rem gradlew startup script for Windows +@rem +@rem ########################################################################## + +@rem Set local scope for the variables, and ensure extensions are enabled +setlocal EnableExtensions + +@rem Catch executions from older scripts and ensure they exit cleanly. +@rem This can be removed once we can be reasonably confident that few people +@rem will be migrating directly to this new wrapper. +goto afterSafetyNet +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: +:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: +goto exitWithErrorLevel +:afterSafetyNet + +set DIRNAME=%~dp0 +if "%DIRNAME%"=="" set DIRNAME=. +@rem This is normally unused +set APP_BASE_NAME=%~n0 +set APP_HOME=%DIRNAME% + +@rem Resolve any "." and ".." in APP_HOME to make it shorter. +for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi + +@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. +set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m" + +@rem Find java.exe +if defined JAVA_HOME goto findJavaFromJavaHome + +set JAVA_EXE=java.exe +%JAVA_EXE% -version >NUL 2>&1 +if %ERRORLEVEL% equ 0 goto execute + +1>&2 echo. +1>&2 echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. +1>&2 echo. +1>&2 echo Please set the JAVA_HOME variable in your environment to match the +1>&2 echo location of your Java installation. + +"%COMSPEC%" /c exit 1 +goto exitWithErrorLevel + +:findJavaFromJavaHome +set JAVA_HOME=%JAVA_HOME:"=% +set JAVA_EXE=%JAVA_HOME%/bin/java.exe + +if exist "%JAVA_EXE%" goto execute + +1>&2 echo. +1>&2 echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% +1>&2 echo. +1>&2 echo Please set the JAVA_HOME variable in your environment to match the +1>&2 echo location of your Java installation. + +"%COMSPEC%" /c exit 1 +goto exitWithErrorLevel + +:execute +@rem Setup the command line + + + +@rem Execute gradlew +@rem endlocal doesn't take effect until after the line is parsed and variables are expanded +@rem which allows us to clear the local environment before executing the java command +endlocal & "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -jar "%APP_HOME%\gradle\wrapper\gradle-wrapper.jar" %* & call :exitWithErrorLevel & goto exitWithErrorLevel + +@rem This label must not be changed. We rely on old scripts being able to jump to this point. +:exitWithErrorLevel +@rem Use "%COMSPEC%" /c exit to allow operators to work properly in scripts +"%COMSPEC%" /c exit %ERRORLEVEL% diff --git a/icon.png b/icon.png new file mode 100644 index 0000000..f5dc0d5 Binary files /dev/null and b/icon.png differ diff --git a/licenses/Cinzel-OFL.txt b/licenses/Cinzel-OFL.txt new file mode 100644 index 0000000..afdfd14 --- /dev/null +++ b/licenses/Cinzel-OFL.txt @@ -0,0 +1,93 @@ +Copyright 2020 The Cinzel Project Authors (https://github.com/NDISCOVER/Cinzel) + +This Font Software is licensed under the SIL Open Font License, Version 1.1. +This license is copied below, and is also available with a FAQ at: +http://scripts.sil.org/OFL + + +----------------------------------------------------------- +SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007 +----------------------------------------------------------- + +PREAMBLE +The goals of the Open Font License (OFL) are to stimulate worldwide +development of collaborative font projects, to support the font creation +efforts of academic and linguistic communities, and to provide a free and +open framework in which fonts may be shared and improved in partnership +with others. + +The OFL allows the licensed fonts to be used, studied, modified and +redistributed freely as long as they are not sold by themselves. The +fonts, including any derivative works, can be bundled, embedded, +redistributed and/or sold with any software provided that any reserved +names are not used by derivative works. The fonts and derivatives, +however, cannot be released under any other type of license. The +requirement for fonts to remain under this license does not apply +to any document created using the fonts or their derivatives. + +DEFINITIONS +"Font Software" refers to the set of files released by the Copyright +Holder(s) under this license and clearly marked as such. This may +include source files, build scripts and documentation. + +"Reserved Font Name" refers to any names specified as such after the +copyright statement(s). + +"Original Version" refers to the collection of Font Software components as +distributed by the Copyright Holder(s). + +"Modified Version" refers to any derivative made by adding to, deleting, +or substituting -- in part or in whole -- any of the components of the +Original Version, by changing formats or by porting the Font Software to a +new environment. + +"Author" refers to any designer, engineer, programmer, technical +writer or other person who contributed to the Font Software. + +PERMISSION & CONDITIONS +Permission is hereby granted, free of charge, to any person obtaining +a copy of the Font Software, to use, study, copy, merge, embed, modify, +redistribute, and sell modified and unmodified copies of the Font +Software, subject to the following conditions: + +1) Neither the Font Software nor any of its individual components, +in Original or Modified Versions, may be sold by itself. + +2) Original or Modified Versions of the Font Software may be bundled, +redistributed and/or sold with any software, provided that each copy +contains the above copyright notice and this license. These can be +included either as stand-alone text files, human-readable headers or +in the appropriate machine-readable metadata fields within text or +binary files as long as those fields can be easily viewed by the user. + +3) No Modified Version of the Font Software may use the Reserved Font +Name(s) unless explicit written permission is granted by the corresponding +Copyright Holder. This restriction only applies to the primary font name as +presented to the users. + +4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font +Software shall not be used to promote, endorse or advertise any +Modified Version, except to acknowledge the contribution(s) of the +Copyright Holder(s) and the Author(s) or with their explicit written +permission. + +5) The Font Software, modified or unmodified, in part or in whole, +must be distributed entirely under this license, and must not be +distributed under any other license. The requirement for fonts to +remain under this license does not apply to any document created +using the Font Software. + +TERMINATION +This license becomes null and void if any of the above conditions are +not met. + +DISCLAIMER +THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT +OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE +COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL +DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM +OTHER DEALINGS IN THE FONT SOFTWARE. diff --git a/licenses/Inter-OFL.txt b/licenses/Inter-OFL.txt new file mode 100644 index 0000000..21f6aff --- /dev/null +++ b/licenses/Inter-OFL.txt @@ -0,0 +1,93 @@ +Copyright 2020 The Inter Project Authors (https://github.com/rsms/inter) + +This Font Software is licensed under the SIL Open Font License, Version 1.1. +This license is copied below, and is also available with a FAQ at: +https://scripts.sil.org/OFL + + +----------------------------------------------------------- +SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007 +----------------------------------------------------------- + +PREAMBLE +The goals of the Open Font License (OFL) are to stimulate worldwide +development of collaborative font projects, to support the font creation +efforts of academic and linguistic communities, and to provide a free and +open framework in which fonts may be shared and improved in partnership +with others. + +The OFL allows the licensed fonts to be used, studied, modified and +redistributed freely as long as they are not sold by themselves. The +fonts, including any derivative works, can be bundled, embedded, +redistributed and/or sold with any software provided that any reserved +names are not used by derivative works. The fonts and derivatives, +however, cannot be released under any other type of license. The +requirement for fonts to remain under this license does not apply +to any document created using the fonts or their derivatives. + +DEFINITIONS +"Font Software" refers to the set of files released by the Copyright +Holder(s) under this license and clearly marked as such. This may +include source files, build scripts and documentation. + +"Reserved Font Name" refers to any names specified as such after the +copyright statement(s). + +"Original Version" refers to the collection of Font Software components as +distributed by the Copyright Holder(s). + +"Modified Version" refers to any derivative made by adding to, deleting, +or substituting -- in part or in whole -- any of the components of the +Original Version, by changing formats or by porting the Font Software to a +new environment. + +"Author" refers to any designer, engineer, programmer, technical +writer or other person who contributed to the Font Software. + +PERMISSION & CONDITIONS +Permission is hereby granted, free of charge, to any person obtaining +a copy of the Font Software, to use, study, copy, merge, embed, modify, +redistribute, and sell modified and unmodified copies of the Font +Software, subject to the following conditions: + +1) Neither the Font Software nor any of its individual components, +in Original or Modified Versions, may be sold by itself. + +2) Original or Modified Versions of the Font Software may be bundled, +redistributed and/or sold with any software, provided that each copy +contains the above copyright notice and this license. These can be +included either as stand-alone text files, human-readable headers or +in the appropriate machine-readable metadata fields within text or +binary files as long as those fields can be easily viewed by the user. + +3) No Modified Version of the Font Software may use the Reserved Font +Name(s) unless explicit written permission is granted by the corresponding +Copyright Holder. This restriction only applies to the primary font name as +presented to the users. + +4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font +Software shall not be used to promote, endorse or advertise any +Modified Version, except to acknowledge the contribution(s) of the +Copyright Holder(s) and the Author(s) or with their explicit written +permission. + +5) The Font Software, modified or unmodified, in part or in whole, +must be distributed entirely under this license, and must not be +distributed under any other license. The requirement for fonts to +remain under this license does not apply to any document created +using the Font Software. + +TERMINATION +This license becomes null and void if any of the above conditions are +not met. + +DISCLAIMER +THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT +OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE +COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL +DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM +OTHER DEALINGS IN THE FONT SOFTWARE. diff --git a/settings.gradle.kts b/settings.gradle.kts new file mode 100644 index 0000000..2dbf490 --- /dev/null +++ b/settings.gradle.kts @@ -0,0 +1,21 @@ +pluginManagement { + repositories { + google() + mavenCentral() + gradlePluginPortal() + } +} + +dependencyResolutionManagement { + repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS) + repositories { + google() + mavenCentral() + } +} + +rootProject.name = "Bela" + +// :engine — pure Kotlin rules engine and bots, no Android dependencies (later: KMP for server/iOS). +// :app — the Android app (Jetpack Compose). +include(":engine", ":app") diff --git a/tools/import_png_cards.py b/tools/import_png_cards.py new file mode 100644 index 0000000..4a88fb6 --- /dev/null +++ b/tools/import_png_cards.py @@ -0,0 +1,67 @@ +""" +Import the PNG deck in card_assets/hungarian-playing-cards/ as the app's card drawables. + + python tools/import_png_cards.py + +Writes, into app/src/main/res/drawable-nodpi/: + card__.webp e.g. card_srce_as.webp + suit_.webp the large suit icons + +Card faces come from cards-2x/ (726 x 1170, made by tools/upscale_png_cards.py) when it exists, otherwise +from cards-large/ (363 x 585). Nothing is resized here. + +The card back is not imported: the app draws its own (CardBack in CardArt.kt). +This overwrites the faces and icons produced by tools/render_cards.py (our own SVG cards); run that script +to switch back. See card_assets/hungarian-playing-cards/NOTICE.md about the licence. +""" + +import sys +from pathlib import Path + +from PIL import Image + +ROOT = Path(__file__).resolve().parent.parent +SOURCE = ROOT / "card_assets" / "hungarian-playing-cards" +TARGET = ROOT / "app" / "src" / "main" / "res" / "drawable-nodpi" + +# Their names -> ours (suit order matches the engine: srce = herc, zvono = karo, list = pik, zir = tref). +SUITS = {"heart": "srce", "bell": "zvono", "leaf": "list", "acorn": "zir"} +RANKS = { + "seven": "7", "eight": "8", "nine": "9", "ten": "10", + "unter": "decko", "ober": "dama", "king": "kralj", "ace": "as", +} + +# Lossless for the original scans; near-lossless lossy for the 2x set keeps the APK reasonable (~4x the pixels). +LOSSLESS_QUALITY = dict(lossless=True, method=6) +LARGE_QUALITY = dict(quality=96, method=6) + + +def save(src: Path, name: str, options: dict) -> None: + with Image.open(src) as image: + image.save(TARGET / name, "WEBP", **options) + print(f"{name:24} {image.size[0]}x{image.size[1]} {(TARGET / name).stat().st_size // 1024} KB") + + +def main() -> None: + large = SOURCE / "cards-large" + double = SOURCE / "cards-2x" + icons = SOURCE / "suit-icons" + names = [f"{s}-{r}" for s in SUITS for r in RANKS] + missing = [f"{n}.png" for n in names if not (large / f"{n}.png").exists()] + if missing: + sys.exit("Missing: " + ", ".join(missing)) + use_double = all((double / f"{n}.webp").exists() for n in names) + print("Card faces from", "cards-2x (726 px)" if use_double else "cards-large (363 px)") + TARGET.mkdir(parents=True, exist_ok=True) + for their_suit, suit in SUITS.items(): + for their_rank, rank in RANKS.items(): + name = f"{their_suit}-{their_rank}" + if use_double: + save(double / f"{name}.webp", f"card_{suit}_{rank}.webp", LARGE_QUALITY) + else: + save(large / f"{name}.png", f"card_{suit}_{rank}.webp", LOSSLESS_QUALITY) + save(icons / f"{their_suit}-icon@large.png", f"suit_{suit}.webp", LOSSLESS_QUALITY) + + +if __name__ == "__main__": + main() diff --git a/tools/make_icon.py b/tools/make_icon.py new file mode 100644 index 0000000..5f2f9d5 --- /dev/null +++ b/tools/make_icon.py @@ -0,0 +1,91 @@ +""" +Turn icon.png (square artwork, full bleed) into the Android launcher icon and the in-app logo. + + python tools/make_icon.py + +Android adaptive icons are 108 dp layers that the launcher masks to a circle, squircle or rounded square, +showing only about the middle 72 dp. Placed full size, the artwork would lose the "B" and the card corners. +So the artwork is scaled to fit the mask, and the space around it is filled with a blurred, enlarged copy of +plain felt in the artwork's edge colour, blended in with soft edges so no square seam shows. + +Writes: + app/src/main/res/mipmap-/ic_launcher_foreground.webp (adaptive icon, all densities) + app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml (adaptive icon definition) + app/src/main/res/values/ic_launcher_background.xml (colour behind the layer) + app/src/main/res/drawable-nodpi/logo.webp (the artwork for the home screen) +""" + +from pathlib import Path + +from PIL import Image, ImageFilter + +ROOT = Path(__file__).resolve().parent.parent +SOURCE = ROOT / "icon.png" +RES = ROOT / "app" / "src" / "main" / "res" + +DENSITIES = {"mdpi": 1.0, "hdpi": 1.5, "xhdpi": 2.0, "xxhdpi": 3.0, "xxxhdpi": 4.0} +LAYER_DP = 108 +ART_DP = 68 # artwork size inside the 108 dp layer; its content then stays inside a 72 dp circle +FEATHER = 0.03 # fraction of the artwork, at its edges, faded into the surround +LOGO_PX = 900 + + +def edge_colour(art: Image.Image) -> tuple: + """Average colour of the artwork's outer border: the felt the surround has to continue.""" + w, h = art.size + band = max(2, w // 60) + strips = [art.crop((0, 0, w, band)), art.crop((0, h - band, w, h)), art.crop((0, 0, band, h)), art.crop((w - band, 0, w, h))] + means = [strip.resize((1, 1), Image.BOX).getpixel((0, 0)) for strip in strips] + return tuple(sum(m[i] for m in means) // len(means) for i in range(3)) + + +def adaptive_layer(art: Image.Image, size: int) -> Image.Image: + # Surround: plain felt in the artwork's edge colour, a little darker towards the corners. + edge = edge_colour(art) + dark = tuple(int(c * 0.6) for c in edge) + gradient = Image.radial_gradient("L").resize((size, size), Image.BICUBIC) # black centre -> white rim + surround = Image.composite(Image.new("RGB", (size, size), dark), Image.new("RGB", (size, size), edge), gradient) + art_px = round(size * ART_DP / LAYER_DP) + sharp = art.resize((art_px, art_px), Image.LANCZOS) + # Alpha: opaque in the middle, fading out over the outer FEATHER of each side so no square edge shows. + fade = max(1, round(art_px * FEATHER)) + mask = Image.new("L", (art_px, art_px), 0) + mask.paste(Image.new("L", (art_px - 2 * fade, art_px - 2 * fade), 255), (fade, fade)) + mask = mask.filter(ImageFilter.GaussianBlur(fade / 2)) + offset = (size - art_px) // 2 + surround.paste(sharp, (offset, offset), mask) + return surround + + +def main() -> None: + art = Image.open(SOURCE).convert("RGB") + for name, scale in DENSITIES.items(): + size = round(LAYER_DP * scale) + folder = RES / f"mipmap-{name}" + folder.mkdir(parents=True, exist_ok=True) + adaptive_layer(art, size).save(folder / "ic_launcher_foreground.webp", "WEBP", quality=95, method=6) + print(f"mipmap-{name}/ic_launcher_foreground.webp {size}px") + + (RES / "mipmap-anydpi-v26").mkdir(parents=True, exist_ok=True) + (RES / "mipmap-anydpi-v26" / "ic_launcher.xml").write_text( + '\n' + "\n" + '\n' + ' \n' + ' \n' + "\n", + encoding="utf-8", + ) + edge = art.getpixel((0, 0)) # the dark felt at the artwork's edge + (RES / "values" / "ic_launcher_background.xml").write_text( + '\n\n' + f' #{edge[0]:02X}{edge[1]:02X}{edge[2]:02X}\n' + "\n", + encoding="utf-8", + ) + art.resize((LOGO_PX, LOGO_PX), Image.LANCZOS).save(RES / "drawable-nodpi" / "logo.webp", "WEBP", quality=92, method=6) + print("drawable-nodpi/logo.webp", LOGO_PX, "px") + + +if __name__ == "__main__": + main() diff --git a/tools/render_cards.py b/tools/render_cards.py new file mode 100644 index 0000000..db4bc6e --- /dev/null +++ b/tools/render_cards.py @@ -0,0 +1,80 @@ +""" +Render the SVG cards in card_assets/ to WebP drawables for the Android app. + + python tools/render_cards.py + +Writes, into app/src/main/res/drawable-nodpi/: + card__.webp one per SVG card (e.g. card_srce_as.webp) + suit_.webp the suit symbol on its own, cut from the suit's 7 card + +Needs Inkscape 1.x (default install path, or set INKSCAPE) and Pillow. Run it again whenever the SVGs change. +""" + +import os +import re +import shutil +import subprocess +import sys +import tempfile +from pathlib import Path + +from PIL import Image + +ROOT = Path(__file__).resolve().parent.parent +SOURCE = ROOT / "card_assets" +TARGET = ROOT / "app" / "src" / "main" / "res" / "drawable-nodpi" +INKSCAPE = os.environ.get("INKSCAPE", r"C:\Program Files\Inkscape\bin\inkscape.com") + +CARD_WIDTH = 720 # px; largest on-screen card ~200 dp (~700 px at xxxhdpi). Keep in sync with SOURCE_WIDTH in CardArt.kt +ICON_SIZE = 128 # px; suit icons are shown at ~20-30 dp +SUITS = ["srce", "zvono", "list", "zir"] +RANKS = ["7", "8", "9", "10", "decko", "dama", "kralj", "as"] +WEBP_QUALITY = 95 + + +def suit_icon_svg(card_svg: str, suit: str) -> str: + """A 55 x 55 SVG holding only the suit symbol defined in a card's .""" + match = re.search(r'(.*?)\s*' % suit, card_svg, re.S) + if not match: + sys.exit(f"No simbol_{suit} group found") + return ( + '' + f"{match.group(1)}" + ) + + +def main() -> None: + missing = [f"{s}_{r}.svg" for s in SUITS for r in RANKS if not (SOURCE / f"{s}_{r}.svg").exists()] + if missing: + sys.exit("Missing cards: " + ", ".join(missing)) + if not Path(INKSCAPE).exists(): + sys.exit(f"Inkscape not found at {INKSCAPE}; set INKSCAPE") + + TARGET.mkdir(parents=True, exist_ok=True) + with tempfile.TemporaryDirectory() as tmp: + tmp = Path(tmp) + jobs = [] # (svg path, png path, width, height, final webp name) + for suit in SUITS: + for rank in RANKS: + jobs.append((SOURCE / f"{suit}_{rank}.svg", tmp / f"card_{suit}_{rank}.png", CARD_WIDTH, None, f"card_{suit}_{rank}.webp")) + icon_svg = tmp / f"suit_{suit}.svg" + icon_svg.write_text(suit_icon_svg((SOURCE / f"{suit}_7.svg").read_text(encoding="utf-8"), suit), encoding="utf-8") + jobs.append((icon_svg, tmp / f"suit_{suit}.png", ICON_SIZE, ICON_SIZE, f"suit_{suit}.webp")) + + # One Inkscape process for everything: much faster than one launch per file. + actions = [] + for svg, png, width, height, _ in jobs: + actions += [f"file-open:{svg}", f"export-filename:{png}", f"export-width:{width}"] + if height: + actions.append(f"export-height:{height}") + actions += ["export-do", "file-close"] + subprocess.run([INKSCAPE, "--actions=" + ";".join(actions)], check=True) + + for _, png, _, _, name in jobs: + with Image.open(png) as image: + image.save(TARGET / name, "WEBP", quality=WEBP_QUALITY, method=6) + print(f"{name} {(TARGET / name).stat().st_size // 1024} KB") + + +if __name__ == "__main__": + main() diff --git a/tools/upscale_png_cards.py b/tools/upscale_png_cards.py new file mode 100644 index 0000000..28c6a9e --- /dev/null +++ b/tools/upscale_png_cards.py @@ -0,0 +1,52 @@ +""" +Make 2x versions of the PNG deck with EDSR super-resolution, so cards can be shown larger than 363 px +without looking stretched. + + python tools/upscale_png_cards.py + +Needs opencv-contrib-python(-headless), numpy and Pillow, and the EDSR x2 model from +https://github.com/Saafke/EDSR_Tensorflow/tree/master/models. Takes about 40 s per card on a CPU. + +Reads card_assets/hungarian-playing-cards/cards-large/-.png (363 x 585) +Writes card_assets/hungarian-playing-cards/cards-2x/-.webp (726 x 1170, lossless) +Colour goes through EDSR; the alpha channel (the rounded corners) is enlarged with Lanczos. +Then run tools/import_png_cards.py, which prefers cards-2x when it exists. +""" + +import sys +from pathlib import Path + +import cv2 +import numpy as np +from PIL import Image + +ROOT = Path(__file__).resolve().parent.parent +DECK = ROOT / "card_assets" / "hungarian-playing-cards" + + +def main() -> None: + if len(sys.argv) != 2: + sys.exit(__doc__) + sr = cv2.dnn_superres.DnnSuperResImpl_create() + sr.readModel(sys.argv[1]) + sr.setModel("edsr", 2) + out_dir = DECK / "cards-2x" + out_dir.mkdir(exist_ok=True) + sources = sorted(p for p in (DECK / "cards-large").glob("*.png") if p.stem != "back") + for i, src in enumerate(sources, 1): + target = out_dir / f"{src.stem}.webp" + if target.exists(): + print(f"[{i}/{len(sources)}] {target.name} exists, skipped", flush=True) + continue + rgba = np.array(Image.open(src).convert("RGBA")) + colour = sr.upsample(cv2.cvtColor(rgba[:, :, :3], cv2.COLOR_RGB2BGR)) + h, w = colour.shape[:2] + alpha = Image.fromarray(rgba[:, :, 3]).resize((w, h), Image.LANCZOS) + image = Image.fromarray(cv2.cvtColor(colour, cv2.COLOR_BGR2RGB)).convert("RGBA") + image.putalpha(alpha) + image.save(target, "WEBP", lossless=True, method=6) + print(f"[{i}/{len(sources)}] {target.name} {w}x{h}", flush=True) + + +if __name__ == "__main__": + main()