Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .env
Original file line number Diff line number Diff line change
@@ -1 +1 @@
REACT_APP_SERVER_ADDRESS=ws://localhost:2567
VITE_SERVER_ADDRESS=ws://localhost:2567
4 changes: 2 additions & 2 deletions .github/workflows/run_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:

strategy:
matrix:
node-version: [19.x, 20.x]
node-version: [20.x, 22.x]

steps:
- uses: actions/checkout@v2
Expand All @@ -27,6 +27,6 @@ jobs:
- name: install dependencies
run: npm ci
- name: run tests
run: npm run test
run: npm run test run
- name: build
run: npm run build
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ You need [the server-side program](https://github.com/yncat/dfg-server) .

First, clone the server-side program. Run `npm ci` to install dependencies, then run `npm start` to start serving. It starts waiting for connections at `localhost:2567` .

Next, clone this repository, run `npm run ci` then `npm start` . It launches browser for the first time. While the development server is running, the game can be accessed by requesting to `localhost:3000` .
Next, clone this repository, run `npm run ci` then `npm start` . While the development server is running, the game can be accessed by requesting to `http://localhost:5173/softs/dfg/game/` .

The development server supports hot-reloading. When you make changes to the source, it will be automatically applied. When you have compilation errors, your browser window will display it for you.

Expand All @@ -25,13 +25,13 @@ Run `npm run build` to make an optimized production build. If you're trying to h
If you build the app with default setting, it will try to connect to localhost. In order to change endpoint for production, create `.env.production.local` inside the project root directory, and specify like this.

```
REACT_APP_SERVER_ADDRESS=wss://example.com
VITE_SERVER_ADDRESS=wss://example.com
```

If you want to specify port number,

```
REACT_APP_SERVER_ADDRESS=wss://example.com:portnum
VITE_SERVER_ADDRESS=wss://example.com:portnum
```

## Adding sounds
Expand Down
46 changes: 25 additions & 21 deletions index.html
Original file line number Diff line number Diff line change
@@ -1,21 +1,25 @@
<!DOCTYPE html>
<html lang="ja">
<head>
<meta charset="UTF-8" />
<link
rel="stylesheet"
href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css"
integrity="sha384-ggOyR0iXCbMQv3Xipma34MD+dH/1fQ784/j6cY/iJTQUOhcWr7x9JvoRxT2MZw1T"
crossorigin="anonymous"
/>
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>大富豪 (daifugo)</title>
</head>
<body>
<h1>大富豪!</h1>
<p><a href="game/">Play</a></p>
<p><a href="manual/japanese.html">Manual (日本語)</a></p>
<p><a href="../">Back</a></p>
</body>
</html>
<!DOCTYPE html>
<html lang="ja">
<head>
<meta charset="utf-8" />
<link rel="icon" href="/favicon.ico" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="theme-color" content="#000000" />
<meta
name="description"
content="オンライン大富豪ゲーム"
/>
<link rel="apple-touch-icon" href="/logo192.png" />
<!--
manifest.json provides metadata used when your web app is installed on a
user's mobile device or desktop. See https://developers.google.com/web/fundamentals/web-app-manifest/
-->
<link rel="manifest" href="/manifest.json" />
<title>大富豪</title>
</head>
<body>
<noscript>You need to enable JavaScript to run this app.</noscript>
<div id="root"></div>
<script type="module" src="/src/index.tsx"></script>
</body>
</html>
Loading