Skip to content

Commit f3adb15

Browse files
committed
Initial Schaetzorama game package
0 parents  commit f3adb15

16 files changed

Lines changed: 5700 additions & 0 deletions

.github/workflows/ci.yml

Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
name: CI
2+
3+
on:
4+
pull_request:
5+
push:
6+
branches: [main]
7+
8+
permissions:
9+
contents: read
10+
11+
jobs:
12+
verify:
13+
runs-on: ubuntu-latest
14+
steps:
15+
- name: Check out game
16+
uses: actions/checkout@v4
17+
with:
18+
path: game
19+
20+
- name: Check out platform packages
21+
uses: actions/checkout@v4
22+
with:
23+
repository: Hartwich/Open-Party-Lab
24+
path: platform
25+
26+
- uses: actions/setup-node@v4
27+
with:
28+
node-version: 20
29+
cache: npm
30+
cache-dependency-path: |
31+
game/package-lock.json
32+
platform/package-lock.json
33+
34+
- name: Install platform dependencies
35+
working-directory: platform
36+
run: npm ci
37+
38+
- name: Build platform packages
39+
working-directory: platform
40+
run: npm run build:packages
41+
42+
- name: Install game dependencies
43+
working-directory: game
44+
run: npm ci
45+
46+
- name: Link platform packages
47+
working-directory: game
48+
run: |
49+
mkdir -p node_modules/@open-party-lab
50+
for package in game-core protocol ui-kit utils; do
51+
ln -s "$GITHUB_WORKSPACE/platform/packages/$package" "node_modules/@open-party-lab/$package"
52+
done
53+
54+
- name: Run typecheck
55+
working-directory: game
56+
run: npm run typecheck
57+
58+
- name: Run build
59+
working-directory: game
60+
run: npm run build
61+
62+
- name: Dry-run npm package
63+
working-directory: game
64+
run: npm run pack:dry-run
65+

.gitignore

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
node_modules/
2+
dist/
3+
*.tsbuildinfo
4+
npm-debug.log*
5+

AGENTS.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# Schaetzorama Agent Guide
2+
3+
This repository contains one Open Party Lab game package. Keep it focused on Schaetzorama only.
4+
5+
Export only the public entrypoints declared in `package.json`. Do not import private files from the Party Platform apps.
6+
7+
Run at least:
8+
9+
```bash
10+
npm run typecheck
11+
npm run build
12+
```
13+

README.md

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
# Open Party Lab: Schaetzorama
2+
3+
Schaetzorama is an optional Open Party Lab game package. Players estimate numbers, sort rankings, assign terms, and use copy jokers before the reveal.
4+
5+
## Local Development
6+
7+
```bash
8+
npm install
9+
npm run typecheck
10+
npm run build
11+
```
12+
13+
For local Platform integration, run this in the Party Platform repo:
14+
15+
```bash
16+
cd ../..
17+
npm run games:sync-local
18+
npm run dev:all
19+
```
20+
21+
The Platform links only game repos that exist locally. If this repo is not present, Schaetzorama is skipped.
22+
23+
## Public Entrypoints
24+
25+
```text
26+
@open-party-lab/game-schaetzorama/manifest
27+
@open-party-lab/game-schaetzorama/protocol
28+
@open-party-lab/game-schaetzorama/server
29+
@open-party-lab/game-schaetzorama/host
30+
@open-party-lab/game-schaetzorama/controller
31+
```
32+

package-lock.json

Lines changed: 61 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
{
2+
"name": "@open-party-lab/game-schaetzorama",
3+
"version": "0.1.0",
4+
"private": false,
5+
"license": "Apache-2.0",
6+
"type": "module",
7+
"main": "./dist/index.js",
8+
"types": "./dist/index.d.ts",
9+
"exports": {
10+
".": {
11+
"types": "./dist/index.d.ts",
12+
"import": "./dist/index.js"
13+
},
14+
"./manifest": {
15+
"types": "./dist/manifest.d.ts",
16+
"import": "./dist/manifest.js"
17+
},
18+
"./protocol": {
19+
"types": "./dist/protocol.d.ts",
20+
"import": "./dist/protocol.js"
21+
},
22+
"./server": {
23+
"types": "./dist/server/index.d.ts",
24+
"import": "./dist/server/index.js"
25+
},
26+
"./host": {
27+
"types": "./dist/host/index.d.ts",
28+
"import": "./dist/host/index.js"
29+
},
30+
"./controller": {
31+
"types": "./dist/controller/index.d.ts",
32+
"import": "./dist/controller/index.js"
33+
}
34+
},
35+
"files": [
36+
"dist",
37+
"README.md",
38+
"AGENTS.md"
39+
],
40+
"scripts": {
41+
"build": "tsc -p tsconfig.json",
42+
"typecheck": "tsc -p tsconfig.json --noEmit",
43+
"dev": "npm run typecheck",
44+
"pack:dry-run": "npm pack --dry-run"
45+
},
46+
"peerDependencies": {
47+
"@open-party-lab/game-core": "0.1.0",
48+
"@open-party-lab/utils": "0.1.0",
49+
"phaser": "^3.90.0"
50+
},
51+
"peerDependenciesMeta": {
52+
"@open-party-lab/game-core": {
53+
"optional": true
54+
},
55+
"@open-party-lab/utils": {
56+
"optional": true
57+
}
58+
},
59+
"devDependencies": {
60+
"phaser": "^3.90.0",
61+
"typescript": "^5.7.3"
62+
}
63+
}

0 commit comments

Comments
 (0)