Skip to content

Commit

Permalink
updated examples
Browse files Browse the repository at this point in the history
  • Loading branch information
AndyGura committed Aug 16, 2024
1 parent d5b9b70 commit 93c045a
Show file tree
Hide file tree
Showing 8 changed files with 4,889 additions and 2,566 deletions.
13 changes: 11 additions & 2 deletions examples/build_examples.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,23 @@ examples=(
)
build_example() {
pushd ./$1
# npm i
rm -rf node_modules && rm -f package-lock.json && rm -rf dist
npm i
# sh ../../etc/switch_example_to_local_gg.sh .
npm run build
# npm run start
popd
}

pids=()
for ix in ${!examples[*]}
do
build_example ${examples[$ix]} &
pids+=($!)
done
for pid in "${pids[@]}"; do
if ! wait $pid; then
echo "Error: A background process failed."
exit 1
fi
done
wait
2,622 changes: 1,772 additions & 850 deletions examples/framework-angular-three-ammo/package-lock.json

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions examples/framework-angular-three-ammo/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@
"@angular/platform-browser": "^15.1.2",
"@angular/platform-browser-dynamic": "^15.1.2",
"@angular/router": "^15.1.2",
"@gg-web-engine/ammo": "0.0.40",
"@gg-web-engine/core": "0.0.40",
"@gg-web-engine/three": "0.0.40",
"@gg-web-engine/ammo": "0.0.48",
"@gg-web-engine/core": "0.0.48",
"@gg-web-engine/three": "0.0.48",
"mini-signals": "2.0.0",
"rxjs": "7.8.1",
"three": "0.167.1",
Expand Down
2 changes: 1 addition & 1 deletion examples/framework-angular-three-ammo/src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ export class App implements OnInit, OnDestroy {
});
this.world.addEntity(destroyTrigger);

const spawnTimer = world.createClock(true);
const spawnTimer = this.world.createClock(true);
spawnTimer.tickRateLimit = 2;
spawnTimer.tick$
.subscribe(() => {
Expand Down
4,801 changes: 3,097 additions & 1,704 deletions examples/framework-react-three-rapier3d/package-lock.json

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions examples/framework-react-three-rapier3d/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@
"private": true,
"dependencies": {
"@dimforge/rapier3d-compat": "0.0.0-50223ff-20240729",
"@gg-web-engine/core": "0.0.40",
"@gg-web-engine/rapier3d": "0.0.40",
"@gg-web-engine/three": "0.0.40",
"@gg-web-engine/core": "0.0.48",
"@gg-web-engine/rapier3d": "0.0.48",
"@gg-web-engine/three": "0.0.48",
"@types/node": "^16.18.65",
"@types/react": "^18.2.38",
"@types/react-dom": "^18.2.17",
Expand Down
1 change: 0 additions & 1 deletion examples/framework-react-three-rapier3d/src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ import {
ThreeCameraComponent,
} from '@gg-web-engine/three';
import { Subject } from 'rxjs';
import { takeUntil } from 'rxjs/operators';
import { Rapier3dWorldComponent } from '@gg-web-engine/rapier3d';
import { PerspectiveCamera } from 'three';

Expand Down
4 changes: 2 additions & 2 deletions examples/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -245,8 +245,8 @@
const name = `${ex.label.toLowerCase().replace(/\s/g, '-')}-${ex.visualModule}-${ex.physicsModule}`;
// const sbBranchSuffix = 'tree/new-examples/';
// const sbBranchSuffix = 'tree/main/';
// const sbBranchSuffix = 'tree/0.0.40/';
const sbBranchSuffix = 'tree/4d36b3398a502a694a0e9dbb1fcfaa65264bc4bb/';
const sbBranchSuffix = 'tree/0.0.48/';
// const sbBranchSuffix = 'tree/4d36b3398a502a694a0e9dbb1fcfaa65264bc4bb/';
return {
...ex,
url: `https://gg-web-demos.guraklgames.com/${name}/index.html`,
Expand Down

0 comments on commit 93c045a

Please sign in to comment.