update ci
All checks were successful
CI / build (push) Successful in 2m5s

This commit is contained in:
ultrablob 2025-04-17 19:28:20 -04:00
parent 9900a4801a
commit 11f72ed309
2 changed files with 26 additions and 14 deletions

View file

@ -33,17 +33,17 @@ jobs:
- uses: https://code.forgejo.org/actions/checkout@v2
name: Checkout Files
- name: Set up Node
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 10
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: lts/*
cache: 'npm'
node-version: ${{ matrix.node-version }}
cache: 'pnpm'
- name: Install dependencies
run: npm ci
- name: Build
run: npm run build
run: pnpm install
- name: Upload Build
uses: https://code.forgejo.org/forgejo/upload-artifact@v4

View file

@ -135,8 +135,8 @@ function mouseAction() {
const DOMpointer = document.getElementById("pointer")
DOMpointer.style.left = mouseBody.position[0] * SCALE + "px"
DOMpointer.style.top = -mouseBody.position[1] * SCALE + "px"
DOMpointer.style.left = mouseBody.interpolatedPosition[0] * SCALE + "px"
DOMpointer.style.top = -mouseBody.interpolatedPosition[1] * SCALE + "px"
// if (mouseEvent.button == 2) {
// mouseBody.position = [mouseEvent.clientX / SCALE, mouseEvent.clientY / SCALE]
@ -163,15 +163,27 @@ function resizeWindow() {
// console.log(delta)
bodies.forEach(element => {
element.physics.wakeUp()
var rect = element.dom.getBoundingClientRect();
element.physics.shapes[0].width = rect.width / SCALE
element.physics.shapes[0].height = rect.height / SCALE
if (delta.top !== 0 || delta.left !== 0) {
element.physics.applyForce([delta.top/SCALE, delta.left/SCALE], element.physics.position)
}
});
}
const height = window.innerHeight;
const adjustment = Math.round(-height - planeBottomBody.position[1]*SCALE)
const adjustmentBottom = Math.round(-window.innerHeight - planeBottomBody.position[1]*SCALE)
console.log(adjustment/SCALE)
const adjustmentRight = Math.round(window.innerWidth - planeRightBody.position[0]*SCALE)
planeBottomBody.velocity = [0, -Math.max(-adjustment/SCALE * 30, -20)]
// console.log(adjustment/SCALE)
planeBottomBody.velocity = [0, -Math.max(-adjustmentBottom/SCALE * 30, -20)]
planeRightBody.velocity = [Math.min(adjustmentRight/SCALE * 30, 20), 0]
currentWindowSize = {
x: window.screenLeft,