{"id":46349272,"url":"https://github.com/whywaita/ofc-app","last_synced_at":"2026-03-04T22:32:18.588Z","repository":{"id":314846454,"uuid":"1056134021","full_name":"whywaita/ofc-app","owner":"whywaita","description":"A cross‑platform implementation of Open Face Chinese Poker (Pineapple variant).","archived":false,"fork":false,"pushed_at":"2026-01-24T19:09:07.000Z","size":7196,"stargazers_count":0,"open_issues_count":1,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-01-25T07:47:40.740Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://whywaita.github.io/ofc-app/","language":"Dart","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/whywaita.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":"AGENTS.md","dco":null,"cla":null},"funding":{"github":["whywaita"]}},"created_at":"2025-09-13T13:09:02.000Z","updated_at":"2026-01-24T19:09:10.000Z","dependencies_parsed_at":"2025-09-15T07:24:28.568Z","dependency_job_id":null,"html_url":"https://github.com/whywaita/ofc-app","commit_stats":null,"previous_names":["whywaita/ofc-app"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/whywaita/ofc-app","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/whywaita%2Fofc-app","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/whywaita%2Fofc-app/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/whywaita%2Fofc-app/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/whywaita%2Fofc-app/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/whywaita","download_url":"https://codeload.github.com/whywaita/ofc-app/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/whywaita%2Fofc-app/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30096782,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-04T21:59:23.547Z","status":"ssl_error","status_checked_at":"2026-03-04T21:57:50.415Z","response_time":59,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2026-03-04T22:32:17.558Z","updated_at":"2026-03-04T22:32:18.432Z","avatar_url":"https://github.com/whywaita.png","language":"Dart","funding_links":["https://github.com/sponsors/whywaita"],"categories":[],"sub_categories":[],"readme":"# Open Face Chinese Poker (OFCP) — Flutter/Dart\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"app/assets/icon/icon-1024.png\" alt=\"ofc-app Logo\" width=\"200\"\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  A cross‑platform implementation of Open Face Chinese Poker (Pineapple variant) built with Flutter (app) and pure Dart (domain). \n\u003c/p\u003e\n\nThis repository contains the scoring rules, foul detection, Fantasy mode logic, and a minimal playable UI for:\n\n- Practice (single player)\n- Pass \u0026 Play (A/B hot‑seat)\n\nThe codebase emphasizes testable, pure‑Dart domain logic and a thin UI layer.\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"docs/assets/play-practice.gif\" alt=\"ofc-app Practice\"\u003e\n\u003c/p\u003e\n\n## Features\n- Domain\n  - Hand evaluation (5‑card, 3‑card), score engine, royalties, strict foul detection\n  - Pineapple flow (initial 5, then 3→place 2→auto‑discard 1)\n  - Fantasy mode (enter/continue rules; FOUL cancels Fantasy)\n- UI\n  - Drag \u0026 drop placement, tray return, vertical Top/Middle/Bottom layout\n  - Unitary primary button (Next 3 / Commit) + Sort (Fantasy only)\n  - Result screens with final boards, FOUL/OK, royalties breakdown, action log\n- Tooling \u0026 CI\n  - Makefile tasks for analyze/test/build/run\n  - GitHub Actions: Dart/Flutter analyze, test, bundle build (with pub cache)\n\n## Repository Layout\n```\n├─ lib/                       # Pure Dart domain logic\n│  ├─ core/models/            # Rank, Suit, PlayingCard, Deck\n│  └─ features/game/domain/   # hand_evaluator, ruleset, foul_checker,\n│                             # score_engine, fantasy_engine, pineapple_engine,\n│                             # cycle_logic, board, board_builder, game_state\n├─ app/                       # Flutter app (Android/iOS only)\n│  └─ lib/                    # main.dart, game_screen.dart, pass_play_screen.dart, result screens\n├─ docs/                      # rdd.md (requirements), todo.md (status)\n├─ test/                      # Domain unit tests\n├─ .github/workflows/ci.yml   # CI pipelines\n└─ Makefile                   # Developer tasks\n```\n\n## Requirements\n- Flutter stable (3.35+) and Dart (3.9+)\n- Android Studio (Android SDK) and/or Xcode (iOS) for device builds\n\n## Quick Start\n```\n# Run all checks\nmake ci\n\n# App (simulator/device)\nmake app-run DEVICE=\"iPhone 15\"   # or an Android device id\n\n# Lint / Test / Build\nmake analyze\nmake test\nmake build\n```\n\nOn iOS devices, enable automatic signing in Xcode:\n- open the workspace: `make app-ios-open`\n- Xcode → Signing \u0026 Capabilities → select your Team (Apple ID)\n\n## Usage Notes (Gameplay)\n- Practice: opens a single‑player board. Drag from the tray onto Top/Middle/Bottom. Next 3 becomes enabled after 2 placements (post‑initial), remaining one card auto‑discards.\n- Pass \u0026 Play: A gets 5 → B gets 5 → A Next 3 → B Next 3 (alternating). If one player is in Fantasy, three‑card deals are skipped for that player.\n- Result: shows both final boards, FOUL/OK, royalties, totals, and the intra‑hand action log.\n\n### Practice Seed Selection (Reproducible Training)\n- When you tap “Practice” on the home screen, a seed‑selection dialog appears before starting.\n  - “Random”: automatically generates an integer seed from the current time.\n  - “Specify”: enter any integer seed to make deals deterministic (same seed → same deck order).\n- `Seed: \u003cnumber\u003e` is shown at the top of the game screen and on the result screen. Share the seed to reproduce the same practice sequence on other devices.\n- The same seed is kept for the entire session. If you prefer per‑hand seed changes, consider adding a small in‑app toggle.\n\n## Testing\n- Domain tests (pure Dart): `dart test -r expanded`\n- App widget smoke tests: `cd app \u0026\u0026 flutter test -r expanded`\n\nDomain logic is kept deterministic; UI tests focus on smoke/critical flows.\n\n## CI\n- GitHub Actions runs on push/PR to `main`/`master`:\n  - Dart: `dart analyze`, `dart test`\n  - Flutter (app): `flutter analyze`, `flutter test`, `flutter build bundle`\n  - Pub cache is enabled to speed up builds\n\n## Contributing\n- Follow Conventional Commits (e.g., `feat(game): unify next3 button`)\n- Keep PRs small, with description, screenshots for UI, and green CI\n- See AGENTS.md for structure, style, and day‑to‑day commands\n\n## Security\n- Do not commit secrets. For iOS signing use Xcode’s automatic provisioning locally.\n- Please open a private issue or contact maintainers for sensitive reports.\n\n## Roadmap (short)\n- A/B result details (row‑by‑row table), pass\u0026play privacy blur\n- Golden/Property tests for hand compare regressions\n- App icons / splash, basic i18n (EN/JA)\n\n## License\nChoose and add a LICENSE file before publishing (MIT recommended). Update this section accordingly.\n\n## Acknowledgements\n- Flutter and Dart teams, and the OSS ecosystem\n- Playing‑card ranking conventions inspired by standard poker hand rules\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwhywaita%2Fofc-app","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwhywaita%2Fofc-app","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwhywaita%2Fofc-app/lists"}