Skip to content

Commit 0c9ee67

Browse files
committed
download FMOD html5 files
1 parent ab1d473 commit 0c9ee67

File tree

3 files changed

+18
-6
lines changed

3 files changed

+18
-6
lines changed

.github/actions/create-native-build/action.yaml

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -61,14 +61,22 @@ runs:
6161
mkdir fmod && cd fmod
6262
PLATFORM_FOR_FMOD=${{ inputs.platform }}
6363
if [ "$PLATFORM_FOR_FMOD" = "web" ]; then
64-
PLATFORM_FOR_FMOD="linux"
64+
PLATFORM_FOR_FMOD="html5"
6565
fi
6666
python ../../fmod-gdextension/get_fmod.py ${{inputs.fmod-user}} ${{inputs.fmod-password}} $PLATFORM_FOR_FMOD ${{env.FMOD_VERSION}}
67-
tar -xvf fmodstudioapi${{env.FMOD_VERSION}}${{inputs.fmod-executable-suffix}}
67+
if [ "$PLATFORM_FOR_FMOD" = "html5" ]; then
68+
unzip fmodstudioapi${{env.FMOD_VERSION}}${{inputs.fmod-executable-suffix}}
69+
else
70+
tar -xvf fmodstudioapi${{env.FMOD_VERSION}}${{inputs.fmod-executable-suffix}}
71+
fi
72+
FMOD_EXTRACT_DIR=$(find . -maxdepth 3 -type d -name "fmodstudioapi${{env.FMOD_VERSION}}${PLATFORM_FOR_FMOD}" | head -n 1)
73+
if [ -z "$FMOD_EXTRACT_DIR" ]; then
74+
echo "FMOD archive directory not found" && exit 1
75+
fi
6876
if [ "${{ inputs.platform }}" = "web" ]; then
69-
mv fmodstudioapi${{env.FMOD_VERSION}}${PLATFORM_FOR_FMOD}/api .
77+
mv "$FMOD_EXTRACT_DIR/api" .
7078
else
71-
mv fmodstudioapi${{env.FMOD_VERSION}}${PLATFORM_FOR_FMOD}/api ${{inputs.platform}}
79+
mv "$FMOD_EXTRACT_DIR/api" ${{inputs.platform}}
7280
fi
7381
cd ../../
7482

.github/workflows/check_pr.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -156,14 +156,14 @@ jobs:
156156
os: "ubuntu-22.04"
157157
platform: web
158158
target: template_debug
159-
fmod-executable-suffix: linux.tar.gz
159+
fmod-executable-suffix: html5.zip
160160
shell: bash
161161

162162
- name: Web Release Compilation
163163
os: "ubuntu-22.04"
164164
platform: web
165165
target: template_release
166-
fmod-executable-suffix: linux.tar.gz
166+
fmod-executable-suffix: html5.zip
167167
shell: bash
168168

169169
steps:

get_fmod.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,10 @@
3030
# iOS...
3131
filename = f'fmodstudioapi{fmod_version}ios.dmg'
3232
downloadlink = f'https://www.fmod.com/api-get-download-link?path=files/fmodstudio/api/iOS/&filename=fmodstudioapi{fmod_version}ios-installer.dmg&user=$1'
33+
elif platform == 'html5':
34+
# HTML5
35+
filename = f'fmodstudioapi{fmod_version}html5.zip'
36+
downloadlink = f'https://www.fmod.com/api-get-download-link?path=files/fmodstudio/api/HTML5/&filename=fmodstudioapi{fmod_version}html5.zip&user='
3337

3438
downloadlink += user
3539

0 commit comments

Comments
 (0)