Skip to content

Commit

Permalink
feat: Added asset file installation system. added rooms goal. improve…
Browse files Browse the repository at this point in the history
…d UI and menu system.
  • Loading branch information
Peter Couture committed Jan 16, 2024
1 parent b66a1ba commit 118bcb1
Show file tree
Hide file tree
Showing 63 changed files with 3,406 additions and 744 deletions.
29 changes: 16 additions & 13 deletions .env
Original file line number Diff line number Diff line change
@@ -1,21 +1,24 @@
# ENV File for Inworld AI Wed SDK | Three.js - Innequin React Project
# The Inworld Character ID can be found on Inworld Studio
REACT_APP_INWORLD_CHARACTER_ID=workspaces/innequin_dev/characters/innequin
# The Default Inworld Character ID can be found on Inworld Studio
# This is the default id used if one hasn't been set directly on a character.
REACT_APP_INWORLD_CHARACTER_ID=workspaces/inworld-playground/characters/innequin
# The Inworld Scene ID can be found on Inworld Studio
REACT_APP_INWORLD_SCENE_ID=workspaces/innequin_dev/scenes/innequin
REACT_APP_INWORLD_SCENE_ID=workspaces/inworld-playground/scenes/inworld_playground
# The URI to the generate token server.
REACT_APP_INWORLD_GENERATE_TOKEN_URI=http://localhost:4000/
# Innequin Base Asset File Location. It can be a local or external path.
# Used as the prefix uri for the animation, texture and model file paths et in config.json.
# Innequin base asset file location. It can be a local or external path.
# Used as the prefix uri for the animation, texture and model file paths are set in config.json.
# Download asset files at=https://storage.googleapis.com/innequin-assets/v5/assets.zip
REACT_APP_INNEQUIN_BASE_URI=/assets/innequin
REACT_APP_INNEQUIN_BASE_URI=/assets/v1.0/innequin
# The path to the Innequin configuration
REACT_APP_INNEQUIN_CONFIG_URI=/assets/innequin/config.json
# Ready Player Me Base Asset File Location. It can be a local or external path.
# Used as the prefix uri for the animation, texture and model file paths et in config.json.
# Download asset files at=https://storage.googleapis.com/innequin-assets/v5/assets.zip
REACT_APP_RPM_BASE_URI=/assets/rpm
REACT_APP_INNEQUIN_CONFIG_URI=/assets/v1.0/innequin/config.json
# Ready Player Me base asset file location. It can be a local or external path.
# Used as the prefix uri for the animation, texture and model file paths are set in config.json.
# Download asset files at=https://storage.googleapis.com/rpm/v1/rpm-assets-v1.zip
REACT_APP_RPM_BASE_URI=/assets/v1.0/rpm
# The path to the Ready Player Me configuration
REACT_APP_RPM_CONFIG_URI=/assets/rpm/config.json
REACT_APP_RPM_CONFIG_URI=/assets/v1.0/rpm/config.json
# Draco Compression Library URI
REACT_APP_DRACO_COMPRESSION_URI=/draco-gltf/
REACT_APP_DRACO_COMPRESSION_URI=/draco-gltf/
# If debug logging is outputted
REACT_APP_DEBUG=false
6 changes: 6 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
node_modules
dist
docs
postman
public
src/asset-library-installer.js
17 changes: 17 additions & 0 deletions .eslintrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
{
"root": true,
"parser": "@typescript-eslint/parser",
"plugins": [
"@typescript-eslint"
],
"extends": [
"eslint:recommended",
"plugin:@typescript-eslint/eslint-recommended",
"plugin:@typescript-eslint/recommended"
],
"rules": {
"no-inner-declarations": 1,
"@typescript-eslint/no-empty-function": 1,
"@typescript-eslint/no-this-alias": 1
}
}
50 changes: 50 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
name: Bug Report
description: Create a report to help us improve
title: "[Bug]: "
labels: ["bug"]
body:
- type: markdown
attributes:
value: |
Thanks for taking the time to fill out this bug report!
- type: dropdown
id: package
attributes:
label: What Inworld.ai Web SDK package are you using?
options:
- "@inworld/web-core"
default: "@inworld/web-core"
validations:
required: true
- type: input
id: version
attributes:
label: Version
description: What version of package are you running?
validations:
required: true
- type: textarea
id: what-happened
attributes:
label: What happened?
description: Also tell us, what did you expect to happen?
placeholder: Tell us what you see!
value: "## Steps to reproduce the problem\n1. \n2. \n3. \n\n## What happened?\n\n## What did you expect to happen?\n\n## Anything else we should know?\n\n"
validations:
required: true
- type: dropdown
id: browsers
attributes:
label: What browsers are you seeing the problem on?
multiple: true
options:
- Firefox
- Chrome
- Safari
- Microsoft Edge
- type: textarea
id: logs
attributes:
label: Relevant log output
description: Please copy and paste any relevant log output. This will be automatically formatted into code, so no need for backticks.
render: shell
26 changes: 26 additions & 0 deletions .github/ISSUE_TEMPLATE/feature_request.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Feature Request
description: Suggest an idea for this project
title: "[Feature]: "
labels: ["enhancement"]
body:
- type: textarea
id: description
attributes:
label: Description
description: Please describe the feature you would like to see added.
validations:
required: true
- type: textarea
id: solution
attributes:
label: Solution
description: Please describe the solution you'd like to see.
validations:
required: false
- type: textarea
id: context
attributes:
label: Additional context
description: Please describe any additional context or screenshots about the feature request here.
validations:
required: false
21 changes: 21 additions & 0 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
## Description

<!--- Describe your changes in detail -->

## Related Issue (for external contributions)
<!--- This project only accepts pull requests related to open issues -->
<!--- If suggesting a new feature or change, please discuss it in an issue first -->
<!--- If fixing a bug, there should be an issue describing it with steps to reproduce -->
<!--- Please link to the issue here: -->

## Related Ticket (for Inworld.ai developers)

<!--- Please link to the ticket here: -->

## Screenshots (if appropriate)

## Checklist before requesting a review

- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my code
- [ ] I have made corresponding changes to the documentation
24 changes: 24 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: Build

on:
pull_request:

jobs:
build-pr:
runs-on: ubuntu-latest
concurrency:
group: build-a-${{ github.ref }}
cancel-in-progress: true
steps:
- name: Checkout source code
uses: actions/checkout@v3
- name: Run Web Core build
uses: ./.github/actions/build_package
with:
package: '@inworld/web-core'
- name: Run Web Threejs build
uses: ./.github/actions/build_package
with:
package: '@inworld/web-threejs'
- name: Run tests
run: yarn test
95 changes: 95 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,95 @@
name: Release & Publish to NPM

on:
workflow_dispatch:
inputs:
increment:
type: choice
description: Select increment
options:
- patch
- minor
- major

package:
type: choice
description: Select package
options:
- '@inworld/web-core'
- '@inworld/web-threejs'

jobs:
github-release:
runs-on: ubuntu-latest
steps:
- name: Echo increment & package
run: echo "${{ inputs.increment }}" "${{ inputs.package }}"
- name: Set git user
run: git config --global user.email "[email protected]" && git config --global user.name "CI-inworld"
- name: Checkout source code
uses: actions/checkout@v3
with:
ref: main
ssh-key: ${{ secrets.GH_SERVICE_ACCOUNT_SSH_KEY }}
- name: Run build
uses: ./.github/actions/build_package
with:
package: ${{ inputs.package }}
- name: Bump version
run: |
yarn workspace ${{ inputs.package }} release:bump ${{ inputs.increment }} --ci
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

npm-release:
runs-on: ubuntu-latest
needs: [github-release]
steps:
- name: Checkout source code
uses: actions/checkout@v3
with:
ref: main
- name: Run build
uses: ./.github/actions/build_package
with:
package: ${{ inputs.package }}
- run: echo "//registry.npmjs.org/:_authToken=${{ secrets.NPM_TOKEN }}" > ~/.npmrc
- name: Publish to npm
run: yarn workspace ${{ inputs.package }} release:publish

release-notification:
runs-on: [self-hosted, kubernetes, nodocker]
needs: [github-release, npm-release]
# always runs even if previous tasks are not successful
if: always()
steps:
- name: Checkout source code
if: needs.npm-release.result == 'success'
uses: actions/checkout@v3
with:
ref: main
- name: Extract version
if: needs.npm-release.result == 'success'
run: |
echo "version=$(yarn workspace ${{ inputs.package }} get:version)" >> $GITHUB_OUTPUT
id: extract-version
- name: Extract changelog
if: needs.npm-release.result == 'success'
run: |
echo "changelog=yarn workspace ${{ inputs.package }} get:changelog" >> $GITHUB_OUTPUT
id: extract-changelog
- name: Extract release notes
if: needs.npm-release.result == 'success'
id: extract-release-notes
uses: ffurrer2/extract-release-notes@v1
with:
changelog_file: ${{ steps.extract-changelog.outputs.changelog }}
- name: Slack Notification
if: always()
uses: rtCamp/action-slack-notify@v2
env:
SLACK_WEBHOOK: ${{ secrets.INTEGRATIONS_SLACK_WEBHOOK }}
SLACK_COLOR: ${{ contains(needs.*.result, 'failure') && 'danger' || 'good' }}
SLACK_TITLE: Release ${{ contains(needs.*.result, 'failure') && 'failure' || steps.extract-version.outputs.version }}
SLACK_MESSAGE: ${{ contains(needs.*.result, 'failure') && ':x:' || steps.extract-release-notes.outputs.release_notes }}
SLACK_FOOTER: '-Web SDK-'
50 changes: 50 additions & 0 deletions .github/workflows/reviewdog.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
name: Review changes

on:
pull_request:
paths-ignore:
- '**/.gitignore'
- '**/*.md'
- '**/proto/**'

jobs:
eslint:
name: Eslint
runs-on: ubuntu-latest
steps:
- name: Checkout source code
uses: actions/checkout@v3
- name: Find changes
uses: dorny/paths-filter@v2
id: changes
with:
filters: |
changed:
- './**/*.{js,jsx,ts,tsx}'
- name: Run Web Core build
if: steps.changes.outputs.changed == 'true'
uses: ./.github/actions/build_package
with:
package: '@inworld/web-core'
- name: Run Web Threejs build
if: steps.changes.outputs.changed == 'true'
uses: ./.github/actions/build_package
with:
package: '@inworld/web-threejs'
- name: Review source code
if: steps.changes.outputs.changed == 'true'
uses: reviewdog/action-eslint@v1
with:
reporter: github-pr-review
workdir: ./
eslint_flags: '--cache ./**/*.{js,jsx,ts,tsx}'

linelint:
runs-on: ubuntu-latest
name: Check if all files end in newline
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Linelint
uses: fernandrone/linelint@master
id: linelint
Loading

0 comments on commit 118bcb1

Please sign in to comment.