From a7aafa9e3e4f0b381a0236795a2140219f4c012d Mon Sep 17 00:00:00 2001 From: Cameron Taylor Date: Thu, 15 Jun 2023 14:09:19 -0400 Subject: [PATCH 1/3] .haxelib caching --- .github/actions/setup-haxeshit/action.yml | 2 +- .github/workflows/build-shit.yml | 44 +++-------------------- 2 files changed, 6 insertions(+), 40 deletions(-) diff --git a/.github/actions/setup-haxeshit/action.yml b/.github/actions/setup-haxeshit/action.yml index 21fab6fb2..2a8986c1f 100644 --- a/.github/actions/setup-haxeshit/action.yml +++ b/.github/actions/setup-haxeshit/action.yml @@ -16,5 +16,5 @@ runs: haxelib git haxelib https://github.com/HaxeFoundation/haxelib.git haxelib version haxelib --global install hmm - haxelib --global run hmm install --quiet + haxelib --global run hmm install shell: bash diff --git a/.github/workflows/build-shit.yml b/.github/workflows/build-shit.yml index 7115f2f6d..6c6a73c40 100644 --- a/.github/workflows/build-shit.yml +++ b/.github/workflows/build-shit.yml @@ -2,7 +2,7 @@ name: build-upload on: workflow_dispatch: push: - + jobs: check_date: runs-on: ubuntu-latest @@ -44,18 +44,14 @@ jobs: actions: write steps: - uses: actions/checkout@v3 - - name: Restore existing build cache for faster compilation - uses: actions/cache/restore@v3 - id: cache-windows-shit + - name: Restore/create existing haxelib cache for faster downloads + uses: actions/cache@v3 + id: cache-haxelib-windows with: # wha? - key: cache-build-win + key: cache-haxelib-windows-${{ hashFiles('**/hmm.json')}} path: | .haxelib/ - export/debug/windows/haxe/ - export/debug/windows/obj/ - restore-keys: | - cache-build-windows - uses: ./.github/actions/setup-haxeshit - name: Build game run: | @@ -66,33 +62,3 @@ jobs: butler-key: ${{ secrets.BUTLER_API_KEY}} build-dir: export/debug/windows/bin target: win - - name: Clearing already existing cache - uses: actions/github-script@v6 - with: - script: | - const caches = await github.rest.actions.getActionsCacheList({ - owner: context.repo.owner, - repo: context.repo.repo, - }) - for (const cache of caches.data.actions_caches) { - if (cache.key == "cache-build-windows") { - console.log('Clearing ' + cache.key + '...') - await github.rest.actions.deleteActionsCacheById({ - owner: context.repo.owner, - repo: context.repo.repo, - cache_id: cache.id, - }) - console.log("Cache cleared.") - } - } - - name: Uploading new cache - uses: actions/cache/save@v3 - with: - # caching again since for some reason it doesnt work with the first post cache shit - key: cache-build-windows - path: | - .haxelib/ - export/debug/windows/haxe/ - export/debug/windows/obj/ - restore-keys: | - cache-build-windows From 0b42b6e3053f4f8c7d045f17537ab2bd904bf0ac Mon Sep 17 00:00:00 2001 From: Cameron Taylor Date: Thu, 15 Jun 2023 14:12:39 -0400 Subject: [PATCH 2/3] moved caching so html5 can also cache haxelibs --- .github/actions/setup-haxeshit/action.yml | 8 ++++++++ .github/workflows/build-shit.yml | 8 -------- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/.github/actions/setup-haxeshit/action.yml b/.github/actions/setup-haxeshit/action.yml index 2a8986c1f..bf81e0d6d 100644 --- a/.github/actions/setup-haxeshit/action.yml +++ b/.github/actions/setup-haxeshit/action.yml @@ -10,6 +10,14 @@ runs: run: | haxelib config shell: bash + - name: Restore/create existing haxelib cache for faster downloads + uses: actions/cache@v3 + id: cache-haxelib-windows + with: + # wha? + key: cache-haxelib-${{ runner.os }}-${{ hashFiles('**/hmm.json')}} + path: | + .haxelib/ - name: Installing Haxe lol run: | haxe -version diff --git a/.github/workflows/build-shit.yml b/.github/workflows/build-shit.yml index 6c6a73c40..35d436b2c 100644 --- a/.github/workflows/build-shit.yml +++ b/.github/workflows/build-shit.yml @@ -44,14 +44,6 @@ jobs: actions: write steps: - uses: actions/checkout@v3 - - name: Restore/create existing haxelib cache for faster downloads - uses: actions/cache@v3 - id: cache-haxelib-windows - with: - # wha? - key: cache-haxelib-windows-${{ hashFiles('**/hmm.json')}} - path: | - .haxelib/ - uses: ./.github/actions/setup-haxeshit - name: Build game run: | From 092dcb5a35aab4074cd4a0fe1019c34f3525d25e Mon Sep 17 00:00:00 2001 From: Cameron Taylor Date: Thu, 15 Jun 2023 14:31:49 -0400 Subject: [PATCH 3/3] counter fix thing --- source/funkin/play/GameOverSubState.hx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source/funkin/play/GameOverSubState.hx b/source/funkin/play/GameOverSubState.hx index 1b79d024b..7c39cef56 100644 --- a/source/funkin/play/GameOverSubState.hx +++ b/source/funkin/play/GameOverSubState.hx @@ -170,8 +170,8 @@ class GameOverSubState extends MusicBeatSubState if (controls.BACK) { blueballed = false; - PlayState.deathCounter = 0; - PlayState.seenCutscene = false; + PlayState.instance.deathCounter = 0; + // PlayState.seenCutscene = false; // old thing... gameOverMusic.stop(); if (PlayStatePlaylist.isStoryMode) FlxG.switchState(new StoryMenuState());