Skip to content

Commit

Permalink
tidy
Browse files Browse the repository at this point in the history
  • Loading branch information
tailuge committed Dec 23, 2024
1 parent 1d7c6d8 commit 60fa277
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 12 deletions.
6 changes: 4 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,7 @@ Some of the Mathaven equations not supplied by the paper were inferred by LLMs a
### Install

```shell
nvm use v18.17.1
nvm use v22.12.0
yarn install
yarn dev
yarn gltfpack
Expand Down Expand Up @@ -225,7 +225,9 @@ yarn prettify
### Two player

```shell
yarn websocket
yarn websocket #(for local dev)
yarn build:server
yarn start:server
```

the client uses query parameter ``?websocketserver=wss://some-host`` to locate
Expand Down
3 changes: 0 additions & 3 deletions dist/Dockerfile

This file was deleted.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
"websocket": "nodemon ./src/network/server/server.ts",
"build:server": "webpack --config ./src/network/server/webpack.server.config.js",
"start:server": "node dist/server.js",
"dockerify": "docker build -f dist/Dockerfile -t tailuge/billiards-nginx .",
"dockerify": "docker buildx build --platform linux/amd64 -f ./src/network/server/Dockerfile -t tailuge/billiards-network .",
"gltfpack": "npx gltfpack -i dist/models/p8.gltf -o dist/models/p8.min.gltf && npx gltfpack -i dist/models/threecushion.gltf -o dist/models/threecushion.min.gltf && npx gltfpack -i dist/models/snooker.gltf -o dist/models/snooker.min.gltf && npx gltfpack -i dist/models/d-snooker.gltf -o dist/models/d-snooker.min.gltf"
},
"nodemonConfig": {
Expand Down
8 changes: 4 additions & 4 deletions src/diagram/throw_gpt4o.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@ import { I, m } from "../model/physics/constants";

export class CollisionThrow {

public static R: number = 0.029; // ball radius in meters
public static readonly R: number = 0.029; // ball radius in meters

// Friction parameters
private static a: number = 0.01; // Minimum friction coefficient
private static b: number = 0.108; // Range of friction variation
private static c: number = 1.088; // Decay rate
private static readonly a: number = 0.01; // Minimum friction coefficient
private static readonly b: number = 0.108; // Range of friction variation
private static readonly c: number = 1.088; // Decay rate

private log;
constructor(log: (...args: any[]) => void = () => { }) {
Expand Down
4 changes: 2 additions & 2 deletions src/network/server/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ FROM node:22-alpine
WORKDIR /app

# Create a non-root user
RUN addgroup -S appgroup && adduser -S appuser -G appgroup
USER appuser
#RUN addgroup -S appgroup && adduser -S appuser -G appgroup
#USER appuser

# Copy the entire repository into the container
COPY . .
Expand Down

0 comments on commit 60fa277

Please sign in to comment.