https://pvzm.net/ to play [Read-only GitHub mirror] pvzm.net
modded vs pvz plants-vs-zombies plantsvszombies javascript online zombie noads jspvz pvzm game plants plant
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge pull request #33 from Plants-vs-Zombies-MODDED/main

authored by

Clay and committed by
GitHub
13d79e10 80bbd18b

+98 -187
+1 -1
.github/workflows/close-stale-issues.yml
··· 6 6 7 7 jobs: 8 8 stale: 9 - runs-on: ubuntu-latest 9 + runs-on: blacksmith-2vcpu-ubuntu-2404 10 10 steps: 11 11 - uses: actions/stale@v9 12 12 with:
+64
.github/workflows/format-and-stamp.yml
··· 1 + name: Format & stamp 2 + 3 + on: 4 + push: 5 + branches: 6 + - main 7 + - staging 8 + workflow_dispatch: 9 + 10 + permissions: 11 + contents: write 12 + deployments: write 13 + 14 + jobs: 15 + format-and-stamp: 16 + runs-on: blacksmith-4vcpu-ubuntu-2404 17 + env: 18 + PNPM_HOME: /home/runner/.local/share/pnpm 19 + steps: 20 + - name: Checkout repository 21 + uses: actions/checkout@v4 22 + with: 23 + fetch-depth: 1 24 + 25 + - name: Setup Node.js & pnpm 26 + uses: actions/setup-node@v4 27 + with: 28 + node-version: "lts/*" 29 + 30 + - name: Install pnpm 31 + run: | 32 + corepack enable pnpm 33 + mkdir -p "$PNPM_HOME" 34 + echo "$PNPM_HOME" >> "$GITHUB_PATH" 35 + 36 + - name: Cache pnpm global packages 37 + uses: actions/cache@v4 38 + with: 39 + path: | 40 + ~/.local/share/pnpm/global 41 + key: pnpm-global-${{ hashFiles('pnpm-lock.yaml') }} 42 + restore-keys: pnpm-global- 43 + 44 + - name: Install dependencies 45 + run: pnpm add -g oxlint oxfmt esbuild html-minifier-terser 46 + 47 + - name: Lint, format & version stamp 48 + run: | 49 + pnpm run fix || true 50 + pnpm oxfmt --write . "**/*.{js,md,html,css,yml}" 51 + echo "${{ github.sha }}" > game/images/Zombies/CX/v.html 52 + 53 + - name: Commit changes 54 + run: | 55 + COMMIT_MSG=$(git log -1 --pretty=format:%s) 56 + AUTHOR_EMAIL=$(git log -1 --pretty=format:%ae) 57 + git config user.name github-actions 58 + git config user.email github-actions@github.com 59 + git add . 60 + git commit -m "Format \"$COMMIT_MSG\" [CF-Pages-Skip] 61 + Original commit: https://github.com/${{ github.repository }}/commit/${{ github.sha }} 62 + 63 + Co-authored-by: ${{ github.actor }} <$AUTHOR_EMAIL>" || exit 0 64 + git push
-92
.github/workflows/main.yml
··· 1 - name: Deploy 2 - 3 - on: 4 - push: 5 - branches: 6 - - main 7 - workflow_dispatch: 8 - 9 - permissions: 10 - contents: write 11 - deployments: write 12 - 13 - concurrency: 14 - group: "cloudflare-pages" 15 - cancel-in-progress: false 16 - 17 - jobs: 18 - build-and-deploy: 19 - runs-on: ubuntu-latest 20 - env: 21 - PNPM_HOME: /home/runner/.local/share/pnpm 22 - steps: 23 - - name: Checkout repository 24 - uses: actions/checkout@v4 25 - with: 26 - fetch-depth: 1 27 - 28 - - name: Setup Node.js & pnpm 29 - uses: actions/setup-node@v3 30 - with: 31 - node-version: "lts/*" 32 - 33 - - name: Install pnpm 34 - run: | 35 - corepack enable pnpm 36 - mkdir -p "$PNPM_HOME" 37 - echo "$PNPM_HOME" >> "$GITHUB_PATH" 38 - 39 - - name: Cache pnpm global packages 40 - uses: actions/cache@v4 41 - with: 42 - path: | 43 - ~/.local/share/pnpm/global 44 - ~/.local/share/pnpm/store 45 - key: pnpm-global-${{ hashFiles('.github/workflows/main.yml') }} 46 - restore-keys: pnpm-global- 47 - 48 - - name: Install dependencies 49 - run: pnpm add -g oxlint oxfmt esbuild html-minifier-terser wrangler@3 50 - 51 - - name: Lint, format & version stamp 52 - run: | 53 - pnpm run fix || true 54 - pnpm oxfmt --write . "**/*.{js,md,html,css,yml}" 55 - echo "${{ github.sha }}" > game/images/Zombies/CX/v.html 56 - 57 - - name: Commit changes 58 - run: | 59 - COMMIT_MSG=$(git log -1 --pretty=format:%s) 60 - AUTHOR_EMAIL=$(git log -1 --pretty=format:%ae) 61 - git config user.name github-actions 62 - git config user.email github-actions@github.com 63 - git add . 64 - git commit -m "Format \"$COMMIT_MSG\" 65 - Original commit: https://github.com/${{ github.repository }}/commit/${{ github.sha }} 66 - 67 - Co-authored-by: ${{ github.actor }} <$AUTHOR_EMAIL>" || exit 0 68 - git push 69 - 70 - - name: Bundle & minify all assets 71 - run: | 72 - esbuild game/js/CPlants.js \ 73 - --bundle --minify --sourcemap --sources-content=true \ 74 - --outfile=game/js/CPlants.js --allow-overwrite 75 - 76 - esbuild $(find . -type f \( -name "*.js" -o -name "*.css" \) \ 77 - -not -path "./node_modules/*" -not -name "CPlants.js") \ 78 - --minify --sourcemap --sources-content=true \ 79 - --outdir=. --allow-overwrite & 80 - 81 - find . -type f -name "*.html" -not -path "./node_modules/*" | \ 82 - xargs -P4 -I{} html-minifier-terser \ 83 - --collapse-whitespace --remove-comments --remove-tag-whitespace \ 84 - --minify-css true --minify-js true -o {} {} & 85 - 86 - wait 87 - 88 - - name: Deploy to Cloudflare Pages 89 - run: wrangler pages deploy . --project-name=pvz --commit-dirty=true 90 - env: 91 - CLOUDFLARE_API_TOKEN: ${{ secrets.CLOUDFLARE_API_TOKEN }} 92 - CLOUDFLARE_ACCOUNT_ID: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
-92
.github/workflows/staging.yml
··· 1 - name: Deploy (Staging) 2 - 3 - on: 4 - push: 5 - branches: 6 - - staging 7 - workflow_dispatch: 8 - 9 - permissions: 10 - contents: write 11 - deployments: write 12 - 13 - concurrency: 14 - group: "cloudflare-pages-staging" 15 - cancel-in-progress: false 16 - 17 - jobs: 18 - build-and-deploy: 19 - runs-on: ubuntu-latest 20 - env: 21 - PNPM_HOME: /home/runner/.local/share/pnpm 22 - steps: 23 - - name: Checkout repository 24 - uses: actions/checkout@v4 25 - with: 26 - fetch-depth: 1 27 - 28 - - name: Setup Node.js & pnpm 29 - uses: actions/setup-node@v3 30 - with: 31 - node-version: "lts/*" 32 - 33 - - name: Install pnpm 34 - run: | 35 - corepack enable pnpm 36 - mkdir -p "$PNPM_HOME" 37 - echo "$PNPM_HOME" >> "$GITHUB_PATH" 38 - 39 - - name: Cache pnpm global packages 40 - uses: actions/cache@v4 41 - with: 42 - path: | 43 - ~/.local/share/pnpm/global 44 - ~/.local/share/pnpm/store 45 - key: pnpm-global-${{ hashFiles('.github/workflows/main.yml') }} 46 - restore-keys: pnpm-global- 47 - 48 - - name: Install dependencies 49 - run: pnpm add -g oxlint oxfmt esbuild html-minifier-terser wrangler@3 50 - 51 - - name: Lint, format & version stamp 52 - run: | 53 - pnpm run fix || true 54 - pnpm oxfmt --write . "**/*.{js,md,html,css,yml}" 55 - echo "${{ github.sha }}" > game/images/Zombies/CX/v.html 56 - 57 - - name: Commit changes 58 - run: | 59 - COMMIT_MSG=$(git log -1 --pretty=format:%s) 60 - AUTHOR_EMAIL=$(git log -1 --pretty=format:%ae) 61 - git config user.name github-actions 62 - git config user.email github-actions@github.com 63 - git add . 64 - git commit -m "Format \"$COMMIT_MSG\" 65 - Original commit: https://github.com/${{ github.repository }}/commit/${{ github.sha }} 66 - 67 - Co-authored-by: ${{ github.actor }} <$AUTHOR_EMAIL>" || exit 0 68 - git push 69 - 70 - - name: Bundle & minify all assets 71 - run: | 72 - esbuild game/js/CPlants.js \ 73 - --bundle --minify --sourcemap --sources-content=true \ 74 - --outfile=game/js/CPlants.js --allow-overwrite 75 - 76 - esbuild $(find . -type f \( -name "*.js" -o -name "*.css" \) \ 77 - -not -path "./node_modules/*" -not -name "CPlants.js") \ 78 - --minify --sourcemap --sources-content=true \ 79 - --outdir=. --allow-overwrite & 80 - 81 - find . -type f -name "*.html" -not -path "./node_modules/*" | \ 82 - xargs -P4 -I{} html-minifier-terser \ 83 - --collapse-whitespace --remove-comments --remove-tag-whitespace \ 84 - --minify-css true --minify-js true -o {} {} & 85 - 86 - wait 87 - 88 - - name: Deploy to Cloudflare Pages 89 - run: wrangler pages deploy . --project-name=pvz-staging --commit-dirty=true --branch=production 90 - env: 91 - CLOUDFLARE_API_TOKEN: ${{ secrets.CLOUDFLARE_API_TOKEN }} 92 - CLOUDFLARE_ACCOUNT_ID: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
+1 -1
game/images/Zombies/CX/v.html
··· 1 - f0ad0490496369839f3dd854f524d44866053b04 1 + 581553080c87ad4372ef799476140377ea052d87
+2 -1
package.json
··· 7 7 "author": "", 8 8 "scripts": { 9 9 "lint": "oxlint", 10 - "fix": "oxlint --fix" 10 + "fix": "oxlint --fix", 11 + "build": "bash scripts/build.sh" 11 12 }, 12 13 "devDependencies": { 13 14 "html-minifier-terser": "^7.2.0",
+30
scripts/build.sh
··· 1 + #!/bin/bash 2 + set -e 3 + 4 + npm install -g oxlint oxfmt esbuild html-minifier-terser 5 + 6 + # lint & format 7 + oxlint . || true 8 + oxfmt --write . "**/*.{js,md,html,css,yml}" 9 + 10 + # bundle entry point 11 + esbuild game/js/CPlants.js \ 12 + --bundle --minify --sourcemap \ 13 + --outfile=game/js/CPlants.js --allow-overwrite 14 + 15 + # minify remaining js & css 16 + find . -type f \( -name "*.js" -o -name "*.css" \) \ 17 + -not -path "./node_modules/*" \ 18 + -not -name "CPlants.js" | \ 19 + xargs -P4 -I{} esbuild {} \ 20 + --minify --sourcemap \ 21 + --outdir=. --allow-overwrite & 22 + 23 + # minify html 24 + find . -type f -name "*.html" \ 25 + -not -path "./node_modules/*" | \ 26 + xargs -P4 -I{} html-minifier-terser \ 27 + --collapse-whitespace --remove-comments --remove-tag-whitespace \ 28 + --minify-css true --minify-js true -o {} {} & 29 + 30 + wait