mirror of
https://gitlab.com/lecarore/breakout71.git
synced 2025-04-24 05:56:14 -04:00
wip
This commit is contained in:
parent
b0d8827e09
commit
4fb4c97734
15 changed files with 4190 additions and 3754 deletions
|
@ -1,8 +1,6 @@
|
|||
import {
|
||||
gameZoneWidthRoundedUp,
|
||||
gameState,
|
||||
isSettingOn,
|
||||
offsetX,
|
||||
offsetXRoundedDown,
|
||||
} from "./game";
|
||||
|
||||
export const sounds = {
|
||||
|
@ -160,7 +158,7 @@ function createExplosionSound(pan = 0.5) {
|
|||
function pixelsToPan(pan: number) {
|
||||
return Math.max(
|
||||
0,
|
||||
Math.min(1, (pan - offsetXRoundedDown) / gameZoneWidthRoundedUp),
|
||||
Math.min(1, (pan - gameState.offsetXRoundedDown) / gameState.gameZoneWidthRoundedUp),
|
||||
);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue