fix: dead enemy won't collide with bullets and will stay on scene #106
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build Unity project | |
on: | |
push: | |
branches: [ main ] | |
workflow_dispatch: | |
jobs: | |
build: | |
name: Build WebGL & Deploy to GitHub Pages | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
with: | |
lfs: true | |
- uses: actions/cache@v3 | |
with: | |
path: Library | |
key: Library-${{ hashFiles('Assets/**', 'Packages/**', 'ProjectSettings/**') }} | |
restore-keys: | | |
Library- | |
# - name: Run tests | |
# uses: game-ci/unity-test-runner@v4 | |
# env: | |
# UNITY_LICENSE: ${{ secrets.UNITY_LICENSE }} | |
# UNITY_EMAIL: ${{ secrets.UNITY_EMAIL }} | |
# UNITY_PASSWORD: ${{ secrets.UNITY_PASSWORD }} | |
# with: | |
# githubToken: ${{ secrets.GITHUB_TOKEN }} | |
- name: Replace key | |
run: | | |
echo ${{ secrets.KEY }} > key.txt | |
sed -i "s/906dafba3cc72263ffb443d8c15fdd73f96d3917aa6ed549454a8f79fe590b35/$(cat key.txt)/g" Assets/Scripts/SpeedrunManager.cs | |
rm key.txt | |
- name: Build project | |
uses: game-ci/unity-builder@v4 | |
env: | |
UNITY_LICENSE: ${{ secrets.UNITY_LICENSE }} | |
UNITY_EMAIL: ${{ secrets.UNITY_EMAIL }} | |
UNITY_PASSWORD: ${{ secrets.UNITY_PASSWORD }} | |
with: | |
targetPlatform: WebGL | |
allowDirtyBuild: true | |
- uses: actions/upload-artifact@v3 | |
with: | |
name: Build | |
path: build/WebGL/WebGL | |
deploy: | |
runs-on: ubuntu-latest | |
needs: build | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
- name: Download build artifact | |
uses: actions/download-artifact@v2 | |
with: | |
name: Build | |
path: build | |
- name: Deploy to GitHub Pages | |
uses: peaceiris/actions-gh-pages@v3 | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
publish_dir: ./build | |
publish_branch: gh-pages | |
destination_dir: suicide-main |