From 36b203f33a930f6484ba1675aa61174683ccb296 Mon Sep 17 00:00:00 2001 From: Bill Date: Tue, 3 Jan 2023 01:04:48 -0500 Subject: [PATCH] Pixi 6.5.8 & Landscapes (#84) * Changes * More changes * fix some var names * Fix door mask * Add tilemap back * Begin landscapes * Add vite * Add landscapes * Add texture caching * More changes * Fix flipped plane material cells * Changes * More landscape changes * Fix PlaneMaterialCell tiling * Add more caching * Destroy BaseRenderTexture * Performance improvements * More improvements * More improvements * Cache mask pixels * Fix settings Co-authored-by: dank074 --- .vscode/settings.json | 26 +- package.json | 71 +- src/api/asset/AssetManager.ts | 10 +- src/api/asset/GraphicAsset.ts | 7 + src/api/asset/IAssetData.ts | 2 + src/api/asset/index.ts | 1 + .../asset/room-visualization/IAssetPlane.ts | 8 + .../room-visualization/IAssetPlaneMask.ts | 7 + .../room-visualization/IAssetPlaneMaskData.ts | 6 + .../IAssetPlaneMaskVisualization.ts | 7 + .../room-visualization/IAssetPlaneMaterial.ts | 7 + .../IAssetPlaneMaterialCell.ts | 7 + .../IAssetPlaneMaterialCellColumn.ts | 8 + .../IAssetPlaneMaterialCellExtraItemData.ts | 6 + .../IAssetPlaneMaterialCellMatrix.ts | 12 + .../room-visualization/IAssetPlaneTexture.ts | 7 + .../IAssetPlaneTextureBitmap.ts | 8 + .../IAssetPlaneVisualization.ts | 10 + .../IAssetPlaneVisualizationAnimatedLayer.ts | 6 + ...ssetPlaneVisualizationAnimatedLayerItem.ts | 11 + .../IAssetPlaneVisualizationData.ts | 10 + .../IAssetPlaneVisualizationLayer.ts | 7 + .../IAssetRoomVisualizationData.ts | 10 + src/api/asset/room-visualization/index.ts | 17 + .../avatar/animation/IAvatarDataContainer.ts | 2 +- src/api/utils/Dict.ts | 3 + src/api/utils/index.ts | 1 + src/nitro/Nitro.ts | 12 +- src/nitro/Plugins.ts | 42 +- src/nitro/avatar/AvatarImagePartContainer.ts | 4 +- .../avatar/animation/AvatarDataContainer.ts | 4 +- src/nitro/room/RoomContentLoader.ts | 10 +- src/nitro/room/RoomEngine.ts | 2 +- src/nitro/room/object/RoomPlaneParser.ts | 2 +- .../logic/furniture/FurnitureWindowLogic.ts | 2 +- .../FurnitureAnimatedVisualization.ts | 35 +- .../FurnitureMannequinVisualization.ts | 9 +- .../furniture/FurnitureVisualization.ts | 5 + .../visualization/pet/PetVisualization.ts | 37 +- .../object/visualization/room/RoomPlane.ts | 442 +++--- .../visualization/room/RoomPlaneBitmapMask.ts | 8 +- .../visualization/room/RoomVisualization.ts | 185 +-- .../room/RoomVisualizationData.ts | 14 +- .../visualization/room/mask/PlaneMask.ts | 4 +- .../room/mask/PlaneMaskManager.ts | 77 +- .../room/rasterizer/IPlaneRasterizer.ts | 4 +- .../room/rasterizer/animated/AnimationItem.ts | 32 +- .../rasterizer/animated/LandscapePlane.ts | 40 +- .../animated/LandscapeRasterizer.ts | 137 +- .../PlaneVisualizationAnimationLayer.ts | 104 +- .../room/rasterizer/basic/FloorPlane.ts | 6 +- .../room/rasterizer/basic/FloorRasterizer.ts | 17 +- .../room/rasterizer/basic/Plane.ts | 2 +- .../room/rasterizer/basic/PlaneMaterial.ts | 4 +- .../rasterizer/basic/PlaneMaterialCell.ts | 138 +- .../basic/PlaneMaterialCellColumn.ts | 433 +++--- .../basic/PlaneMaterialCellMatrix.ts | 220 ++- .../room/rasterizer/basic/PlaneRasterizer.ts | 95 +- .../room/rasterizer/basic/PlaneTexture.ts | 4 +- .../rasterizer/basic/PlaneTextureBitmap.ts | 4 +- .../rasterizer/basic/PlaneVisualization.ts | 78 +- .../basic/PlaneVisualizationLayer.ts | 74 +- .../room/rasterizer/basic/WallPlane.ts | 6 +- .../room/rasterizer/basic/WallRasterizer.ts | 24 +- .../room/utils/PlaneBitmapData.ts | 16 +- .../visualization/room/utils/Randomizer.ts | 8 +- src/nitro/utils/Int32.ts | 13 + src/nitro/utils/WebGL.ts | 8 - src/nitro/utils/index.ts | 2 +- src/pixi-proxy/CopyChannelFilter.ts | 49 + src/pixi-proxy/NitroAdjustmentFilter.ts | 4 - src/pixi-proxy/{tilemap => }/NitroTilemap.ts | 0 src/pixi-proxy/RoomTextureUtils.ts | 99 ++ src/pixi-proxy/TextureUtils.ts | 76 +- .../adjustment-filter/AdjustmentFilter.ts | 120 ++ src/pixi-proxy/adjustment-filter/index.ts | 1 + src/pixi-proxy/index.ts | 7 +- src/pixi-proxy/tilemap/index.ts | 2 - src/room/renderer/RoomSpriteCanvas.ts | 2 +- src/room/renderer/utils/ExtendedSprite.ts | 85 +- src/room/utils/ColorConverter.ts | 15 + src/room/utils/Rasterizer.ts | 21 +- tsconfig.json | 12 +- vite.config.js | 36 + yarn.lock | 1235 ++++++++++++----- 85 files changed, 2637 insertions(+), 1767 deletions(-) create mode 100644 src/api/asset/room-visualization/IAssetPlane.ts create mode 100644 src/api/asset/room-visualization/IAssetPlaneMask.ts create mode 100644 src/api/asset/room-visualization/IAssetPlaneMaskData.ts create mode 100644 src/api/asset/room-visualization/IAssetPlaneMaskVisualization.ts create mode 100644 src/api/asset/room-visualization/IAssetPlaneMaterial.ts create mode 100644 src/api/asset/room-visualization/IAssetPlaneMaterialCell.ts create mode 100644 src/api/asset/room-visualization/IAssetPlaneMaterialCellColumn.ts create mode 100644 src/api/asset/room-visualization/IAssetPlaneMaterialCellExtraItemData.ts create mode 100644 src/api/asset/room-visualization/IAssetPlaneMaterialCellMatrix.ts create mode 100644 src/api/asset/room-visualization/IAssetPlaneTexture.ts create mode 100644 src/api/asset/room-visualization/IAssetPlaneTextureBitmap.ts create mode 100644 src/api/asset/room-visualization/IAssetPlaneVisualization.ts create mode 100644 src/api/asset/room-visualization/IAssetPlaneVisualizationAnimatedLayer.ts create mode 100644 src/api/asset/room-visualization/IAssetPlaneVisualizationAnimatedLayerItem.ts create mode 100644 src/api/asset/room-visualization/IAssetPlaneVisualizationData.ts create mode 100644 src/api/asset/room-visualization/IAssetPlaneVisualizationLayer.ts create mode 100644 src/api/asset/room-visualization/IAssetRoomVisualizationData.ts create mode 100644 src/api/asset/room-visualization/index.ts create mode 100644 src/api/utils/Dict.ts create mode 100644 src/nitro/utils/Int32.ts delete mode 100644 src/nitro/utils/WebGL.ts create mode 100644 src/pixi-proxy/CopyChannelFilter.ts delete mode 100644 src/pixi-proxy/NitroAdjustmentFilter.ts rename src/pixi-proxy/{tilemap => }/NitroTilemap.ts (100%) create mode 100644 src/pixi-proxy/RoomTextureUtils.ts create mode 100644 src/pixi-proxy/adjustment-filter/AdjustmentFilter.ts create mode 100644 src/pixi-proxy/adjustment-filter/index.ts delete mode 100644 src/pixi-proxy/tilemap/index.ts create mode 100644 vite.config.js diff --git a/.vscode/settings.json b/.vscode/settings.json index 7b328b85..3fdf856d 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -4,13 +4,29 @@ "typescript.preferences.quoteStyle": "single", "typescript.format.placeOpenBraceOnNewLineForControlBlocks": true, "typescript.format.placeOpenBraceOnNewLineForFunctions": true, + "editor.wordWrap": "on", "editor.codeActionsOnSave": { - "source.fixAll": true, - "source.organizeImports": true, + "source.fixAll.eslint": true, + "source.fixAll.sortJSON": false, + "source.organizeImports": true }, - "emmet.showExpandedAbbreviation": "never", - "git.ignoreLimitWarning": true, + "editor.formatOnSave": false, + "git.ignoreLimitWarning": true, "files.eol": "\n", "files.insertFinalNewline": true, - "files.trimFinalNewlines": true + "files.trimFinalNewlines": true, + "emmet.showExpandedAbbreviation": "never", + "eslint.format.enable": true, + "eslint.validate": [ + "javascript", + "typescript" + ], + "eslint.workingDirectories": [ + { + "pattern": "./src" + } + ], + "javascript.format.enable": false, + "thunder-client.saveToWorkspace": false, + "thunder-client.workspaceRelativePath": "." } diff --git a/package.json b/package.json index 986052db..4ab9f2de 100644 --- a/package.json +++ b/package.json @@ -16,53 +16,58 @@ "homepage": "https://git.krews.org/nitro/nitro-renderer", "type": "module", "scripts": { - "compile": "tsc --project ./tsconfig.json", + "build": "vite build", + "compile": "tsc --project ./tsconfig.json --noEmit false", "eslint": "eslint ./src --fix" }, + "main": "./index", "dependencies": { - "@pixi/app": "~6.4.2", - "@pixi/basis": "~6.4.2", - "@pixi/canvas-display": "~6.4.2", - "@pixi/canvas-extract": "~6.4.2", - "@pixi/canvas-renderer": "~6.4.2", - "@pixi/constants": "~6.4.2", - "@pixi/core": "~6.4.2", - "@pixi/display": "~6.4.2", - "@pixi/events": "~6.4.2", - "@pixi/extract": "~6.4.2", - "@pixi/filter-adjustment": "^4.1.3", - "@pixi/filter-alpha": "~6.4.2", - "@pixi/filter-color-matrix": "~6.4.2", - "@pixi/graphics": "~6.4.2", - "@pixi/graphics-extras": "~6.4.2", - "@pixi/interaction": "~6.4.2", - "@pixi/loaders": "~6.4.2", - "@pixi/math": "~6.4.2", - "@pixi/math-extras": "~6.4.2", - "@pixi/mixin-cache-as-bitmap": "~6.4.2", - "@pixi/mixin-get-child-by-name": "~6.4.2", - "@pixi/mixin-get-global-position": "~6.4.2", - "@pixi/polyfill": "~6.4.2", - "@pixi/runner": "~6.4.2", - "@pixi/settings": "~6.4.2", - "@pixi/sprite": "~6.4.2", - "@pixi/sprite-tiling": "~6.4.2", - "@pixi/spritesheet": "~6.4.2", - "@pixi/text": "~6.4.2", - "@pixi/ticker": "~6.4.2", + "@pixi/app": "~6.5.0", + "@pixi/basis": "~6.5.0", + "@pixi/canvas-display": "~6.5.0", + "@pixi/canvas-extract": "~6.5.0", + "@pixi/canvas-renderer": "~6.5.0", + "@pixi/constants": "~6.5.0", + "@pixi/core": "~6.5.0", + "@pixi/display": "~6.5.0", + "@pixi/events": "~6.5.0", + "@pixi/extensions": "~6.5.0", + "@pixi/extract": "~6.5.0", + "@pixi/filter-alpha": "~6.5.0", + "@pixi/filter-color-matrix": "~6.5.0", + "@pixi/graphics": "~6.5.0", + "@pixi/graphics-extras": "~6.5.0", + "@pixi/interaction": "~6.5.0", + "@pixi/loaders": "~6.5.0", + "@pixi/math": "~6.5.0", + "@pixi/math-extras": "~6.5.0", + "@pixi/mixin-cache-as-bitmap": "~6.5.0", + "@pixi/mixin-get-child-by-name": "~6.5.0", + "@pixi/mixin-get-global-position": "~6.5.0", + "@pixi/polyfill": "~6.5.0", + "@pixi/runner": "~6.5.0", + "@pixi/settings": "~6.5.0", + "@pixi/sprite": "~6.5.0", + "@pixi/sprite-tiling": "~6.5.0", + "@pixi/spritesheet": "~6.5.0", + "@pixi/text": "~6.5.0", + "@pixi/ticker": "~6.5.0", "@pixi/tilemap": "^3.2.2", - "@pixi/utils": "~6.4.2", + "@pixi/utils": "~6.5.0", "gifuct-js": "^2.1.2", "howler": "^2.2.3", "pako": "^2.0.4" }, "devDependencies": { + "@rollup/plugin-typescript": "^10.0.1", "@types/howler": "^2.2.7", "@types/pako": "^1.0.3", "@typescript-eslint/eslint-plugin": "^5.30.7", "@typescript-eslint/parser": "^5.30.7", "eslint": "^8.20.0", "tslib": "^2.3.1", - "typescript": "~4.4.4" + "typescript": "~4.4.4", + "vite": "^4.0.2", + "vite-plugin-minify": "^1.5.2" } } diff --git a/src/api/asset/AssetManager.ts b/src/api/asset/AssetManager.ts index 76bce11a..fa23735d 100644 --- a/src/api/asset/AssetManager.ts +++ b/src/api/asset/AssetManager.ts @@ -175,15 +175,9 @@ export class AssetManager implements IAssetManager { const spritesheet = new Spritesheet(baseTexture, spritesheetData); - return new Promise((resolve, reject) => - { - spritesheet.parse(() => - { - this.createCollection(data, spritesheet); + await spritesheet.parse(); - return resolve(); - }); - }); + this.createCollection(data, spritesheet); }; if(baseTexture.valid) diff --git a/src/api/asset/GraphicAsset.ts b/src/api/asset/GraphicAsset.ts index 7b717978..b99bb71c 100644 --- a/src/api/asset/GraphicAsset.ts +++ b/src/api/asset/GraphicAsset.ts @@ -1,5 +1,7 @@ import { Resource, Texture } from '@pixi/core'; import { Rectangle } from '@pixi/math'; +import { Sprite } from '@pixi/sprite'; +import { TextureUtils } from '../../pixi-proxy'; import { IGraphicAsset } from './IGraphicAsset'; export class GraphicAsset implements IGraphicAsset @@ -64,6 +66,11 @@ export class GraphicAsset implements IGraphicAsset this._initialized = true; } + public getImageUrl(): string + { + return TextureUtils.generateImageUrl(new Sprite(this._texture)); + } + public get name(): string { return this._name; diff --git a/src/api/asset/IAssetData.ts b/src/api/asset/IAssetData.ts index ff4524c8..f12820f3 100644 --- a/src/api/asset/IAssetData.ts +++ b/src/api/asset/IAssetData.ts @@ -3,6 +3,7 @@ import { IAsset } from './IAsset'; import { IAssetAlias } from './IAssetAlias'; import { IAssetPalette } from './IAssetPalette'; import { IAssetLogicData } from './logic'; +import { IAssetRoomVisualizationData } from './room-visualization'; import { ISpritesheetData } from './spritesheet'; import { IAssetVisualizationData } from './visualization'; @@ -18,4 +19,5 @@ export interface IAssetData { animations?: { [index: string]: IAssetAnimation }; palettes?: { [index: string]: IAssetPalette }; visualizations?: IAssetVisualizationData[]; + roomVisualization?: IAssetRoomVisualizationData; } diff --git a/src/api/asset/index.ts b/src/api/asset/index.ts index 2154d708..3ba873fe 100644 --- a/src/api/asset/index.ts +++ b/src/api/asset/index.ts @@ -17,6 +17,7 @@ export * from './IGraphicAssetPalette'; export * from './logic'; export * from './logic/model'; export * from './logic/particlesystem'; +export * from './room-visualization'; export * from './spritesheet'; export * from './visualization'; export * from './visualization/animation'; diff --git a/src/api/asset/room-visualization/IAssetPlane.ts b/src/api/asset/room-visualization/IAssetPlane.ts new file mode 100644 index 00000000..60076412 --- /dev/null +++ b/src/api/asset/room-visualization/IAssetPlane.ts @@ -0,0 +1,8 @@ +import { IAssetPlaneVisualization } from './IAssetPlaneVisualization'; + +export interface IAssetPlane +{ + id?: string; + visualizations?: IAssetPlaneVisualization[]; + animatedVisualization?: IAssetPlaneVisualization[]; +} diff --git a/src/api/asset/room-visualization/IAssetPlaneMask.ts b/src/api/asset/room-visualization/IAssetPlaneMask.ts new file mode 100644 index 00000000..0fd84659 --- /dev/null +++ b/src/api/asset/room-visualization/IAssetPlaneMask.ts @@ -0,0 +1,7 @@ +import { IAssetPlaneMaskVisualization } from './IAssetPlaneMaskVisualization'; + +export interface IAssetPlaneMask +{ + id?: string; + visualizations?: IAssetPlaneMaskVisualization[]; +} diff --git a/src/api/asset/room-visualization/IAssetPlaneMaskData.ts b/src/api/asset/room-visualization/IAssetPlaneMaskData.ts new file mode 100644 index 00000000..2767b59f --- /dev/null +++ b/src/api/asset/room-visualization/IAssetPlaneMaskData.ts @@ -0,0 +1,6 @@ +import { IAssetPlaneMask } from './IAssetPlaneMask'; + +export interface IAssetPlaneMaskData +{ + masks?: IAssetPlaneMask[]; +} diff --git a/src/api/asset/room-visualization/IAssetPlaneMaskVisualization.ts b/src/api/asset/room-visualization/IAssetPlaneMaskVisualization.ts new file mode 100644 index 00000000..66c5ae8c --- /dev/null +++ b/src/api/asset/room-visualization/IAssetPlaneMaskVisualization.ts @@ -0,0 +1,7 @@ +import { IAssetPlaneTextureBitmap } from './IAssetPlaneTextureBitmap'; + +export interface IAssetPlaneMaskVisualization +{ + size?: number; + bitmaps?: IAssetPlaneTextureBitmap[]; +} diff --git a/src/api/asset/room-visualization/IAssetPlaneMaterial.ts b/src/api/asset/room-visualization/IAssetPlaneMaterial.ts new file mode 100644 index 00000000..59ae0076 --- /dev/null +++ b/src/api/asset/room-visualization/IAssetPlaneMaterial.ts @@ -0,0 +1,7 @@ +import { IAssetPlaneMaterialCellMatrix } from './IAssetPlaneMaterialCellMatrix'; + +export interface IAssetPlaneMaterial +{ + id?: string; + matrices?: IAssetPlaneMaterialCellMatrix[]; +} diff --git a/src/api/asset/room-visualization/IAssetPlaneMaterialCell.ts b/src/api/asset/room-visualization/IAssetPlaneMaterialCell.ts new file mode 100644 index 00000000..fafae273 --- /dev/null +++ b/src/api/asset/room-visualization/IAssetPlaneMaterialCell.ts @@ -0,0 +1,7 @@ +import { IAssetPlaneMaterialCellExtraItemData } from './IAssetPlaneMaterialCellExtraItemData'; + +export interface IAssetPlaneMaterialCell +{ + textureId?: string; + extraData?: IAssetPlaneMaterialCellExtraItemData; +} diff --git a/src/api/asset/room-visualization/IAssetPlaneMaterialCellColumn.ts b/src/api/asset/room-visualization/IAssetPlaneMaterialCellColumn.ts new file mode 100644 index 00000000..d2b36d30 --- /dev/null +++ b/src/api/asset/room-visualization/IAssetPlaneMaterialCellColumn.ts @@ -0,0 +1,8 @@ +import { IAssetPlaneMaterialCell } from './IAssetPlaneMaterialCell'; + +export interface IAssetPlaneMaterialCellColumn +{ + repeatMode?: string; + width?: number; + cells?: IAssetPlaneMaterialCell[]; +} diff --git a/src/api/asset/room-visualization/IAssetPlaneMaterialCellExtraItemData.ts b/src/api/asset/room-visualization/IAssetPlaneMaterialCellExtraItemData.ts new file mode 100644 index 00000000..a49833f0 --- /dev/null +++ b/src/api/asset/room-visualization/IAssetPlaneMaterialCellExtraItemData.ts @@ -0,0 +1,6 @@ +export interface IAssetPlaneMaterialCellExtraItemData +{ + limitMax?: number; + extraItemTypes?: string[]; + offsets?: [number, number][]; +} diff --git a/src/api/asset/room-visualization/IAssetPlaneMaterialCellMatrix.ts b/src/api/asset/room-visualization/IAssetPlaneMaterialCellMatrix.ts new file mode 100644 index 00000000..526cde27 --- /dev/null +++ b/src/api/asset/room-visualization/IAssetPlaneMaterialCellMatrix.ts @@ -0,0 +1,12 @@ +import { IAssetPlaneMaterialCellColumn } from './IAssetPlaneMaterialCellColumn'; + +export interface IAssetPlaneMaterialCellMatrix +{ + repeatMode?: string; + align?: string; + normalMinX?: number; + normalMaxX?: number; + normalMinY?: number; + normalMaxY?: number; + columns?: IAssetPlaneMaterialCellColumn[]; +} diff --git a/src/api/asset/room-visualization/IAssetPlaneTexture.ts b/src/api/asset/room-visualization/IAssetPlaneTexture.ts new file mode 100644 index 00000000..fff62fa9 --- /dev/null +++ b/src/api/asset/room-visualization/IAssetPlaneTexture.ts @@ -0,0 +1,7 @@ +import { IAssetPlaneTextureBitmap } from './IAssetPlaneTextureBitmap'; + +export interface IAssetPlaneTexture +{ + id?: string; + bitmaps?: IAssetPlaneTextureBitmap[]; +} diff --git a/src/api/asset/room-visualization/IAssetPlaneTextureBitmap.ts b/src/api/asset/room-visualization/IAssetPlaneTextureBitmap.ts new file mode 100644 index 00000000..e1af985a --- /dev/null +++ b/src/api/asset/room-visualization/IAssetPlaneTextureBitmap.ts @@ -0,0 +1,8 @@ +export interface IAssetPlaneTextureBitmap +{ + assetName?: string; + normalMinX?: number; + normalMaxX?: number; + normalMinY?: number; + normalMaxY?: number; +} diff --git a/src/api/asset/room-visualization/IAssetPlaneVisualization.ts b/src/api/asset/room-visualization/IAssetPlaneVisualization.ts new file mode 100644 index 00000000..db3b4de7 --- /dev/null +++ b/src/api/asset/room-visualization/IAssetPlaneVisualization.ts @@ -0,0 +1,10 @@ +import { IAssetPlaneVisualizationAnimatedLayer } from './IAssetPlaneVisualizationAnimatedLayer'; +import { IAssetPlaneVisualizationLayer } from './IAssetPlaneVisualizationLayer'; + +export interface IAssetPlaneVisualization +{ + size?: number; + horizontalAngle?: number; + verticalAngle?: number; + allLayers?: (IAssetPlaneVisualizationLayer | IAssetPlaneVisualizationAnimatedLayer)[]; +} diff --git a/src/api/asset/room-visualization/IAssetPlaneVisualizationAnimatedLayer.ts b/src/api/asset/room-visualization/IAssetPlaneVisualizationAnimatedLayer.ts new file mode 100644 index 00000000..4cd50c2e --- /dev/null +++ b/src/api/asset/room-visualization/IAssetPlaneVisualizationAnimatedLayer.ts @@ -0,0 +1,6 @@ +import { IAssetPlaneVisualizationAnimatedLayerItem } from './IAssetPlaneVisualizationAnimatedLayerItem'; + +export interface IAssetPlaneVisualizationAnimatedLayer +{ + items?: IAssetPlaneVisualizationAnimatedLayerItem[]; +} diff --git a/src/api/asset/room-visualization/IAssetPlaneVisualizationAnimatedLayerItem.ts b/src/api/asset/room-visualization/IAssetPlaneVisualizationAnimatedLayerItem.ts new file mode 100644 index 00000000..9ee426e6 --- /dev/null +++ b/src/api/asset/room-visualization/IAssetPlaneVisualizationAnimatedLayerItem.ts @@ -0,0 +1,11 @@ +export interface IAssetPlaneVisualizationAnimatedLayerItem +{ + id?: number; + assetId?: string; + x?: string; + y?: string; + randomX?: string; + randomY?: string; + speedX?: number; + speedY?: number; +} diff --git a/src/api/asset/room-visualization/IAssetPlaneVisualizationData.ts b/src/api/asset/room-visualization/IAssetPlaneVisualizationData.ts new file mode 100644 index 00000000..4e48d532 --- /dev/null +++ b/src/api/asset/room-visualization/IAssetPlaneVisualizationData.ts @@ -0,0 +1,10 @@ +import { IAssetPlane } from './IAssetPlane'; +import { IAssetPlaneMaterial } from './IAssetPlaneMaterial'; +import { IAssetPlaneTexture } from './IAssetPlaneTexture'; + +export interface IAssetPlaneVisualizationData +{ + planes?: IAssetPlane[]; + materials?: IAssetPlaneMaterial[]; + textures?: IAssetPlaneTexture[]; +} diff --git a/src/api/asset/room-visualization/IAssetPlaneVisualizationLayer.ts b/src/api/asset/room-visualization/IAssetPlaneVisualizationLayer.ts new file mode 100644 index 00000000..e009893e --- /dev/null +++ b/src/api/asset/room-visualization/IAssetPlaneVisualizationLayer.ts @@ -0,0 +1,7 @@ +export interface IAssetPlaneVisualizationLayer +{ + materialId?: string; + color?: number; + offset?: number; + align?: string; +} diff --git a/src/api/asset/room-visualization/IAssetRoomVisualizationData.ts b/src/api/asset/room-visualization/IAssetRoomVisualizationData.ts new file mode 100644 index 00000000..e82ea8f9 --- /dev/null +++ b/src/api/asset/room-visualization/IAssetRoomVisualizationData.ts @@ -0,0 +1,10 @@ +import { IAssetPlaneMaskData } from './IAssetPlaneMaskData'; +import { IAssetPlaneVisualizationData } from './IAssetPlaneVisualizationData'; + +export interface IAssetRoomVisualizationData +{ + floorData?: IAssetPlaneVisualizationData; + wallData?: IAssetPlaneVisualizationData; + landscapeData?: IAssetPlaneVisualizationData; + maskData?: IAssetPlaneMaskData; +} diff --git a/src/api/asset/room-visualization/index.ts b/src/api/asset/room-visualization/index.ts new file mode 100644 index 00000000..4d6facee --- /dev/null +++ b/src/api/asset/room-visualization/index.ts @@ -0,0 +1,17 @@ +export * from './IAssetPlane'; +export * from './IAssetPlaneMask'; +export * from './IAssetPlaneMaskData'; +export * from './IAssetPlaneMaskVisualization'; +export * from './IAssetPlaneMaterial'; +export * from './IAssetPlaneMaterialCell'; +export * from './IAssetPlaneMaterialCellColumn'; +export * from './IAssetPlaneMaterialCellExtraItemData'; +export * from './IAssetPlaneMaterialCellMatrix'; +export * from './IAssetPlaneTexture'; +export * from './IAssetPlaneTextureBitmap'; +export * from './IAssetPlaneVisualization'; +export * from './IAssetPlaneVisualizationAnimatedLayer'; +export * from './IAssetPlaneVisualizationAnimatedLayerItem'; +export * from './IAssetPlaneVisualizationData'; +export * from './IAssetPlaneVisualizationLayer'; +export * from './IAssetRoomVisualizationData'; diff --git a/src/api/nitro/avatar/animation/IAvatarDataContainer.ts b/src/api/nitro/avatar/animation/IAvatarDataContainer.ts index 1e6ed488..e35443aa 100644 --- a/src/api/nitro/avatar/animation/IAvatarDataContainer.ts +++ b/src/api/nitro/avatar/animation/IAvatarDataContainer.ts @@ -1,4 +1,4 @@ -import { AdjustmentFilter } from '@pixi/filter-adjustment'; +import { AdjustmentFilter } from '../../../../pixi-proxy'; export interface IAvatarDataContainer { diff --git a/src/api/utils/Dict.ts b/src/api/utils/Dict.ts new file mode 100644 index 00000000..241c64aa --- /dev/null +++ b/src/api/utils/Dict.ts @@ -0,0 +1,3 @@ +export type Dict = { + [key: string]: T; +}; diff --git a/src/api/utils/index.ts b/src/api/utils/index.ts index 07d750be..51632ffe 100644 --- a/src/api/utils/index.ts +++ b/src/api/utils/index.ts @@ -2,6 +2,7 @@ export * from './AdvancedMap'; export * from './ArrayBufferToBase64'; export * from './BinaryReader'; export * from './BinaryWriter'; +export * from './Dict'; export * from './IAdvancedMap'; export * from './IBinaryReader'; export * from './IBinaryWriter'; diff --git a/src/nitro/Nitro.ts b/src/nitro/Nitro.ts index 79217e72..f821c6e8 100644 --- a/src/nitro/Nitro.ts +++ b/src/nitro/Nitro.ts @@ -14,7 +14,7 @@ import { GameMessageHandler } from './game'; import { INitro } from './INitro'; import { NitroLocalizationManager } from './localization'; import './Plugins'; -import { RoomEngine } from './room'; +import { LandscapeRasterizer, RoomEngine } from './room'; import { RoomSessionManager, SessionDataManager } from './session'; import { SoundManager } from './sound'; import { HabboWebTools } from './utils/HabboWebTools'; @@ -23,6 +23,7 @@ LegacyExternalInterface.available; settings.SCALE_MODE = (!(window.devicePixelRatio % 1)) ? SCALE_MODES.NEAREST : SCALE_MODES.LINEAR; settings.ROUND_PIXELS = true; +settings.GC_MAX_IDLE = 120; export class Nitro implements INitro { @@ -87,9 +88,9 @@ export class Nitro implements INitro const instance = new this(new NitroCore(), { autoDensity: false, - resolution: window.devicePixelRatio, width: window.innerWidth, height: window.innerHeight, + resolution: window.devicePixelRatio, view: canvas }); @@ -192,16 +193,15 @@ export class Nitro implements INitro private onConfigurationLoadedEvent(event: ConfigurationEvent): void { - const animationFPS = NitroConfiguration.getValue('system.animation.fps', 24); - const limitsFPS = NitroConfiguration.getValue('system.limits.fps', false); - - if(limitsFPS) GetTicker().maxFPS = animationFPS; + GetTicker().maxFPS = NitroConfiguration.getValue('system.fps.max', 24); NitroLogger.LOG_DEBUG = NitroConfiguration.getValue('system.log.debug', true); NitroLogger.LOG_WARN = NitroConfiguration.getValue('system.log.warn', false); NitroLogger.LOG_ERROR = NitroConfiguration.getValue('system.log.error', false); NitroLogger.LOG_EVENTS = NitroConfiguration.getValue('system.log.events', false); NitroLogger.LOG_PACKETS = NitroConfiguration.getValue('system.log.packets', false); + + LandscapeRasterizer.LANDSCAPES_ENABLED = NitroConfiguration.getValue('room.landscapes.enabled', true); } private onRoomEngineReady(event: RoomEngineEvent): void diff --git a/src/nitro/Plugins.ts b/src/nitro/Plugins.ts index a653fa76..5cf5e8c2 100644 --- a/src/nitro/Plugins.ts +++ b/src/nitro/Plugins.ts @@ -1,10 +1,9 @@ -import { Application } from '@pixi/app'; import '@pixi/canvas-display'; -import { BatchRenderer, Renderer } from '@pixi/core'; +import { BatchRenderer, extensions } from '@pixi/core'; import { Extract } from '@pixi/extract'; import '@pixi/graphics-extras'; import { InteractionManager } from '@pixi/interaction'; -import { AppLoaderPlugin, Loader } from '@pixi/loaders'; +import { AppLoaderPlugin } from '@pixi/loaders'; import '@pixi/math-extras'; import '@pixi/mixin-cache-as-bitmap'; import '@pixi/mixin-get-child-by-name'; @@ -13,33 +12,12 @@ import '@pixi/polyfill'; import { TilingSpriteRenderer } from '@pixi/sprite-tiling'; import { SpritesheetLoader } from '@pixi/spritesheet'; import { TickerPlugin } from '@pixi/ticker'; -import { TileRenderer } from '@pixi/tilemap'; -import * as utils from '@pixi/utils'; -export * from '@pixi/app'; -export * from '@pixi/canvas-renderer'; -export * from '@pixi/constants'; -export * from '@pixi/core'; -export * from '@pixi/display'; -export * from '@pixi/events'; -export * from '@pixi/extract'; -export * from '@pixi/graphics'; -export * from '@pixi/loaders'; -export * from '@pixi/math'; -export * from '@pixi/runner'; -export * from '@pixi/settings'; -export * from '@pixi/sprite'; -export * from '@pixi/spritesheet'; -export * from '@pixi/text'; -export * from '@pixi/ticker'; -export { utils }; -Renderer.registerPlugin('batch', BatchRenderer); -Renderer.registerPlugin('extract', Extract); -Renderer.registerPlugin('tilingSprite', TilingSpriteRenderer); -Renderer.registerPlugin('tilemap', TileRenderer); -Renderer.registerPlugin('interaction', InteractionManager); - -Loader.registerPlugin(SpritesheetLoader); - -Application.registerPlugin(AppLoaderPlugin); -Application.registerPlugin(TickerPlugin); +extensions.add( + BatchRenderer, + Extract, + TilingSpriteRenderer, + InteractionManager, + SpritesheetLoader, + AppLoaderPlugin, + TickerPlugin); diff --git a/src/nitro/avatar/AvatarImagePartContainer.ts b/src/nitro/avatar/AvatarImagePartContainer.ts index a64d3b09..a632ab79 100644 --- a/src/nitro/avatar/AvatarImagePartContainer.ts +++ b/src/nitro/avatar/AvatarImagePartContainer.ts @@ -1,5 +1,5 @@ -import { AdjustmentFilter } from '@pixi/filter-adjustment'; -import { IActionDefinition, IPartColor } from '../../api'; +import { IActionDefinition, IPartColor } from '../../api'; +import { AdjustmentFilter } from '../../pixi-proxy'; import { AvatarAnimationFrame } from './structure'; export class AvatarImagePartContainer diff --git a/src/nitro/avatar/animation/AvatarDataContainer.ts b/src/nitro/avatar/animation/AvatarDataContainer.ts index 258cbb84..bd6113c0 100644 --- a/src/nitro/avatar/animation/AvatarDataContainer.ts +++ b/src/nitro/avatar/animation/AvatarDataContainer.ts @@ -1,5 +1,5 @@ -import { AdjustmentFilter } from '@pixi/filter-adjustment'; -import { IAssetAnimationAvatar, IAvatarDataContainer } from '../../../api'; +import { IAssetAnimationAvatar, IAvatarDataContainer } from '../../../api'; +import { AdjustmentFilter } from '../../../pixi-proxy'; export class AvatarDataContainer implements IAvatarDataContainer { diff --git a/src/nitro/room/RoomContentLoader.ts b/src/nitro/room/RoomContentLoader.ts index 29884d92..dbfb9e41 100644 --- a/src/nitro/room/RoomContentLoader.ts +++ b/src/nitro/room/RoomContentLoader.ts @@ -541,15 +541,9 @@ export class RoomContentLoader implements IFurnitureDataListener, IRoomContentLo { const spritesheet = new Spritesheet(baseTexture, spritesheetData); - return new Promise((resolve, reject) => - { - spritesheet.parse(() => - { - this.createCollection(data, spritesheet); + await spritesheet.parse(); - return resolve(); - }); - }); + this.createCollection(data, spritesheet); }; if(baseTexture.valid) diff --git a/src/nitro/room/RoomEngine.ts b/src/nitro/room/RoomEngine.ts index c37d4b66..d912d445 100644 --- a/src/nitro/room/RoomEngine.ts +++ b/src/nitro/room/RoomEngine.ts @@ -350,7 +350,7 @@ export class RoomEngine extends NitroManager implements IRoomEngine, IRoomCreato instance.model.setValue(RoomVariableEnum.ROOM_MIN_Y, minY); instance.model.setValue(RoomVariableEnum.ROOM_MAX_Y, maxY); - const seed = ((((minX * 423) + (maxX * 671)) + (minY * 913)) + (maxY * 7509)); + const seed = Math.trunc((minX * 423) + (maxX * 671) + (minY * 913) + (maxY * 7509)); if(roomObject && roomObject.model) roomObject.model.setValue(RoomObjectVariable.ROOM_RANDOM_SEED, seed); } diff --git a/src/nitro/room/object/RoomPlaneParser.ts b/src/nitro/room/object/RoomPlaneParser.ts index 4a791f27..1a070eb1 100644 --- a/src/nitro/room/object/RoomPlaneParser.ts +++ b/src/nitro/room/object/RoomPlaneParser.ts @@ -1168,7 +1168,7 @@ export class RoomPlaneParser private addWall(k: IVector3D, _arg_2: IVector3D, _arg_3: IVector3D, _arg_4: IVector3D, _arg_5: boolean, _arg_6: boolean, _arg_7: boolean): void { this.addPlane(RoomPlaneData.PLANE_WALL, k, _arg_2, _arg_3, [_arg_4]); - //this.addPlane(RoomPlaneData.PLANE_LANDSCAPE, k, _arg_2, _arg_3, [_arg_4]); + this.addPlane(RoomPlaneData.PLANE_LANDSCAPE, k, _arg_2, _arg_3, [_arg_4]); const _local_8: number = (RoomPlaneParser.WALL_THICKNESS * this._wallThicknessMultiplier); const _local_9: number = (RoomPlaneParser.FLOOR_THICKNESS * this._floorThicknessMultiplier); const _local_10: Vector3d = Vector3d.crossProduct(_arg_2, _arg_3); diff --git a/src/nitro/room/object/logic/furniture/FurnitureWindowLogic.ts b/src/nitro/room/object/logic/furniture/FurnitureWindowLogic.ts index c8e1be4c..b4739b20 100644 --- a/src/nitro/room/object/logic/furniture/FurnitureWindowLogic.ts +++ b/src/nitro/room/object/logic/furniture/FurnitureWindowLogic.ts @@ -14,7 +14,7 @@ export class FurnitureWindowLogic extends FurnitureMultiStateLogic if(asset.logic.maskType && (asset.logic.maskType !== '') && (asset.logic.maskType.length > 0)) maskType = asset.logic.maskType; } - this.object.model.setValue(RoomObjectVariable.FURNITURE_USES_PLANE_MASK, 0); + this.object.model.setValue(RoomObjectVariable.FURNITURE_USES_PLANE_MASK, 1); this.object.model.setValue(RoomObjectVariable.FURNITURE_PLANE_MASK_TYPE, maskType); } } diff --git a/src/nitro/room/object/visualization/furniture/FurnitureAnimatedVisualization.ts b/src/nitro/room/object/visualization/furniture/FurnitureAnimatedVisualization.ts index 1d7b310b..2767e5a2 100644 --- a/src/nitro/room/object/visualization/furniture/FurnitureAnimatedVisualization.ts +++ b/src/nitro/room/object/visualization/furniture/FurnitureAnimatedVisualization.ts @@ -8,8 +8,6 @@ export class FurnitureAnimatedVisualization extends FurnitureVisualization public static TYPE: string = RoomObjectVisualizationType.FURNITURE_ANIMATED; public static DEFAULT_ANIMATION_ID: number = 0; - protected _data: FurnitureAnimatedVisualizationData; - protected _state: number; protected _frameIncrease: number; private _animationData: AnimationStateData; @@ -62,7 +60,7 @@ export class FurnitureAnimatedVisualization extends FurnitureVisualization protected getAnimationId(animationData: AnimationStateData): number { - if((this.animationId !== FurnitureAnimatedVisualization.DEFAULT_ANIMATION_ID) && this._data.hasAnimation(this._animationScale, this.animationId)) return this.animationId; + if((this.animationId !== FurnitureAnimatedVisualization.DEFAULT_ANIMATION_ID) && this.data.hasAnimation(this._animationScale, this.animationId)) return this.animationId; return FurnitureAnimatedVisualization.DEFAULT_ANIMATION_ID; } @@ -108,7 +106,7 @@ export class FurnitureAnimatedVisualization extends FurnitureVisualization if(!isNaN(state)) { - const animationId = this._data.getAnimationId(this._animationScale, state); + const animationId = this.data.getAnimationId(this._animationScale, state); this.setAnimation(animationId); } @@ -141,7 +139,7 @@ export class FurnitureAnimatedVisualization extends FurnitureVisualization protected setAnimation(animationId: number): void { - if(!this._data) return; + if(!this.data) return; this.setSubAnimation(this._animationData, animationId, (this._state >= 0)); } @@ -158,11 +156,11 @@ export class FurnitureAnimatedVisualization extends FurnitureVisualization if(animationId !== state) { - if(!this._data.isImmediateChange(this._animationScale, animationId, state)) + if(!this.data.isImmediateChange(this._animationScale, animationId, state)) { let transition = AnimationData.getTransitionFromAnimationId(state); - if(this._data.hasAnimation(this._animationScale, transition)) + if(this.data.hasAnimation(this._animationScale, transition)) { animationData.animationAfterTransitionId = animationId; animationId = transition; @@ -171,7 +169,7 @@ export class FurnitureAnimatedVisualization extends FurnitureVisualization { transition = AnimationData.getTransitionToAnimationId(animationId); - if(this._data.hasAnimation(this._animationScale, transition)) + if(this.data.hasAnimation(this._animationScale, transition)) { animationData.animationAfterTransitionId = animationId; animationId = transition; @@ -185,7 +183,7 @@ export class FurnitureAnimatedVisualization extends FurnitureVisualization { const transition = AnimationData.getTransitionToAnimationId(animationId); - if(this._data.hasAnimation(this._animationScale, transition)) + if(this.data.hasAnimation(this._animationScale, transition)) { animationData.animationAfterTransitionId = animationId; animationId = transition; @@ -198,7 +196,7 @@ export class FurnitureAnimatedVisualization extends FurnitureVisualization { const transition = AnimationData.getTransitionFromAnimationId(state); - if(this._data.hasAnimation(this._animationScale, transition)) + if(this.data.hasAnimation(this._animationScale, transition)) { animationData.animationAfterTransitionId = animationId; animationId = transition; @@ -207,7 +205,7 @@ export class FurnitureAnimatedVisualization extends FurnitureVisualization { const transition = AnimationData.getTransitionToAnimationId(animationId); - if(this._data.hasAnimation(this._animationScale, transition)) + if(this.data.hasAnimation(this._animationScale, transition)) { animationData.animationAfterTransitionId = animationId; animationId = transition; @@ -242,12 +240,12 @@ export class FurnitureAnimatedVisualization extends FurnitureVisualization protected updateAnimation(scale: number): number { - if(!this._data) return 0; + if(!this.data) return 0; if(scale !== this._animationScale) { this._animationScale = scale; - this._animatedLayerCount = this._data.getLayerCount(scale); + this._animatedLayerCount = this.data.getLayerCount(scale); this.resetAllAnimationFrames(); } @@ -284,7 +282,7 @@ export class FurnitureAnimatedVisualization extends FurnitureVisualization const animationId = this.getAnimationId(animationData); let frameCount = animationData.frameCounter; - if(!frameCount) frameCount = this._data.getStartFrame(scale, animationId, this._direction); + if(!frameCount) frameCount = this.data.getStartFrame(scale, animationId, this._direction); frameCount += this.frameIncrease; animationData.frameCounter = frameCount; @@ -322,11 +320,11 @@ export class FurnitureAnimatedVisualization extends FurnitureVisualization if(sequenceId === AnimationFrame.SEQUENCE_NOT_DEFINED) { - frame = this._data.getFrame(scale, animationId, this._direction, layerId, frameCount); + frame = this.data.getFrame(scale, animationId, this._direction, layerId, frameCount); } else { - frame = this._data.getFrameFromSequence(scale, animationId, this._direction, layerId, sequenceId, (frame.activeSequenceOffset + frame.repeats), frameCount); + frame = this.data.getFrameFromSequence(scale, animationId, this._direction, layerId, sequenceId, (frame.activeSequenceOffset + frame.repeats), frameCount); } animationData.setFrame(layerId, frame); @@ -405,4 +403,9 @@ export class FurnitureAnimatedVisualization extends FurnitureVisualization { return this._frameIncrease; } + + protected get data(): FurnitureAnimatedVisualizationData + { + return this._data as FurnitureAnimatedVisualizationData; + } } diff --git a/src/nitro/room/object/visualization/furniture/FurnitureMannequinVisualization.ts b/src/nitro/room/object/visualization/furniture/FurnitureMannequinVisualization.ts index 10e7fdac..db1630b3 100644 --- a/src/nitro/room/object/visualization/furniture/FurnitureMannequinVisualization.ts +++ b/src/nitro/room/object/visualization/furniture/FurnitureMannequinVisualization.ts @@ -6,8 +6,6 @@ export class FurnitureMannequinVisualization extends FurnitureVisualization impl { private static AVATAR_IMAGE_SPRITE_TAG: string = 'avatar_image'; - protected _data: FurnitureMannequinVisualizationData; - private _mannequinScale: number; private _figure: string; private _gender: string; @@ -101,7 +99,7 @@ export class FurnitureMannequinVisualization extends FurnitureVisualization impl { if(!this.avatarExists() || forceUpdate) { - const avatarImage = this._data.createAvatarImage(this._figure, this._mannequinScale, this._gender, this); + const avatarImage = this.data.createAvatarImage(this._figure, this._mannequinScale, this._gender, this); if(avatarImage) { @@ -168,4 +166,9 @@ export class FurnitureMannequinVisualization extends FurnitureVisualization impl { return this._disposed; } + + protected get data(): FurnitureMannequinVisualizationData + { + return this._data as FurnitureMannequinVisualizationData; + } } diff --git a/src/nitro/room/object/visualization/furniture/FurnitureVisualization.ts b/src/nitro/room/object/visualization/furniture/FurnitureVisualization.ts index 98d2f3e1..5b956843 100644 --- a/src/nitro/room/object/visualization/furniture/FurnitureVisualization.ts +++ b/src/nitro/room/object/visualization/furniture/FurnitureVisualization.ts @@ -580,4 +580,9 @@ export class FurnitureVisualization extends RoomObjectSpriteVisualization { return this._direction; } + + protected get data(): FurnitureVisualizationData + { + return this._data; + } } diff --git a/src/nitro/room/object/visualization/pet/PetVisualization.ts b/src/nitro/room/object/visualization/pet/PetVisualization.ts index e484f622..e12279ab 100644 --- a/src/nitro/room/object/visualization/pet/PetVisualization.ts +++ b/src/nitro/room/object/visualization/pet/PetVisualization.ts @@ -19,8 +19,6 @@ export class PetVisualization extends FurnitureAnimatedVisualization private static GESTURE_ANIMATION_INDEX: number = 1; private static ANIMATION_INDEX_COUNT: number = 2; - protected _data: PetVisualizationData; - private _posture: string; private _gesture: string; private _isSleeping: boolean; @@ -48,8 +46,6 @@ export class PetVisualization extends FurnitureAnimatedVisualization { super(); - this._data = null; - this._posture = ''; this._gesture = ''; this._isSleeping = false; @@ -195,7 +191,7 @@ export class PetVisualization extends FurnitureAnimatedVisualization const headDirection = model.getValue(RoomObjectVariable.HEAD_DIRECTION); - if(!isNaN(headDirection) && this._data.isAllowedToTurnHead) + if(!isNaN(headDirection) && this.data.isAllowedToTurnHead) { this._headDirection = headDirection; } @@ -253,22 +249,22 @@ export class PetVisualization extends FurnitureAnimatedVisualization protected setPostureAndGesture(posture: string, gesture: string): void { - if(!this._data) return; + if(!this.data) return; if(posture !== this._posture) { this._posture = posture; - this.setAnimationForIndex(PetVisualization.POSTURE_ANIMATION_INDEX, this._data.postureToAnimation(this._scale, posture)); + this.setAnimationForIndex(PetVisualization.POSTURE_ANIMATION_INDEX, this.data.postureToAnimation(this._scale, posture)); } - if(this._data.getGestureDisabled(this._scale, posture)) gesture = null; + if(this.data.getGestureDisabled(this._scale, posture)) gesture = null; if(gesture !== this._gesture) { this._gesture = gesture; - this.setAnimationForIndex(PetVisualization.GESTURE_ANIMATION_INDEX, this._data.gestureToAnimation(this._scale, gesture)); + this.setAnimationForIndex(PetVisualization.GESTURE_ANIMATION_INDEX, this.data.gestureToAnimation(this._scale, gesture)); } } @@ -431,16 +427,16 @@ export class PetVisualization extends FurnitureAnimatedVisualization protected getLayerZOffset(scale: number, direction: number, layerId: number): number { - if(!this._data) return LayerData.DEFAULT_ZOFFSET; + if(!this.data) return LayerData.DEFAULT_ZOFFSET; - return this._data.getLayerZOffset(scale, this.getDirection(scale, layerId), layerId); + return this.data.getLayerZOffset(scale, this.getDirection(scale, layerId), layerId); } private getDirection(scale: number, layerId: number): number { if(!this.isHeadSprite(layerId)) return this._direction; - return this._data.getValidDirection(scale, this._headDirection); + return this.data.getValidDirection(scale, this._headDirection); } protected getFrameNumber(scale: number, layerId: number): number @@ -468,8 +464,8 @@ export class PetVisualization extends FurnitureAnimatedVisualization { if(this._headSprites[layerId] === undefined) { - const isHead = (this._data.getLayerTag(this._scale, DirectionData.USE_DEFAULT_DIRECTION, layerId) === PetVisualization.HEAD); - const isHair = (this._data.getLayerTag(this._scale, DirectionData.USE_DEFAULT_DIRECTION, layerId) === PetVisualization.HAIR); + const isHead = (this.data.getLayerTag(this._scale, DirectionData.USE_DEFAULT_DIRECTION, layerId) === PetVisualization.HEAD); + const isHair = (this.data.getLayerTag(this._scale, DirectionData.USE_DEFAULT_DIRECTION, layerId) === PetVisualization.HAIR); if(isHead || isHair) this._headSprites[layerId] = true; else this._headSprites[layerId] = false; @@ -484,7 +480,7 @@ export class PetVisualization extends FurnitureAnimatedVisualization { if(layerId < (this.totalSprites - (1 + PetVisualization.ADDITIONAL_SPRITE_COUNT))) { - const tag = this._data.getLayerTag(this._scale, DirectionData.USE_DEFAULT_DIRECTION, layerId); + const tag = this.data.getLayerTag(this._scale, DirectionData.USE_DEFAULT_DIRECTION, layerId); if(((tag && (tag.length > 0)) && (tag !== PetVisualization.HEAD)) && (tag !== PetVisualization.HAIR)) { @@ -508,7 +504,7 @@ export class PetVisualization extends FurnitureAnimatedVisualization { if(this._saddleSprites[layerId] === undefined) { - if(this._data.getLayerTag(this._scale, DirectionData.USE_DEFAULT_DIRECTION, layerId) === PetVisualization.SADDLE) + if(this.data.getLayerTag(this._scale, DirectionData.USE_DEFAULT_DIRECTION, layerId) === PetVisualization.SADDLE) { this._saddleSprites[layerId] = true; } @@ -583,9 +579,9 @@ export class PetVisualization extends FurnitureAnimatedVisualization part = part.split('@')[0]; - posture = this._data.animationToPosture(scale, (parseInt(part) / 100), false); + posture = this.data.animationToPosture(scale, (parseInt(part) / 100), false); - if(!posture) posture = this._data.getGestureForAnimationId(scale, (parseInt(part) / 100)); + if(!posture) posture = this.data.getGestureForAnimationId(scale, (parseInt(part) / 100)); } return posture; @@ -595,4 +591,9 @@ export class PetVisualization extends FurnitureAnimatedVisualization { return GetAssetManager().getTexture(name); } + + protected get data(): PetVisualizationData + { + return this._data as PetVisualizationData; + } } diff --git a/src/nitro/room/object/visualization/room/RoomPlane.ts b/src/nitro/room/object/visualization/room/RoomPlane.ts index 56de6062..9656954a 100644 --- a/src/nitro/room/object/visualization/room/RoomPlane.ts +++ b/src/nitro/room/object/visualization/room/RoomPlane.ts @@ -1,14 +1,14 @@ -import { RenderTexture, Resource, Texture } from '@pixi/core'; -import { Graphics } from '@pixi/graphics'; -import { Matrix, Point, Rectangle } from '@pixi/math'; +import { Renderer, RenderTexture, Resource, Texture } from '@pixi/core'; +import { Matrix, Point } from '@pixi/math'; +import { Sprite } from '@pixi/sprite'; import { IRoomGeometry, IRoomPlane, IVector3D, Vector3d } from '../../../../../api'; -import { NitroRenderTexture, TextureUtils } from '../../../../../pixi-proxy'; +import { PixiApplicationProxy, RoomTextureUtils, TextureUtils } from '../../../../../pixi-proxy'; +import { ColorConverter } from '../../../../../room'; import { PlaneMaskManager } from './mask'; import { PlaneDrawingData } from './PlaneDrawingData'; -import { IPlaneRasterizer, PlaneVisualizationLayer } from './rasterizer'; +import { IPlaneRasterizer } from './rasterizer'; import { RoomPlaneBitmapMask } from './RoomPlaneBitmapMask'; import { RoomPlaneRectangleMask } from './RoomPlaneRectangleMask'; -import { RoomVisualization } from './RoomVisualization'; import { PlaneBitmapData, Randomizer } from './utils'; export class RoomPlane implements IRoomPlane @@ -31,8 +31,7 @@ export class RoomPlane implements IRoomPlane private _geometryUpdateId: number; private _type: number; private _isVisible: boolean; - private _bitmapTexture: NitroRenderTexture; - private _bitmapData: Graphics; + private _bitmapData: RenderTexture; private _hasTexture: boolean; private _offset: Point; private _relativeDepth: number; @@ -51,7 +50,8 @@ export class RoomPlane implements IRoomPlane private _bitmapMasks: RoomPlaneBitmapMask[]; private _rectangleMasks: RoomPlaneRectangleMask[]; private _maskChanged: boolean; - private _maskBitmapData: Graphics; + private _maskBitmapData: RenderTexture; + private _maskPixels: Uint8Array; private _bitmapMasksOld: RoomPlaneBitmapMask[]; private _rectangleMasksOld: RoomPlaneRectangleMask[]; private _cornerA: Vector3d; @@ -128,10 +128,9 @@ export class RoomPlane implements IRoomPlane this._uniqueId = ++RoomPlane._uniqueIdCounter; } - private static blend(k: number, _arg_2: number): number + private static blend(a: number, b: number): number { - return 0; - //return Canvas.colorize(_arg_2, (k | 0xFF000000)) & 0xFFFFFF; + return ColorConverter.colorize(b, (a | 0xFF000000)) & 0xFFFFFF; } public set canBeVisible(k: boolean) @@ -153,16 +152,14 @@ export class RoomPlane implements IRoomPlane { if(!this.visible || !this._bitmapData) return null; - let texture: RenderTexture = RoomVisualization.getTextureCache(this._bitmapData); + return this._bitmapData; + } - if(!texture) - { - texture = TextureUtils.generateTexture(this._bitmapData, new Rectangle(0, 0, this._width, this._height)); + public get maskBitmapData(): RenderTexture + { + if(!this.visible || !this._maskBitmapData) return null; - RoomVisualization.addTextureCache(this._bitmapData, texture); - } - - return texture; + return this._maskBitmapData; } public get visible(): boolean @@ -252,7 +249,7 @@ export class RoomPlane implements IRoomPlane { if(this._bitmapData) { - this._bitmapData.destroy(); + this._bitmapData.destroy(true); this._bitmapData = null; } @@ -263,7 +260,7 @@ export class RoomPlane implements IRoomPlane { if(!bitmap) continue; - if(bitmap.bitmap) bitmap.bitmap.destroy(); + if(bitmap.texture) bitmap.texture.destroy(); bitmap.dispose(); } @@ -284,10 +281,11 @@ export class RoomPlane implements IRoomPlane this._cornerD = null; this._bitmapMasks = null; this._rectangleMasks = null; + this._maskPixels = null; if(this._maskBitmapData) { - this._maskBitmapData.destroy(); + this._maskBitmapData.destroy(true); this._maskBitmapData = null; } @@ -322,7 +320,7 @@ export class RoomPlane implements IRoomPlane return true; } - private resetTextureCache(k: Graphics = null): void + private resetTextureCache(k: RenderTexture = null): void { if(this._textures && this._textures.size) { @@ -364,75 +362,68 @@ export class RoomPlane implements IRoomPlane return false; } - private getTexture(k: IRoomGeometry, _arg_2: number): Graphics + private getTexture(geometry: IRoomGeometry, timeSinceStartMs: number): RenderTexture { - if(!k) return null; + if(!geometry) return null; - let _local_3: PlaneBitmapData = null; + let bitmapData: PlaneBitmapData = null; - if(this.needsNewTexture(k, _arg_2)) + if(this.needsNewTexture(geometry, timeSinceStartMs)) { - const _local_4 = this.getTextureIdentifier(k.scale); - const _local_5 = (this._leftSide.length * k.scale); - const _local_6 = (this._rightSide.length * k.scale); - const _local_7 = k.getCoordinatePosition(this._normal); + const identifier = this.getTextureIdentifier(geometry.scale); + const width = this._leftSide.length * geometry.scale; + const height = this._rightSide.length * geometry.scale; + const normal = geometry.getCoordinatePosition(this._normal); if(this._activeTexture) { - _local_3 = this._activeTexture; + bitmapData = this._activeTexture; } else { - _local_3 = this._textures.get(_local_4); + bitmapData = this._textures.get(identifier); } - let _local_8: Graphics = null; + let texture: RenderTexture = null; - if(_local_3) _local_8 = _local_3.bitmap; + if(bitmapData) texture = bitmapData.texture; if(this._rasterizer) { - _local_3 = this._rasterizer.render(_local_8, this._id, _local_5, _local_6, k.scale, _local_7, this._hasTexture, this._textureOffsetX, this._textureOffsetY, this._textureMaxX, this._textureMaxY, _arg_2); + bitmapData = this._rasterizer.render(this._uniqueId.toString(), texture, this._id, width, height, geometry.scale, normal, this._hasTexture, this._textureOffsetX, this._textureOffsetY, this._textureMaxX, this._textureMaxY, timeSinceStartMs); - if(_local_3) - { - if(_local_8 && (_local_3.bitmap !== _local_8)) _local_8.destroy(); - } + if(bitmapData && texture && (bitmapData?.texture !== texture)) texture.destroy(true); } else { - const _local_9 = new Graphics(); + const renderTexture = RoomTextureUtils.createAndFillRenderTexture(width, height); - _local_9.beginFill(0xFFFFFF); - _local_9.drawRect(0, 0, _local_5, _local_6); - _local_9.endFill(); - - _local_3 = new PlaneBitmapData(_local_9, -1); + bitmapData = new PlaneBitmapData(renderTexture, -1); } - if(_local_3) + if(bitmapData) { - this.updateMask(_local_3.bitmap, k); - this.cacheTexture(_local_4, _local_3); + this.updateMask(bitmapData.texture, geometry); + this.cacheTexture(identifier, bitmapData); } } else { if(this._activeTexture) { - _local_3 = this._activeTexture; + bitmapData = this._activeTexture; } else { - _local_3 = this._textures.get(this.getTextureIdentifier(k.scale)); + bitmapData = this._textures.get(this.getTextureIdentifier(geometry.scale)); } } - if(_local_3) + if(bitmapData) { - this._activeTexture = _local_3; + this._activeTexture = bitmapData; - return _local_3.bitmap; + return bitmapData.texture; } return null; @@ -442,7 +433,7 @@ export class RoomPlane implements IRoomPlane { if(!this._useMask) return null; - const _local_5 = new PlaneDrawingData(); + const drawingData = new PlaneDrawingData(); const index = 0; @@ -465,18 +456,17 @@ export class RoomPlane implements IRoomPlane if(asset) { - const _local_3 = (this._maskBitmapData.width * (1 - (mask.leftSideLoc / this._leftSide.length))); - const _local_4 = (this._maskBitmapData.height * (1 - (mask.rightSideLoc / this._rightSide.length))); - const _local_11 = new Point((_local_3 + asset.offsetX), (_local_4 + asset.offsetY)); + const x = (this._maskBitmapData.width * (1 - (mask.leftSideLoc / this._leftSide.length))); + const y = (this._maskBitmapData.height * (1 - (mask.rightSideLoc / this._rightSide.length))); - _local_5.addMask(assetName, _local_11, asset.flipH, asset.flipV); + drawingData.addMask(assetName, new Point((x + asset.offsetX), (y + asset.offsetY)), asset.flipH, asset.flipV); } } } } } - return _local_5; + return drawingData; } private screenWidth(k: IRoomGeometry): number @@ -496,54 +486,43 @@ export class RoomPlane implements IRoomPlane const maskData = this.resolveMasks(geometry); const layers = this._rasterizer.getLayers(this._id); - let i = 0; - - while(i < layers.length) + for(const layer of layers) { - const layer = (layers[i] as PlaneVisualizationLayer); - - if(layer) + if(this._hasTexture && layer.getMaterial()) { - if(this._hasTexture && layer.getMaterial()) + const normal = geometry.getCoordinatePosition(this._normal); + const cellMatrix = layer.getMaterial().getMaterialCellMatrix(normal); + const data = new PlaneDrawingData(maskData, RoomPlane.blend(this._color, layer.getColor()), cellMatrix.isBottomAligned()); + + Randomizer.setSeed(this._randomSeed); + + for(const column of cellMatrix.getColumns(this.screenWidth(geometry))) { - const normal = geometry.getCoordinatePosition(this._normal); - const cm = layer.getMaterial().getMaterialCellMatrix(normal); - //const data = new PlaneDrawingData(maskData, blend(this._color, layer.getColor()), cm.isBottomAligned()); - const data = new PlaneDrawingData(maskData, this._color, cm.isBottomAligned()); + const assetNames: string[] = []; - Randomizer.setSeed(this._randomSeed); - - for(const column of cm.getColumns(this.screenWidth(geometry))) + for(const cell of column.getCells()) { - const assetNames: string[] = []; + const name = cell.getAssetName(normal); - for(const cell of column.getCells()) - { - const name = cell.getAssetName(normal); - - if(name) assetNames.push(name); - } - - if(assetNames.length > 0) - { - if(!column.isRepeated()) assetNames.push(''); - - data.addAssetColumn(assetNames); - } + if(name) assetNames.push(name); } - if(data.assetNameColumns.length > 0) drawingDatas.push(data); - } - else - { - //data = new PlaneDrawingData(maskData, blend(this._color, layer.getColor())); - const data = new PlaneDrawingData(maskData, this._color); + if(assetNames.length > 0) + { + if(!column.isRepeated()) assetNames.push(''); - drawingDatas.push(data); + data.addAssetColumn(assetNames); + } } + + if(data.assetNameColumns.length > 0) drawingDatas.push(data); } + else + { + const data = new PlaneDrawingData(maskData, RoomPlane.blend(this._color, layer.getColor())); - i++; + drawingDatas.push(data); + } } if(!drawingDatas.length) drawingDatas.push(new PlaneDrawingData(maskData, this._color)); @@ -636,31 +615,42 @@ export class RoomPlane implements IRoomPlane { if(this._bitmapData) { - this._bitmapData.destroy(); + if((this._width !== this._bitmapData.width) || (this._height !== this._bitmapData.height)) + { + this._bitmapData.destroy(); - this._bitmapData = null; + this._bitmapData = null; - if((this._width < 1) || (this._height < 1)) return true; + if((this._width < 1) || (this._height < 1)) return true; + + this._bitmapData = RoomTextureUtils.createAndFillRenderTexture(this._width, this._height); + } + else + { + if((this._width < 1) || (this._height < 1)) + { + this._bitmapData.destroy(); + + this._bitmapData = null; + + return true; + } + + TextureUtils.clearAndFillRenderTexture(this._bitmapData); + } } else { if((this._width < 1) || (this._height < 1)) return false; + + this._bitmapData = RoomTextureUtils.createAndFillRenderTexture(this._width, this._height); } - const graphic = new Graphics(); - - graphic.beginFill(0xFFFFFF, 0); - graphic.drawRect(0, 0, this._width, this._height); - graphic.endFill(); - - this._bitmapData = graphic; - if(!this._bitmapData) return false; } else { - //this._bitmapData.lock(); - //this._bitmapData.fillRect(this._bitmapData.rect, 0xFFFFFF); + TextureUtils.clearAndFillRenderTexture(this._bitmapData); } Randomizer.setSeed(this._randomSeed); @@ -684,13 +674,13 @@ export class RoomPlane implements IRoomPlane return false; } - private updateCorners(k: IRoomGeometry): void + private updateCorners(geometry: IRoomGeometry): void { - this._cornerA.assign(k.getScreenPosition(this._location)); - this._cornerB.assign(k.getScreenPosition(Vector3d.sum(this._location, this._rightSide))); - this._cornerC.assign(k.getScreenPosition(Vector3d.sum(Vector3d.sum(this._location, this._leftSide), this._rightSide))); - this._cornerD.assign(k.getScreenPosition(Vector3d.sum(this._location, this._leftSide))); - this._offset = k.getScreenPoint(this._origin); + this._cornerA.assign(geometry.getScreenPosition(this._location)); + this._cornerB.assign(geometry.getScreenPosition(Vector3d.sum(this._location, this._rightSide))); + this._cornerC.assign(geometry.getScreenPosition(Vector3d.sum(Vector3d.sum(this._location, this._leftSide), this._rightSide))); + this._cornerD.assign(geometry.getScreenPosition(Vector3d.sum(this._location, this._leftSide))); + this._offset = geometry.getScreenPoint(this._origin); this._cornerA.x = Math.round(this._cornerA.x); this._cornerA.y = Math.round(this._cornerA.y); this._cornerB.x = Math.round(this._cornerB.x); @@ -701,76 +691,74 @@ export class RoomPlane implements IRoomPlane this._cornerD.y = Math.round(this._cornerD.y); this._offset.x = Math.round(this._offset.x); this._offset.y = Math.round(this._offset.y); - const _local_2: number = Math.min(this._cornerA.x, this._cornerB.x, this._cornerC.x, this._cornerD.x); - let _local_3: number = Math.max(this._cornerA.x, this._cornerB.x, this._cornerC.x, this._cornerD.x); - const _local_4: number = Math.min(this._cornerA.y, this._cornerB.y, this._cornerC.y, this._cornerD.y); - let _local_5: number = Math.max(this._cornerA.y, this._cornerB.y, this._cornerC.y, this._cornerD.y); - _local_3 = (_local_3 - _local_2); - this._offset.x = (this._offset.x - _local_2); - this._cornerA.x = (this._cornerA.x - _local_2); - this._cornerB.x = (this._cornerB.x - _local_2); - this._cornerC.x = (this._cornerC.x - _local_2); - this._cornerD.x = (this._cornerD.x - _local_2); - _local_5 = (_local_5 - _local_4); - this._offset.y = (this._offset.y - _local_4); - this._cornerA.y = (this._cornerA.y - _local_4); - this._cornerB.y = (this._cornerB.y - _local_4); - this._cornerC.y = (this._cornerC.y - _local_4); - this._cornerD.y = (this._cornerD.y - _local_4); - this._width = _local_3; - this._height = _local_5; + + const minX = Math.min(this._cornerA.x, this._cornerB.x, this._cornerC.x, this._cornerD.x); + const maxX = Math.max(this._cornerA.x, this._cornerB.x, this._cornerC.x, this._cornerD.x) - minX; + const minY = Math.min(this._cornerA.y, this._cornerB.y, this._cornerC.y, this._cornerD.y); + const maxY = Math.max(this._cornerA.y, this._cornerB.y, this._cornerC.y, this._cornerD.y) - minY; + + this._offset.x = (this._offset.x - minX); + this._cornerA.x = (this._cornerA.x - minX); + this._cornerB.x = (this._cornerB.x - minX); + this._cornerC.x = (this._cornerC.x - minX); + this._cornerD.x = (this._cornerD.x - minX); + + this._offset.y = (this._offset.y - minY); + this._cornerA.y = (this._cornerA.y - minY); + this._cornerB.y = (this._cornerB.y - minY); + this._cornerC.y = (this._cornerC.y - minY); + this._cornerD.y = (this._cornerD.y - minY); + + this._width = maxX; + this._height = maxY; } - private renderTexture(k: IRoomGeometry, _arg_2: Graphics): void + private getMatrixForDimensions(width: number, height: number): Matrix + { + let _local_3: number = (this._cornerD.x - this._cornerC.x); + let _local_4: number = (this._cornerD.y - this._cornerC.y); + let _local_5: number = (this._cornerB.x - this._cornerC.x); + let _local_6: number = (this._cornerB.y - this._cornerC.y); + + if((this._type === RoomPlane.TYPE_WALL) || (this._type === RoomPlane.TYPE_LANDSCAPE)) + { + if(Math.abs((_local_5 - width)) <= 1) _local_5 = width; + + if(Math.abs((_local_6 - width)) <= 1) _local_6 = width; + + if(Math.abs((_local_3 - height)) <= 1) _local_3 = height; + + if(Math.abs((_local_4 - height)) <= 1) _local_4 = height; + } + + const xScale: number = (_local_5 / width); + const ySkew: number = (_local_6 / width); + const xSkew: number = (_local_3 / height); + const yScale: number = (_local_4 / height); + + const matrix = new Matrix(xScale, ySkew, xSkew, yScale); + + matrix.translate(this._cornerC.x, this._cornerC.y); + + return matrix; + } + + private renderTexture(geometry: IRoomGeometry, _arg_2: RenderTexture): void { if(((((((this._cornerA == null) || (this._cornerB == null)) || (this._cornerC == null)) || (this._cornerD == null)) || (_arg_2 == null)) || (this._bitmapData == null))) { return; } - let _local_3: number = (this._cornerD.x - this._cornerC.x); - let _local_4: number = (this._cornerD.y - this._cornerC.y); - let _local_5: number = (this._cornerB.x - this._cornerC.x); - let _local_6: number = (this._cornerB.y - this._cornerC.y); - if(((this._type == RoomPlane.TYPE_WALL) || (this._type == RoomPlane.TYPE_LANDSCAPE))) - { - if(Math.abs((_local_5 - _arg_2.width)) <= 1) - { - _local_5 = _arg_2.width; - } - if(Math.abs((_local_6 - _arg_2.width)) <= 1) - { - _local_6 = _arg_2.width; - } - if(Math.abs((_local_3 - _arg_2.height)) <= 1) - { - _local_3 = _arg_2.height; - } - if(Math.abs((_local_4 - _arg_2.height)) <= 1) - { - _local_4 = _arg_2.height; - } - } - const _local_7: number = (_local_5 / _arg_2.width); - const _local_8: number = (_local_6 / _arg_2.width); - const _local_9: number = (_local_3 / _arg_2.height); - const _local_10: number = (_local_4 / _arg_2.height); - const matrix = new Matrix(); - matrix.a = _local_7; - matrix.b = _local_8; - matrix.c = _local_9; - matrix.d = _local_10; - matrix.translate(this._cornerC.x, this._cornerC.y); - this.draw(_arg_2, matrix); + this.draw(_arg_2, this.getMatrixForDimensions(_arg_2.width, _arg_2.height)); } - private draw(k: Graphics, matrix: Matrix): void + private draw(k: RenderTexture, matrix: Matrix): void { - const clone = k.clone(); + //k.baseTexture.mipmap = MIPMAP_MODES.OFF; + //k.baseTexture.scaleMode = SCALE_MODES.LINEAR; - clone.transform.setFromMatrix(matrix); - - this._bitmapData = clone; + TextureUtils.writeToRenderTexture(new Sprite(k), this._bitmapData, true, matrix); } public resetBitmapMasks(): void @@ -781,25 +769,18 @@ export class RoomPlane implements IRoomPlane this._bitmapMasks = []; } - public addBitmapMask(k: string, _arg_2: number, _arg_3: number): boolean + public addBitmapMask(maskType: string, leftSideLoc: number, rightSideLoc: number): boolean { if(!this._useMask) return false; - let _local_5 = 0; - - while(_local_5 < this._bitmapMasks.length) + for(const mask of this._bitmapMasks) { - const mask = this._bitmapMasks[_local_5]; + if(!mask) continue; - if(mask) - { - if((((mask.type === k) && (mask.leftSideLoc === _arg_2)) && (mask.rightSideLoc === _arg_3))) return false; - } - - _local_5++; + if((((mask.type === maskType) && (mask.leftSideLoc === leftSideLoc)) && (mask.rightSideLoc === rightSideLoc))) return false; } - const mask = new RoomPlaneBitmapMask(k, _arg_2, _arg_3); + const mask = new RoomPlaneBitmapMask(maskType, leftSideLoc, rightSideLoc); this._bitmapMasks.push(mask); this._maskChanged = true; @@ -841,8 +822,7 @@ export class RoomPlane implements IRoomPlane { if(!this._maskChanged) return; - let _local_3 = true; - let _local_6: boolean; + let maskChanged = true; if(this._bitmapMasks.length === this._bitmapMasksOld.length) { @@ -850,7 +830,7 @@ export class RoomPlane implements IRoomPlane { if(!mask) continue; - _local_6 = false; + let _local_6 = false; for(const plane of this._bitmapMasksOld) { @@ -866,7 +846,7 @@ export class RoomPlane implements IRoomPlane if(!_local_6) { - _local_3 = false; + maskChanged = false; break; } @@ -874,22 +854,22 @@ export class RoomPlane implements IRoomPlane } else { - _local_3 = false; + maskChanged = false; } - if(this._rectangleMasks.length > this._rectangleMasksOld.length) _local_3 = false; + if(this._rectangleMasks.length > this._rectangleMasksOld.length) maskChanged = false; - if(_local_3) this._maskChanged = false; + if(maskChanged) this._maskChanged = false; } - private updateMask(texture: Graphics, geometry: IRoomGeometry): void + private updateMask(canvas: RenderTexture, geometry: IRoomGeometry): void { - if(!texture || !geometry) return; + if(!canvas || !geometry) return; if(((!this._useMask) || ((!this._bitmapMasks.length && !this._rectangleMasks.length) && !this._maskChanged)) || !this._maskManager) return; - const width = texture.width; - const height = texture.height; + const width = canvas.width; + const height = canvas.height; this.updateMaskChangeStatus(); @@ -897,18 +877,11 @@ export class RoomPlane implements IRoomPlane { if(this._maskBitmapData) { - this._maskBitmapData.destroy(); + this._maskBitmapData.destroy(true); this._maskBitmapData = null; } - const graphic = new Graphics(); - - graphic - .beginFill(0xFFFFFF, 0) - .drawRect(0, 0, width, height) - .endFill(); - - this._maskBitmapData = graphic; + this._maskBitmapData = RoomTextureUtils.createAndFillRenderTexture(width, height); this._maskChanged = true; } @@ -917,15 +890,9 @@ export class RoomPlane implements IRoomPlane this._bitmapMasksOld = []; this._rectangleMasksOld = []; - if(this._maskBitmapData) - { - this._maskBitmapData - .beginFill(0xFFFFFF, 0) - .drawRect(0, 0, width, height) - .endFill(); - } + if(this._maskBitmapData) TextureUtils.clearAndFillRenderTexture(this._maskBitmapData); - this.resetTextureCache(texture); + this.resetTextureCache(canvas); const normal = geometry.getCoordinatePosition(this._normal); @@ -965,10 +932,10 @@ export class RoomPlane implements IRoomPlane const wd = ((this._maskBitmapData.width * rectMask.leftSideLength) / this._leftSide.length); const ht = ((this._maskBitmapData.height * rectMask.rightSideLength) / this._rightSide.length); - this._maskBitmapData + /* this._maskBitmapData .beginFill(0xFF0000) .drawRect((posX - wd), (posY - ht), wd, ht) - .endFill(); + .endFill(); */ this._rectangleMasksOld.push(new RoomPlaneRectangleMask(rectMask.leftSideLength, rectMask.rightSideLoc, rectMask.leftSideLength, rectMask.rightSideLength)); } @@ -976,45 +943,36 @@ export class RoomPlane implements IRoomPlane i++; } + this._maskPixels = TextureUtils.getPixels(this._maskBitmapData); + this._maskChanged = false; } - this.combineTextureMask(texture, this._maskBitmapData); + this.combineTextureMask(canvas, this._maskPixels); } - private combineTextureMask(texture: Graphics, mask: Graphics): void + private combineTextureMask(canvas: RenderTexture, maskPixels: Uint8Array): void { - if(!texture || !mask) return; + if(!canvas || !maskPixels) return; - const maskCanvas = TextureUtils.generateCanvas(mask); - const textureCanvas = TextureUtils.generateCanvas(texture); - const textureCtx = textureCanvas.getContext('2d'); + const canvasPixels = TextureUtils.getPixels(canvas); - textureCtx.drawImage(maskCanvas, 0, 0); - - const textureImageData = textureCtx.getImageData(0, 0, textureCanvas.width, textureCanvas.height); - const data = textureImageData.data; - - for(let i = 0; i < data.length; i += 4) + for(let i = 0; i < canvasPixels.length; i += 4) { - const red = data[i]; - const green = data[i + 1]; - const blue = data[i + 2]; - const alpha = data[i + 3]; + const maskRed = maskPixels[i]; + const maskGreen = maskPixels[i + 1]; + const maskBlue = maskPixels[i + 2]; + const maskAlpha = maskPixels[i + 3]; - if(!red && !green && !blue) data[i + 3] = 0; + if(!maskRed && !maskGreen && !maskBlue) canvasPixels[i + 3] = 0; } - textureCtx.putImageData(textureImageData, 0, 0); + const canvaGLTexture = canvas.baseTexture._glTextures['1']?.texture; + const gl = (PixiApplicationProxy.instance.renderer as Renderer)?.gl; - const newTexture = Texture.from(textureCanvas); + if(!canvaGLTexture || !gl) return; - if(!newTexture) return; - - texture - .clear() - .beginTextureFill({ texture: newTexture }) - .drawRect(0, 0, newTexture.width, newTexture.height) - .endFill(); + gl.bindTexture(gl.TEXTURE_2D, canvaGLTexture); + gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, canvas.width, canvas.height, 0, gl.RGBA, gl.UNSIGNED_BYTE, canvasPixels); } } diff --git a/src/nitro/room/object/visualization/room/RoomPlaneBitmapMask.ts b/src/nitro/room/object/visualization/room/RoomPlaneBitmapMask.ts index f2164042..44f583cc 100644 --- a/src/nitro/room/object/visualization/room/RoomPlaneBitmapMask.ts +++ b/src/nitro/room/object/visualization/room/RoomPlaneBitmapMask.ts @@ -4,11 +4,11 @@ private _leftSideLoc: number; private _rightSideLoc: number; - constructor(k: string, _arg_2: number, _arg_3: number) + constructor(maskType: string, leftSideLoc: number, rightSideLoc: number) { - this._type = k; - this._leftSideLoc = _arg_2; - this._rightSideLoc = _arg_3; + this._type = maskType; + this._leftSideLoc = leftSideLoc; + this._rightSideLoc = rightSideLoc; } public get type(): string diff --git a/src/nitro/room/object/visualization/room/RoomVisualization.ts b/src/nitro/room/object/visualization/room/RoomVisualization.ts index daf0093d..992939a3 100644 --- a/src/nitro/room/object/visualization/room/RoomVisualization.ts +++ b/src/nitro/room/object/visualization/room/RoomVisualization.ts @@ -1,7 +1,8 @@ -import { RenderTexture, Resource, Texture } from '@pixi/core'; import { Rectangle } from '@pixi/math'; -import { AdvancedMap, AlphaTolerance, IObjectVisualizationData, IPlaneVisualization, IRoomGeometry, IRoomObjectModel, IRoomObjectSprite, IRoomPlane, RoomObjectSpriteType, RoomObjectVariable, Vector3d } from '../../../../../api'; +import { AlphaTolerance, IObjectVisualizationData, IPlaneVisualization, IRoomGeometry, IRoomObjectModel, IRoomObjectSprite, IRoomPlane, RoomObjectSpriteType, RoomObjectVariable, Vector3d } from '../../../../../api'; +import { RoomTextureUtils } from '../../../../../pixi-proxy'; import { RoomObjectSpriteVisualization } from '../../../../../room'; +import { ToInt32 } from '../../../../utils'; import { RoomMapData } from '../../RoomMapData'; import { RoomMapMaskData } from '../../RoomMapMaskData'; import { RoomPlaneBitmapMaskData } from '../../RoomPlaneBitmapMaskData'; @@ -13,10 +14,6 @@ import { RoomVisualizationData } from './RoomVisualizationData'; export class RoomVisualization extends RoomObjectSpriteVisualization implements IPlaneVisualization { - public static LAST_VISUALIZATION: RoomVisualization = null; - - public static RENDER_TEXTURE_CACHE: Map> = new Map(); - public static FLOOR_COLOR: number = 0xFFFFFF; public static FLOOR_COLOR_LEFT: number = 0xDDDDDD; public static FLOOR_COLOR_RIGHT: number = 0xBBBBBB; @@ -102,31 +99,6 @@ export class RoomVisualization extends RoomObjectSpriteVisualization implements this._typeVisibility[RoomPlane.TYPE_LANDSCAPE] = true; } - public static getTextureCache(key: any): RenderTexture - { - const existing = RoomVisualization.RENDER_TEXTURE_CACHE.get(RoomVisualization.LAST_VISUALIZATION); - - if(!existing) return null; - - return existing.getValue(key); - } - - public static addTextureCache(key: any, value: RenderTexture): void - { - if(!RoomVisualization.LAST_VISUALIZATION) return; - - let existing = RoomVisualization.RENDER_TEXTURE_CACHE.get(RoomVisualization.LAST_VISUALIZATION); - - if(!existing) - { - existing = new AdvancedMap(); - - RoomVisualization.RENDER_TEXTURE_CACHE.set(RoomVisualization.LAST_VISUALIZATION, existing); - } - - existing.add(key, value); - } - public initialize(data: IObjectVisualizationData): boolean { if(!(data instanceof RoomVisualizationData)) return false; @@ -171,19 +143,7 @@ export class RoomVisualization extends RoomObjectSpriteVisualization implements this._data = null; } - const existingTextureCache = RoomVisualization.RENDER_TEXTURE_CACHE.get(this); - - if(existingTextureCache) - { - for(const texture of existingTextureCache.getValues()) - { - texture.destroy(true); - } - - existingTextureCache.dispose(); - - RoomVisualization.RENDER_TEXTURE_CACHE.delete(this); - } + RoomTextureUtils.clearCache(); } protected reset(): void @@ -202,14 +162,6 @@ export class RoomVisualization extends RoomObjectSpriteVisualization implements { if(!this.object || !geometry) return; - RoomVisualization.LAST_VISUALIZATION = this; - - let removeCount = 0; - - const existing = RoomVisualization.RENDER_TEXTURE_CACHE.get(RoomVisualization.LAST_VISUALIZATION); - - if(existing) removeCount = existing.length; - const geometryUpdate = this.updateGeometry(geometry); const objectModel = this.object.model; @@ -219,28 +171,7 @@ export class RoomVisualization extends RoomObjectSpriteVisualization implements if(this.updateHole(objectModel)) needsUpdate = true; - if(this.initializeRoomPlanes()) - { - if(existing && removeCount) - { - setTimeout(() => - { - while(removeCount) - { - const texture = existing.getWithIndex(0); - - if(texture) - { - texture.destroy(true); - - existing.remove(existing.getKey(0)); - } - - removeCount--; - } - }, 0); - } - } + this.initializeRoomPlanes(); needsUpdate = this.updateMasks(objectModel); @@ -436,9 +367,9 @@ export class RoomVisualization extends RoomObjectSpriteVisualization implements this.reset(); } - protected initializeRoomPlanes(): boolean + protected initializeRoomPlanes(): void { - if(!this.object || this._isPlaneSet) return false; + if(!this.object || this._isPlaneSet) return; if(!isNaN(this._floorThickness)) this._roomPlaneParser.floorThicknessMultiplier = this._floorThickness; if(!isNaN(this._wallThickness)) this._roomPlaneParser.wallThicknessMultiplier = this._wallThickness; @@ -447,8 +378,8 @@ export class RoomVisualization extends RoomObjectSpriteVisualization implements if(!this._roomPlaneParser.initializeFromMapData(mapData)) return; - const _local_3 = this.getLandscapeWidth(); - const _local_4 = this.getLandscapeHeight(); + const maxX = this.getLandscapeWidth(); + const maxY = this.getLandscapeHeight(); let _local_5 = 0; let randomSeed = this.object.model.getValue(RoomObjectVariable.ROOM_RANDOM_SEED); @@ -468,7 +399,7 @@ export class RoomVisualization extends RoomObjectSpriteVisualization implements { const _local_14 = Vector3d.crossProduct(leftSide, rightSide); - randomSeed = ((randomSeed * 7613) + 517); + randomSeed = ToInt32(Math.trunc((randomSeed * 7613) + 517) >>> 0); plane = null; if(planeType === RoomPlaneData.PLANE_FLOOR) @@ -529,7 +460,7 @@ export class RoomVisualization extends RoomObjectSpriteVisualization implements else if(planeType === RoomPlaneData.PLANE_LANDSCAPE) { - plane = new RoomPlane(this.object.getLocation(), location, leftSide, rightSide, RoomPlane.TYPE_LANDSCAPE, true, secondaryNormals, randomSeed, _local_5, 0, _local_3, _local_4); + plane = new RoomPlane(this.object.getLocation(), location, leftSide, rightSide, RoomPlane.TYPE_LANDSCAPE, true, secondaryNormals, randomSeed, _local_5, 0, maxX, maxY); if(_local_14.y > 0) { @@ -619,8 +550,6 @@ export class RoomVisualization extends RoomObjectSpriteVisualization implements this._isPlaneSet = true; this.defineSprites(); - - return true; } protected defineSprites(): void @@ -768,90 +697,93 @@ export class RoomVisualization extends RoomObjectSpriteVisualization implements this._visiblePlaneSpriteNumbers = []; } - protected updatePlanes(k: IRoomGeometry, _arg_2: boolean, _arg_3: number): boolean + protected updatePlanes(geometry: IRoomGeometry, geometryUpdate: boolean, timeSinceStartMs: number): boolean { - if(!k || !this.object) return; + if(!geometry || !this.object) return; this._assetUpdateCounter++; - if(_arg_2) + if(geometryUpdate) { this._visiblePlanes = []; this._visiblePlaneSpriteNumbers = []; } - const _local_8 = (this._visiblePlanes.length > 0); + const hasVisiblePlanes = (this._visiblePlanes.length > 0); - let _local_6 = this._visiblePlanes; + let visiblePlanes = this._visiblePlanes; - if(!this._visiblePlanes.length) _local_6 = this._planes; + if(!this._visiblePlanes.length) visiblePlanes = this._planes; let depth = 0; let updated = false; let index = 0; - while(index < _local_6.length) + while(index < visiblePlanes.length) { - let _local_10 = index; + let id = index; - if(_local_8) _local_10 = this._visiblePlaneSpriteNumbers[index]; + if(hasVisiblePlanes) id = this._visiblePlaneSpriteNumbers[index]; - const _local_11 = this.getSprite(_local_10); + const sprite = this.getSprite(id); - if(_local_11) + if(sprite) { - const _local_12 = _local_6[index]; + const plane = visiblePlanes[index]; - if(_local_12) + if(plane) { - _local_11.id = _local_12.uniqueId; + sprite.id = plane.uniqueId; - if(_local_12.update(k, _arg_3)) + if(plane.update(geometry, timeSinceStartMs)) { - if(_local_12.visible) + if(plane.visible) { - depth = ((_local_12.relativeDepth + this.floorRelativeDepth) + (_local_10 / 1000)); + depth = ((plane.relativeDepth + this.floorRelativeDepth) + (id / 1000)); - if(_local_12.type !== RoomPlane.TYPE_FLOOR) + if(plane.type !== RoomPlane.TYPE_FLOOR) { - depth = ((_local_12.relativeDepth + this.wallRelativeDepth) + (_local_10 / 1000)); + depth = ((plane.relativeDepth + this.wallRelativeDepth) + (id / 1000)); - if((_local_12.leftSide.length < 1) || (_local_12.rightSide.length < 1)) + if((plane.leftSide.length < 1) || (plane.rightSide.length < 1)) { depth = (depth + (RoomVisualization.ROOM_DEPTH_OFFSET * 0.5)); } } - const _local_14 = ((('plane ' + _local_10) + ' ') + k.scale); - - this.updateSprite(_local_11, _local_12, _local_14, depth); + this.updateSprite(sprite, geometry, plane, `plane ${ id } ${ geometry.scale }`, depth); } + updated = true; } - if(_local_11.visible != ((_local_12.visible) && (this._typeVisibility[_local_12.type]))) + + if(sprite.visible != ((plane.visible) && (this._typeVisibility[plane.type]))) { - _local_11.visible = (!(_local_11.visible)); + sprite.visible = (!(sprite.visible)); updated = true; } - if(_local_11.visible) + + if(sprite.visible) { - if(!_local_8) + if(!hasVisiblePlanes) { - this._visiblePlanes.push(_local_12); + this._visiblePlanes.push(plane); this._visiblePlaneSpriteNumbers.push(index); } } } else { - _local_11.id = 0; - if(_local_11.visible) + sprite.id = 0; + + if(sprite.visible) { - _local_11.visible = false; + sprite.visible = false; updated = true; } } } + index++; } @@ -909,12 +841,12 @@ export class RoomVisualization extends RoomObjectSpriteVisualization implements { if(plane.leftSide && plane.rightSide) { - const _local_16 = Vector3d.scalarProjection(_local_14, plane.leftSide); - const _local_17 = Vector3d.scalarProjection(_local_14, plane.rightSide); + const leftSideLoc = Vector3d.scalarProjection(_local_14, plane.leftSide); + const rightSideLoc = Vector3d.scalarProjection(_local_14, plane.rightSide); if((plane.type === RoomPlane.TYPE_WALL) || ((plane.type === RoomPlane.TYPE_LANDSCAPE) && (maskCategory === RoomPlaneBitmapMaskData.HOLE))) { - plane.addBitmapMask(maskType, _local_16, _local_17); + plane.addBitmapMask(maskType, leftSideLoc, rightSideLoc); } else { @@ -961,21 +893,16 @@ export class RoomVisualization extends RoomObjectSpriteVisualization implements } } - private updateSprite(k: IRoomObjectSprite, _arg_2: RoomPlane, _arg_3: string, _arg_4: number): void + private updateSprite(sprite: IRoomObjectSprite, geometry: IRoomGeometry, plane: RoomPlane, _arg_3: string, relativeDepth: number): void { - const offset = _arg_2.offset; + const offset = plane.offset; - k.offsetX = -(offset.x); - k.offsetY = -(offset.y); - k.relativeDepth = _arg_4; - k.color = _arg_2.color; - k.texture = this.getPlaneBitmap(_arg_2, _arg_3); - k.name = ((_arg_3 + '_') + this._assetUpdateCounter); - } - - private getPlaneBitmap(k: RoomPlane, _arg_2: string): Texture - { - return k.bitmapData; + sprite.offsetX = -(offset.x); + sprite.offsetY = -(offset.y); + sprite.relativeDepth = relativeDepth; + sprite.color = plane.color; + sprite.texture = plane.bitmapData; + sprite.name = ((_arg_3 + '_') + this._assetUpdateCounter); } public getBoundingRectangle(): Rectangle diff --git a/src/nitro/room/object/visualization/room/RoomVisualizationData.ts b/src/nitro/room/object/visualization/room/RoomVisualizationData.ts index 4c138479..98534fe3 100644 --- a/src/nitro/room/object/visualization/room/RoomVisualizationData.ts +++ b/src/nitro/room/object/visualization/room/RoomVisualizationData.ts @@ -24,23 +24,21 @@ export class RoomVisualizationData extends Disposable implements IObjectVisualiz public initialize(asset: IAssetData): boolean { - //@ts-ignore - const wallData = asset.wallData; + if(!asset.roomVisualization) return false; + + const wallData = asset.roomVisualization.wallData; if(wallData) this._wallRasterizer.initialize(wallData); - //@ts-ignore - const floorData = asset.floorData; + const floorData = asset.roomVisualization.floorData; if(floorData) this._floorRasterizer.initialize(floorData); - //@ts-ignore - const landscapeData = asset.landscapeData; + const landscapeData = asset.roomVisualization.landscapeData; if(landscapeData) this._landscapeRasterizer.initialize(landscapeData); - //@ts-ignore - const maskData = asset.maskData; + const maskData = asset.roomVisualization.maskData; if(maskData) this._maskManager.initialize(maskData); diff --git a/src/nitro/room/object/visualization/room/mask/PlaneMask.ts b/src/nitro/room/object/visualization/room/mask/PlaneMask.ts index e7d42b97..aa141b07 100644 --- a/src/nitro/room/object/visualization/room/mask/PlaneMask.ts +++ b/src/nitro/room/object/visualization/room/mask/PlaneMask.ts @@ -55,7 +55,7 @@ export class PlaneMask private getSizeIndex(k: number): number { let sizeIndex = 0; - const index = 1; + let index = 1; while(index < this._sizes.length) { @@ -67,6 +67,8 @@ export class PlaneMask } sizeIndex = index; + + index++; } return sizeIndex; diff --git a/src/nitro/room/object/visualization/room/mask/PlaneMaskManager.ts b/src/nitro/room/object/visualization/room/mask/PlaneMaskManager.ts index 9e43ef1b..ab14f003 100644 --- a/src/nitro/room/object/visualization/room/mask/PlaneMaskManager.ts +++ b/src/nitro/room/object/visualization/room/mask/PlaneMaskManager.ts @@ -1,6 +1,8 @@ -import { Graphics } from '@pixi/graphics'; +import { RenderTexture } from '@pixi/core'; import { Matrix, Point } from '@pixi/math'; -import { IGraphicAssetCollection, IVector3D } from '../../../../../../api'; +import { Sprite } from '@pixi/sprite'; +import { IAssetPlaneMaskData, IAssetPlaneTextureBitmap, IGraphicAssetCollection, IVector3D } from '../../../../../../api'; +import { PixiApplicationProxy } from '../../../../../../pixi-proxy'; import { PlaneMask } from './PlaneMask'; import { PlaneMaskVisualization } from './PlaneMaskVisualization'; @@ -8,7 +10,7 @@ export class PlaneMaskManager { private _assetCollection: IGraphicAssetCollection; private _masks: Map; - private _data: any; + private _data: IAssetPlaneMaskData; constructor() { @@ -17,7 +19,7 @@ export class PlaneMaskManager this._data = null; } - public get data(): any + public get data(): IAssetPlaneMaskData { return this._data; } @@ -40,7 +42,7 @@ export class PlaneMaskManager } } - public initialize(k: any): void + public initialize(k: IAssetPlaneMaskData): void { this._data = k; } @@ -54,17 +56,17 @@ export class PlaneMaskManager this.parseMasks(this.data, k); } - private parseMasks(k: any, _arg_2: IGraphicAssetCollection): void + private parseMasks(maskData: IAssetPlaneMaskData, _arg_2: IGraphicAssetCollection): void { - if(!k || !_arg_2) return; + if(!maskData || !_arg_2) return; - if(k.masks && k.masks.length) + if(maskData.masks && maskData.masks.length) { let index = 0; - while(index < k.masks.length) + while(index < maskData.masks.length) { - const mask = k.masks[index]; + const mask = maskData.masks[index]; if(mask) { @@ -85,7 +87,7 @@ export class PlaneMaskManager if(visualization) { - const size = visualization.size as number; + const size = visualization.size; const maskVisualization = newMask.createMaskVisualization(size); if(maskVisualization) @@ -108,18 +110,18 @@ export class PlaneMaskManager } } - private parseMaskBitmaps(k: any, _arg_2: PlaneMaskVisualization, _arg_3: IGraphicAssetCollection): string + private parseMaskBitmaps(bitmaps: IAssetPlaneTextureBitmap[], maskVisualization: PlaneMaskVisualization, assetCollection: IGraphicAssetCollection): string { - if(!k || !k.length) return null; + if(!bitmaps || !bitmaps.length) return null; let graphicName: string = null; - for(const bitmap of k) + for(const bitmap of bitmaps) { if(!bitmap) continue; const assetName = bitmap.assetName; - const asset = _arg_3.getAsset(assetName); + const asset = assetCollection.getAsset(assetName); if(!asset) continue; @@ -135,19 +137,19 @@ export class PlaneMaskManager if(!asset.flipH) graphicName = assetName; - _arg_2.addBitmap(asset, normalMinX, normalMaxX, normalMinY, normalMaxY); + maskVisualization.addBitmap(asset, normalMinX, normalMaxX, normalMinY, normalMaxY); } return graphicName; } - public updateMask(k: Graphics, _arg_2: string, _arg_3: number, _arg_4: IVector3D, _arg_5: number, _arg_6: number): boolean + public updateMask(canvas: RenderTexture, type: string, scale: number, normal: IVector3D, posX: number, posY: number): boolean { - const mask = this._masks.get(_arg_2); + const mask = this._masks.get(type); if(!mask) return true; - const asset = mask.getGraphicAsset(_arg_3, _arg_4); + const asset = mask.getGraphicAsset(scale, normal); if(!asset) return true; @@ -155,34 +157,41 @@ export class PlaneMaskManager if(!texture) return true; - const point = new Point((_arg_5 + asset.offsetX), (_arg_6 + asset.offsetY)); + const point = new Point((posX + asset.offsetX), (posY + asset.offsetY)); const matrix = new Matrix(); - let a = 1; - let b = 1; - let c = 0; - let d = 0; + let xScale = 1; + let ySkew = 1; + let xSkew = 0; + let yScale = 0; + let tx = (point.x + xSkew); + let ty = (point.y + yScale); if(asset.flipH) { - a = -1; - c = -(texture.width); + xScale = -1; + xSkew = texture.width; + + tx = ((point.x + xSkew) - texture.width); } if(asset.flipV) { - b = -1; - d = -(texture.height); + ySkew = -1; + yScale = texture.height; + + ty = ((point.y + yScale) - texture.height); } - matrix.scale(a, b); - matrix.translate((point.x + c), (point.y + d)); + matrix.scale(xScale, ySkew); + matrix.translate(tx, ty); - k - .beginTextureFill({ texture, matrix }) - .drawRect(matrix.tx, matrix.ty, texture.width, texture.height) - .endFill(); + PixiApplicationProxy.instance.renderer.render(new Sprite(texture), { + renderTexture: canvas, + clear: false, + transform: matrix + }); return true; } diff --git a/src/nitro/room/object/visualization/room/rasterizer/IPlaneRasterizer.ts b/src/nitro/room/object/visualization/room/rasterizer/IPlaneRasterizer.ts index 1d49aa97..1abb0b2f 100644 --- a/src/nitro/room/object/visualization/room/rasterizer/IPlaneRasterizer.ts +++ b/src/nitro/room/object/visualization/room/rasterizer/IPlaneRasterizer.ts @@ -1,4 +1,4 @@ -import { Graphics } from '@pixi/graphics'; +import { RenderTexture } from '@pixi/core'; import { IVector3D } from '../../../../../../api'; import { PlaneBitmapData } from '../utils'; import { PlaneVisualizationLayer } from './basic'; @@ -6,7 +6,7 @@ import { PlaneVisualizationLayer } from './basic'; export interface IPlaneRasterizer { initializeDimensions(_arg_1: number, _arg_2: number): boolean; - render(_arg_1: Graphics, _arg_2: string, _arg_3: number, _arg_4: number, _arg_5: number, _arg_6: IVector3D, _arg_7: boolean, _arg_8?: number, _arg_9?: number, _arg_10?: number, _arg_11?: number, _arg_12?: number): PlaneBitmapData; + render(planeId: string, canvas: RenderTexture, id: string, width: number, height: number, scale: number, normal: IVector3D, useTexture: boolean, offsetX?: number, offsetY?: number, maxX?: number, maxY?: number, timeSinceStartMs?: number): PlaneBitmapData; getTextureIdentifier(_arg_1: number, _arg_2: IVector3D): string; getLayers(_arg_1: string): PlaneVisualizationLayer[]; reinitialize(): void; diff --git a/src/nitro/room/object/visualization/room/rasterizer/animated/AnimationItem.ts b/src/nitro/room/object/visualization/room/rasterizer/animated/AnimationItem.ts index 51e5df1f..3fcbab6b 100644 --- a/src/nitro/room/object/visualization/room/rasterizer/animated/AnimationItem.ts +++ b/src/nitro/room/object/visualization/room/rasterizer/animated/AnimationItem.ts @@ -7,15 +7,15 @@ export class AnimationItem private _y: number; private _speedX: number; private _speedY: number; - private _bitmapData: IGraphicAsset; + private _asset: IGraphicAsset; - constructor(k: number, _arg_2: number, _arg_3: number, _arg_4: number, _arg_5: IGraphicAsset) + constructor(x: number, y: number, speedX: number, speedY: number, asset: IGraphicAsset) { - this._x = k; - this._y = _arg_2; - this._speedX = _arg_3; - this._speedY = _arg_4; - this._bitmapData = _arg_5; + this._x = x; + this._y = y; + this._speedX = speedX; + this._speedY = speedY; + this._asset = asset; if(isNaN(this._x)) this._x = 0; @@ -28,25 +28,25 @@ export class AnimationItem public get bitmapData(): IGraphicAsset { - return this._bitmapData; + return this._asset; } public dispose(): void { - this._bitmapData = null; + this._asset = null; } - public getPosition(k: number, _arg_2: number, _arg_3: number, _arg_4: number, _arg_5: number): Point + public getPosition(maxX: number, maxY: number, dimensionX: number, dimensionY: number, timeSinceStartMs: number): Point { - let _local_6 = this._x; - let _local_7 = this._y; + let x = this._x; + let y = this._y; - if(_arg_3 > 0) _local_6 = (_local_6 + (((this._speedX / _arg_3) * _arg_5) / 1000)); + if(dimensionX > 0) x = (x + (((this._speedX / dimensionX) * timeSinceStartMs) / 1000)); - if(_arg_4 > 0) _local_7 = (_local_7 + (((this._speedY / _arg_4) * _arg_5) / 1000)); + if(dimensionY > 0) y = (y + (((this._speedY / dimensionY) * timeSinceStartMs) / 1000)); - const _local_8 = ((_local_6 % 1) * k); - const _local_9 = ((_local_7 % 1) * _arg_2); + const _local_8 = Math.trunc((x % 1) * maxX); + const _local_9 = Math.trunc((y % 1) * maxY); return new Point(_local_8, _local_9); } diff --git a/src/nitro/room/object/visualization/room/rasterizer/animated/LandscapePlane.ts b/src/nitro/room/object/visualization/room/rasterizer/animated/LandscapePlane.ts index ce958842..9686ffa1 100644 --- a/src/nitro/room/object/visualization/room/rasterizer/animated/LandscapePlane.ts +++ b/src/nitro/room/object/visualization/room/rasterizer/animated/LandscapePlane.ts @@ -1,4 +1,4 @@ -import { Graphics } from '@pixi/graphics'; +import { RenderTexture } from '@pixi/core'; import { IVector3D, Vector3d } from '../../../../../../../api'; import { Plane } from '../basic'; @@ -11,31 +11,31 @@ export class LandscapePlane extends Plane private _width: number = 0; private _height: number = 0; - public isStatic(k: number): boolean + public isStatic(scale: number): boolean { - const _local_2 = this.getPlaneVisualization(k); + const visualization = this.getPlaneVisualization(scale); - if(_local_2) return !(_local_2.hasAnimationLayers); + if(visualization) return !visualization.hasAnimationLayers; - return super.isStatic(k); + return super.isStatic(scale); } - public initializeDimensions(k: number, _arg_2: number): void + public initializeDimensions(width: number, height: number): void { - if(k < 0) k = 0; + if(width < 0) width = 0; - if(_arg_2 < 0) _arg_2 = 0; + if(height < 0) height = 0; - if((k !== this._width) || (_arg_2 !== this._height)) + if((width !== this._width) || (height !== this._height)) { - this._width = k; - this._height = _arg_2; + this._width = width; + this._height = height; } } - public render(k: Graphics, _arg_2: number, _arg_3: number, _arg_4: number, _arg_5: IVector3D, _arg_6: boolean, _arg_7: number, _arg_8: number, _arg_9: number, _arg_10: number, _arg_11: number): Graphics + public render(planeId: string, canvas: RenderTexture, width: number, height: number, scale: number, normal: IVector3D, useTexture: boolean, offsetX: number, offsetY: number, maxX: number, maxY: number, timeSinceStartMs: number): RenderTexture { - const visualization = this.getPlaneVisualization(_arg_4); + const visualization = this.getPlaneVisualization(scale); if(!visualization || !visualization.geometry) return null; @@ -45,15 +45,15 @@ export class LandscapePlane extends Plane if(_local_13 && _local_14 && _local_15) { - _arg_2 = Math.round(Math.abs((((_local_13.x - _local_15.x) * _arg_2) / visualization.geometry.scale))); - _arg_3 = Math.round(Math.abs((((_local_13.y - _local_14.y) * _arg_3) / visualization.geometry.scale))); + width = Math.round(Math.abs((((_local_13.x - _local_15.x) * width) / visualization.geometry.scale))); + height = Math.round(Math.abs((((_local_13.y - _local_14.y) * height) / visualization.geometry.scale))); - const _local_16 = (_arg_7 * Math.abs((_local_13.x - _local_15.x))); - const _local_17 = (_arg_8 * Math.abs((_local_13.y - _local_14.y))); - const _local_18 = (_arg_9 * Math.abs((_local_13.x - _local_15.x))); - const _local_19 = (_arg_10 * Math.abs((_local_13.y - _local_14.y))); + const renderOffsetX = Math.trunc(offsetX * Math.abs((_local_13.x - _local_15.x))); + const renderOffsetY = Math.trunc(offsetY * Math.abs((_local_13.y - _local_14.y))); + const renderMaxX = Math.trunc(maxX * Math.abs((_local_13.x - _local_15.x))); + const renderMaxY = Math.trunc(maxY * Math.abs((_local_13.y - _local_14.y))); - return visualization.render(k, _arg_2, _arg_3, _arg_5, _arg_6, _local_16, _local_17, _local_18, _local_19, _arg_9, _arg_10, _arg_11); + return visualization.render(planeId, canvas, width, height, normal, useTexture, renderOffsetX, renderOffsetY, renderMaxX, renderMaxY, maxX, maxY, timeSinceStartMs); } return null; diff --git a/src/nitro/room/object/visualization/room/rasterizer/animated/LandscapeRasterizer.ts b/src/nitro/room/object/visualization/room/rasterizer/animated/LandscapeRasterizer.ts index c489781b..7d3c8623 100644 --- a/src/nitro/room/object/visualization/room/rasterizer/animated/LandscapeRasterizer.ts +++ b/src/nitro/room/object/visualization/room/rasterizer/animated/LandscapeRasterizer.ts @@ -1,15 +1,20 @@ -import { Graphics } from '@pixi/graphics'; -import { IVector3D, NitroConfiguration } from '../../../../../../../api'; +import { RenderTexture } from '@pixi/core'; +import { IAssetPlane, IAssetPlaneVisualizationAnimatedLayer, IAssetPlaneVisualizationLayer, IVector3D, Vector3d } from '../../../../../../../api'; +import { RoomTextureUtils, TextureUtils } from '../../../../../../../pixi-proxy'; import { PlaneBitmapData, Randomizer } from '../../utils'; import { PlaneMaterial, PlaneRasterizer, PlaneVisualizationLayer } from '../basic'; import { LandscapePlane } from './LandscapePlane'; export class LandscapeRasterizer extends PlaneRasterizer { + public static LANDSCAPES_ENABLED: boolean = true; + public static LANDSCAPE_DEFAULT_COLOR: number = 8828617; + private static UPDATE_INTERVAL: number = 500; private _landscapeWidth: number = 0; private _landscapeHeight: number = 0; + private _cachedBitmap: RenderTexture = null; public initializeDimensions(k: number, _arg_2: number): boolean { @@ -27,12 +32,12 @@ export class LandscapeRasterizer extends PlaneRasterizer { if(!this.data) return; - const landscapes = this.data.landscapes; + const landscapes = this.data.planes; if(landscapes && landscapes.length) this.parseLandscapes(landscapes); } - private parseLandscapes(k: any): void + private parseLandscapes(k: IAssetPlane[]): void { if(!k) return; @@ -45,7 +50,7 @@ export class LandscapeRasterizer extends PlaneRasterizer if(!landscape) continue; const id = landscape.id; - const visualizations = landscape.animatedVisualizations; + const visualizations = landscape.animatedVisualization; const plane = new LandscapePlane(); @@ -58,14 +63,10 @@ export class LandscapeRasterizer extends PlaneRasterizer let horizontalAngle = LandscapePlane.HORIZONTAL_ANGLE_DEFAULT; let verticalAngle = LandscapePlane.VERTICAL_ANGLE_DEFAULT; - if(visualization.horizontalAngle) horizontalAngle = visualization.horizontalAngle; - if(visualization.verticalAngle) verticalAngle = visualization.verticalAngle; + if(visualization.horizontalAngle !== undefined) horizontalAngle = visualization.horizontalAngle; + if(visualization.verticalAngle !== undefined) verticalAngle = visualization.verticalAngle; - const basicLayers = visualization.layers; - const animatedLayers = visualization.animationLayers; - const totalBasicLayers = ((basicLayers && basicLayers.length) || 0); - const totalAnimatedLayers = ((animatedLayers && animatedLayers.length) || 0); - const totalLayers = (totalBasicLayers + totalAnimatedLayers); + const totalLayers = (visualization.allLayers.length ?? 0); const planeVisualization = plane.createPlaneVisualization(size, (totalLayers || 0), this.getGeometry(size, horizontalAngle, verticalAngle)); @@ -75,55 +76,45 @@ export class LandscapeRasterizer extends PlaneRasterizer let layerId = 0; - if(totalBasicLayers) + while(layerId < totalLayers) { - while(layerId < basicLayers.length) - { - const layer = basicLayers[layerId]; + const layer = visualization.allLayers[layerId]; - if(layer) + if(layer) + { + if((layer as IAssetPlaneVisualizationAnimatedLayer).items === undefined) { + const basicLayer = (layer as IAssetPlaneVisualizationLayer); + let material: PlaneMaterial = null; let align: number = PlaneVisualizationLayer.ALIGN_DEFAULT; let color: number = LandscapePlane.DEFAULT_COLOR; let offset: number = PlaneVisualizationLayer.DEFAULT_OFFSET; - if(layer.materialId) material = this.getMaterial(layer.materialId); + if(basicLayer.materialId) material = this.getMaterial(basicLayer.materialId); - if(layer.color) color = layer.color; + if(basicLayer.color) color = basicLayer.color; - if(layer.offset) offset = layer.offset; + if(basicLayer.offset) offset = basicLayer.offset; - if(layer.align) + if(basicLayer.align) { - if(layer.align === 'bottom') + if(basicLayer.align === 'bottom') { align = PlaneVisualizationLayer.ALIGN_BOTTOM; } - else if(layer.align === 'top') align = PlaneVisualizationLayer.ALIGN_TOP; + else if(basicLayer.align === 'top') align = PlaneVisualizationLayer.ALIGN_TOP; } planeVisualization.setLayer(layerId, material, color, align, offset); } - - layerId++; - } - } - - layerId = 0; - - if(totalAnimatedLayers) - { - const animationItems: {}[] = []; - - while(layerId < animatedLayers.length) - { - const layer = animatedLayers[layerId]; - - if(layer) + else { - const items = layer.animationItems; + const animatedLayer = (layer as IAssetPlaneVisualizationAnimatedLayer); + + const items = animatedLayer.items; + const animationItems: {}[] = []; if(items && items.length) { @@ -135,8 +126,8 @@ export class LandscapeRasterizer extends PlaneRasterizer const assetId = item.assetId; const x = this.getCoordinateValue(item.x || '', item.randomX || ''); const y = this.getCoordinateValue(item.y || '', item.randomY || ''); - const speedX = item.speedX ? item.speedX / NitroConfiguration.getValue('system.animation.fps', 24) : 0; - const speedY = item.speedY ? item.speedY / NitroConfiguration.getValue('system.animation.fps', 24) : 0; + const speedX = item.speedX; + const speedY = item.speedY; animationItems.push({ asset: assetId, @@ -148,12 +139,12 @@ export class LandscapeRasterizer extends PlaneRasterizer } } } + + planeVisualization.setAnimationLayer(layerId, animationItems, this.assetCollection); } layerId++; } - - planeVisualization.setAnimationLayer(layerId, animationItems, this.assetCollection); } } } @@ -162,38 +153,38 @@ export class LandscapeRasterizer extends PlaneRasterizer } } - private getCoordinateValue(k: string, _arg_2: string): number + private getCoordinateValue(x: string, randomX: string): number { let _local_3 = 0; - if((k.length > 0)) + if((x.length > 0)) { - if(k.charAt((k.length - 1)) === '%') + if(x.charAt((x.length - 1)) === '%') { - k = k.substr(0, (k.length - 1)); + x = x.substr(0, (x.length - 1)); - _local_3 = (parseFloat(k) / 100); + _local_3 = (parseFloat(x) / 100); } } - if((_arg_2.length > 0)) + if((randomX.length > 0)) { const _local_4 = 10000; const _local_5 = Randomizer.getValues(1, 0, _local_4); const _local_6 = (_local_5[0] / _local_4); - if(_arg_2.charAt((_arg_2.length - 1)) === '%') + if(randomX.charAt((randomX.length - 1)) === '%') { - _arg_2 = _arg_2.substr(0, (_arg_2.length - 1)); + randomX = randomX.substr(0, (randomX.length - 1)); - _local_3 = (_local_3 + ((_local_6 * parseFloat(_arg_2)) / 100)); + _local_3 = (_local_3 + ((_local_6 * parseFloat(randomX)) / 100)); } } return _local_3; } - public render(canvas: Graphics, id: string, width: number, height: number, scale: number, normal: IVector3D, useTexture: boolean, offsetX: number = 0, offsetY: number = 0, maxX: number = 0, maxY: number = 0, timeSinceStartMs: number = 0): PlaneBitmapData + public render(planeId: string, canvas: RenderTexture, id: string, width: number, height: number, scale: number, normal: IVector3D, useTexture: boolean, offsetX: number = 0, offsetY: number = 0, maxX: number = 0, maxY: number = 0, timeSinceStartMs: number = 0): PlaneBitmapData { let plane = this.getPlane(id) as LandscapePlane; @@ -201,16 +192,46 @@ export class LandscapeRasterizer extends PlaneRasterizer if(!plane) return null; - if(canvas) + if(canvas) TextureUtils.clearRenderTexture(canvas); + + if(!LandscapeRasterizer.LANDSCAPES_ENABLED) { - canvas.clear(); + const visualization = plane.getPlaneVisualization(scale); + + if(!visualization || !visualization.geometry) return null; + + const _local_13 = visualization.geometry.getScreenPoint(new Vector3d(0, 0, 0)); + const _local_14 = visualization.geometry.getScreenPoint(new Vector3d(0, 0, 1)); + const _local_15 = visualization.geometry.getScreenPoint(new Vector3d(0, 1, 0)); + + if(_local_13 && _local_14 && _local_15) + { + width = Math.round(Math.abs((((_local_13.x - _local_15.x) * width) / visualization.geometry.scale))); + height = Math.round(Math.abs((((_local_13.y - _local_14.y) * height) / visualization.geometry.scale))); + } + + if(!this._cachedBitmap || (this._cachedBitmap.width !== width ) || (this._cachedBitmap.height !== height)) + { + if(this._cachedBitmap) + { + this._cachedBitmap.destroy(true); + + this._cachedBitmap = null; + } + + this._cachedBitmap = RoomTextureUtils.createAndFillRenderTexture(width, height, LandscapeRasterizer.LANDSCAPE_DEFAULT_COLOR); + } + + return new PlaneBitmapData(this._cachedBitmap, -1); } - let graphic = plane.render(canvas, width, height, scale, normal, useTexture, offsetX, offsetY, maxX, maxY, timeSinceStartMs); + if(canvas) TextureUtils.clearRenderTexture(canvas); + + let graphic = plane.render(planeId, canvas, width, height, scale, normal, useTexture, offsetX, offsetY, maxX, maxY, timeSinceStartMs); if(graphic && (graphic !== canvas)) { - graphic = graphic.clone(); + graphic = new RenderTexture(graphic.baseTexture); if(!graphic) return null; } diff --git a/src/nitro/room/object/visualization/room/rasterizer/animated/PlaneVisualizationAnimationLayer.ts b/src/nitro/room/object/visualization/room/rasterizer/animated/PlaneVisualizationAnimationLayer.ts index e93ea29f..40d45626 100644 --- a/src/nitro/room/object/visualization/room/rasterizer/animated/PlaneVisualizationAnimationLayer.ts +++ b/src/nitro/room/object/visualization/room/rasterizer/animated/PlaneVisualizationAnimationLayer.ts @@ -1,23 +1,24 @@ -import { Graphics } from '@pixi/graphics'; -import { Matrix } from '@pixi/math'; +import { RenderTexture } from '@pixi/core'; +import { Sprite } from '@pixi/sprite'; import { IDisposable, IGraphicAssetCollection, IVector3D } from '../../../../../../../api'; +import { RoomTextureUtils, TextureUtils } from '../../../../../../../pixi-proxy'; import { AnimationItem } from './AnimationItem'; export class PlaneVisualizationAnimationLayer implements IDisposable { private _color: number = 0; - private _bitmapData: Graphics = null; + private _bitmapData: RenderTexture = null; private _isDisposed: boolean = false; private _items: AnimationItem[]; - constructor(k: any, _arg_2: IGraphicAssetCollection) + constructor(k: any, assets: IGraphicAssetCollection) { this._color = 0; this._bitmapData = null; this._isDisposed = false; this._items = []; - if(k && _arg_2) + if(k && assets) { for(const item of k) { @@ -27,7 +28,7 @@ export class PlaneVisualizationAnimationLayer implements IDisposable if(assetName) { - const asset = _arg_2.getAsset(assetName); + const asset = assets.getAsset(assetName); if(asset) this._items.push(new AnimationItem(item.x, item.y, item.speedX, item.speedY, asset)); } @@ -63,33 +64,25 @@ export class PlaneVisualizationAnimationLayer implements IDisposable { if(this._bitmapData) { - this._bitmapData.destroy(); + this._bitmapData.destroy(true); this._bitmapData = null; } } - public render(canvas: Graphics, width: number, height: number, normal: IVector3D, offsetX: number, offsetY: number, maxX: number, maxY: number, dimensionX: number, dimensionY: number, timeSinceStartMs: number): Graphics + public render(canvas: RenderTexture, width: number, height: number, normal: IVector3D, offsetX: number, offsetY: number, maxX: number, maxY: number, dimensionX: number, dimensionY: number, timeSinceStartMs: number): RenderTexture { - if((((canvas == null) || (!(canvas.width == width))) || (!(canvas.height == height)))) + if(!canvas || (canvas.width !== width) || (canvas.height !== height)) { - if((((this._bitmapData == null) || (!(this._bitmapData.width == width))) || (!(this._bitmapData.height == height)))) + if(!this._bitmapData || (this._bitmapData.width !== width) || (this._bitmapData.height !== height)) { - if(this._bitmapData != null) - { - this._bitmapData.destroy(); - } + if(this._bitmapData) this._bitmapData.destroy(true); - this._bitmapData = new Graphics() - .drawRect(0, 0, width, height); + this._bitmapData = RoomTextureUtils.createRenderTexture(width, height); } else { - this._bitmapData - .beginFill(0xFFFFFF) - .drawRect(0, 0, this._bitmapData.width, this._bitmapData.height) - .endFill(); - //this._bitmapData.fillRect(this._bitmapData.rect, 0xFFFFFF); + TextureUtils.clearRenderTexture(this._bitmapData); } canvas = this._bitmapData; @@ -97,51 +90,60 @@ export class PlaneVisualizationAnimationLayer implements IDisposable if(((maxX > 0) && (maxY > 0))) { - let _local_12 = 0; + let index = 0; - while(_local_12 < this._items.length) + while(index < this._items.length) { - const _local_13 = (this._items[_local_12] as AnimationItem); - if(_local_13 != null) + const item = (this._items[index] as AnimationItem); + + if(item) { - const _local_14 = _local_13.getPosition(maxX, maxY, dimensionX, dimensionY, timeSinceStartMs); + const point = item.getPosition(maxX, maxY, dimensionX, dimensionY, timeSinceStartMs); - _local_14.x = (_local_14.x - offsetX); - _local_14.y = (_local_14.y - offsetY); + point.x = Math.trunc(point.x - offsetX); + point.y = Math.trunc(point.y - offsetY); - if(_local_13.bitmapData) + if(item.bitmapData) { - if(_local_14.x > 0 && (_local_14.x + _local_13.bitmapData.width < canvas.width)) + if((point.x > -(item.bitmapData.width)) && (point.x < canvas.width) && (point.y > -(item.bitmapData.height)) && (point.y < canvas.height)) { - canvas - .beginFill(0x00FF00) - .beginTextureFill({ texture: _local_13.bitmapData.texture, matrix: new Matrix(1, 0, 0, 1, _local_14.x, _local_14.y) }) - .drawRect(_local_14.x, _local_14.y, _local_13.bitmapData.width, _local_13.bitmapData.height) - .endFill(); + const sprite = new Sprite(item.bitmapData.texture); + + sprite.position.set(point.x, point.y); + + TextureUtils.writeToRenderTexture(sprite, canvas, false); } - else if(_local_14.x > 0) + + if(((point.x - maxX) > -(item.bitmapData.width)) && ((point.x - maxX) < canvas.width) && (point.y > -(item.bitmapData.height)) && (point.y < canvas.height)) { - const difference = canvas.width - _local_14.x; - canvas - .beginFill(0x00FF00) - .beginTextureFill({ texture: _local_13.bitmapData.texture, matrix: new Matrix(1, 0, 0, 1, _local_14.x, _local_14.y) }) - .drawRect(_local_14.x, _local_14.y, difference, _local_13.bitmapData.height) - .endFill(); + const sprite = new Sprite(item.bitmapData.texture); + + sprite.position.set((point.x - maxX), point.y); + + TextureUtils.writeToRenderTexture(sprite, canvas, false); } - else + + if((point.x > -(item.bitmapData.width)) && (point.x < canvas.width) && ((point.y - maxY) > -(item.bitmapData.height)) && ((point.y - maxY) < canvas.height)) { - //if(_local_14.x > -_local_13.bitmapData.width) - const difference = _local_13.bitmapData.width + _local_14.x; - canvas - .beginFill(0x00FF00) - .beginTextureFill({ texture: _local_13.bitmapData.texture, matrix: new Matrix(1, 0, 0, 1, _local_14.x, _local_14.y) }) - .drawRect(0, _local_14.y, difference, _local_13.bitmapData.height) - .endFill(); + const sprite = new Sprite(item.bitmapData.texture); + + sprite.position.set(point.x, (point.y - maxY)); + + TextureUtils.writeToRenderTexture(sprite, canvas, false); + } + + if(((point.x - maxX) > -(item.bitmapData.width)) && ((point.x - maxX) < canvas.width) && ((point.y - maxY) > -(item.bitmapData.height)) && ((point.y - maxY) < canvas.height)) + { + const sprite = new Sprite(item.bitmapData.texture); + + sprite.position.set((point.x - maxX), (point.y - maxY)); + + TextureUtils.writeToRenderTexture(sprite, canvas, false); } } } - _local_12++; + index++; } } diff --git a/src/nitro/room/object/visualization/room/rasterizer/basic/FloorPlane.ts b/src/nitro/room/object/visualization/room/rasterizer/basic/FloorPlane.ts index 511d6482..278d0dd1 100644 --- a/src/nitro/room/object/visualization/room/rasterizer/basic/FloorPlane.ts +++ b/src/nitro/room/object/visualization/room/rasterizer/basic/FloorPlane.ts @@ -1,4 +1,4 @@ -import { Graphics } from '@pixi/graphics'; +import { RenderTexture } from '@pixi/core'; import { IVector3D, Vector3d } from '../../../../../../../api'; import { Plane } from './Plane'; @@ -8,7 +8,7 @@ export class FloorPlane extends Plane public static HORIZONTAL_ANGLE_DEFAULT: number = 45; public static VERTICAL_ANGLE_DEFAULT: number = 30; - public render(canvas: Graphics, width: number, height: number, scale: number, normal: IVector3D, useTexture: boolean, offsetX: number, offsetY: number): Graphics + public render(planeId: string, canvas: RenderTexture, width: number, height: number, scale: number, normal: IVector3D, useTexture: boolean, offsetX: number, offsetY: number): RenderTexture { const visualization = this.getPlaneVisualization(scale); @@ -32,6 +32,6 @@ export class FloorPlane extends Plane y = (offsetY * Math.trunc(Math.abs(_local_15))); } - return visualization.render(canvas, width, height, normal, useTexture, x, y); + return visualization.render(planeId, canvas, width, height, normal, useTexture, x, y); } } diff --git a/src/nitro/room/object/visualization/room/rasterizer/basic/FloorRasterizer.ts b/src/nitro/room/object/visualization/room/rasterizer/basic/FloorRasterizer.ts index 21fe9b4f..32840b5c 100644 --- a/src/nitro/room/object/visualization/room/rasterizer/basic/FloorRasterizer.ts +++ b/src/nitro/room/object/visualization/room/rasterizer/basic/FloorRasterizer.ts @@ -1,5 +1,6 @@ -import { Graphics } from '@pixi/graphics'; -import { IVector3D } from '../../../../../../../api'; +import { RenderTexture } from '@pixi/core'; +import { IAssetPlane, IVector3D } from '../../../../../../../api'; +import { TextureUtils } from '../../../../../../../pixi-proxy'; import { PlaneBitmapData } from '../../utils'; import { FloorPlane } from './FloorPlane'; import { PlaneRasterizer } from './PlaneRasterizer'; @@ -10,12 +11,12 @@ export class FloorRasterizer extends PlaneRasterizer { if(!this.data) return; - const floors = this.data.floors; + const floors = this.data.planes; if(floors && floors.length) this.parseFloors(floors); } - private parseFloors(k: any): void + private parseFloors(k: IAssetPlane[]): void { if(!k) return; @@ -35,7 +36,7 @@ export class FloorRasterizer extends PlaneRasterizer } } - public render(canvas: Graphics, id: string, width: number, height: number, scale: number, normal: IVector3D, useTexture: boolean, offsetX: number = 0, offsetY: number = 0, maxX: number = 0, maxY: number = 0, timeSinceStartMs: number = 0): PlaneBitmapData + public render(planeId: string, canvas: RenderTexture, id: string, width: number, height: number, scale: number, normal: IVector3D, useTexture: boolean, offsetX: number = 0, offsetY: number = 0, maxX: number = 0, maxY: number = 0, timeSinceStartMs: number = 0): PlaneBitmapData { let plane = this.getPlane(id) as FloorPlane; @@ -43,13 +44,13 @@ export class FloorRasterizer extends PlaneRasterizer if(!plane) return null; - if(canvas) canvas.clear(); + if(canvas) TextureUtils.clearAndFillRenderTexture(canvas); - let graphic = plane.render(canvas, width, height, scale, normal, useTexture, offsetX, offsetY); + let graphic = plane.render(planeId, canvas, width, height, scale, normal, useTexture, offsetX, offsetY); if(graphic && (graphic !== canvas)) { - graphic = graphic.clone(); + graphic = new RenderTexture(graphic.baseTexture); if(!graphic) return null; } diff --git a/src/nitro/room/object/visualization/room/rasterizer/basic/Plane.ts b/src/nitro/room/object/visualization/room/rasterizer/basic/Plane.ts index b177505b..9524f069 100644 --- a/src/nitro/room/object/visualization/room/rasterizer/basic/Plane.ts +++ b/src/nitro/room/object/visualization/room/rasterizer/basic/Plane.ts @@ -85,7 +85,7 @@ export class Plane return sizeIndex; } - protected getPlaneVisualization(size: number): PlaneVisualization + public getPlaneVisualization(size: number): PlaneVisualization { if(size === this._lastSize) return this._lastPlaneVisualization; diff --git a/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneMaterial.ts b/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneMaterial.ts index d82731f8..844c5c3f 100644 --- a/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneMaterial.ts +++ b/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneMaterial.ts @@ -1,4 +1,4 @@ -import { Graphics } from '@pixi/graphics'; +import { RenderTexture } from '@pixi/core'; import { IVector3D } from '../../../../../../../api'; import { PlaneMaterialCellMatrix } from './PlaneMaterialCellMatrix'; @@ -76,7 +76,7 @@ export class PlaneMaterial return null; } - public render(canvas: Graphics, width: number, height: number, normal: IVector3D, useTexture: boolean, offsetX: number, offsetY: number, topAlign: boolean): Graphics + public render(canvas: RenderTexture, width: number, height: number, normal: IVector3D, useTexture: boolean, offsetX: number, offsetY: number, topAlign: boolean): RenderTexture { if(width < 1) width = 1; diff --git a/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneMaterialCell.ts b/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneMaterialCell.ts index 3b04492c..6422b0b1 100644 --- a/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneMaterialCell.ts +++ b/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneMaterialCell.ts @@ -1,12 +1,13 @@ import { Matrix, Point } from '@pixi/math'; +import { Sprite } from '@pixi/sprite'; +import { TilingSprite } from '@pixi/sprite-tiling'; import { IGraphicAsset, IVector3D } from '../../../../../../../api'; -import { NitroSprite } from '../../../../../../../pixi-proxy'; import { Randomizer } from '../../utils'; import { PlaneTexture } from './PlaneTexture'; export class PlaneMaterialCell { - private _cachedSprite: NitroSprite; + private _cachedSprite: Sprite; private _texture: PlaneTexture; private _extraItemOffsets: Point[]; private _extraItemAssets: IGraphicAsset[]; @@ -56,7 +57,7 @@ export class PlaneMaterialCell public get isStatic(): boolean { - return this._extraItemCount == 0; + return this._extraItemCount === 0; } public dispose(): void @@ -102,7 +103,7 @@ export class PlaneMaterialCell return 0; } - public render(normal: IVector3D, textureOffsetX: number, textureOffsetY: number): NitroSprite + public render(normal: IVector3D, textureOffsetX: number, textureOffsetY: number): Sprite { if(!this._texture) return null; @@ -110,7 +111,7 @@ export class PlaneMaterialCell if(!texture) return null; - const bitmap = new NitroSprite(texture); + const bitmap = new TilingSprite(texture, texture.width, texture.height); if((textureOffsetX !== 0) || (textureOffsetY !== 0)) { @@ -118,8 +119,9 @@ export class PlaneMaterialCell while(textureOffsetY < 0) textureOffsetY += texture.height; - bitmap.x = (textureOffsetX % texture.width); - bitmap.y = (textureOffsetY % texture.height); + bitmap.tilePosition.set((textureOffsetX % texture.width), (textureOffsetY % texture.height)); + + bitmap.uvRespectAnchor = true; if(textureOffsetX) { @@ -134,89 +136,75 @@ export class PlaneMaterialCell } } - if(bitmap) + if(!this.isStatic) { - if(!this.isStatic) + if(this._cachedSprite) this._cachedSprite.destroy(); + + this._cachedSprite = bitmap; + + const limitMin = Math.min(this._extraItemCount, this._extraItemOffsets.length); + const limitMax = Math.max(this._extraItemCount, this._extraItemOffsets.length); + const offsetIndexes = Randomizer.getArray(this._extraItemCount, limitMax); + + let i = 0; + + while(i < limitMin) { - if(this._cachedSprite) + const offset = this._extraItemOffsets[offsetIndexes[i]]; + const item = this._extraItemAssets[(i % this._extraItemAssets.length)]; + + if(offset && item) { - if((this._cachedSprite.width !== bitmap.width) || (this._cachedSprite.height !== bitmap.height)) + const assetTexture = item.texture; + + if(assetTexture) { - this._cachedSprite.destroy(); + let itemOffsetX = item.offsetX; + let itemOffsetY = item.offsetY; - this._cachedSprite = null; - } - } + let x = 1; + let y = 1; + let translateX = 0; + let translateY = 0; - if(!this._cachedSprite) - { - this._cachedSprite = new NitroSprite(texture); - } - - const limitMin = Math.min(this._extraItemCount, this._extraItemOffsets.length); - const limitMax = Math.max(this._extraItemCount, this._extraItemOffsets.length); - const offsetIndexes = Randomizer.getArray(this._extraItemCount, limitMax); - - let i = 0; - - while(i < limitMin) - { - const offset = this._extraItemOffsets[offsetIndexes[i]]; - const item = this._extraItemAssets[(i % this._extraItemAssets.length)]; - - if(offset && item) - { - const assetTexture = item.texture; - - if(assetTexture) + if(item.flipH) { - const offsetFinal = new Point((offset.x + item.offsetX), (offset.y + item.offsetY)); - const flipMatrix = new Matrix(); - - let x = 1; - let y = 1; - let translateX = 0; - let translateY = 0; - - if(item.flipH) - { - x = -1; - translateX = assetTexture.width; - } - - if(item.flipV) - { - y = -1; - translateY = assetTexture.height; - } - - let offsetX = (offsetFinal.x + translateX); - offsetX = ((offsetX >> 1) << 1); - - flipMatrix.scale(x, y); - flipMatrix.translate(offsetX, (offsetFinal.y + translateY)); - - const sprite = new NitroSprite(assetTexture); - - sprite.transform.setFromMatrix(flipMatrix); - - sprite.x = flipMatrix.tx; - sprite.y = flipMatrix.ty; - - this._cachedSprite.addChild(sprite); + x = -1; + translateX = assetTexture.width; + itemOffsetX = -(item.width + item.x); } - } - i++; + if(item.flipV) + { + y = -1; + translateY = assetTexture.height; + itemOffsetY = -(item.height + item.y); + } + + const offsetFinal = new Point((offset.x + itemOffsetX), (offset.y + itemOffsetY)); + const flipMatrix = new Matrix(); + + let offsetX = (offsetFinal.x + translateX); + offsetX = ((offsetX >> 1) << 1); + + flipMatrix.scale(x, y); + flipMatrix.translate(offsetX, (offsetFinal.y + translateY)); + + const sprite = new Sprite(assetTexture); + + sprite.transform.setFromMatrix(flipMatrix); + + this._cachedSprite.addChild(sprite); + } } - return this._cachedSprite; + i++; } - return bitmap; + return this._cachedSprite; } - return null; + return bitmap; } public getAssetName(normal: IVector3D): string diff --git a/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneMaterialCellColumn.ts b/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneMaterialCellColumn.ts index 442793b3..0ed98f69 100644 --- a/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneMaterialCellColumn.ts +++ b/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneMaterialCellColumn.ts @@ -1,6 +1,7 @@ -import { Graphics } from '@pixi/graphics'; -import { IVector3D, NitroLogger, Vector3d } from '../../../../../../../api'; -import { NitroRenderTexture } from '../../../../../../../pixi-proxy'; +import { RenderTexture, Texture } from '@pixi/core'; +import { Sprite } from '@pixi/sprite'; +import { IVector3D, Vector3d } from '../../../../../../../api'; +import { RoomTextureUtils, TextureUtils } from '../../../../../../../pixi-proxy'; import { PlaneMaterialCell } from './PlaneMaterialCell'; export class PlaneMaterialCellColumn @@ -15,8 +16,7 @@ export class PlaneMaterialCellColumn private _cells: PlaneMaterialCell[]; private _repeatMode: number; private _width: number; - private _cachedTexture: NitroRenderTexture; - private _cachedBitmapData: Graphics; + private _cachedBitmapData: RenderTexture; private _cachedBitmapNormal: Vector3d; private _cachedBitmapDataOffsetX: number; private _cachedBitmapDataOffsetY: number; @@ -86,7 +86,7 @@ export class PlaneMaterialCellColumn if(this._cachedBitmapData) { - this._cachedBitmapData.destroy(); + this._cachedBitmapData.destroy(true); this._cachedBitmapData = null; } @@ -100,7 +100,7 @@ export class PlaneMaterialCellColumn if(this._cachedBitmapData) { - this._cachedBitmapData.destroy(); + this._cachedBitmapData.destroy(true); this._cachedBitmapData = null; } @@ -125,15 +125,9 @@ export class PlaneMaterialCellColumn this._isCached = false; } - public render(height: number, normal: IVector3D, offsetX: number, offsetY: number): Graphics + public render(height: number, normal: IVector3D, offsetX: number, offsetY: number): RenderTexture { - let ht = 0; - - if(this._repeatMode == PlaneMaterialCellColumn.REPEAT_MODE_NONE) - { - ht = this.getCellsHeight(this._cells, normal); - height = ht; - } + if(this._repeatMode === PlaneMaterialCellColumn.REPEAT_MODE_NONE) height = this.getCellsHeight(this._cells, normal); if(!this._cachedBitmapNormal) this._cachedBitmapNormal = new Vector3d(); @@ -145,10 +139,19 @@ export class PlaneMaterialCellColumn { return this._cachedBitmapData; } + else + { + if(this._cachedBitmapData.height === height) + { + TextureUtils.clearRenderTexture(this._cachedBitmapData); + } + else + { + this._cachedBitmapData.destroy(true); - this._cachedBitmapData.destroy(); - - this._cachedBitmapData = null; + this._cachedBitmapData = null; + } + } } } else @@ -157,14 +160,16 @@ export class PlaneMaterialCellColumn { if(this._cachedBitmapData.height === height) { - this._cachedBitmapData - .beginFill(0xFFFFFF) - .drawRect(0, 0, this._cachedBitmapData.width, height) - .endFill(); + const sprite = new Sprite(Texture.EMPTY); + + sprite.width = this._cachedBitmapData.width; + sprite.height = height; + + TextureUtils.writeToRenderTexture(sprite, this._cachedBitmapData); } else { - this._cachedBitmapData.destroy(); + this._cachedBitmapData.destroy(true); this._cachedBitmapData = null; } @@ -175,10 +180,7 @@ export class PlaneMaterialCellColumn if(!this._cachedBitmapData) { - this._cachedBitmapData = new Graphics() - .beginFill(0xFFFFFF) - .drawRect(0, 0, this._width, height) - .endFill(); + this._cachedBitmapData = RoomTextureUtils.createRenderTexture(this._width, height); } this._cachedBitmapNormal.assign(normal); @@ -193,20 +195,16 @@ export class PlaneMaterialCellColumn this.renderRepeatNone(normal); break; case PlaneMaterialCellColumn.REPEAT_MODE_BORDERS: - NitroLogger.log('REPEAT_MODE_BORDERS'); - // this.renderRepeatBorders(normal); + this.renderRepeatBorders(normal); break; case PlaneMaterialCellColumn.REPEAT_MODE_CENTER: - NitroLogger.log('REPEAT_MODE_CENTER'); - // this.renderRepeatCenter(normal); + this.renderRepeatCenter(normal); break; case PlaneMaterialCellColumn.REPEAT_MODE_FIRST: - NitroLogger.log('REPEAT_MODE_FIRST'); - // this.renderRepeatFirst(normal); + this.renderRepeatFirst(normal); break; case PlaneMaterialCellColumn.REPEAT_MODE_LAST: - NitroLogger.log('REPEAT_MODE_LAST'); - // this.renderRepeatLast(normal); + this.renderRepeatLast(normal); break; default: this.renderRepeatAll(normal, offsetX, offsetY); @@ -264,7 +262,7 @@ export class PlaneMaterialCellColumn graphic.y = index; - this._cachedBitmapData.addChild(graphic); + TextureUtils.writeToRenderTexture(graphic, this._cachedBitmapData, false); if(flag) index = (index + graphic.height); @@ -299,190 +297,195 @@ export class PlaneMaterialCellColumn } } - // private renderRepeatBorders(k:IVector3D): void - // { - // if (((this._cells.length == 0) || (this._cachedBitmapData == null))) - // { - // return; - // } - // var _local_2:PlaneMaterialCell; - // var _local_3:BitmapData; - // var _local_4:Array = []; - // var _local_5: number; - // var _local_6: number; - // var _local_7: number; - // _local_7 = 1; - // while (_local_7 < (this._cells.length - 1)) - // { - // _local_2 = (this._cells[_local_7] as PlaneMaterialCell); - // if (_local_2 != null) - // { - // _local_6 = _local_2.getHeight(k); - // if (_local_6 > 0) - // { - // _local_5 = (_local_5 + _local_6); - // _local_4.push(_local_2); - // } - // } - // _local_7++; - // } - // if (this._cells.length == 1) - // { - // _local_2 = (this._cells[0] as PlaneMaterialCell); - // if (_local_2 != null) - // { - // _local_6 = _local_2.getHeight(k); - // if (_local_6 > 0) - // { - // _local_5 = (_local_5 + _local_6); - // _local_4.push(_local_2); - // } - // } - // } - // var _local_8:* = ((this._cachedBitmapData.height - _local_5) >> 1); - // var _local_9: number = this.renderCells(_local_4, _local_8, true, k); - // _local_2 = (this._cells[0] as PlaneMaterialCell); - // if (_local_2 != null) - // { - // _local_4 = [_local_2]; - // while (_local_8 >= 0) - // { - // _local_8 = this.renderCells(_local_4, _local_8, false, k); - // } - // } - // _local_2 = (this._cells[(this._cells.length - 1)] as PlaneMaterialCell); - // if (_local_2 != null) - // { - // _local_4 = [_local_2]; - // while (_local_9 < this._cachedBitmapData.height) - // { - // _local_9 = this.renderCells(_local_4, _local_9, true, k); - // } - // } - // } + private renderRepeatBorders(k:IVector3D): void + { + if(!this._cells.length || !this._cachedBitmapData) return; - // private renderRepeatCenter(k:IVector3D): void - // { - // var _local_13: number; - // var _local_14: number; - // var _local_15: number; - // var _local_16:Array; - // if (((this._cells.length == 0) || (this._cachedBitmapData == null))) - // { - // return; - // } - // var _local_2:PlaneMaterialCell; - // var _local_3:BitmapData; - // var _local_4:Array = []; - // var _local_5:Array = []; - // var _local_6: number; - // var _local_7: number; - // var _local_8: number; - // var _local_9: number; - // _local_9 = 0; - // while (_local_9 < (this._cells.length >> 1)) - // { - // _local_2 = (this._cells[_local_9] as PlaneMaterialCell); - // if (_local_2 != null) - // { - // _local_8 = _local_2.getHeight(k); - // if (_local_8 > 0) - // { - // _local_6 = (_local_6 + _local_8); - // _local_4.push(_local_2); - // } - // } - // _local_9++; - // } - // _local_9 = ((this._cells.length >> 1) + 1); - // while (_local_9 < this._cells.length) - // { - // _local_2 = (this._cells[_local_9] as PlaneMaterialCell); - // if (_local_2 != null) - // { - // _local_8 = _local_2.getHeight(k); - // if (_local_8 > 0) - // { - // _local_7 = (_local_7 + _local_8); - // _local_5.push(_local_2); - // } - // } - // _local_9++; - // } - // var _local_10: number; - // var _local_11: number; - // var _local_12: number = this._cachedBitmapData.height; - // if ((_local_6 + _local_7) > this._cachedBitmapData.height) - // { - // _local_10 = ((_local_6 + _local_7) - this._cachedBitmapData.height); - // _local_11 = (_local_11 - (_local_10 >> 1)); - // _local_12 = (_local_12 + (_local_10 - (_local_10 >> 1))); - // } - // if (_local_10 == 0) - // { - // _local_2 = (this._cells[(this._cells.length >> 1)] as PlaneMaterialCell); - // if (_local_2 != null) - // { - // _local_8 = _local_2.getHeight(k); - // if (_local_8 > 0) - // { - // _local_13 = (this._cachedBitmapData.height - (_local_6 + _local_7)); - // _local_14 = (Math.ceil((_local_13 / _local_8)) * _local_8); - // _local_11 = (_local_6 - ((_local_14 - _local_13) >> 1)); - // _local_15 = (_local_11 + _local_14); - // _local_16 = [_local_2]; - // while (_local_11 < _local_15) - // { - // _local_11 = this.renderCells(_local_16, _local_11, true, k); - // } - // } - // } - // } - // _local_11 = 0; - // this.renderCells(_local_4, _local_11, true, k); - // this.renderCells(_local_5, _local_12, false, k); - // } + const _local_4: PlaneMaterialCell[] = []; - // private renderRepeatFirst(k:IVector3D): void - // { - // var _local_4:Array; - // if (((this._cells.length == 0) || (this._cachedBitmapData == null))) - // { - // return; - // } - // var _local_2:PlaneMaterialCell; - // var _local_3: number = this._cachedBitmapData.height; - // _local_3 = this.renderCells(this._cells, _local_3, false, k); - // _local_2 = (this._cells[0] as PlaneMaterialCell); - // if (_local_2 != null) - // { - // _local_4 = [_local_2]; - // while (_local_3 >= 0) - // { - // _local_3 = this.renderCells(_local_4, _local_3, false, k); - // } - // } - // } + let _local_5 = 0; + let _local_7 = 1; - // private renderRepeatLast(k: IVector3D): void - // { - // if(!this._cells.length || !this._cachedBitmapData) return; + while(_local_7 < (this._cells.length - 1)) + { + const cell = (this._cells[_local_7] as PlaneMaterialCell); + if(cell) + { + const height = cell.getHeight(k); - // var _local_4:Array; - // var _local_2:PlaneMaterialCell; - // var _local_3: number; - // _local_3 = this.renderCells(this._cells, _local_3, true, k); - // _local_2 = (this._cells[(this._cells.length - 1)] as PlaneMaterialCell); - // if (_local_2 != null) - // { - // _local_4 = [_local_2]; - // while (_local_3 < this._cachedBitmapData.height) - // { - // _local_3 = this.renderCells(_local_4, _local_3, true, k); - // } - // } - // } + if(height > 0) + { + _local_5 = (_local_5 + height); + + _local_4.push(cell); + } + } + + _local_7++; + } + + if(this._cells.length == 1) + { + const cell = this._cells[0]; + + if(cell) + { + const height = cell.getHeight(k); + + if(height > 0) + { + _local_5 = (_local_5 + height); + + _local_4.push(cell); + } + } + } + + let _local_8 = ((this._cachedBitmapData.height - _local_5) >> 1); + let index: number = this.renderCells(_local_4, _local_8, true, k); + + let cell = this._cells[0]; + + if(cell) + { + const cells = [cell]; + + while(_local_8 >= 0) _local_8 = this.renderCells(cells, _local_8, false, k); + } + + cell = this._cells[(this._cells.length - 1)]; + + if(cell) + { + const cells = [cell]; + + while(index < this._cachedBitmapData.height) index = this.renderCells(cells, index, true, k); + } + } + + private renderRepeatCenter(k:IVector3D): void + { + if(!this._cells.length || !this._cachedBitmapData) return; + + const _local_4: PlaneMaterialCell[] = []; + const _local_5: PlaneMaterialCell[] = []; + + let _local_6 = 0; + let _local_7 = 0; + + let _local_9 = 0; + + while(_local_9 < (this._cells.length >> 1)) + { + const cell = this._cells[_local_9]; + + if(cell) + { + const height = cell.getHeight(k); + + if(height > 0) + { + _local_6 = (_local_6 + height); + + _local_4.push(cell); + } + } + + _local_9++; + } + + _local_9 = ((this._cells.length >> 1) + 1); + + while(_local_9 < this._cells.length) + { + const cell = this._cells[_local_9]; + + if(cell) + { + const height = cell.getHeight(k); + + if(height > 0) + { + _local_7 = (_local_7 + height); + + _local_5.push(cell); + } + } + + _local_9++; + } + + let _local_10 = 0; + let _local_11: number; + let _local_12 = this._cachedBitmapData.height; + + if((_local_6 + _local_7) > this._cachedBitmapData.height) + { + _local_10 = ((_local_6 + _local_7) - this._cachedBitmapData.height); + _local_11 = (_local_11 - (_local_10 >> 1)); + _local_12 = (_local_12 + (_local_10 - (_local_10 >> 1))); + } + + if(_local_10 == 0) + { + const cell = this._cells[(this._cells.length >> 1)]; + + if(cell) + { + const height = cell.getHeight(k); + + if(height > 0) + { + const _local_13 = (this._cachedBitmapData.height - (_local_6 + _local_7)); + const _local_14 = (Math.ceil((_local_13 / height)) * height); + + let _local_11 = (_local_6 - ((_local_14 - _local_13) >> 1)); + + const _local_15 = (_local_11 + _local_14); + const _local_16 = [cell]; + + while(_local_11 < _local_15) _local_11 = this.renderCells(_local_16, _local_11, true, k); + } + } + } + + this.renderCells(_local_4, 0, true, k); + this.renderCells(_local_5, _local_12, false, k); + } + + private renderRepeatFirst(k:IVector3D): void + { + if(!this._cells.length || !this._cachedBitmapData) return; + + let index = this.renderCells(this._cells, this._cachedBitmapData.height, false, k); + + const cell = (this._cells[0] as PlaneMaterialCell); + + if(!cell) return; + + const cells = [ cell ]; + + while(index >= 0) index = this.renderCells(cells, index, false, k); + } + + private renderRepeatLast(normal: IVector3D): void + { + if(!this._cells.length || !this._cachedBitmapData) return; + + let index = this.renderCells(this._cells, 0, true, normal); + + const cell = (this._cells[(this._cells.length - 1)] as PlaneMaterialCell); + + if(!cell) return; + + const cells = [cell]; + + while(index < this._cachedBitmapData.height) + { + index = this.renderCells(cells, index, true, normal); + } + } public getCells(): PlaneMaterialCell[] { diff --git a/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneMaterialCellMatrix.ts b/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneMaterialCellMatrix.ts index d5210d8e..04618ebc 100644 --- a/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneMaterialCellMatrix.ts +++ b/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneMaterialCellMatrix.ts @@ -1,8 +1,8 @@ -import { Graphics } from '@pixi/graphics'; +import { RenderTexture, Texture } from '@pixi/core'; import { Point, Rectangle } from '@pixi/math'; -import { IVector3D, Vector3d } from '../../../../../../../api'; -import { TextureUtils } from '../../../../../../../pixi-proxy'; -import { RoomVisualization } from '../../RoomVisualization'; +import { Sprite } from '@pixi/sprite'; +import { IVector3D, NitroLogger, Vector3d } from '../../../../../../../api'; +import { RoomTextureUtils, TextureUtils } from '../../../../../../../pixi-proxy'; import { Randomizer } from '../../utils'; import { PlaneMaterialCell } from './PlaneMaterialCell'; import { PlaneMaterialCellColumn } from './PlaneMaterialCellColumn'; @@ -25,7 +25,7 @@ export class PlaneMaterialCellMatrix private _columns: PlaneMaterialCellColumn[]; private _repeatMode: number = 1; private _align: number = 1; - private _cachedBitmapData: Graphics; + private _cachedBitmapData: RenderTexture; private _cachedBitmapNormal: Vector3d = null; private _cachedBitmapHeight: number = 0; private _isCached: boolean = false; @@ -34,35 +34,39 @@ export class PlaneMaterialCellMatrix private _normalMaxX: number = 1; private _normalMinY: number = -1; private _normalMaxY: number = 1; + private _texturePool: Map; constructor(totalColumns: number, repeatMode: number = 1, align: number = 1, normalMinX: number = -1, normalMaxX: number = 1, normalMinY: number = -1, normalMaxY: number = 1) { this._columns = []; - if(totalColumns < 1) - { - totalColumns = 1; - } + + if(totalColumns < 1) totalColumns = 1; + let _local_8 = 0; + while(_local_8 < totalColumns) { this._columns.push(null); + _local_8++; } + this._repeatMode = repeatMode; this._align = align; this._normalMinX = normalMinX; this._normalMaxX = normalMaxX; this._normalMinY = normalMinY; this._normalMaxY = normalMaxY; - if(this._repeatMode == PlaneMaterialCellMatrix.REPEAT_MODE_RANDOM) - { - this._isStatic = false; - } + this._texturePool = new Map(); + + if(this._repeatMode === PlaneMaterialCellMatrix.REPEAT_MODE_RANDOM) this._isStatic = false; } private static nextRandomColumnIndex(totalColumns: number): number { - return ((Randomizer.getValues(1, 0, (totalColumns * 17631))[0]) % totalColumns); + const _local_2 = Randomizer.getValues(1, 0, (totalColumns * 17631)); + + return _local_2[0] % totalColumns; } public get normalMinX(): number @@ -99,7 +103,7 @@ export class PlaneMaterialCellMatrix { if(this._cachedBitmapData) { - this._cachedBitmapData.destroy(); + this._cachedBitmapData.destroy(true); this._cachedBitmapData = null; } @@ -135,6 +139,13 @@ export class PlaneMaterialCellMatrix } } + if(this._texturePool && this._texturePool.size) + { + this._texturePool.forEach(texture => texture.destroy(true)); + + this._texturePool.clear(); + } + this._isCached = false; } @@ -154,7 +165,7 @@ export class PlaneMaterialCellMatrix return true; } - public render(canvas: Graphics, width: number, height: number, normal: IVector3D, useTexture: boolean, offsetX: number, offsetY: number, topAlign: boolean): Graphics + public render(canvas: RenderTexture, width: number, height: number, normal: IVector3D, useTexture: boolean, offsetX: number, offsetY: number, topAlign: boolean): RenderTexture { if(width < 1) width = 1; @@ -168,7 +179,7 @@ export class PlaneMaterialCellMatrix { if(this._cachedBitmapData) { - if(((this._cachedBitmapData.width === width) && (this._cachedBitmapData.height == height)) && Vector3d.isEqual(this._cachedBitmapNormal, normal)) + if((this._cachedBitmapData.width === width) && (this._cachedBitmapData.height === height) && Vector3d.isEqual(this._cachedBitmapNormal, normal)) { if(canvas) { @@ -180,29 +191,12 @@ export class PlaneMaterialCellMatrix return this._cachedBitmapData; } - this._cachedBitmapData.destroy(); - this._cachedBitmapData = null; } } else { - if(this._cachedBitmapData) - { - if((this._cachedBitmapData.width === width) && (this._cachedBitmapData.height === height)) - { - this._cachedBitmapData - .beginFill(0xFFFFFF) - .drawRect(0, 0, width, height) - .endFill(); - } - else - { - this._cachedBitmapData.destroy(); - - this._cachedBitmapData = null; - } - } + this._cachedBitmapData = null; } this._isCached = true; @@ -214,19 +208,22 @@ export class PlaneMaterialCellMatrix if(!this._cachedBitmapData) { - const graphic = new Graphics() - .beginFill(0xFFFFFF) - .drawRect(0, 0, width, height) - .endFill(); + this._cachedBitmapData = this._texturePool.get(`${width}:${height}`); - this._cachedBitmapData = graphic; + if(!this._cachedBitmapData) + { + this._cachedBitmapData = RoomTextureUtils.createAndFillRenderTexture(width, height); + + this._texturePool.set(`${width}:${height}`, this._cachedBitmapData); + } + else + { + TextureUtils.clearAndFillRenderTexture(this._cachedBitmapData); + } } else { - this._cachedBitmapData - .beginFill(0xFFFFFF) - .drawRect(0, 0, width, height) - .endFill(); + TextureUtils.clearAndFillRenderTexture(this._cachedBitmapData); } if(canvas) @@ -243,15 +240,21 @@ export class PlaneMaterialCellMatrix { this._cachedBitmapHeight = height; - const graphic = new Graphics() - .beginFill(0xFFFFFF) - .drawRect(0, 0, width, height) - .endFill(); + this._cachedBitmapData = this._texturePool.get(`${width}:${height}`); - this._cachedBitmapData = graphic; + if(!this._cachedBitmapData) + { + this._cachedBitmapData = RoomTextureUtils.createRenderTexture(width, height); + + this._texturePool.set(`${width}:${height}`, this._cachedBitmapData); + } + else + { + TextureUtils.clearRenderTexture(this._cachedBitmapData); + } } - const columns: Graphics[] = []; + const columns: RenderTexture[] = []; let columnIndex = 0; @@ -281,19 +284,23 @@ export class PlaneMaterialCellMatrix switch(this._repeatMode) { case PlaneMaterialCellMatrix.REPEAT_MODE_BORDERS: + NitroLogger.log('REPEAT_MODE_BORDERS'); // maxColumnHeight = this.renderRepeatBorders(this._cachedBitmapData, columns); break; case PlaneMaterialCellMatrix.REPEAT_MODE_CENTER: + NitroLogger.log('REPEAT_MODE_CENTER'); // maxColumnHeight = this.renderRepeatCenter(this._cachedBitmapData, columns); break; case PlaneMaterialCellMatrix.REPEAT_MODE_FIRST: + NitroLogger.log('REPEAT_MODE_FIRST'); // maxColumnHeight = this.renderRepeatFirst(this._cachedBitmapData, columns); break; case PlaneMaterialCellMatrix.REPEAT_MODE_LAST: + NitroLogger.log('REPEAT_MODE_LAST'); // maxColumnHeight = this.renderRepeatLast(this._cachedBitmapData, columns); break; case PlaneMaterialCellMatrix.REPEAT_MODE_RANDOM: - // maxColumnHeight = this.renderRepeatRandom(this._cachedBitmapData, columns); + maxColumnHeight = this.renderRepeatRandom(this._cachedBitmapData, columns); break; default: maxColumnHeight = this.renderRepeatAll(this._cachedBitmapData, columns); @@ -312,51 +319,48 @@ export class PlaneMaterialCellMatrix return this._cachedBitmapData; } - private copyCachedBitmapOnCanvas(canvas: Graphics, height: number, offsetY: number, topAlign: boolean): void + private copyCachedBitmapOnCanvas(canvas: RenderTexture, height: number, offsetY: number, topAlign: boolean): void { if(!canvas || !this._cachedBitmapData || (canvas === this._cachedBitmapData)) return; if(!topAlign) offsetY = ((canvas.height - height) - offsetY); - let _local_5: Rectangle; + let bounds: Rectangle = null; - if(this._align == PlaneMaterialCellMatrix.ALIGN_TOP) + if(this._align === PlaneMaterialCellMatrix.ALIGN_TOP) { - _local_5 = new Rectangle(0, 0, this._cachedBitmapData.width, this._cachedBitmapHeight); + bounds = new Rectangle(0, 0, this._cachedBitmapData.width, this._cachedBitmapHeight); } else { - _local_5 = new Rectangle(0, (this._cachedBitmapData.height - this._cachedBitmapHeight), this._cachedBitmapData.width, this._cachedBitmapHeight); + bounds = new Rectangle(0, (this._cachedBitmapData.height - this._cachedBitmapHeight), this._cachedBitmapData.width, this._cachedBitmapHeight); } - const texture = TextureUtils.generateTexture(this._cachedBitmapData, _local_5); + const texture = new Texture(this._cachedBitmapData.baseTexture, bounds); + const sprite = new Sprite(texture); - if(texture) - { - canvas - .beginTextureFill({ texture }) - .drawRect(0, offsetY, _local_5.width, _local_5.height) - .endFill(); - } + sprite.position.set(0, offsetY); + + TextureUtils.writeToRenderTexture(sprite, canvas, false); } - private getColumnsWidth(columns: Graphics[]): number + private getColumnsWidth(columns: RenderTexture[]): number { if(!columns || !columns.length) return 0; let width = 0; - for(const graphic of columns) + for(const texture of columns) { - if(!graphic) continue; + if(!texture) continue; - width += graphic.width; + width += texture.width; } return width; } - private renderColumns(canvas: Graphics, columns: Graphics[], x: number, flag: boolean): Point + private renderColumns(canvas: RenderTexture, columns: RenderTexture[], x: number, flag: boolean): Point { if(!canvas || !columns || !columns.length) return new Point(x, 0); @@ -375,18 +379,11 @@ export class PlaneMaterialCellMatrix if(this._align == PlaneMaterialCellMatrix.ALIGN_BOTTOM) y = (canvas.height - column.height); - let texture = RoomVisualization.getTextureCache(column); + const sprite = new Sprite(column); - if(!texture) - { - texture = TextureUtils.generateTexture(column, new Rectangle(0, 0, column.width, column.height)); + sprite.position.set(x, y); - RoomVisualization.addTextureCache(column, texture); - } - - canvas.beginTextureFill({ texture }); - canvas.drawRect(x, y, texture.width, texture.height); - canvas.endFill(); + TextureUtils.writeToRenderTexture(sprite, canvas, false); if(column.height > height) height = column.height; @@ -401,7 +398,7 @@ export class PlaneMaterialCellMatrix return new Point(x, height); } - private renderRepeatAll(canvas: Graphics, columns: Graphics[]): number + private renderRepeatAll(canvas: RenderTexture, columns: RenderTexture[]): number { if(!canvas || !columns || !columns.length) return 0; @@ -646,37 +643,37 @@ export class PlaneMaterialCellMatrix // return _local_3; // } - // private renderRepeatRandom(k:BitmapData, _arg_2:Array): number - // { - // var _local_6:Array; - // var _local_7:Point; - // if ((((_arg_2 == null) || (_arg_2.length == 0)) || (k == null))) - // { - // return 0; - // } - // var _local_3: number; - // var _local_4:BitmapData; - // var _local_5: number; - // while (_local_5 < k.width) - // { - // _local_4 = (_arg_2[nextRandomColumnIndex(_arg_2.length)] as BitmapData); - // if (_local_4 != null) - // { - // _local_6 = [_local_4]; - // _local_7 = this.renderColumns(k, _local_6, _local_5, true); - // _local_5 = _local_7.x; - // if (_local_7.y > _local_3) - // { - // _local_3 = _local_7.y; - // } - // } - // else - // { - // return _local_3; - // } - // } - // return _local_3; - // } + private renderRepeatRandom(canvas: RenderTexture, columns: RenderTexture[]): number + { + if(!canvas || !columns || !columns.length) return 0; + + let height = 0; + let width = 0; + + while(width < canvas.width) + { + const column = columns[PlaneMaterialCellMatrix.nextRandomColumnIndex(columns.length)]; + + if(column != null) + { + const point = this.renderColumns(canvas, [ column ], width, true); + + width = point.x; + + if(point.y > height) + { + height = point.y; + } + } + else + { + return height; + + } + } + + return height; + } public getColumns(width: number): PlaneMaterialCellColumn[] { @@ -697,6 +694,7 @@ export class PlaneMaterialCellMatrix if(column.width > 1) columnIndex += column.width; else break; } + else break; } return columns; diff --git a/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneRasterizer.ts b/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneRasterizer.ts index c104fd62..ff351b32 100644 --- a/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneRasterizer.ts +++ b/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneRasterizer.ts @@ -1,7 +1,6 @@ -import { Resource, Texture } from '@pixi/core'; -import { Graphics } from '@pixi/graphics'; +import { RenderTexture, Resource, Texture } from '@pixi/core'; import { Point } from '@pixi/math'; -import { IGraphicAsset, IGraphicAssetCollection, IRoomGeometry, IVector3D, Vector3d } from '../../../../../../../api'; +import { IAssetPlaneMaterial, IAssetPlaneMaterialCellColumn, IAssetPlaneTexture, IAssetPlaneVisualization, IAssetPlaneVisualizationData, IAssetPlaneVisualizationLayer, IGraphicAsset, IGraphicAssetCollection, IRoomGeometry, IVector3D, Vector3d } from '../../../../../../../api'; import { Rasterizer, RoomGeometry } from '../../../../../../../room'; import { PlaneBitmapData } from '../../utils'; import { IPlaneRasterizer } from '../IPlaneRasterizer'; @@ -23,7 +22,7 @@ export class PlaneRasterizer implements IPlaneRasterizer private _textures: Map; private _planes: Map; private _geometries: Map; - private _data: any; + private _data: IAssetPlaneVisualizationData; constructor() { @@ -35,7 +34,7 @@ export class PlaneRasterizer implements IPlaneRasterizer this._data = null; } - protected get data(): any + protected get data(): IAssetPlaneVisualizationData { return this._data; } @@ -111,7 +110,7 @@ export class PlaneRasterizer implements IPlaneRasterizer } } - public initialize(data: any): void + public initialize(data: IAssetPlaneVisualizationData): void { this._data = data; } @@ -199,7 +198,6 @@ export class PlaneRasterizer implements IPlaneRasterizer private initializeTexturesAndMaterials(): void { if(this._data.textures && this._data.textures.length) this.parseTextures(this._data.textures, this.assetCollection); - if(this._data.materials && this._data.materials.length) this.parsePlaneMaterials(this._data.materials); } @@ -207,7 +205,7 @@ export class PlaneRasterizer implements IPlaneRasterizer { } - private parseTextures(textures: any, collection: IGraphicAssetCollection): void + private parseTextures(textures: IAssetPlaneTexture[], collection: IGraphicAssetCollection): void { if(!textures || !collection) return; @@ -255,6 +253,10 @@ export class PlaneRasterizer implements IPlaneRasterizer { newTexture = Rasterizer.getFlipHBitmapData(texture); } + else + { + newTexture = newTexture.clone(); + } plane.addBitmap(newTexture, normalMinX, normalMaxX, normalMinY, normalMaxY, assetName); } @@ -268,7 +270,7 @@ export class PlaneRasterizer implements IPlaneRasterizer } } - private parsePlaneMaterials(materials: any): void + private parsePlaneMaterials(materials: IAssetPlaneMaterial[]): void { if(!materials || !materials.length) return; @@ -285,14 +287,20 @@ export class PlaneRasterizer implements IPlaneRasterizer { if(!matrix) continue; - let repeatMode = matrix.repeatMode; - let align = matrix.align; - const normalMinX = PlaneMaterialCellMatrix.MIN_NORMAL_COORDINATE_VALUE; - const normalMaxX = PlaneMaterialCellMatrix.MAX_NORMAL_COORDINATE_VALUE; - const normalMinY = PlaneMaterialCellMatrix.MIN_NORMAL_COORDINATE_VALUE; - const normalMaxY = PlaneMaterialCellMatrix.MAX_NORMAL_COORDINATE_VALUE; + let repeatMode = PlaneMaterialCellMatrix.REPEAT_MODE_DEFAULT; + let align = PlaneMaterialCellMatrix.ALIGN_DEFAULT; - switch(repeatMode) + let normalMinX = PlaneMaterialCellMatrix.MIN_NORMAL_COORDINATE_VALUE; + let normalMaxX = PlaneMaterialCellMatrix.MAX_NORMAL_COORDINATE_VALUE; + let normalMinY = PlaneMaterialCellMatrix.MIN_NORMAL_COORDINATE_VALUE; + let normalMaxY = PlaneMaterialCellMatrix.MAX_NORMAL_COORDINATE_VALUE; + + if(matrix.normalMinX !== undefined) normalMinX = matrix.normalMinX; + if(matrix.normalMaxX !== undefined) normalMaxX = matrix.normalMaxX; + if(matrix.normalMinY !== undefined) normalMinY = matrix.normalMinY; + if(matrix.normalMaxY !== undefined) normalMaxY = matrix.normalMaxY; + + switch(matrix.repeatMode) { case 'borders': repeatMode = PlaneMaterialCellMatrix.REPEAT_MODE_BORDERS; @@ -314,7 +322,7 @@ export class PlaneRasterizer implements IPlaneRasterizer break; } - switch(align) + switch(matrix.align) { case 'top': align = PlaneMaterialCellMatrix.ALIGN_TOP; @@ -349,7 +357,7 @@ export class PlaneRasterizer implements IPlaneRasterizer } } - private parsePlaneMaterialCellColumn(column: { repeatMode: string, width: number }, cellMatrix: PlaneMaterialCellMatrix, index: number): void + private parsePlaneMaterialCellColumn(column: IAssetPlaneMaterialCellColumn, cellMatrix: PlaneMaterialCellMatrix, index: number): void { if(!column || !cellMatrix) return; @@ -384,7 +392,7 @@ export class PlaneRasterizer implements IPlaneRasterizer cellMatrix.createColumn(index, width, cells, repeatMode); } - private parsePlaneMaterialCells(column: any): PlaneMaterialCell[] + private parsePlaneMaterialCells(column: IAssetPlaneMaterialCellColumn): PlaneMaterialCell[] { if(!column || !column.cells || !column.cells.length) return null; @@ -405,24 +413,20 @@ export class PlaneRasterizer implements IPlaneRasterizer let graphics: IGraphicAsset[] = null; let limit = 0; - if(cell.extras && cell.extras.length) + if(cell.extraData) { - const extra = cell.extras[0]; - const types = extra.types; - const offsets = extra.offsets; + const types = cell.extraData.extraItemTypes; + const offsets = cell.extraData.offsets; if(types && offsets) { if(types.length && offsets.length) { - const type = types[0]; - const offset = offsets[0]; - - assetNames = this.parseExtraItemTypes(type); - offsetPoints = this.parseExtraItemOffsets(offset); + assetNames = this.parseExtraItemTypes(types); + offsetPoints = this.parseExtraItemOffsets(offsets); limit = offsetPoints.length; - if(extra.limitMax) limit = extra.limitMax; + if(cell.extraData.limitMax !== undefined) limit = cell.extraData.limitMax; } } } @@ -457,21 +461,19 @@ export class PlaneRasterizer implements IPlaneRasterizer return cells; } - private parseExtraItemTypes(k: any): string[] + private parseExtraItemTypes(k: string[]): string[] { const assetNames: string[] = []; - if(k && k.types && k.types.length) + if(k && k.length) { let index = 0; - while(index < k.types.length) + while(index < k.length) { - const type = k.types[index]; + const type = k[index]; - const assetName = type.assetName; - - if(assetName) assetNames.push(assetName); + if(type) assetNames.push(type); index++; } @@ -480,20 +482,17 @@ export class PlaneRasterizer implements IPlaneRasterizer return assetNames; } - private parseExtraItemOffsets(k: any): Point[] + private parseExtraItemOffsets(k: [ number, number][]): Point[] { const offsets: Point[] = []; - if(k && k.offsets && k.offsets.length) + if(k && k.length) { let index = 0; - while(index < k.offsets.length) + while(index < k.length) { - const offset = k.offsets[index]; - - const x = offset.x; - const y = offset.y; + const [ x, y ] = k[index]; offsets.push(new Point(x, y)); @@ -525,7 +524,7 @@ export class PlaneRasterizer implements IPlaneRasterizer return geometry; } - protected parseVisualizations(plane: Plane, visualizations: any): void + protected parseVisualizations(plane: Plane, visualizations: IAssetPlaneVisualization[]): void { if(!plane || !visualizations) return; @@ -540,10 +539,10 @@ export class PlaneRasterizer implements IPlaneRasterizer let horizontalAngle = FloorPlane.HORIZONTAL_ANGLE_DEFAULT; let verticalAngle = FloorPlane.VERTICAL_ANGLE_DEFAULT; - if(visualization.horizontalAngle) horizontalAngle = visualization.horizontalAngle; - if(visualization.verticalAngle) verticalAngle = visualization.verticalAngle; + if(visualization.horizontalAngle !== undefined) horizontalAngle = visualization.horizontalAngle; + if(visualization.verticalAngle !== undefined) verticalAngle = visualization.verticalAngle; - const layers = visualization.layers; + const layers = visualization.allLayers as IAssetPlaneVisualizationLayer[]; const planeVisualization = plane.createPlaneVisualization(size, ((layers && layers.length) || 0), this.getGeometry(size, horizontalAngle, verticalAngle)); @@ -585,7 +584,7 @@ export class PlaneRasterizer implements IPlaneRasterizer } } - public render(canvas: Graphics, id: string, width: number, height: number, size: number, normal: IVector3D, useTexture: boolean, offsetX: number = 0, offsetY: number = 0, maxX: number = 0, maxY: number = 0, timeSinceStartMs: number = 0): PlaneBitmapData + public render(planeId: string, canvas: RenderTexture, id: string, width: number, height: number, size: number, normal: IVector3D, useTexture: boolean, offsetX: number = 0, offsetY: number = 0, maxX: number = 0, maxY: number = 0, timeSinceStartMs: number = 0): PlaneBitmapData { return null; } diff --git a/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneTexture.ts b/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneTexture.ts index 5ff8c4eb..d89fe1e0 100644 --- a/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneTexture.ts +++ b/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneTexture.ts @@ -29,9 +29,9 @@ export class PlaneTexture } } - public addBitmap(texture: Texture, normalMinX: number = -1, normalMaxX: number = 1, normalMinY: number = -1, normalMaxY: number = 1, assetName: string = null): void + public addBitmap(bitmap: Texture, normalMinX: number = -1, normalMaxX: number = 1, normalMinY: number = -1, normalMaxY: number = 1, assetName: string = null): void { - this._bitmaps.push(new PlaneTextureBitmap(texture, normalMinX, normalMaxX, normalMinY, normalMaxY, assetName)); + this._bitmaps.push(new PlaneTextureBitmap(bitmap, normalMinX, normalMaxX, normalMinY, normalMaxY, assetName)); } public getBitmap(k: IVector3D): Texture diff --git a/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneTextureBitmap.ts b/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneTextureBitmap.ts index 7049a66a..d49d1f24 100644 --- a/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneTextureBitmap.ts +++ b/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneTextureBitmap.ts @@ -12,14 +12,14 @@ export class PlaneTextureBitmap private _normalMaxY: number; private _assetName: string; - constructor(texture: Texture, normalMinX: number = -1, normalMaxX: number = 1, normalMinY: number = -1, normalMaxY: number = 1, assetName: string = null) + constructor(bitmap: Texture, normalMinX: number = -1, normalMaxX: number = 1, normalMinY: number = -1, normalMaxY: number = 1, assetName: string = null) { + this._bitmap = bitmap; this._normalMinX = normalMinX; this._normalMaxX = normalMaxX; this._normalMinY = normalMinY; this._normalMaxY = normalMaxY; this._assetName = assetName; - this._bitmap = texture; } public get bitmap(): Texture diff --git a/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneVisualization.ts b/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneVisualization.ts index 4c40c495..2e327666 100644 --- a/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneVisualization.ts +++ b/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneVisualization.ts @@ -1,5 +1,7 @@ -import { Graphics } from '@pixi/graphics'; +import { RenderTexture } from '@pixi/core'; +import { Sprite } from '@pixi/sprite'; import { IDisposable, IGraphicAssetCollection, IRoomGeometry, IVector3D, Vector3d } from '../../../../../../../api'; +import { RoomTextureUtils, TextureUtils } from '../../../../../../../pixi-proxy'; import { PlaneVisualizationAnimationLayer } from '../animated'; import { PlaneMaterial } from './PlaneMaterial'; import { PlaneVisualizationLayer } from './PlaneVisualizationLayer'; @@ -8,10 +10,11 @@ export class PlaneVisualization { private _layers: IDisposable[]; private _geometry: IRoomGeometry; - private _cachedBitmapData: Graphics; + private _cachedBitmapData: RenderTexture; private _cachedBitmapNormal: Vector3d; private _isCached: boolean; private _hasAnimationLayers: boolean; + private _texturePool: Map; constructor(size: number, totalLayers: number, geometry: IRoomGeometry) { @@ -21,6 +24,7 @@ export class PlaneVisualization this._cachedBitmapNormal = new Vector3d(); this._isCached = false; this._hasAnimationLayers = false; + this._texturePool = new Map(); if(totalLayers < 0) totalLayers = 0; @@ -98,6 +102,13 @@ export class PlaneVisualization } } + if(this._texturePool && this._texturePool.size) + { + this._texturePool.forEach(texture => texture.destroy(true)); + + this._texturePool.clear(); + } + this._isCached = false; } @@ -137,7 +148,7 @@ export class PlaneVisualization return this._layers as PlaneVisualizationLayer[]; } - public render(canvas: Graphics, width: number, height: number, normal: IVector3D, useTexture: boolean, offsetX: number = 0, offsetY: number = 0, maxX: number = 0, maxY: number = 0, dimensionX: number = 0, dimensionY: number = 0, timeSinceStartMs: number = 0): Graphics + public render(planeId: string, canvas: RenderTexture, width: number, height: number, normal: IVector3D, useTexture: boolean, offsetX: number = 0, offsetY: number = 0, maxX: number = 0, maxY: number = 0, dimensionX: number = 0, dimensionY: number = 0, timeSinceStartMs: number = 0): RenderTexture { if(width < 1) width = 1; @@ -147,26 +158,15 @@ export class PlaneVisualization if(this._cachedBitmapData) { - if(((this._cachedBitmapData.width === width) && (this._cachedBitmapData.height === height)) && (Vector3d.isEqual(this._cachedBitmapNormal, normal))) + if((this._cachedBitmapData.width === width) && (this._cachedBitmapData.height === height) && (Vector3d.isEqual(this._cachedBitmapNormal, normal))) { if(!this.hasAnimationLayers) { if(canvas) { - canvas.addChild(this._cachedBitmapData); + TextureUtils.writeToRenderTexture(new Sprite(this._cachedBitmapData), canvas, true); return canvas; - // const texture = TextureUtils.generateTexture(this._cachedBitmapData, new Rectangle(0, 0, width, height)); - - // if(texture) - // { - // canvas - // .beginTextureFill({ texture }) - // .drawRect(0, 0, texture.width, texture.height) - // .endFill(); - - // return canvas; - // } } return this._cachedBitmapData; @@ -174,8 +174,6 @@ export class PlaneVisualization } else { - this._cachedBitmapData.destroy(); - this._cachedBitmapData = null; } } @@ -184,17 +182,37 @@ export class PlaneVisualization if(!this._cachedBitmapData) { - this._cachedBitmapData = new Graphics() - .beginFill(0xFFFFFF) - .drawRect(0, 0, width, height) - .endFill(); + let cache = this._texturePool.get(planeId); + let swapCache = this._texturePool.get(planeId + '-swap'); + + if(!swapCache) + { + swapCache = RoomTextureUtils.createAndFillRenderTexture(width, height); + + this._texturePool.set(planeId + '-swap', swapCache); + } + else + { + if(cache) + { + [ cache, swapCache ] = [ swapCache, cache ]; + } + } + + if(!cache) + { + cache = RoomTextureUtils.createAndFillRenderTexture(width, height); + + this._texturePool.set(planeId, cache); + } + + this._cachedBitmapData = swapCache; + + TextureUtils.clearAndFillRenderTexture(this._cachedBitmapData); } else { - this._cachedBitmapData - .beginFill(0xFFFFFF) - .drawRect(0, 0, width, height) - .endFill(); + TextureUtils.clearAndFillRenderTexture(this._cachedBitmapData); } if(!canvas) canvas = this._cachedBitmapData; @@ -221,13 +239,7 @@ export class PlaneVisualization if(canvas && (canvas !== this._cachedBitmapData)) { - this._cachedBitmapData.addChild(canvas.clone()); - // const texture = TextureUtils.generateTexture(canvas, new Rectangle(0, 0, canvas.width, canvas.height)); - - // this._cachedBitmapData - // .beginTextureFill({ texture }) - // .drawRect(0, 0, canvas.width, canvas.height) - // .endFill(); + TextureUtils.writeToRenderTexture(new Sprite(canvas), this._cachedBitmapData, false); return canvas; } diff --git a/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneVisualizationLayer.ts b/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneVisualizationLayer.ts index b97e5dff..f5bec4bc 100644 --- a/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneVisualizationLayer.ts +++ b/src/nitro/room/object/visualization/room/rasterizer/basic/PlaneVisualizationLayer.ts @@ -1,8 +1,7 @@ -import { Graphics } from '@pixi/graphics'; -import { Rectangle } from '@pixi/math'; +import { RenderTexture } from '@pixi/core'; +import { Sprite } from '@pixi/sprite'; import { IVector3D } from '../../../../../../../api'; -import { TextureUtils } from '../../../../../../../pixi-proxy'; -import { RoomVisualization } from '../../RoomVisualization'; +import { RoomTextureUtils, TextureUtils } from '../../../../../../../pixi-proxy'; import { PlaneMaterial } from './PlaneMaterial'; export class PlaneVisualizationLayer @@ -16,7 +15,7 @@ export class PlaneVisualizationLayer private _color: number; private _offset: number; private _align: number; - private _bitmapData: Graphics; + private _bitmapData: RenderTexture; private _isDisposed: boolean; constructor(material: PlaneMaterial, color: number, align: number, offset: number = 0) @@ -56,30 +55,49 @@ export class PlaneVisualizationLayer { if(this._bitmapData) { - this._bitmapData.destroy(); + this._bitmapData.destroy(true); this._bitmapData = null; } } - public render(canvas: Graphics, width: number, height: number, normal: IVector3D, useTexture: boolean, offsetX: number, offsetY: number): Graphics + public render(canvas: RenderTexture, width: number, height: number, normal: IVector3D, useTexture: boolean, offsetX: number, offsetY: number): RenderTexture { if(!canvas || (canvas.width !== width) || (canvas.height !== height)) canvas = null; - let bitmapData: Graphics = null; + const r = (this._color >> 16); + const g = ((this._color >> 8) & 0xFF); + const b = (this._color & 0xFF); + + let hasColor = false; + + if(((r < 0xFF) || (g < 0xFF))|| (b < 0xFF)) hasColor = true; + + let bitmapData: RenderTexture = null; if(this._material) { - bitmapData = this._material.render(null, width, height, normal, useTexture, offsetX, (offsetY + this.offset), (this.align === PlaneVisualizationLayer.ALIGN_TOP)); + bitmapData = this._material.render(hasColor ? null : canvas, width, height, normal, useTexture, offsetX, (offsetY + this.offset), (this.align === PlaneVisualizationLayer.ALIGN_TOP)); if(bitmapData && (bitmapData !== canvas)) { if(this._bitmapData) this._bitmapData.destroy(); - this._bitmapData = bitmapData.clone(); + this._bitmapData = new RenderTexture(bitmapData.baseTexture); bitmapData = this._bitmapData; } + + if(bitmapData && hasColor) + { + const sprite = new Sprite(bitmapData); + + sprite.tint = this._color; + + TextureUtils.writeToRenderTexture(sprite, canvas, false); + + bitmapData = canvas; + } } else { @@ -89,45 +107,13 @@ export class PlaneVisualizationLayer if(this._bitmapData) this._bitmapData.destroy(); - const graphic = new Graphics() - .beginFill(0xFFFFFF) - .drawRect(0, 0, width, height) - .endFill(); - - this._bitmapData = graphic; + this._bitmapData = RoomTextureUtils.createAndFillRenderTexture(width, height, this._color); bitmapData = this._bitmapData; } else { - canvas - .beginFill(0xFFFFFF) - .drawRect(0, 0, width, height) - .endFill(); - - bitmapData = canvas; - } - } - - if(bitmapData) - { - bitmapData.tint = this._color; - - if(canvas && (bitmapData !== canvas)) - { - let texture = RoomVisualization.getTextureCache(bitmapData); - - if(!texture) - { - texture = TextureUtils.generateTexture(bitmapData, new Rectangle(0, 0, width, height)); - - RoomVisualization.addTextureCache(bitmapData, texture); - } - - canvas - .beginTextureFill({ texture }) - .drawRect(0, 0, width, height) - .endFill(); + TextureUtils.clearAndFillRenderTexture(canvas, this._color); bitmapData = canvas; } diff --git a/src/nitro/room/object/visualization/room/rasterizer/basic/WallPlane.ts b/src/nitro/room/object/visualization/room/rasterizer/basic/WallPlane.ts index 2f1a1ea3..74776468 100644 --- a/src/nitro/room/object/visualization/room/rasterizer/basic/WallPlane.ts +++ b/src/nitro/room/object/visualization/room/rasterizer/basic/WallPlane.ts @@ -1,4 +1,4 @@ -import { Graphics } from '@pixi/graphics'; +import { RenderTexture } from '@pixi/core'; import { IVector3D, Vector3d } from '../../../../../../../api'; import { Plane } from './Plane'; @@ -8,7 +8,7 @@ export class WallPlane extends Plane public static HORIZONTAL_ANGLE_DEFAULT: number = 45; public static VERTICAL_ANGLE_DEFAULT: number = 30; - public render(canvas: Graphics, width: number, height: number, size: number, normal: IVector3D, useTexture: boolean): Graphics + public render(planeId: string, canvas: RenderTexture, width: number, height: number, size: number, normal: IVector3D, useTexture: boolean): RenderTexture { const visualization = this.getPlaneVisualization(size); @@ -24,6 +24,6 @@ export class WallPlane extends Plane height = Math.round(Math.abs((_local_8.y - _local_9.y))); } - return visualization.render(canvas, width, height, normal, useTexture); + return visualization.render(planeId, canvas, width, height, normal, useTexture); } } diff --git a/src/nitro/room/object/visualization/room/rasterizer/basic/WallRasterizer.ts b/src/nitro/room/object/visualization/room/rasterizer/basic/WallRasterizer.ts index 5eff8cfa..c46ba849 100644 --- a/src/nitro/room/object/visualization/room/rasterizer/basic/WallRasterizer.ts +++ b/src/nitro/room/object/visualization/room/rasterizer/basic/WallRasterizer.ts @@ -1,5 +1,6 @@ -import { Graphics } from '@pixi/graphics'; -import { IVector3D } from '../../../../../../../api'; +import { RenderTexture } from '@pixi/core'; +import { IAssetPlane, IVector3D } from '../../../../../../../api'; +import { TextureUtils } from '../../../../../../../pixi-proxy'; import { PlaneBitmapData } from '../../utils'; import { PlaneRasterizer } from './PlaneRasterizer'; import { WallPlane } from './WallPlane'; @@ -10,12 +11,12 @@ export class WallRasterizer extends PlaneRasterizer { if(!this.data) return; - const walls = this.data.walls; + const walls = this.data.planes; if(walls && walls.length) this.parseWalls(walls); } - private parseWalls(k: any): void + private parseWalls(k: IAssetPlane[]): void { if(!k) return; @@ -35,7 +36,7 @@ export class WallRasterizer extends PlaneRasterizer } } - public render(canvas: Graphics, id: string, width: number, height: number, scale: number, normal: IVector3D, useTexture: boolean, offsetX: number = 0, offsetY: number = 0, maxX: number = 0, maxY: number = 0, timeSinceStartMs: number = 0): PlaneBitmapData + public render(planeId: string, canvas: RenderTexture, id: string, width: number, height: number, scale: number, normal: IVector3D, useTexture: boolean, offsetX: number = 0, offsetY: number = 0, maxX: number = 0, maxY: number = 0, timeSinceStartMs: number = 0): PlaneBitmapData { let plane = this.getPlane(id) as WallPlane; @@ -43,20 +44,13 @@ export class WallRasterizer extends PlaneRasterizer if(!plane) return null; - if(canvas) - { - const rectangle = canvas.getBounds(); + if(canvas) TextureUtils.clearAndFillRenderTexture(canvas); - canvas.clear(); - - canvas.drawRect(rectangle.x, rectangle.y, rectangle.width, rectangle.height); - } - - let graphic = plane.render(canvas, width, height, scale, normal, useTexture); + let graphic = plane.render(planeId, canvas, width, height, scale, normal, useTexture); if(graphic && (graphic !== canvas)) { - graphic = graphic.clone(); + graphic = new RenderTexture(graphic.baseTexture); if(!graphic) return null; } diff --git a/src/nitro/room/object/visualization/room/utils/PlaneBitmapData.ts b/src/nitro/room/object/visualization/room/utils/PlaneBitmapData.ts index 1ccd7312..c72e07fe 100644 --- a/src/nitro/room/object/visualization/room/utils/PlaneBitmapData.ts +++ b/src/nitro/room/object/visualization/room/utils/PlaneBitmapData.ts @@ -1,24 +1,24 @@ -import { Graphics } from '@pixi/graphics'; +import { RenderTexture } from '@pixi/core'; export class PlaneBitmapData { - private _bitmap: Graphics; + private _texture: RenderTexture; private _timeStamp: number; - constructor(k: Graphics, _arg_2: number) + constructor(texture: RenderTexture, timestamp: number) { - this._bitmap = k; - this._timeStamp = _arg_2; + this._texture = texture; + this._timeStamp = timestamp; } public dispose(): void { - this._bitmap = null; + this._texture = null; } - public get bitmap(): Graphics + public get texture(): RenderTexture { - return this._bitmap; + return this._texture; } public get timeStamp(): number diff --git a/src/nitro/room/object/visualization/room/utils/Randomizer.ts b/src/nitro/room/object/visualization/room/utils/Randomizer.ts index 22a90d0d..e7c6c3d0 100644 --- a/src/nitro/room/object/visualization/room/utils/Randomizer.ts +++ b/src/nitro/room/object/visualization/room/utils/Randomizer.ts @@ -1,4 +1,6 @@ -export class Randomizer +import { ToInt32 } from '../../../../../utils'; + +export class Randomizer { public static DEFAULT_SEED: number = 1; public static DEFAULT_MODULUS: number = 16777216; @@ -102,7 +104,7 @@ private iterate(): number { - let k: number = ((this._multiplier * this._seed) + this._increment); + let k: number = ToInt32(Math.trunc(this._multiplier * this._seed) + this._increment); if(k < 0) k = -(k); @@ -119,7 +121,7 @@ if(_arg_2 < 1) return k; - _local_3 = (k + ((_local_3 / this._modulus) * _arg_2)); + _local_3 = Math.trunc(k + ((_local_3 / this._modulus) * _arg_2)); return _local_3; } diff --git a/src/nitro/utils/Int32.ts b/src/nitro/utils/Int32.ts new file mode 100644 index 00000000..1267f480 --- /dev/null +++ b/src/nitro/utils/Int32.ts @@ -0,0 +1,13 @@ +const toUint32 = (x: number) => x >>> 0; + +export const ToInt32 = (x: number) => +{ + const uint32 = toUint32(x); + + if(uint32 >= Math.pow(2, 31)) + { + return uint32 - Math.pow(2, 32); + } + + return uint32; +}; diff --git a/src/nitro/utils/WebGL.ts b/src/nitro/utils/WebGL.ts deleted file mode 100644 index 85a2e9c9..00000000 --- a/src/nitro/utils/WebGL.ts +++ /dev/null @@ -1,8 +0,0 @@ -import { isWebGLSupported } from '@pixi/utils'; -export class WebGL -{ - public static isWebGLAvailable(): boolean - { - return isWebGLSupported(); - } -} diff --git a/src/nitro/utils/index.ts b/src/nitro/utils/index.ts index 1342563a..a09920dc 100644 --- a/src/nitro/utils/index.ts +++ b/src/nitro/utils/index.ts @@ -3,4 +3,4 @@ export * from './FixedSizeStack'; export * from './FriendlyTime'; export * from './FurniId'; export * from './HabboWebTools'; -export * from './WebGL'; +export * from './Int32'; diff --git a/src/pixi-proxy/CopyChannelFilter.ts b/src/pixi-proxy/CopyChannelFilter.ts new file mode 100644 index 00000000..70dd7746 --- /dev/null +++ b/src/pixi-proxy/CopyChannelFilter.ts @@ -0,0 +1,49 @@ +import { Filter, RenderTexture } from '@pixi/core'; + +const vertex = ` +attribute vec2 aVertexPosition; +attribute vec2 aTextureCoord; +uniform mat3 projectionMatrix; +varying vec2 vTextureCoord; +void main(void) +{ + gl_Position = vec4((projectionMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0); + vTextureCoord = aTextureCoord; +}`; + +const fragment = ` +varying vec2 vTextureCoord; +uniform sampler2D uSampler; +uniform sampler2D mask; +uniform int fromChannel; +uniform int toChannel; + +void main(void) { + vec4 maskColor = texture2D(mask, vTextureCoord); + vec4 currentColor = texture2D(uSampler, vTextureCoord); + vec4 adjusted = currentColor; + + if(maskColor.r == 0.0 && maskColor.g == 0.0 && maskColor.b == 0.0) + { + adjusted.a = 0.0; + } + + gl_FragColor = vec4(adjusted.r, adjusted.g, adjusted.b, adjusted.a); +}`; + +export class CopyChannelFilter extends Filter +{ + public static readonly CHANNEL_RED = 0; + public static readonly CHANNEL_GREEN = 1; + public static readonly CHANNEL_BLUE = 2; + public static readonly CHANNEL_ALPHA = 3; + + constructor(mask: RenderTexture, fromChannel: number, toChannel: number) + { + super(vertex, fragment, { + mask: mask.castToBaseTexture(), + fromChannel, + toChannel + }); + } +} diff --git a/src/pixi-proxy/NitroAdjustmentFilter.ts b/src/pixi-proxy/NitroAdjustmentFilter.ts deleted file mode 100644 index 1fb7f616..00000000 --- a/src/pixi-proxy/NitroAdjustmentFilter.ts +++ /dev/null @@ -1,4 +0,0 @@ -import { AdjustmentFilter } from '@pixi/filter-adjustment'; - -export class NitroAdjustmentFilter extends AdjustmentFilter -{} diff --git a/src/pixi-proxy/tilemap/NitroTilemap.ts b/src/pixi-proxy/NitroTilemap.ts similarity index 100% rename from src/pixi-proxy/tilemap/NitroTilemap.ts rename to src/pixi-proxy/NitroTilemap.ts diff --git a/src/pixi-proxy/RoomTextureUtils.ts b/src/pixi-proxy/RoomTextureUtils.ts new file mode 100644 index 00000000..90cdf5ef --- /dev/null +++ b/src/pixi-proxy/RoomTextureUtils.ts @@ -0,0 +1,99 @@ +import { AbstractRenderer, Renderer, RenderTexture, Texture } from '@pixi/core'; +import { DisplayObject } from '@pixi/display'; +import { Extract } from '@pixi/extract'; +import { Matrix, Rectangle } from '@pixi/math'; +import { Sprite } from '@pixi/sprite'; +import { PixiApplicationProxy } from './PixiApplicationProxy'; + +export class RoomTextureUtils +{ + public static RENDER_TEXTURE_CACHE: RenderTexture[] = []; + + public static clearCache(): void + { + this.RENDER_TEXTURE_CACHE.forEach(renderTexture => renderTexture?.destroy(true)); + + this.RENDER_TEXTURE_CACHE = []; + } + + public static clearRenderTexture(renderTexture: RenderTexture): RenderTexture + { + if(!renderTexture) return null; + + return this.writeToRenderTexture(new Sprite(Texture.EMPTY), renderTexture); + } + + public static createRenderTexture(width: number, height: number): RenderTexture + { + if((width < 0) || (height < 0)) return null; + + const renderTexture = RenderTexture.create({ + width, + height + }); + + this.RENDER_TEXTURE_CACHE.push(renderTexture); + + return renderTexture; + } + + public static createAndFillRenderTexture(width: number, height: number, color: number = 16777215): RenderTexture + { + if((width < 0) || (height < 0)) return null; + + const renderTexture = this.createRenderTexture(width, height); + + return this.clearAndFillRenderTexture(renderTexture, color); + } + + public static createAndWriteRenderTexture(width: number, height: number, displayObject: DisplayObject, transform: Matrix = null): RenderTexture + { + if((width < 0) || (height < 0)) return null; + + const renderTexture = this.createRenderTexture(width, height); + + return this.writeToRenderTexture(displayObject, renderTexture, true, transform); + } + + public static clearAndFillRenderTexture(renderTexture: RenderTexture, color: number = 16777215): RenderTexture + { + if(!renderTexture) return null; + + const sprite = new Sprite(Texture.WHITE); + + sprite.tint = color; + + sprite.width = renderTexture.width; + sprite.height = renderTexture.height; + + return this.writeToRenderTexture(sprite, renderTexture); + } + + public static writeToRenderTexture(displayObject: DisplayObject, renderTexture: RenderTexture, clear: boolean = true, transform: Matrix = null): RenderTexture + { + if(!displayObject || !renderTexture) return null; + + this.getRenderer().render(displayObject, { + renderTexture, + clear, + transform + }); + + return renderTexture; + } + + public static getPixels(displayObject: DisplayObject | RenderTexture, frame: Rectangle = null): Uint8Array + { + return this.getExtractor().pixels(displayObject); + } + + public static getRenderer(): Renderer | AbstractRenderer + { + return PixiApplicationProxy.instance.renderer; + } + + public static getExtractor(): Extract + { + return (this.getRenderer().plugins.extract as Extract); + } +} diff --git a/src/pixi-proxy/TextureUtils.ts b/src/pixi-proxy/TextureUtils.ts index 311118df..de4ab8f8 100644 --- a/src/pixi-proxy/TextureUtils.ts +++ b/src/pixi-proxy/TextureUtils.ts @@ -1,16 +1,19 @@ -import { SCALE_MODES } from '@pixi/constants'; import { AbstractRenderer, Renderer, RenderTexture, Resource, Texture } from '@pixi/core'; import { DisplayObject } from '@pixi/display'; import { Extract } from '@pixi/extract'; -import { Rectangle } from '@pixi/math'; +import { Matrix, Rectangle } from '@pixi/math'; +import { settings } from '@pixi/settings'; +import { Sprite } from '@pixi/sprite'; import { PixiApplicationProxy } from './PixiApplicationProxy'; export class TextureUtils { - public static generateTexture(displayObject: DisplayObject, region: Rectangle = null, scaleMode: number = SCALE_MODES.NEAREST, resolution: number = 1): RenderTexture + public static generateTexture(displayObject: DisplayObject, region: Rectangle = null, scaleMode: number = null, resolution: number = 1): RenderTexture { if(!displayObject) return null; + if(scaleMode === null) scaleMode = settings.SCALE_MODE; + return this.getRenderer().generateTexture(displayObject, { scaleMode, resolution, @@ -46,6 +49,73 @@ export class TextureUtils return this.getExtractor().canvas(target); } + public static clearRenderTexture(renderTexture: RenderTexture): RenderTexture + { + if(!renderTexture) return null; + + return this.writeToRenderTexture(new Sprite(Texture.EMPTY), renderTexture); + } + + public static createRenderTexture(width: number, height: number): RenderTexture + { + if((width < 0) || (height < 0)) return null; + + return RenderTexture.create({ + width, + height + }); + } + + public static createAndFillRenderTexture(width: number, height: number, color: number = 16777215): RenderTexture + { + if((width < 0) || (height < 0)) return null; + + const renderTexture = this.createRenderTexture(width, height); + + return this.clearAndFillRenderTexture(renderTexture, color); + } + + public static createAndWriteRenderTexture(width: number, height: number, displayObject: DisplayObject, transform: Matrix = null): RenderTexture + { + if((width < 0) || (height < 0)) return null; + + const renderTexture = this.createRenderTexture(width, height); + + return this.writeToRenderTexture(displayObject, renderTexture, true, transform); + } + + public static clearAndFillRenderTexture(renderTexture: RenderTexture, color: number = 16777215): RenderTexture + { + if(!renderTexture) return null; + + const sprite = new Sprite(Texture.WHITE); + + sprite.tint = color; + + sprite.width = renderTexture.width; + sprite.height = renderTexture.height; + + return this.writeToRenderTexture(sprite, renderTexture); + } + + public static writeToRenderTexture(displayObject: DisplayObject, renderTexture: RenderTexture, clear: boolean = true, transform: Matrix = null): RenderTexture + { + if(!displayObject || !renderTexture) return null; + + this.getRenderer().render(displayObject, { + renderTexture, + clear, + transform + }); + + return renderTexture; + } + + public static getPixels(displayObject: DisplayObject | RenderTexture, frame: Rectangle = null): Uint8Array + { + return this.getExtractor().pixels(displayObject); + } + public static getRenderer(): Renderer | AbstractRenderer { return PixiApplicationProxy.instance.renderer; diff --git a/src/pixi-proxy/adjustment-filter/AdjustmentFilter.ts b/src/pixi-proxy/adjustment-filter/AdjustmentFilter.ts new file mode 100644 index 00000000..118c9a0c --- /dev/null +++ b/src/pixi-proxy/adjustment-filter/AdjustmentFilter.ts @@ -0,0 +1,120 @@ +import { CLEAR_MODES } from '@pixi/constants'; +import { Filter, FilterSystem, RenderTexture } from '@pixi/core'; + +interface AdjustmentFilterOptions +{ + gamma: number; + saturation: number; + contrast: number; + brightness: number; + red: number; + green: number; + blue: number; + alpha: number; +} + +export class AdjustmentFilter extends Filter +{ + /** The amount of luminance */ + public gamma = 1; + + /** The amount of saturation */ + public saturation = 1; + + /** The amount of contrast */ + public contrast = 1; + + /** The amount of brightness */ + public brightness = 1; + + /** The amount of red channel */ + public red = 1; + + /** The amount of green channel */ + public green = 1; + + /** The amount of blue channel */ + public blue = 1; + + /** The amount of alpha channel */ + public alpha = 1; + + /** + * @param {object|number} [options] - The optional parameters of the filter. + * @param {number} [options.gamma=1] - The amount of luminance + * @param {number} [options.saturation=1] - The amount of color saturation + * @param {number} [options.contrast=1] - The amount of contrast + * @param {number} [options.brightness=1] - The overall brightness + * @param {number} [options.red=1] - The multipled red channel + * @param {number} [options.green=1] - The multipled green channel + * @param {number} [options.blue=1] - The multipled blue channel + * @param {number} [options.alpha=1] - The overall alpha amount + */ + constructor(options?: Partial) + { + super( + `attribute vec2 aVertexPosition; + attribute vec2 aTextureCoord; + + uniform mat3 projectionMatrix; + + varying vec2 vTextureCoord; + + void main(void) + { + gl_Position = vec4((projectionMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0); + vTextureCoord = aTextureCoord; + }`, + `varying vec2 vTextureCoord; + uniform sampler2D uSampler; + + uniform float gamma; + uniform float contrast; + uniform float saturation; + uniform float brightness; + uniform float red; + uniform float green; + uniform float blue; + uniform float alpha; + + void main(void) + { + vec4 c = texture2D(uSampler, vTextureCoord); + + if (c.a > 0.0) { + c.rgb /= c.a; + + vec3 rgb = pow(c.rgb, vec3(1. / gamma)); + rgb = mix(vec3(.5), mix(vec3(dot(vec3(.2125, .7154, .0721), rgb)), rgb, saturation), contrast); + rgb.r *= red; + rgb.g *= green; + rgb.b *= blue; + c.rgb = rgb * brightness; + + c.rgb *= c.a; + } + + gl_FragColor = c * alpha; + }`); + + Object.assign(this, options); + } + + /** + * Override existing apply method in PIXI.Filter + * @ignore + */ + apply(filterManager: FilterSystem, input: RenderTexture, output: RenderTexture, clear: CLEAR_MODES): void + { + this.uniforms.gamma = Math.max(this.gamma, 0.0001); + this.uniforms.saturation = this.saturation; + this.uniforms.contrast = this.contrast; + this.uniforms.brightness = this.brightness; + this.uniforms.red = this.red; + this.uniforms.green = this.green; + this.uniforms.blue = this.blue; + this.uniforms.alpha = this.alpha; + + filterManager.applyFilter(this, input, output, clear); + } +} diff --git a/src/pixi-proxy/adjustment-filter/index.ts b/src/pixi-proxy/adjustment-filter/index.ts new file mode 100644 index 00000000..1f6c0ff5 --- /dev/null +++ b/src/pixi-proxy/adjustment-filter/index.ts @@ -0,0 +1 @@ +export * from './AdjustmentFilter'; diff --git a/src/pixi-proxy/index.ts b/src/pixi-proxy/index.ts index 5ade1222..0a12f169 100644 --- a/src/pixi-proxy/index.ts +++ b/src/pixi-proxy/index.ts @@ -1,8 +1,10 @@ +export { POINT_STRUCT_SIZE } from '@pixi/tilemap'; +export * from './adjustment-filter'; +export * from './CopyChannelFilter'; export * from './GetTicker'; export * from './GetTickerFPS'; export * from './GetTickerTime'; export * from './INitroPoint'; -export * from './NitroAdjustmentFilter'; export * from './NitroAlphaFilter'; export * from './NitroBaseTexture'; export * from './NitroContainer'; @@ -14,8 +16,9 @@ export * from './NitroRenderTexture'; export * from './NitroSprite'; export * from './NitroSpritesheet'; export * from './NitroTexture'; +export * from './NitroTilemap'; export * from './PaletteMapFilter'; export * from './PixiApplicationProxy'; export * from './PixiInteractionEventProxy'; +export * from './RoomTextureUtils'; export * from './TextureUtils'; -export * from './tilemap'; diff --git a/src/pixi-proxy/tilemap/index.ts b/src/pixi-proxy/tilemap/index.ts deleted file mode 100644 index d14e1ff8..00000000 --- a/src/pixi-proxy/tilemap/index.ts +++ /dev/null @@ -1,2 +0,0 @@ -export { POINT_STRUCT_SIZE } from '@pixi/tilemap'; -export * from './NitroTilemap'; diff --git a/src/room/renderer/RoomSpriteCanvas.ts b/src/room/renderer/RoomSpriteCanvas.ts index a7134a51..6a88da85 100644 --- a/src/room/renderer/RoomSpriteCanvas.ts +++ b/src/room/renderer/RoomSpriteCanvas.ts @@ -73,7 +73,7 @@ export class RoomSpriteCanvas implements IRoomRenderingCanvas this._container = container; this._geometry = new RoomGeometry(scale, new Vector3d(-135, 30, 0), new Vector3d(11, 11, 5), new Vector3d(-135, 0.5, 0)); - this._animationFPS = Nitro.instance.getConfiguration('system.animation.fps', 24); + this._animationFPS = Nitro.instance.getConfiguration('system.fps.animation', 24); this._renderTimestamp = 0; this._totalTimeRunning = 0; this._lastFrame = 0; diff --git a/src/room/renderer/utils/ExtendedSprite.ts b/src/room/renderer/utils/ExtendedSprite.ts index e86fcc4b..7cff5b0e 100644 --- a/src/room/renderer/utils/ExtendedSprite.ts +++ b/src/room/renderer/utils/ExtendedSprite.ts @@ -1,8 +1,9 @@ import { BLEND_MODES } from '@pixi/constants'; -import { BaseTexture, RenderTexture, Resource, Texture } from '@pixi/core'; +import { BaseTexture, Resource, Texture } from '@pixi/core'; import { Point } from '@pixi/math'; import { Sprite } from '@pixi/sprite'; -import { NitroSprite, TextureUtils } from '../../../pixi-proxy'; +import { AlphaTolerance } from '../../../api'; +import { TextureUtils } from '../../../pixi-proxy'; export class ExtendedSprite extends Sprite { @@ -16,8 +17,6 @@ export class ExtendedSprite extends Sprite private _pairedSpriteId: number; private _pairedSpriteUpdateCounter: number; - public name: string; - constructor(texture: Texture = null) { super(texture); @@ -91,26 +90,7 @@ export class ExtendedSprite extends Sprite //@ts-ignore if(!baseTexture.hitMap) { - let canvas: HTMLCanvasElement = null; - - if(!baseTexture.resource) - { - //@ts-ignore - if(!texture.getLocalBounds) - { - const tempSprite = new NitroSprite(texture); - - canvas = TextureUtils.generateCanvas(tempSprite); - - tempSprite.destroy(); - } - else - { - canvas = TextureUtils.generateCanvas(texture as RenderTexture); - } - } - - if(!ExtendedSprite.generateHitMap(baseTexture, canvas)) return false; + if(!ExtendedSprite.generateHitMap(baseTexture)) return false; } //@ts-ignore @@ -135,65 +115,32 @@ export class ExtendedSprite extends Sprite return (hitMap[ind2] & (1 << ind1)) !== 0; } - private static generateHitMap(baseTexture: BaseTexture, tempCanvas: HTMLCanvasElement = null): boolean + private static generateHitMap(baseTexture: BaseTexture): boolean { - let canvas: HTMLCanvasElement = null; - let context: CanvasRenderingContext2D = null; - - if(tempCanvas) - { - canvas = tempCanvas; - context = canvas.getContext('2d'); - } - else - { - if(!baseTexture.resource) return false; - - //@ts-ignore - const source = baseTexture.resource.source as HTMLCanvasElement; - - if(!source) return false; - - if(source.getContext) - { - canvas = source; - context = canvas.getContext('2d'); - } - - else if(source instanceof Image) - { - canvas = document.createElement('canvas'); - canvas.width = source.width; - canvas.height = source.height; - context = canvas.getContext('2d'); - - context.drawImage(source, 0, 0); - } - - else return false; - } - - const width = canvas.width; - const height = canvas.height; - const imageData = context.getImageData(0, 0, width, height); + if(!baseTexture) return false; + const texture = new Texture(baseTexture); + const sprite = new Sprite(texture); + const pixels = TextureUtils.getPixels(sprite); + const width = baseTexture.width; + const height = baseTexture.height; const hitmap = new Uint32Array(Math.ceil(width * height / 32)); - const threshold = 128; + const threshold = AlphaTolerance.MATCH_OPAQUE_PIXELS; for(let i = 0; i < width * height; i++) { const ind1 = i % 32; const ind2 = i / 32 | 0; - if(imageData.data[i * 4 + 3] >= threshold) - { - hitmap[ind2] = hitmap[ind2] | (1 << ind1); - } + if(pixels[i * 4 + 3] >= threshold) hitmap[ind2] = hitmap[ind2] | (1 << ind1); } //@ts-ignore baseTexture.hitMap = hitmap; + sprite.destroy(); + texture.destroy(); + return true; } diff --git a/src/room/utils/ColorConverter.ts b/src/room/utils/ColorConverter.ts index 839f167e..ab2c3695 100644 --- a/src/room/utils/ColorConverter.ts +++ b/src/room/utils/ColorConverter.ts @@ -335,4 +335,19 @@ export class ColorConverter { return ColorConverter.xyz2CieLab(ColorConverter.rgb2xyz(k)); } + + public static colorize(colorA: number, colorB: number): number + { + if(colorB === 0xFFFFFFFF) return colorA; + + let r = ((colorB >> 16) & 0xFF); + let g = ((colorB >> 8) & 0xFF); + let b = (colorB & 0xFF); + + r = ((((colorA >> 16) & 0xFF) * r) / 0xFF); + g = ((((colorA >> 8) & 0xFF) * g) / 0xFF); + b = (((colorA & 0xFF) * b) / 0xFF); + + return ((colorA && 0xFF000000) | (r << 16) | (g << 8) | b); + } } diff --git a/src/room/utils/Rasterizer.ts b/src/room/utils/Rasterizer.ts index 2fc1420b..df75b6f3 100644 --- a/src/room/utils/Rasterizer.ts +++ b/src/room/utils/Rasterizer.ts @@ -1,7 +1,8 @@ import { Resource, Texture } from '@pixi/core'; import { Graphics } from '@pixi/graphics'; import { Matrix } from '@pixi/math'; -import { TextureUtils } from '../../pixi-proxy'; +import { Sprite } from '@pixi/sprite'; +import { PixiApplicationProxy, TextureUtils } from '../../pixi-proxy'; export class Rasterizer { @@ -67,22 +68,20 @@ export class Rasterizer { if(!k) return null; + const renderTexture = TextureUtils.createRenderTexture(k.width, k.height); + const matrix = new Matrix(); matrix.scale(-1, 1); matrix.translate(k.width, 0); - const graphic = new Graphics(); + PixiApplicationProxy.instance.renderer.render(new Sprite(k), { + renderTexture, + clear: true, + transform: matrix + }); - graphic - .beginTextureFill({ - texture: k, - matrix - }) - .drawRect(0, 0, k.width, k.height) - .endFill(); - - return TextureUtils.generateTexture(graphic); + return renderTexture; } public static getFlipVBitmapData(k: Texture): Texture diff --git a/tsconfig.json b/tsconfig.json index 4a96583b..6b1f315e 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -6,7 +6,7 @@ "sourceMap": false, "declaration": true, "experimentalDecorators": true, - "moduleResolution": "node", + "moduleResolution": "Node", "esModuleInterop": true, "importHelpers": true, "isolatedModules": true, @@ -16,13 +16,13 @@ "allowJs": true, "skipLibCheck": true, "noEmit": true, - "target": "es5", + "target": "ES6", "lib": [ - "dom", - "dom.iterable", - "esnext" + "DOM", + "DOM.Iterable", + "ESNext" ], - "module": "esnext", + "module": "ES6", "paths": { "mini-signals": [ "node_modules/mini-signals/index.js" diff --git a/vite.config.js b/vite.config.js new file mode 100644 index 00000000..40ccd6b9 --- /dev/null +++ b/vite.config.js @@ -0,0 +1,36 @@ +// vite.config.js +import typescript from '@rollup/plugin-typescript'; +import { resolve } from 'path'; +import { defineConfig } from 'vite'; +import { ViteMinifyPlugin } from 'vite-plugin-minify'; + +const resolvePath = str => resolve(__dirname, str); + +export default defineConfig({ + plugins: [ + typescript({ + 'target': 'es6', + 'rootDir': resolvePath('./src'), + 'declaration': true, + exclude: resolvePath('./node_modules/**'), + allowSyntheticDefaultImports: true + }), + ViteMinifyPlugin() + ], + build: { + lib: { + entry: resolve(__dirname, 'src/index.ts'), + name: 'nitro-renderer', + fileName: 'nitro-renderer' + } + }, + resolve: { + alias: { + '@': resolve(__dirname, 'src'), + '~': resolve(__dirname, 'node_modules') + } + }, + server: { + host: '127.0.0.1' + } +}); diff --git a/yarn.lock b/yarn.lock index 19b0b998..885907fb 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2,14 +2,124 @@ # yarn lockfile v1 -"@eslint/eslintrc@^1.3.0": - version "1.3.0" - resolved "https://registry.yarnpkg.com/@eslint/eslintrc/-/eslintrc-1.3.0.tgz#29f92c30bb3e771e4a2048c95fa6855392dfac4f" - integrity sha512-UWW0TMTmk2d7hLcWD1/e2g5HDM/HQ3csaLSqXCfqwh4uNDuNqlaKWXmEsL4Cs41Z0KnILNvwbHAah3C2yt06kw== +"@esbuild/android-arm64@0.16.9": + version "0.16.9" + resolved "https://registry.yarnpkg.com/@esbuild/android-arm64/-/android-arm64-0.16.9.tgz#474da719599f99d820ec010c92846a4f685fa28a" + integrity sha512-ndIAZJUeLx4O+4AJbFQCurQW4VRUXjDsUvt1L+nP8bVELOWdmdCEOtlIweCUE6P+hU0uxYbEK2AEP0n5IVQvhg== + +"@esbuild/android-arm@0.16.9": + version "0.16.9" + resolved "https://registry.yarnpkg.com/@esbuild/android-arm/-/android-arm-0.16.9.tgz#b0747ec074bba3ca652bfa8de3f55acfbb2d259e" + integrity sha512-kW5ccqWHVOOTGUkkJbtfoImtqu3kA1PFkivM+9QPFSHphPfPBlBalX9eDRqPK+wHCqKhU48/78T791qPgC9e9A== + +"@esbuild/android-x64@0.16.9": + version "0.16.9" + resolved "https://registry.yarnpkg.com/@esbuild/android-x64/-/android-x64-0.16.9.tgz#1cd75e8ed7d6d7eb5f9896f623df63882bd8e887" + integrity sha512-UbMcJB4EHrAVOnknQklREPgclNU2CPet2h+sCBCXmF2mfoYWopBn/CfTfeyOkb/JglOcdEADqAljFndMKnFtOw== + +"@esbuild/darwin-arm64@0.16.9": + version "0.16.9" + resolved "https://registry.yarnpkg.com/@esbuild/darwin-arm64/-/darwin-arm64-0.16.9.tgz#820c88738cd97621737abcd5f05400ae5e0c66e6" + integrity sha512-d7D7/nrt4CxPul98lx4PXhyNZwTYtbdaHhOSdXlZuu5zZIznjqtMqLac8Bv+IuT6SVHiHUwrkL6ywD7mOgLW+A== + +"@esbuild/darwin-x64@0.16.9": + version "0.16.9" + resolved "https://registry.yarnpkg.com/@esbuild/darwin-x64/-/darwin-x64-0.16.9.tgz#5a19c00781595e0dfeef1826b3512d04c37b98ff" + integrity sha512-LZc+Wlz06AkJYtwWsBM3x2rSqTG8lntDuftsUNQ3fCx9ZttYtvlDcVtgb+NQ6t9s6K5No5zutN3pcjZEC2a4iQ== + +"@esbuild/freebsd-arm64@0.16.9": + version "0.16.9" + resolved "https://registry.yarnpkg.com/@esbuild/freebsd-arm64/-/freebsd-arm64-0.16.9.tgz#2b7c16f5d15c259ed279b293b97c28c4a4bb107f" + integrity sha512-gIj0UQZlQo93CHYouHKkpzP7AuruSaMIm1etcWIxccFEVqCN1xDr6BWlN9bM+ol/f0W9w3hx3HDuEwcJVtGneQ== + +"@esbuild/freebsd-x64@0.16.9": + version "0.16.9" + resolved "https://registry.yarnpkg.com/@esbuild/freebsd-x64/-/freebsd-x64-0.16.9.tgz#2db48ffeeab149c2b970494a60b82bf3004b8630" + integrity sha512-GNors4vaMJ7lzGOuhzNc7jvgsQZqErGA8rsW+nck8N1nYu86CvsJW2seigVrQQWOV4QzEP8Zf3gm+QCjA2hnBQ== + +"@esbuild/linux-arm64@0.16.9": + version "0.16.9" + resolved "https://registry.yarnpkg.com/@esbuild/linux-arm64/-/linux-arm64-0.16.9.tgz#4c63c9f8ddd690d140ac3e0f360226d3fcdd75d8" + integrity sha512-YPxQunReYp8RQ1FvexFrOEqqf+nLbS3bKVZF5FRT2uKM7Wio7BeATqAwO02AyrdSEntt3I5fhFsujUChIa8CZg== + +"@esbuild/linux-arm@0.16.9": + version "0.16.9" + resolved "https://registry.yarnpkg.com/@esbuild/linux-arm/-/linux-arm-0.16.9.tgz#7704de1c2a30bc68d8f615d3ecb1cf68f001256a" + integrity sha512-cNx1EF99c2t1Ztn0lk9N+MuwBijGF8mH6nx9GFsB3e0lpUpPkCE/yt5d+7NP9EwJf5uzqdjutgVYoH1SNqzudA== + +"@esbuild/linux-ia32@0.16.9": + version "0.16.9" + resolved "https://registry.yarnpkg.com/@esbuild/linux-ia32/-/linux-ia32-0.16.9.tgz#bf0fda9f046e6c8332d7c8350b8a94d63acb4ceb" + integrity sha512-zb12ixDIKNwFpIqR00J88FFitVwOEwO78EiUi8wi8FXlmSc3GtUuKV/BSO+730Kglt0B47+ZrJN1BhhOxZaVrw== + +"@esbuild/linux-loong64@0.16.9": + version "0.16.9" + resolved "https://registry.yarnpkg.com/@esbuild/linux-loong64/-/linux-loong64-0.16.9.tgz#c16378b898fa38f5f788f76fbce16a45c49c8793" + integrity sha512-X8te4NLxtHiNT6H+4Pfm5RklzItA1Qy4nfyttihGGX+Koc53Ar20ViC+myY70QJ8PDEOehinXZj/F7QK3A+MKQ== + +"@esbuild/linux-mips64el@0.16.9": + version "0.16.9" + resolved "https://registry.yarnpkg.com/@esbuild/linux-mips64el/-/linux-mips64el-0.16.9.tgz#492605f13f19dc06c350d94e4048c21478b9dec4" + integrity sha512-ZqyMDLt02c5smoS3enlF54ndK5zK4IpClLTxF0hHfzHJlfm4y8IAkIF8LUW0W7zxcKy7oAwI7BRDqeVvC120SA== + +"@esbuild/linux-ppc64@0.16.9": + version "0.16.9" + resolved "https://registry.yarnpkg.com/@esbuild/linux-ppc64/-/linux-ppc64-0.16.9.tgz#ccaf759fc4f7a5fe72bdac05b4f5bf18ef1fe01b" + integrity sha512-k+ca5W5LDBEF3lfDwMV6YNXwm4wEpw9krMnNvvlNz3MrKSD2Eb2c861O0MaKrZkG/buTQAP4vkavbLwgIe6xjg== + +"@esbuild/linux-riscv64@0.16.9": + version "0.16.9" + resolved "https://registry.yarnpkg.com/@esbuild/linux-riscv64/-/linux-riscv64-0.16.9.tgz#542d0e68bc99fb658fe732b0917931c09775f1a3" + integrity sha512-GuInVdogjmg9DhgkEmNipHkC+3tzkanPJzgzTC2ihsvrruLyFoR1YrTGixblNSMPudQLpiqkcwGwwe0oqfrvfA== + +"@esbuild/linux-s390x@0.16.9": + version "0.16.9" + resolved "https://registry.yarnpkg.com/@esbuild/linux-s390x/-/linux-s390x-0.16.9.tgz#4398f9d9d64dba4cfa6eed267476eaa9c9b7f214" + integrity sha512-49wQ0aYkvwXonGsxc7LuuLNICMX8XtO92Iqmug5Qau0kpnV6SP34jk+jIeu4suHwAbSbRhVFtDv75yRmyfQcHw== + +"@esbuild/linux-x64@0.16.9": + version "0.16.9" + resolved "https://registry.yarnpkg.com/@esbuild/linux-x64/-/linux-x64-0.16.9.tgz#67c6b418ef36addbca17af0d7a2274c37ddffba2" + integrity sha512-Nx4oKEAJ6EcQlt4dK7qJyuZUoXZG7CAeY22R7rqZijFzwFfMOD+gLP56uV7RrV86jGf8PeRY8TBsRmOcZoG42w== + +"@esbuild/netbsd-x64@0.16.9": + version "0.16.9" + resolved "https://registry.yarnpkg.com/@esbuild/netbsd-x64/-/netbsd-x64-0.16.9.tgz#22ed58e404ebeb2475b821bc4e25f1027eb0c912" + integrity sha512-d0WnpgJ+FTiMZXEQ1NOv9+0gvEhttbgKEvVqWWAtl1u9AvlspKXbodKHzQ5MLP6YV1y52Xp+p8FMYqj8ykTahg== + +"@esbuild/openbsd-x64@0.16.9": + version "0.16.9" + resolved "https://registry.yarnpkg.com/@esbuild/openbsd-x64/-/openbsd-x64-0.16.9.tgz#2b2597b4edd4d26946f7c56838680fbeb4d455eb" + integrity sha512-jccK11278dvEscHFfMk5EIPjF4wv1qGD0vps7mBV1a6TspdR36O28fgPem/SA/0pcsCPHjww5ouCLwP+JNAFlw== + +"@esbuild/sunos-x64@0.16.9": + version "0.16.9" + resolved "https://registry.yarnpkg.com/@esbuild/sunos-x64/-/sunos-x64-0.16.9.tgz#c132603a19ef79c0d7bd95afb09f41618ea8dda2" + integrity sha512-OetwTSsv6mIDLqN7I7I2oX9MmHGwG+AP+wKIHvq+6sIHwcPPJqRx+DJB55jy9JG13CWcdcQno/7V5MTJ5a0xfQ== + +"@esbuild/win32-arm64@0.16.9": + version "0.16.9" + resolved "https://registry.yarnpkg.com/@esbuild/win32-arm64/-/win32-arm64-0.16.9.tgz#bf74d007d7f0fe1fe32c4fff82d27b271b3e1d58" + integrity sha512-tKSSSK6unhxbGbHg+Cc+JhRzemkcsX0tPBvG0m5qsWbkShDK9c+/LSb13L18LWVdOQZwuA55Vbakxmt6OjBDOQ== + +"@esbuild/win32-ia32@0.16.9": + version "0.16.9" + resolved "https://registry.yarnpkg.com/@esbuild/win32-ia32/-/win32-ia32-0.16.9.tgz#e46478e77431bca1a8b80f6260fc6b0020aa8127" + integrity sha512-ZTQ5vhNS5gli0KK8I6/s6+LwXmNEfq1ftjnSVyyNm33dBw8zDpstqhGXYUbZSWWLvkqiRRjgxgmoncmi6Yy7Ng== + +"@esbuild/win32-x64@0.16.9": + version "0.16.9" + resolved "https://registry.yarnpkg.com/@esbuild/win32-x64/-/win32-x64-0.16.9.tgz#4595a29c2930c5157aa1be0963abbbac989647c9" + integrity sha512-C4ZX+YFIp6+lPrru3tpH6Gaapy8IBRHw/e7l63fzGDhn/EaiGpQgbIlT5paByyy+oMvRFQoxxyvC4LE0AjJMqQ== + +"@eslint/eslintrc@^1.3.3": + version "1.3.3" + resolved "https://registry.yarnpkg.com/@eslint/eslintrc/-/eslintrc-1.3.3.tgz#2b044ab39fdfa75b4688184f9e573ce3c5b0ff95" + integrity sha512-uj3pT6Mg+3t39fvLrj8iuCIJ38zKO9FpGtJ4BBJebJhEwjoT+KLVNCcHT5QC9NGRIEi7fZ0ZR8YRb884auB4Lg== dependencies: ajv "^6.12.4" debug "^4.3.2" - espree "^9.3.2" + espree "^9.4.0" globals "^13.15.0" ignore "^5.2.0" import-fresh "^3.2.1" @@ -17,23 +127,68 @@ minimatch "^3.1.2" strip-json-comments "^3.1.1" -"@humanwhocodes/config-array@^0.9.2": - version "0.9.5" - resolved "https://registry.npmjs.org/@humanwhocodes/config-array/-/config-array-0.9.5.tgz" - integrity sha512-ObyMyWxZiCu/yTisA7uzx81s40xR2fD5Cg/2Kq7G02ajkNubJf6BopgDTmDyc3U7sXpNKM8cYOw7s7Tyr+DnCw== +"@humanwhocodes/config-array@^0.11.6": + version "0.11.8" + resolved "https://registry.yarnpkg.com/@humanwhocodes/config-array/-/config-array-0.11.8.tgz#03595ac2075a4dc0f191cc2131de14fbd7d410b9" + integrity sha512-UybHIJzJnR5Qc/MsD9Kr+RpO2h+/P1GhOwdiLPXK5TWk5sgTdu88bTD9UP+CKbPPh5Rni1u0GjAdYQLemG8g+g== dependencies: "@humanwhocodes/object-schema" "^1.2.1" debug "^4.1.1" - minimatch "^3.0.4" + minimatch "^3.0.5" + +"@humanwhocodes/module-importer@^1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@humanwhocodes/module-importer/-/module-importer-1.0.1.tgz#af5b2691a22b44be847b0ca81641c5fb6ad0172c" + integrity sha512-bxveV4V8v5Yb4ncFTT3rPSgZBOpCkjfK0y4oVVVJwIuDVBRMDXrPyXRL988i5ap9m9bnyEEjWfm5WkBmtffLfA== "@humanwhocodes/object-schema@^1.2.1": version "1.2.1" - resolved "https://registry.npmjs.org/@humanwhocodes/object-schema/-/object-schema-1.2.1.tgz" + resolved "https://registry.yarnpkg.com/@humanwhocodes/object-schema/-/object-schema-1.2.1.tgz#b520529ec21d8e5945a1851dfd1c32e94e39ff45" integrity sha512-ZnQMnLV4e7hDlUvw8H+U8ASL02SS2Gn6+9Ac3wGGLIe7+je2AeAOxPY+izIPJDfFDb7eDjev0Us8MO1iFRN8hA== +"@jridgewell/gen-mapping@^0.3.0": + version "0.3.2" + resolved "https://registry.yarnpkg.com/@jridgewell/gen-mapping/-/gen-mapping-0.3.2.tgz#c1aedc61e853f2bb9f5dfe6d4442d3b565b253b9" + integrity sha512-mh65xKQAzI6iBcFzwv28KVWSmCkdRBWoOh+bYQGW3+6OZvbbN3TqMGo5hqYxQniRcH9F2VZIoJCm4pa3BPDK/A== + dependencies: + "@jridgewell/set-array" "^1.0.1" + "@jridgewell/sourcemap-codec" "^1.4.10" + "@jridgewell/trace-mapping" "^0.3.9" + +"@jridgewell/resolve-uri@3.1.0": + version "3.1.0" + resolved "https://registry.yarnpkg.com/@jridgewell/resolve-uri/-/resolve-uri-3.1.0.tgz#2203b118c157721addfe69d47b70465463066d78" + integrity sha512-F2msla3tad+Mfht5cJq7LSXcdudKTWCVYUgw6pLFOOHSTtZlj6SWNYAp+AhuqLmWdBO2X5hPrLcu8cVP8fy28w== + +"@jridgewell/set-array@^1.0.1": + version "1.1.2" + resolved "https://registry.yarnpkg.com/@jridgewell/set-array/-/set-array-1.1.2.tgz#7c6cf998d6d20b914c0a55a91ae928ff25965e72" + integrity sha512-xnkseuNADM0gt2bs+BvhO0p78Mk762YnZdsuzFV018NoG1Sj1SCQvpSqa7XUaTam5vAGasABV9qXASMKnFMwMw== + +"@jridgewell/source-map@^0.3.2": + version "0.3.2" + resolved "https://registry.yarnpkg.com/@jridgewell/source-map/-/source-map-0.3.2.tgz#f45351aaed4527a298512ec72f81040c998580fb" + integrity sha512-m7O9o2uR8k2ObDysZYzdfhb08VuEml5oWGiosa1VdaPZ/A6QyPkAJuwN0Q1lhULOf6B7MtQmHENS743hWtCrgw== + dependencies: + "@jridgewell/gen-mapping" "^0.3.0" + "@jridgewell/trace-mapping" "^0.3.9" + +"@jridgewell/sourcemap-codec@1.4.14", "@jridgewell/sourcemap-codec@^1.4.10": + version "1.4.14" + resolved "https://registry.yarnpkg.com/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.14.tgz#add4c98d341472a289190b424efbdb096991bb24" + integrity sha512-XPSJHWmi394fuUuzDnGz1wiKqWfo1yXecHQMRf2l6hztTO+nPru658AyDngaBe7isIxEkRsPR3FZh+s7iVa4Uw== + +"@jridgewell/trace-mapping@^0.3.9": + version "0.3.17" + resolved "https://registry.yarnpkg.com/@jridgewell/trace-mapping/-/trace-mapping-0.3.17.tgz#793041277af9073b0951a7fe0f0d8c4c98c36985" + integrity sha512-MCNzAp77qzKca9+W/+I0+sEpaUnZoeasnghNeVc41VZCEKaCH73Vq3BZZ/SzWIgrqE4H4ceI+p+b6C0mHf9T4g== + dependencies: + "@jridgewell/resolve-uri" "3.1.0" + "@jridgewell/sourcemap-codec" "1.4.14" + "@nodelib/fs.scandir@2.1.5": version "2.1.5" - resolved "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz" + resolved "https://registry.yarnpkg.com/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz#7619c2eb21b25483f6d167548b4cfd5a7488c3d5" integrity sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g== dependencies: "@nodelib/fs.stat" "2.0.5" @@ -41,292 +196,320 @@ "@nodelib/fs.stat@2.0.5", "@nodelib/fs.stat@^2.0.2": version "2.0.5" - resolved "https://registry.npmjs.org/@nodelib/fs.stat/-/fs.stat-2.0.5.tgz" + resolved "https://registry.yarnpkg.com/@nodelib/fs.stat/-/fs.stat-2.0.5.tgz#5bd262af94e9d25bd1e71b05deed44876a222e8b" integrity sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A== -"@nodelib/fs.walk@^1.2.3": +"@nodelib/fs.walk@^1.2.3", "@nodelib/fs.walk@^1.2.8": version "1.2.8" - resolved "https://registry.npmjs.org/@nodelib/fs.walk/-/fs.walk-1.2.8.tgz" + resolved "https://registry.yarnpkg.com/@nodelib/fs.walk/-/fs.walk-1.2.8.tgz#e95737e8bb6746ddedf69c556953494f196fe69a" integrity sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg== dependencies: "@nodelib/fs.scandir" "2.1.5" fastq "^1.6.0" -"@pixi/app@~6.4.2": - version "6.4.2" - resolved "https://registry.yarnpkg.com/@pixi/app/-/app-6.4.2.tgz#d24e1fe4cb415e8dd7f2fd26a8e59969debee3ca" - integrity sha512-r0cTQan9ST0N+QmaaZQso7q0Q/lk9pUXB7dez+2vrLEbP8TAnLym2V2H+ChN6TwD+EoX6qXD7oFohNbwPedNyA== +"@pixi/app@~6.5.0": + version "6.5.8" + resolved "https://registry.yarnpkg.com/@pixi/app/-/app-6.5.8.tgz#0a09bce23a222458e6a769d8ecbb0643ee165368" + integrity sha512-pDPkamtYDaPhscNxack+bHNqazCwrqw6cAotKyoz1mvLXeGhxqTntOcfgGLZR2fNbnY8EBmdduLvH7n2jI/LTg== -"@pixi/basis@~6.4.2": - version "6.4.2" - resolved "https://registry.yarnpkg.com/@pixi/basis/-/basis-6.4.2.tgz#27631986560c2dc7c07a0059be4c122c3dbe1753" - integrity sha512-R17XUYnni8Nkg4Z9b2h/GYSQsY/iUQEZWJK3QHhdCbTOVb+NyKpEO7Jt5aOIqdpmC7jEySIN3x64xa+Wq+Ezbg== +"@pixi/basis@~6.5.0": + version "6.5.8" + resolved "https://registry.yarnpkg.com/@pixi/basis/-/basis-6.5.8.tgz#a9ded903fea5d0ba240c22839648868de2f64702" + integrity sha512-j4j08fZsdg8b3F1Cs1cE478m6aVk6ix53pTrv+kxq0Givl3ctO+wwWEU07BFAuvsGGySKrhAEt4vmz78cRK9KQ== -"@pixi/canvas-display@~6.4.2": - version "6.4.2" - resolved "https://registry.yarnpkg.com/@pixi/canvas-display/-/canvas-display-6.4.2.tgz#3641eb07db542c0e3fc80fb9110b245dbe712887" - integrity sha512-RoHJLcLkl4w3a3HrWhkvB8Tu9V0GWIxOcdM81o58rBFhi+BWC4MEuiqkQ/6AUXaaCSYV4dIbyiEbrxb7fJM57g== +"@pixi/canvas-display@~6.5.0": + version "6.5.8" + resolved "https://registry.yarnpkg.com/@pixi/canvas-display/-/canvas-display-6.5.8.tgz#9d280a2ee8b9ec0fbf2a9420b592152f91902997" + integrity sha512-7kgFmN2dCWBhgo+CEKpZDmgqRkYCQeHoVsyOSyxSvTqHDnMjFane1OwTBg6p4PlsE+Jn1BEx/3V2ja/XbR9XOg== -"@pixi/canvas-extract@~6.4.2": - version "6.4.2" - resolved "https://registry.yarnpkg.com/@pixi/canvas-extract/-/canvas-extract-6.4.2.tgz#224ca7399fb0f7e0f551b5c437357b4078a68cdd" - integrity sha512-BNddDRWD0Eejn7pozqTJkmfQNVcwx9r++aAFZ4DOqXJji84G57M4eXkdM22+N4j5hgxxxiCTZCkYUmCIk9Y/RQ== +"@pixi/canvas-extract@~6.5.0": + version "6.5.8" + resolved "https://registry.yarnpkg.com/@pixi/canvas-extract/-/canvas-extract-6.5.8.tgz#c4ae9f6c29aea26ac9cdc00ed89c84ba213aa2ec" + integrity sha512-9jRVlQpumyj0QWF9CQzsDqg7QkqYxLhX/Xu87o5bWfpwrocF6AlJJak0zc6WMLvDEJ1ZI3mNdV2P1AW9ba4+WA== -"@pixi/canvas-renderer@~6.4.2": - version "6.4.2" - resolved "https://registry.yarnpkg.com/@pixi/canvas-renderer/-/canvas-renderer-6.4.2.tgz#cd73279918f3c61a09645d5e2bdae3585ffd7c44" - integrity sha512-NnVT61LlzCk80FGl/imp8zVg6cxinyFk7uljTYJBPJTM6PBFdn/LD+H3wcdbggjNWVSfqwYXVM6gN5Ce22tONg== +"@pixi/canvas-renderer@~6.5.0": + version "6.5.8" + resolved "https://registry.yarnpkg.com/@pixi/canvas-renderer/-/canvas-renderer-6.5.8.tgz#88c816f9b0aa116ac25d322963f6a0f7bc3051c4" + integrity sha512-W+qp05VNtPIoE1/azAyAcYLYXONdql15ts72bsGssRvGJGmECzfhOKq389S4j9X5uVKm51CZhChE7yReWkbUEw== -"@pixi/constants@~6.4.2": - version "6.4.2" - resolved "https://registry.yarnpkg.com/@pixi/constants/-/constants-6.4.2.tgz#1835fe2cbae9ce7865f9a67bd2d4aef800be6a11" - integrity sha512-qj+eviYmJqeGkMbIKSkp1FVMLglQPVyzzyo/2/0VYmSuY4m4WItC4w3wtyjDd4vBK9YxZIUBZz+LKJvKkRplLQ== +"@pixi/constants@~6.5.0": + version "6.5.8" + resolved "https://registry.yarnpkg.com/@pixi/constants/-/constants-6.5.8.tgz#034bf0f318546bf3c9346f4f3a7528f8cadcdb55" + integrity sha512-yYRCebBPqajm1kn5f8QQTTvl7oDRDk1nppfO+JpqbrFXg0W7oqIMurec3KeG9RdZW5foOiXDoz1Gw+VtolYIEw== -"@pixi/core@~6.4.2": - version "6.4.2" - resolved "https://registry.yarnpkg.com/@pixi/core/-/core-6.4.2.tgz#b62fa4dc59280313a33922eac69db63f0336db42" - integrity sha512-W5RWg0537uz2ni0BW9pA0gRmYGBE628e5XR4iDXO5VLSIZmc4jcaBLsPC7o1amcg1xo5Ty44yMpVpodv+GGRCw== +"@pixi/core@~6.5.0": + version "6.5.8" + resolved "https://registry.yarnpkg.com/@pixi/core/-/core-6.5.8.tgz#6b4fb6d877723427c8b3b438d071c1d523a859f5" + integrity sha512-Gconik7/PpFPMpCpOddXVIPx5C2StWKw7lQ4YX19yQ+cRRmecCea2cV0xTBtpEjjx0ilX7nBfIEuZ4zIlMmlbA== dependencies: "@types/offscreencanvas" "^2019.6.4" -"@pixi/display@~6.4.2": - version "6.4.2" - resolved "https://registry.yarnpkg.com/@pixi/display/-/display-6.4.2.tgz#04ad9c5b41e039fe9a778c5346d28a810d82a2fe" - integrity sha512-mE35oRa4Ex5NOVXsuk7JldmmjBfO0gtOO7FPU3VpheOB13HLoacJ4XAa1HfAGapFiFZe+K19gOXEiOj1RyJfGA== +"@pixi/display@~6.5.0": + version "6.5.8" + resolved "https://registry.yarnpkg.com/@pixi/display/-/display-6.5.8.tgz#f6e69aba09926affd610ad90b68b01cf6d5e3a64" + integrity sha512-2K8YOG8s0iF8x/k2Q0RTFmoMJ9biI6PXEh76nH3EqUFdpyrIIgrG5aOMnCkVDvOxlgVRrKG8Q3JBHlSievTmuw== -"@pixi/events@~6.4.2": - version "6.4.2" - resolved "https://registry.yarnpkg.com/@pixi/events/-/events-6.4.2.tgz#b65d2b6e64631571179079819972b515d6336ec5" - integrity sha512-peLSZrNzU4jRlKkYc80FpyW4ziep1rDnHxto/kKNkEJbn2dALZjMdzIV7ALB17pV7GH5ZH2cqwiKw26rhLFwmQ== +"@pixi/events@~6.5.0": + version "6.5.8" + resolved "https://registry.yarnpkg.com/@pixi/events/-/events-6.5.8.tgz#739a2bf634484d4394acc55019fa6910a35cf925" + integrity sha512-9pnL1Z/YBynIEk2I5f3ZvcB+fnqxeZ0dP5m1OKZ8GpKnkZz6/2FZ9hbelyeZgW9iHUPNy98A+Nrfv4oE7lB5Dg== -"@pixi/extract@~6.4.2": - version "6.4.2" - resolved "https://registry.yarnpkg.com/@pixi/extract/-/extract-6.4.2.tgz#9423483ecc58d6feb441d8eb8d5bc2cdacc37c9c" - integrity sha512-4eMqkns+NL2/DmdezjbVG4TW+eII3hvgDM3koDQNoO4yjMgU+55TTptPU9jJL/JJwntRiUECLSIHg8eZxmA5mA== +"@pixi/extensions@~6.5.0": + version "6.5.8" + resolved "https://registry.yarnpkg.com/@pixi/extensions/-/extensions-6.5.8.tgz#6976b8f582ce09dea9ba3baebd14c5958c39b222" + integrity sha512-6vEV801Vn/EkU/qjFiZ76OZWPq5KsBR2r+P5gfKv4YLnaDc3A+0IpUOJ7sLBAJqmr0iw68g6xV6MnuqVjNGjFg== -"@pixi/filter-adjustment@^4.1.3": - version "4.1.3" - resolved "https://registry.npmjs.org/@pixi/filter-adjustment/-/filter-adjustment-4.1.3.tgz" - integrity sha512-W+NhPiZRYKoRToa5+tkU95eOw8gnS5dfIp3ZP+pLv2mdER9RI+4xHxp1uLHMqUYZViTaMdZIIoVOuCgHFPYCbQ== +"@pixi/extract@~6.5.0": + version "6.5.8" + resolved "https://registry.yarnpkg.com/@pixi/extract/-/extract-6.5.8.tgz#d2a07055a766b7269b3f3a0ad1fdb93762168f6f" + integrity sha512-qbuuD/iBA4J+TCBgrbMe8oDUFbCriyy9LTKEtQp+pghKD5MEMvJ3nO6Osumxqiqta2kYU6WldFLTldKyHEiQ7Q== -"@pixi/filter-alpha@~6.4.2": - version "6.4.2" - resolved "https://registry.yarnpkg.com/@pixi/filter-alpha/-/filter-alpha-6.4.2.tgz#592f3285a86293d372c241c01530966f463d15d9" - integrity sha512-If6a/tCPnFo0FQI/v6uy0OSqrNI8YMZMdcY7CfgklqDHx50CvhKp0d2tPYE4ETNgSpO883LARz6pi6yLAH83AA== +"@pixi/filter-alpha@~6.5.0": + version "6.5.8" + resolved "https://registry.yarnpkg.com/@pixi/filter-alpha/-/filter-alpha-6.5.8.tgz#627ac683285754ebc94ad560bf99c015721d3314" + integrity sha512-W4IkFTLTP84H+DS9XIdBGunAEpaXLrasDc4CQBeyp4c4hBlGlzriUZp30vkmqm7GPmFhzPe7aiJtNYgUpxKQBQ== -"@pixi/filter-color-matrix@~6.4.2": - version "6.4.2" - resolved "https://registry.yarnpkg.com/@pixi/filter-color-matrix/-/filter-color-matrix-6.4.2.tgz#313aa6df18dfe8d91049ee8aff4eafd22ef54e63" - integrity sha512-IsR2piAxGmyesqZ4OlIyv5OvUkHx3K5iL+js6vricbcbBZA9fQUjTXdZmb7RloO6Po3Amze3f9ZkuLe4CNpUDQ== +"@pixi/filter-color-matrix@~6.5.0": + version "6.5.8" + resolved "https://registry.yarnpkg.com/@pixi/filter-color-matrix/-/filter-color-matrix-6.5.8.tgz#4fa64977c87fcb5420aff439df1652a2048c47a6" + integrity sha512-iix+a/KEi6HAwZwkUH3nkIzyLu0ln3HBuHEFLUUhug7xrQgQgGrTQZ32iWlfpJD/BZuKphIGfzlxMFfvyQmkVw== -"@pixi/graphics-extras@~6.4.2": - version "6.4.2" - resolved "https://registry.yarnpkg.com/@pixi/graphics-extras/-/graphics-extras-6.4.2.tgz#caf4277b6852b93b2f58cbb4c400e8fd194b04b7" - integrity sha512-SOYBCs2bs5wZYnMPLr3lTb/CZ5yP8cX/GUa+Nu4ohtpesrXlvkAWdAG+qeujnsUNp/9RLXQZhjw5vFC6TzqbRA== +"@pixi/graphics-extras@~6.5.0": + version "6.5.8" + resolved "https://registry.yarnpkg.com/@pixi/graphics-extras/-/graphics-extras-6.5.8.tgz#79c113ff285f5954df78b64becf58a05c162936f" + integrity sha512-RdrAucGr6etEzz64TiViPcxlEpUfwJTj62j8eMDU1BjCwSaNDs5TN3LerY/en7IRRsUsrVLMn/3z52B25P+rjQ== -"@pixi/graphics@~6.4.2": - version "6.4.2" - resolved "https://registry.yarnpkg.com/@pixi/graphics/-/graphics-6.4.2.tgz#a3dadc078432b67d4606b1f05c5ab3fce80db40b" - integrity sha512-bMIuOee3ONsibRzq9/YUOPfrJ9rD5UK4ifhHRcB5sXwyRXhVK2HNkT2H4+0JQ8o7TxqjJE8neb5en9hn3ZR3SQ== +"@pixi/graphics@~6.5.0": + version "6.5.8" + resolved "https://registry.yarnpkg.com/@pixi/graphics/-/graphics-6.5.8.tgz#25db47335d8191c38ae39adc95bd9eb20672247b" + integrity sha512-DUuUXHO4t5fg+n+srMkHX38QEH3WtS1IMXtovBGFJkkopG0Z0xjxSp5XvsPPw1J//4fzkHZI5OBrlN613p9+sg== -"@pixi/interaction@~6.4.2": - version "6.4.2" - resolved "https://registry.yarnpkg.com/@pixi/interaction/-/interaction-6.4.2.tgz#5745498057c174fb5c7538619644c7b104a58cf5" - integrity sha512-CJ4BAZUM+9ykRE9NIOyTiv7oR+PoiDqn+GcI8boE9mRyJ0WZosznCYdcAwEk5k/F5+Az0z8hK3PjzTuNvrPAcw== +"@pixi/interaction@~6.5.0": + version "6.5.8" + resolved "https://registry.yarnpkg.com/@pixi/interaction/-/interaction-6.5.8.tgz#d4e83cb4d1f03f23633706ef9495406a2401dc26" + integrity sha512-uP247r0f47vo9WSpEnsUfeD1izxVGpjtg4iAyGT/02ezWse2vD1aEL8AbxFa65TL0IXOKsHEQudCVL+wjnbSKQ== -"@pixi/loaders@~6.4.2": - version "6.4.2" - resolved "https://registry.yarnpkg.com/@pixi/loaders/-/loaders-6.4.2.tgz#74558719d9febfc34de863a2df791502cefdc600" - integrity sha512-2y4JbGhhYYYdKIZfy9Evc7rcctqcXiP6xuAuIfqVgRD9SjQkxImelgCpyYT/BpjXP5jetyim8Usv07Ynx+4B0w== +"@pixi/loaders@~6.5.0": + version "6.5.8" + resolved "https://registry.yarnpkg.com/@pixi/loaders/-/loaders-6.5.8.tgz#5fe2e74c2c532b4bb900063ee2f33385e5446f7a" + integrity sha512-mj11UPKsqWaTEPMpCnFugr6heKkQeNFuVSddSwE8crg19l46zcMhk3ucpQX15RDpAdDJjtl3OraevQCHHbNENw== -"@pixi/math-extras@~6.4.2": - version "6.4.2" - resolved "https://registry.yarnpkg.com/@pixi/math-extras/-/math-extras-6.4.2.tgz#3210e6ca2f7b0c8d2e5d8cc1142a8e3e349fef2e" - integrity sha512-Dc1GszTU5pW4cSG6VV2UYMkcDASC5KW0N7wPGEh3UCB8p79JwmN+xJ/mCC6m9lkgAdAc6b3KQTUPdWFycnpdJA== +"@pixi/math-extras@~6.5.0": + version "6.5.8" + resolved "https://registry.yarnpkg.com/@pixi/math-extras/-/math-extras-6.5.8.tgz#5329bcaa827f96fbdfea5c0b90709861bc37686a" + integrity sha512-Vkc1OHPZKoVI89mHigAtpBma6bU3z6t4XJfXwG6RkHX/D955gtnZ80BBeu3wt482z1iMedYLgHv9eqW70ROtxg== -"@pixi/math@~6.4.2": - version "6.4.2" - resolved "https://registry.yarnpkg.com/@pixi/math/-/math-6.4.2.tgz#32c39453877e6faa0c8891b8fbeec02a4f8bfecf" - integrity sha512-/byuwLhzln7Gahl3pT/Ckfwe4nvAQ3tAYu+38B+b18HkQWi3Ykci/QwVq/nICb5sa5tJzW3icno2qcv7zBd2xQ== +"@pixi/math@~6.5.0": + version "6.5.8" + resolved "https://registry.yarnpkg.com/@pixi/math/-/math-6.5.8.tgz#7dc06425c6a53b6a2adf5e66e57a2f9db0907cc9" + integrity sha512-9493KEH5ITnjOZvQZbaU22lD0kcg/XhNh+309KYfwFX787zA1BN/7is06oHEgHBDb2NemqioYi6sw1WnECgQig== -"@pixi/mixin-cache-as-bitmap@~6.4.2": - version "6.4.2" - resolved "https://registry.yarnpkg.com/@pixi/mixin-cache-as-bitmap/-/mixin-cache-as-bitmap-6.4.2.tgz#10f37259ddc65aafb0a492adb17135d040db7874" - integrity sha512-TyMoSDoxd8o1J6/S/8xjJlCO4ThVOC2aJdHMP3hNX8GqjszOWZ2JONwVrPauToCPLyM76JXoDylwINB0bMh3YQ== +"@pixi/mixin-cache-as-bitmap@~6.5.0": + version "6.5.8" + resolved "https://registry.yarnpkg.com/@pixi/mixin-cache-as-bitmap/-/mixin-cache-as-bitmap-6.5.8.tgz#3e70ae36d3c63cb53f75ca74fec7814f3bfc01b4" + integrity sha512-5TTv4w8v7guI6z3gKz5ppUCbNMRw+8RRNru/aq65qUl6kcUaJiYwQdBFJ/vJwpI9ePEScWrCuLVEc8QtX6xjNw== -"@pixi/mixin-get-child-by-name@~6.4.2": - version "6.4.2" - resolved "https://registry.yarnpkg.com/@pixi/mixin-get-child-by-name/-/mixin-get-child-by-name-6.4.2.tgz#1e8ad6736eaeb4f62d8eb6536bc501d069399d70" - integrity sha512-VP8RihmDiah3x/7jHoJe1f9PCWadWOC5m5pHE886e4KafZq6vRJAoD9SMBm2VxcVJMZAvwIXnnTd6M2paC6ijg== +"@pixi/mixin-get-child-by-name@~6.5.0": + version "6.5.8" + resolved "https://registry.yarnpkg.com/@pixi/mixin-get-child-by-name/-/mixin-get-child-by-name-6.5.8.tgz#414a8bbf8d80686e351bc8f9abb8f12be2d04ff8" + integrity sha512-b15HTdHpW4ErDBpf7wm1vvWHrTv5kQzElXrwAPBCnLgvronfSL9mL7npOUkZOybUorCoEBq/7oNVjkimsQc5gw== -"@pixi/mixin-get-global-position@~6.4.2": - version "6.4.2" - resolved "https://registry.yarnpkg.com/@pixi/mixin-get-global-position/-/mixin-get-global-position-6.4.2.tgz#8f4566210839fe59c1dc36d74879e24d367d596e" - integrity sha512-sb+uzQ1OjXeGZaehuhmYoLtmrpt18gj4OQXa/ACebIEYZNB0fy57k1MMEhQlQvv4cOML0nglf64nzhkdNxk85A== +"@pixi/mixin-get-global-position@~6.5.0": + version "6.5.8" + resolved "https://registry.yarnpkg.com/@pixi/mixin-get-global-position/-/mixin-get-global-position-6.5.8.tgz#7fc71b89e13d37fdf39955a3de680511883ef5f2" + integrity sha512-Y5epEW5mRrgpDOHvfc92t0PaBgboBKXR4n/AzOOFt0h9GRNTmVKYBpUQPp/HO+r1Bxq+XbaGm1CyfkjUUxnORA== -"@pixi/polyfill@~6.4.2": - version "6.4.2" - resolved "https://registry.yarnpkg.com/@pixi/polyfill/-/polyfill-6.4.2.tgz#c1a0b44ae60bff6749e00df069803546afe86a9b" - integrity sha512-526FVALec5Hf6KVuguRLmLjnAAodpcBeZdQvMVEyMqgxZLch3f6QSwq+SITqR2lr7toqRYEWMyH7ISXdqbcRAg== +"@pixi/polyfill@~6.5.0": + version "6.5.8" + resolved "https://registry.yarnpkg.com/@pixi/polyfill/-/polyfill-6.5.8.tgz#98d753fc6ca95cf086077ee230d089595a32bbfb" + integrity sha512-z2klHelxTZExMyO4oiLdxJMGzzXnToEIDn7Dwfy3FY+98LbxSa2dVFCgzDsYeiiS8fSMsni2Ru7aZT/DFsRDcA== dependencies: object-assign "^4.1.1" promise-polyfill "^8.2.0" -"@pixi/runner@~6.4.2": - version "6.4.2" - resolved "https://registry.yarnpkg.com/@pixi/runner/-/runner-6.4.2.tgz#006ab5e49e281717868d46d6b020d26675b1f334" - integrity sha512-mH1//C931Rd+RB/c66t8VMNmLUGBCnefRftgijV5mBFXNgyP8Dnbig1790Qw4IDKPgiiR1mRmGDGAJAr0Xa/3A== +"@pixi/runner@~6.5.0": + version "6.5.8" + resolved "https://registry.yarnpkg.com/@pixi/runner/-/runner-6.5.8.tgz#e86ed6fac1f243d17dfa5d5317cb0b98fdce3960" + integrity sha512-/9KVgQjTKiBa1qHdNmhP9I+AHgC/Eu9QiKcc+oakLCJtpYi79lx+nDFrpLUamIi2c7lP0hDWVe0XqlQeYmSwag== -"@pixi/settings@~6.4.2": - version "6.4.2" - resolved "https://registry.yarnpkg.com/@pixi/settings/-/settings-6.4.2.tgz#1d912cd0c82d669c03666e4e8bd11b79aaf9fac7" - integrity sha512-wA2PEVoHYaRiQ0/zvq8nqJZkzDT3qLRl8S7yVfL1yhsbCsh6KI0hjCwqy8b8xCAVAMwkInzWx64lvQbfActnAg== - dependencies: - ismobilejs "^1.1.0" +"@pixi/settings@~6.5.0": + version "6.5.8" + resolved "https://registry.yarnpkg.com/@pixi/settings/-/settings-6.5.8.tgz#574df7b10039903e4e158a067be8fd5d8531c653" + integrity sha512-gmnwHkg9+tlQRuFNOdimzl73Dup2fdEo/VYaF7spT+8womE4KWAvARCBMqY/10aAx1iYeYuo5av/RfqrePB5Hg== -"@pixi/sprite-tiling@~6.4.2": - version "6.4.2" - resolved "https://registry.yarnpkg.com/@pixi/sprite-tiling/-/sprite-tiling-6.4.2.tgz#ed7459224ced02824d2161e31b2dc8f9e5d1c060" - integrity sha512-2kTVlgOMDi8MmvrZJBe4pt96hIcFS89kJrZYG+aEg7DoS1oQJ1X/T68feqz0PfMHgTJtQiDqn2NbR+/S1E/HpQ== +"@pixi/sprite-tiling@~6.5.0": + version "6.5.8" + resolved "https://registry.yarnpkg.com/@pixi/sprite-tiling/-/sprite-tiling-6.5.8.tgz#2fafe50268565ab7f03d4aba50b2c2a975056edc" + integrity sha512-PG3tiWI6uUest/d7HAz4/3I8NjpYyeMUL2WDy86nMXCJ6bLdTs/s9Nq3DLckaUsyIMTGsVbj/BXjE8LP1WDTog== -"@pixi/sprite@~6.4.2": - version "6.4.2" - resolved "https://registry.yarnpkg.com/@pixi/sprite/-/sprite-6.4.2.tgz#018f63dace945bf3bcb26d06e8160118bb9db128" - integrity sha512-UW3587gBSdY8iCh/t7+7j1CV9iouAQrLvRNw42gJm5iQm+GaLWpQEI3GSaQX9u47fi1C2nokeGa6uB2Hwz/48Q== +"@pixi/sprite@~6.5.0": + version "6.5.8" + resolved "https://registry.yarnpkg.com/@pixi/sprite/-/sprite-6.5.8.tgz#94bcf4fe590f674e193e64b02365fa4582453c40" + integrity sha512-ywvbrNgjK+K93X9cvHtDCnsBtU7B9JD/3wg+1G6v1Ktrr2E1gwVIQK1NANBrjzt6cYGphz5EqGAW68d0rMBliw== -"@pixi/spritesheet@~6.4.2": - version "6.4.2" - resolved "https://registry.yarnpkg.com/@pixi/spritesheet/-/spritesheet-6.4.2.tgz#e17118c476ebf2f3371022b5df8f254ed7989208" - integrity sha512-iSKVXcH4oPNZ+XdirqMTdgo3MbbXRsoAeuXsoWum2aP4Zm94cSQ0kRGAMXg5SVhQTWF5w+tQ+JKfE/kGZqd5Vg== +"@pixi/spritesheet@~6.5.0": + version "6.5.8" + resolved "https://registry.yarnpkg.com/@pixi/spritesheet/-/spritesheet-6.5.8.tgz#d369372e0341a522e44d75e2c750534392a5f9e6" + integrity sha512-WiJd4fKpSitD3A+/u5q8IPoHXMFT8++bsluhuJvDwzo//s0PHb9qExlF2xos7zUmekmydEFMkDnrl4+lWn2cyg== -"@pixi/text@~6.4.2": - version "6.4.2" - resolved "https://registry.yarnpkg.com/@pixi/text/-/text-6.4.2.tgz#340aa90a241deecff499b540b9e1ec34cadff27c" - integrity sha512-jX2LBjgEwKqm5lTUKh3gusSKsSPQpibdcxYMQKxMDNVqvNyGG9UqEO/FogMnGg6c5EHBKyMas26c8oXrf1oagg== +"@pixi/text@~6.5.0": + version "6.5.8" + resolved "https://registry.yarnpkg.com/@pixi/text/-/text-6.5.8.tgz#ed23ea16812b0b5be2d0b964e707c5c407f1e758" + integrity sha512-7AZPj5+vWcUjK0QzQ3ehiEwEqywiWR8NhDmnnN5nRNHR9u5IOOnqCQtBTdDffYPN0uMgCi8MzUPwTJhGuyOeww== -"@pixi/ticker@~6.4.2": - version "6.4.2" - resolved "https://registry.yarnpkg.com/@pixi/ticker/-/ticker-6.4.2.tgz#5e84fcd9c76240e9c141f268b780de19b63cf231" - integrity sha512-OM2U0qLiU2Z+qami7DRNkBJnx20ElQO/5mJNsoHQRH6k/po0nXlux8jcCXhh5DE9lds4RdUFAwTL4RmLT1clDw== +"@pixi/ticker@~6.5.0": + version "6.5.8" + resolved "https://registry.yarnpkg.com/@pixi/ticker/-/ticker-6.5.8.tgz#708120bcadce7c4446e2238df590c54debbaed78" + integrity sha512-7VKq5hfnRDSv6a16pATqZAmpQfEu4G171iUTloy3QZfbnPw0s3JervZSih1yJJD84GXEF4VzYB26pJ/x3arGjQ== "@pixi/tilemap@^3.2.2": version "3.2.2" - resolved "https://registry.npmjs.org/@pixi/tilemap/-/tilemap-3.2.2.tgz" + resolved "https://registry.yarnpkg.com/@pixi/tilemap/-/tilemap-3.2.2.tgz#8327e5d7007a90be640a0b1eb9943a1e405b57e4" integrity sha512-svdmMyJP63vdae3t66tCmE8IWeO/6lD1xXU+5gzfxqxJS5seTp2bm8mQok2c8PF0O6l/NYlLz6BRklOuEuHboQ== -"@pixi/utils@~6.4.2": - version "6.4.2" - resolved "https://registry.yarnpkg.com/@pixi/utils/-/utils-6.4.2.tgz#77c5bac2ba26094ac0308327a5b6685d3287f649" - integrity sha512-FORUzSikNUNceS6sf2NlRcGukmJrnWCQToA6Nqk+tQ7Lvb42vDTVI66ya44O6HYM2J0nL684YeYesWbAZ+UeKg== +"@pixi/utils@~6.5.0": + version "6.5.8" + resolved "https://registry.yarnpkg.com/@pixi/utils/-/utils-6.5.8.tgz#5b7662c00951ac530bb0b72329bab922f4030930" + integrity sha512-zLnvmVQBWPDnwkfvrSpBBF2XpWSMt+kQAsX562eqjuME63ic9M6fK4u/IaA8csdlG2wtcjBvSYWrpWmPq0bWag== dependencies: "@types/earcut" "^2.1.0" - earcut "^2.2.2" + earcut "^2.2.4" eventemitter3 "^3.1.0" url "^0.11.0" +"@rollup/plugin-typescript@^10.0.1": + version "10.0.1" + resolved "https://registry.yarnpkg.com/@rollup/plugin-typescript/-/plugin-typescript-10.0.1.tgz#270b515b116ea28320e6bb62451c4767d49072d6" + integrity sha512-wBykxRLlX7EzL8BmUqMqk5zpx2onnmRMSw/l9M1sVfkJvdwfxogZQVNUM9gVMJbjRLDR5H6U0OMOrlDGmIV45A== + dependencies: + "@rollup/pluginutils" "^5.0.1" + resolve "^1.22.1" + +"@rollup/pluginutils@^5.0.1": + version "5.0.2" + resolved "https://registry.yarnpkg.com/@rollup/pluginutils/-/pluginutils-5.0.2.tgz#012b8f53c71e4f6f9cb317e311df1404f56e7a33" + integrity sha512-pTd9rIsP92h+B6wWwFbW8RkZv4hiR/xKsqre4SIuAOaOEQRxi0lqLke9k2/7WegC85GgUs9pjmOjCUi3In4vwA== + dependencies: + "@types/estree" "^1.0.0" + estree-walker "^2.0.2" + picomatch "^2.3.1" + "@types/earcut@^2.1.0": version "2.1.1" resolved "https://registry.yarnpkg.com/@types/earcut/-/earcut-2.1.1.tgz#573a0af609f17005c751f6f4ffec49cfe358ea51" integrity sha512-w8oigUCDjElRHRRrMvn/spybSMyX8MTkKA5Dv+tS1IE/TgmNZPqUYtvYBXGY8cieSE66gm+szeK+bnbxC2xHTQ== +"@types/estree@^1.0.0": + version "1.0.0" + resolved "https://registry.yarnpkg.com/@types/estree/-/estree-1.0.0.tgz#5fb2e536c1ae9bf35366eed879e827fa59ca41c2" + integrity sha512-WulqXMDUTYAXCjZnk6JtIHPigp55cVtDgDrO2gHRwhyJto21+1zbVCtOYB2L1F9w4qCQ0rOGWBnBe0FNTiEJIQ== + "@types/howler@^2.2.7": version "2.2.7" resolved "https://registry.yarnpkg.com/@types/howler/-/howler-2.2.7.tgz#5acfbed57f9e1d99b8dabe1b824729e1c1ea1fae" integrity sha512-PEZldwZqJJw1PWRTpupyC7ajVTZA8aHd8nB/Y0n6zRZi5u8ktYDntsHj13ltEiBRqWwF06pASxBEvCTxniG8eA== "@types/json-schema@^7.0.9": - version "7.0.9" - resolved "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.9.tgz" - integrity sha512-qcUXuemtEu+E5wZSJHNxUXeCZhAfXKQ41D+duX+VYPde7xyEVZci+/oXKJL13tnRs9lR2pr4fod59GT6/X1/yQ== + version "7.0.11" + resolved "https://registry.yarnpkg.com/@types/json-schema/-/json-schema-7.0.11.tgz#d421b6c527a3037f7c84433fd2c4229e016863d3" + integrity sha512-wOuvG1SN4Us4rez+tylwwwCV1psiNVOkJeM3AUWUNWg/jDQY2+HE/444y5gc+jBmRqASOm2Oeh5c1axHobwRKQ== "@types/offscreencanvas@^2019.6.4": - version "2019.6.4" - resolved "https://registry.yarnpkg.com/@types/offscreencanvas/-/offscreencanvas-2019.6.4.tgz#64f6d120b53925028299c744fcdd32d2cd525963" - integrity sha512-u8SAgdZ8ROtkTF+mfZGOscl0or6BSj9A4g37e6nvxDc+YB/oDut0wHkK2PBBiC2bNR8TS0CPV+1gAk4fNisr1Q== + version "2019.7.0" + resolved "https://registry.yarnpkg.com/@types/offscreencanvas/-/offscreencanvas-2019.7.0.tgz#e4a932069db47bb3eabeb0b305502d01586fa90d" + integrity sha512-PGcyveRIpL1XIqK8eBsmRBt76eFgtzuPiSTyKHZxnGemp2yzGzWpjYKAfK3wIMiU7eH+851yEpiuP8JZerTmWg== "@types/pako@^1.0.3": - version "1.0.3" - resolved "https://registry.npmjs.org/@types/pako/-/pako-1.0.3.tgz" - integrity sha512-EDxOsHAD5dqjbjEUM1xwa7rpKPFb8ECBE5irONTQU7/OsO3thI5YrNEWSPNMvYmvFM0l/OLQJ6Mgw7PEdXSjhg== + version "1.0.4" + resolved "https://registry.yarnpkg.com/@types/pako/-/pako-1.0.4.tgz#b4262aef92680a9331fcdb8420c69cf3dd98d3f3" + integrity sha512-Z+5bJSm28EXBSUJEgx29ioWeEEHUh6TiMkZHDhLwjc9wVFH+ressbkmX6waUZc5R3Gobn4Qu5llGxaoflZ+yhA== + +"@types/semver@^7.3.12": + version "7.3.13" + resolved "https://registry.yarnpkg.com/@types/semver/-/semver-7.3.13.tgz#da4bfd73f49bd541d28920ab0e2bf0ee80f71c91" + integrity sha512-21cFJr9z3g5dW8B0CVI9g2O9beqaThGQ6ZFBqHfwhzLDKUxaqTIy3vnfah/UPkfOiF2pLq+tGz+W8RyCskuslw== "@typescript-eslint/eslint-plugin@^5.30.7": - version "5.30.7" - resolved "https://registry.yarnpkg.com/@typescript-eslint/eslint-plugin/-/eslint-plugin-5.30.7.tgz#1621dabc1ae4084310e19e9efc80dfdbb97e7493" - integrity sha512-l4L6Do+tfeM2OK0GJsU7TUcM/1oN/N25xHm3Jb4z3OiDU4Lj8dIuxX9LpVMS9riSXQs42D1ieX7b85/r16H9Fw== + version "5.46.1" + resolved "https://registry.yarnpkg.com/@typescript-eslint/eslint-plugin/-/eslint-plugin-5.46.1.tgz#098abb4c9354e19f460d57ab18bff1f676a6cff0" + integrity sha512-YpzNv3aayRBwjs4J3oz65eVLXc9xx0PDbIRisHj+dYhvBn02MjYOD96P8YGiWEIFBrojaUjxvkaUpakD82phsA== dependencies: - "@typescript-eslint/scope-manager" "5.30.7" - "@typescript-eslint/type-utils" "5.30.7" - "@typescript-eslint/utils" "5.30.7" + "@typescript-eslint/scope-manager" "5.46.1" + "@typescript-eslint/type-utils" "5.46.1" + "@typescript-eslint/utils" "5.46.1" debug "^4.3.4" - functional-red-black-tree "^1.0.1" ignore "^5.2.0" + natural-compare-lite "^1.4.0" regexpp "^3.2.0" semver "^7.3.7" tsutils "^3.21.0" "@typescript-eslint/parser@^5.30.7": - version "5.30.7" - resolved "https://registry.yarnpkg.com/@typescript-eslint/parser/-/parser-5.30.7.tgz#99d09729392aec9e64b1de45cd63cb81a4ddd980" - integrity sha512-Rg5xwznHWWSy7v2o0cdho6n+xLhK2gntImp0rJroVVFkcYFYQ8C8UJTSuTw/3CnExBmPjycjmUJkxVmjXsld6A== + version "5.46.1" + resolved "https://registry.yarnpkg.com/@typescript-eslint/parser/-/parser-5.46.1.tgz#1fc8e7102c1141eb64276c3b89d70da8c0ba5699" + integrity sha512-RelQ5cGypPh4ySAtfIMBzBGyrNerQcmfA1oJvPj5f+H4jI59rl9xxpn4bonC0tQvUKOEN7eGBFWxFLK3Xepneg== dependencies: - "@typescript-eslint/scope-manager" "5.30.7" - "@typescript-eslint/types" "5.30.7" - "@typescript-eslint/typescript-estree" "5.30.7" + "@typescript-eslint/scope-manager" "5.46.1" + "@typescript-eslint/types" "5.46.1" + "@typescript-eslint/typescript-estree" "5.46.1" debug "^4.3.4" -"@typescript-eslint/scope-manager@5.30.7": - version "5.30.7" - resolved "https://registry.yarnpkg.com/@typescript-eslint/scope-manager/-/scope-manager-5.30.7.tgz#8269a931ef1e5ae68b5eb80743cc515c4ffe3dd7" - integrity sha512-7BM1bwvdF1UUvt+b9smhqdc/eniOnCKxQT/kj3oXtj3LqnTWCAM0qHRHfyzCzhEfWX0zrW7KqXXeE4DlchZBKw== +"@typescript-eslint/scope-manager@5.46.1": + version "5.46.1" + resolved "https://registry.yarnpkg.com/@typescript-eslint/scope-manager/-/scope-manager-5.46.1.tgz#70af8425c79bbc1178b5a63fb51102ddf48e104a" + integrity sha512-iOChVivo4jpwUdrJZyXSMrEIM/PvsbbDOX1y3UCKjSgWn+W89skxWaYXACQfxmIGhPVpRWK/VWPYc+bad6smIA== dependencies: - "@typescript-eslint/types" "5.30.7" - "@typescript-eslint/visitor-keys" "5.30.7" + "@typescript-eslint/types" "5.46.1" + "@typescript-eslint/visitor-keys" "5.46.1" -"@typescript-eslint/type-utils@5.30.7": - version "5.30.7" - resolved "https://registry.yarnpkg.com/@typescript-eslint/type-utils/-/type-utils-5.30.7.tgz#5693dc3db6f313f302764282d614cfdbc8a9fcfd" - integrity sha512-nD5qAE2aJX/YLyKMvOU5jvJyku4QN5XBVsoTynFrjQZaDgDV6i7QHFiYCx10wvn7hFvfuqIRNBtsgaLe0DbWhw== +"@typescript-eslint/type-utils@5.46.1": + version "5.46.1" + resolved "https://registry.yarnpkg.com/@typescript-eslint/type-utils/-/type-utils-5.46.1.tgz#195033e4b30b51b870dfcf2828e88d57b04a11cc" + integrity sha512-V/zMyfI+jDmL1ADxfDxjZ0EMbtiVqj8LUGPAGyBkXXStWmCUErMpW873zEHsyguWCuq2iN4BrlWUkmuVj84yng== dependencies: - "@typescript-eslint/utils" "5.30.7" + "@typescript-eslint/typescript-estree" "5.46.1" + "@typescript-eslint/utils" "5.46.1" debug "^4.3.4" tsutils "^3.21.0" -"@typescript-eslint/types@5.30.7": - version "5.30.7" - resolved "https://registry.yarnpkg.com/@typescript-eslint/types/-/types-5.30.7.tgz#18331487cc92d0f1fb1a6f580c8ec832528079d0" - integrity sha512-ocVkETUs82+U+HowkovV6uxf1AnVRKCmDRNUBUUo46/5SQv1owC/EBFkiu4MOHeZqhKz2ktZ3kvJJ1uFqQ8QPg== +"@typescript-eslint/types@5.46.1": + version "5.46.1" + resolved "https://registry.yarnpkg.com/@typescript-eslint/types/-/types-5.46.1.tgz#4e9db2107b9a88441c4d5ecacde3bb7a5ebbd47e" + integrity sha512-Z5pvlCaZgU+93ryiYUwGwLl9AQVB/PQ1TsJ9NZ/gHzZjN7g9IAn6RSDkpCV8hqTwAiaj6fmCcKSQeBPlIpW28w== -"@typescript-eslint/typescript-estree@5.30.7": - version "5.30.7" - resolved "https://registry.yarnpkg.com/@typescript-eslint/typescript-estree/-/typescript-estree-5.30.7.tgz#05da9f1b281985bfedcf62349847f8d168eecc07" - integrity sha512-tNslqXI1ZdmXXrHER83TJ8OTYl4epUzJC0aj2i4DMDT4iU+UqLT3EJeGQvJ17BMbm31x5scSwo3hPM0nqQ1AEA== +"@typescript-eslint/typescript-estree@5.46.1": + version "5.46.1" + resolved "https://registry.yarnpkg.com/@typescript-eslint/typescript-estree/-/typescript-estree-5.46.1.tgz#5358088f98a8f9939355e0996f9c8f41c25eced2" + integrity sha512-j9W4t67QiNp90kh5Nbr1w92wzt+toiIsaVPnEblB2Ih2U9fqBTyqV9T3pYWZBRt6QoMh/zVWP59EpuCjc4VRBg== dependencies: - "@typescript-eslint/types" "5.30.7" - "@typescript-eslint/visitor-keys" "5.30.7" + "@typescript-eslint/types" "5.46.1" + "@typescript-eslint/visitor-keys" "5.46.1" debug "^4.3.4" globby "^11.1.0" is-glob "^4.0.3" semver "^7.3.7" tsutils "^3.21.0" -"@typescript-eslint/utils@5.30.7": - version "5.30.7" - resolved "https://registry.yarnpkg.com/@typescript-eslint/utils/-/utils-5.30.7.tgz#7135be070349e9f7caa262b0ca59dc96123351bb" - integrity sha512-Z3pHdbFw+ftZiGUnm1GZhkJgVqsDL5CYW2yj+TB2mfXDFOMqtbzQi2dNJIyPqPbx9mv2kUxS1gU+r2gKlKi1rQ== +"@typescript-eslint/utils@5.46.1": + version "5.46.1" + resolved "https://registry.yarnpkg.com/@typescript-eslint/utils/-/utils-5.46.1.tgz#7da3c934d9fd0eb4002a6bb3429f33298b469b4a" + integrity sha512-RBdBAGv3oEpFojaCYT4Ghn4775pdjvwfDOfQ2P6qzNVgQOVrnSPe5/Pb88kv7xzYQjoio0eKHKB9GJ16ieSxvA== dependencies: "@types/json-schema" "^7.0.9" - "@typescript-eslint/scope-manager" "5.30.7" - "@typescript-eslint/types" "5.30.7" - "@typescript-eslint/typescript-estree" "5.30.7" + "@types/semver" "^7.3.12" + "@typescript-eslint/scope-manager" "5.46.1" + "@typescript-eslint/types" "5.46.1" + "@typescript-eslint/typescript-estree" "5.46.1" eslint-scope "^5.1.1" eslint-utils "^3.0.0" + semver "^7.3.7" -"@typescript-eslint/visitor-keys@5.30.7": - version "5.30.7" - resolved "https://registry.yarnpkg.com/@typescript-eslint/visitor-keys/-/visitor-keys-5.30.7.tgz#c093abae75b4fd822bfbad9fc337f38a7a14909a" - integrity sha512-KrRXf8nnjvcpxDFOKej4xkD7657+PClJs5cJVSG7NNoCNnjEdc46juNAQt7AyuWctuCgs6mVRc1xGctEqrjxWw== +"@typescript-eslint/visitor-keys@5.46.1": + version "5.46.1" + resolved "https://registry.yarnpkg.com/@typescript-eslint/visitor-keys/-/visitor-keys-5.46.1.tgz#126cc6fe3c0f83608b2b125c5d9daced61394242" + integrity sha512-jczZ9noovXwy59KjRTk1OftT78pwygdcmCuBf8yMoWt/8O8l+6x2LSEze0E4TeepXK4MezW3zGSyoDRZK7Y9cg== dependencies: - "@typescript-eslint/types" "5.30.7" + "@typescript-eslint/types" "5.46.1" eslint-visitor-keys "^3.3.0" acorn-jsx@^5.3.2: @@ -334,14 +517,14 @@ acorn-jsx@^5.3.2: resolved "https://registry.yarnpkg.com/acorn-jsx/-/acorn-jsx-5.3.2.tgz#7ed5bb55908b3b2f1bc55c6af1653bada7f07937" integrity sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ== -acorn@^8.7.1: - version "8.7.1" - resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.7.1.tgz#0197122c843d1bf6d0a5e83220a788f278f63c30" - integrity sha512-Xx54uLJQZ19lKygFXOWsscKUbsBZW0CPykPhVQdhIeIwrbPmJzqeASDInc8nKBnp/JT6igTs82qPXz069H8I/A== +acorn@^8.5.0, acorn@^8.8.0: + version "8.8.1" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.8.1.tgz#0a3f9cbecc4ec3bea6f0a80b66ae8dd2da250b73" + integrity sha512-7zFpHzhnqYKrkYdUjF1HI1bzd0VygEGX8lFk4k5zVMqHEoES+P+7TKI+EvLO9WVMJ8eekdO0aDEK044xTXwPPA== ajv@^6.10.0, ajv@^6.12.4: version "6.12.6" - resolved "https://registry.npmjs.org/ajv/-/ajv-6.12.6.tgz" + resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.12.6.tgz#baf5a62e802b07d977034586f8c3baf5adf26df4" integrity sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g== dependencies: fast-deep-equal "^3.1.1" @@ -351,93 +534,116 @@ ajv@^6.10.0, ajv@^6.12.4: ansi-regex@^5.0.1: version "5.0.1" - resolved "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz" + resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-5.0.1.tgz#082cb2c89c9fe8659a311a53bd6a4dc5301db304" integrity sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ== ansi-styles@^4.1.0: version "4.3.0" - resolved "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz" + resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-4.3.0.tgz#edd803628ae71c04c85ae7a0906edad34b648937" integrity sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg== dependencies: color-convert "^2.0.1" argparse@^2.0.1: version "2.0.1" - resolved "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz" + resolved "https://registry.yarnpkg.com/argparse/-/argparse-2.0.1.tgz#246f50f3ca78a3240f6c997e8a9bd1eac49e4b38" integrity sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q== array-union@^2.1.0: version "2.1.0" - resolved "https://registry.npmjs.org/array-union/-/array-union-2.1.0.tgz" + resolved "https://registry.yarnpkg.com/array-union/-/array-union-2.1.0.tgz#b798420adbeb1de828d84acd8a2e23d3efe85e8d" integrity sha512-HGyxoOTYUyCM6stUe6EJgnd4EoewAI7zMdfqO+kGjnlZmBDz/cR5pf8r/cR4Wq60sL/p0IkcjUEEPwS3GFrIyw== balanced-match@^1.0.0: version "1.0.2" - resolved "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz" + resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.2.tgz#e83e3a7e3f300b34cb9d87f615fa0cbf357690ee" integrity sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw== brace-expansion@^1.1.7: version "1.1.11" - resolved "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz" + resolved "https://registry.yarnpkg.com/brace-expansion/-/brace-expansion-1.1.11.tgz#3c7fcbf529d87226f3d2f52b966ff5271eb441dd" integrity sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA== dependencies: balanced-match "^1.0.0" concat-map "0.0.1" -braces@^3.0.1: +braces@^3.0.2: version "3.0.2" - resolved "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz" + resolved "https://registry.yarnpkg.com/braces/-/braces-3.0.2.tgz#3454e1a462ee8d599e236df336cd9ea4f8afe107" integrity sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A== dependencies: fill-range "^7.0.1" +buffer-from@^1.0.0: + version "1.1.2" + resolved "https://registry.yarnpkg.com/buffer-from/-/buffer-from-1.1.2.tgz#2b146a6fd72e80b4f55d255f35ed59a3a9a41bd5" + integrity sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ== + callsites@^3.0.0: version "3.1.0" - resolved "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz" + resolved "https://registry.yarnpkg.com/callsites/-/callsites-3.1.0.tgz#b3630abd8943432f54b3f0519238e33cd7df2f73" integrity sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ== +camel-case@^4.1.2: + version "4.1.2" + resolved "https://registry.yarnpkg.com/camel-case/-/camel-case-4.1.2.tgz#9728072a954f805228225a6deea6b38461e1bd5a" + integrity sha512-gxGWBrTT1JuMx6R+o5PTXMmUnhnVzLQ9SNutD4YqKtI6ap897t3tKECYla6gCWEkplXnlNybEkZg9GEGxKFCgw== + dependencies: + pascal-case "^3.1.2" + tslib "^2.0.3" + chalk@^4.0.0: version "4.1.2" - resolved "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz" + resolved "https://registry.yarnpkg.com/chalk/-/chalk-4.1.2.tgz#aac4e2b7734a740867aeb16bf02aad556a1e7a01" integrity sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA== dependencies: ansi-styles "^4.1.0" supports-color "^7.1.0" +clean-css@^5.2.2: + version "5.3.1" + resolved "https://registry.yarnpkg.com/clean-css/-/clean-css-5.3.1.tgz#d0610b0b90d125196a2894d35366f734e5d7aa32" + integrity sha512-lCr8OHhiWCTw4v8POJovCoh4T7I9U11yVsPjMWWnnMmp9ZowCxyad1Pathle/9HjaDp+fdQKjO9fQydE6RHTZg== + dependencies: + source-map "~0.6.0" + color-convert@^2.0.1: version "2.0.1" - resolved "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz" + resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-2.0.1.tgz#72d3a68d598c9bdb3af2ad1e84f21d896abd4de3" integrity sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ== dependencies: color-name "~1.1.4" color-name@~1.1.4: version "1.1.4" - resolved "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz" + resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.4.tgz#c2a09a87acbde69543de6f63fa3995c826c536a2" integrity sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA== +commander@^2.20.0: + version "2.20.3" + resolved "https://registry.yarnpkg.com/commander/-/commander-2.20.3.tgz#fd485e84c03eb4881c20722ba48035e8531aeb33" + integrity sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ== + +commander@^8.3.0: + version "8.3.0" + resolved "https://registry.yarnpkg.com/commander/-/commander-8.3.0.tgz#4837ea1b2da67b9c616a67afbb0fafee567bca66" + integrity sha512-OkTL9umf+He2DZkUq8f8J9of7yL6RJKI24dVITBmNfZBmri9zYZQrKkuXiKhyfPSu8tUhnVBB1iKXevvnlR4Ww== + concat-map@0.0.1: version "0.0.1" - resolved "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz" - integrity sha1-2Klr13/Wjfd5OnMDajug1UBdR3s= + resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b" + integrity sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg== cross-spawn@^7.0.2: version "7.0.3" - resolved "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz" + resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-7.0.3.tgz#f73a85b9d5d41d045551c177e2882d4ac85728a6" integrity sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w== dependencies: path-key "^3.1.0" shebang-command "^2.0.0" which "^2.0.1" -debug@^4.1.1, debug@^4.3.2: - version "4.3.3" - resolved "https://registry.npmjs.org/debug/-/debug-4.3.3.tgz" - integrity sha512-/zxw5+vh1Tfv+4Qn7a5nsbcJKPaSvCDhojn6FEl9vupwK2VCSDtEiEtqr8DFtzYFOdz63LBkxec7DYuc2jon6Q== - dependencies: - ms "2.1.2" - -debug@^4.3.4: +debug@^4.1.1, debug@^4.3.2, debug@^4.3.4: version "4.3.4" resolved "https://registry.yarnpkg.com/debug/-/debug-4.3.4.tgz#1319f6579357f2338d3337d2cdd4914bb5dcc865" integrity sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ== @@ -446,36 +652,72 @@ debug@^4.3.4: deep-is@^0.1.3: version "0.1.4" - resolved "https://registry.npmjs.org/deep-is/-/deep-is-0.1.4.tgz" + resolved "https://registry.yarnpkg.com/deep-is/-/deep-is-0.1.4.tgz#a6f2dce612fadd2ef1f519b73551f17e85199831" integrity sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ== dir-glob@^3.0.1: version "3.0.1" - resolved "https://registry.npmjs.org/dir-glob/-/dir-glob-3.0.1.tgz" + resolved "https://registry.yarnpkg.com/dir-glob/-/dir-glob-3.0.1.tgz#56dbf73d992a4a93ba1584f4534063fd2e41717f" integrity sha512-WkrWp9GR4KXfKGYzOLmTuGVi1UWFfws377n9cc55/tb6DuqyF6pcQ5AbiHEshaDpY9v6oaSr2XCDidGmMwdzIA== dependencies: path-type "^4.0.0" doctrine@^3.0.0: version "3.0.0" - resolved "https://registry.npmjs.org/doctrine/-/doctrine-3.0.0.tgz" + resolved "https://registry.yarnpkg.com/doctrine/-/doctrine-3.0.0.tgz#addebead72a6574db783639dc87a121773973961" integrity sha512-yS+Q5i3hBf7GBkd4KG8a7eBNNWNGLTaEwwYWUijIYM7zrlYDM0BFXHjjPWlWZ1Rg7UaddZeIDmi9jF3HmqiQ2w== dependencies: esutils "^2.0.2" -earcut@^2.2.2: - version "2.2.3" - resolved "https://registry.yarnpkg.com/earcut/-/earcut-2.2.3.tgz#d44ced2ff5a18859568e327dd9c7d46b16f55cf4" - integrity sha512-iRDI1QeCQIhMCZk48DRDMVgQSSBDmbzzNhnxIo+pwx3swkfjMh6vh0nWLq1NdvGHLKH6wIrAM3vQWeTj6qeoug== +dot-case@^3.0.4: + version "3.0.4" + resolved "https://registry.yarnpkg.com/dot-case/-/dot-case-3.0.4.tgz#9b2b670d00a431667a8a75ba29cd1b98809ce751" + integrity sha512-Kv5nKlh6yRrdrGvxeJ2e5y2eRUpkUosIW4A2AS38zwSz27zu7ufDwQPi5Jhs3XAlGNetl3bmnGhQsMtkKJnj3w== + dependencies: + no-case "^3.0.4" + tslib "^2.0.3" + +earcut@^2.2.4: + version "2.2.4" + resolved "https://registry.yarnpkg.com/earcut/-/earcut-2.2.4.tgz#6d02fd4d68160c114825d06890a92ecaae60343a" + integrity sha512-/pjZsA1b4RPHbeWZQn66SWS8nZZWLQQ23oE3Eam7aroEFGEvwKAsJfZ9ytiEMycfzXWpca4FA9QIOehf7PocBQ== + +esbuild@^0.16.3: + version "0.16.9" + resolved "https://registry.yarnpkg.com/esbuild/-/esbuild-0.16.9.tgz#01b6c3a6cbc072108253ac160a0734229bf8c921" + integrity sha512-gkH83yHyijMSZcZFs1IWew342eMdFuWXmQo3zkDPTre25LIPBJsXryg02M3u8OpTwCJdBkdaQwqKkDLnAsAeLQ== + optionalDependencies: + "@esbuild/android-arm" "0.16.9" + "@esbuild/android-arm64" "0.16.9" + "@esbuild/android-x64" "0.16.9" + "@esbuild/darwin-arm64" "0.16.9" + "@esbuild/darwin-x64" "0.16.9" + "@esbuild/freebsd-arm64" "0.16.9" + "@esbuild/freebsd-x64" "0.16.9" + "@esbuild/linux-arm" "0.16.9" + "@esbuild/linux-arm64" "0.16.9" + "@esbuild/linux-ia32" "0.16.9" + "@esbuild/linux-loong64" "0.16.9" + "@esbuild/linux-mips64el" "0.16.9" + "@esbuild/linux-ppc64" "0.16.9" + "@esbuild/linux-riscv64" "0.16.9" + "@esbuild/linux-s390x" "0.16.9" + "@esbuild/linux-x64" "0.16.9" + "@esbuild/netbsd-x64" "0.16.9" + "@esbuild/openbsd-x64" "0.16.9" + "@esbuild/sunos-x64" "0.16.9" + "@esbuild/win32-arm64" "0.16.9" + "@esbuild/win32-ia32" "0.16.9" + "@esbuild/win32-x64" "0.16.9" escape-string-regexp@^4.0.0: version "4.0.0" - resolved "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz" + resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz#14ba83a5d373e3d311e5afca29cf5bfad965bf34" integrity sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA== eslint-scope@^5.1.1: version "5.1.1" - resolved "https://registry.npmjs.org/eslint-scope/-/eslint-scope-5.1.1.tgz" + resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-5.1.1.tgz#e786e59a66cb92b3f6c1fb0d508aab174848f48c" integrity sha512-2NxwbF/hZ0KpepYN0cNbo+FN6XoK7GaHlQhgx/hIZl6Va0bF45RQOOwhLIy8lQDbuCiadSLCBnH2CFYquit5bw== dependencies: esrecurse "^4.3.0" @@ -483,7 +725,7 @@ eslint-scope@^5.1.1: eslint-scope@^7.1.1: version "7.1.1" - resolved "https://registry.npmjs.org/eslint-scope/-/eslint-scope-7.1.1.tgz" + resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-7.1.1.tgz#fff34894c2f65e5226d3041ac480b4513a163642" integrity sha512-QKQM/UXpIiHcLqJ5AOyIW7XZmzjkzQXYE54n1++wb0u9V/abW3l9uQnxX8Z5Xd18xyKIMTUAyQ0k1e8pz6LUrw== dependencies: esrecurse "^4.3.0" @@ -491,28 +733,30 @@ eslint-scope@^7.1.1: eslint-utils@^3.0.0: version "3.0.0" - resolved "https://registry.npmjs.org/eslint-utils/-/eslint-utils-3.0.0.tgz" + resolved "https://registry.yarnpkg.com/eslint-utils/-/eslint-utils-3.0.0.tgz#8aebaface7345bb33559db0a1f13a1d2d48c3672" integrity sha512-uuQC43IGctw68pJA1RgbQS8/NP7rch6Cwd4j3ZBtgo4/8Flj4eGE7ZYSZRN3iq5pVUv6GPdW5Z1RFleo84uLDA== dependencies: eslint-visitor-keys "^2.0.0" eslint-visitor-keys@^2.0.0: version "2.1.0" - resolved "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-2.1.0.tgz" + resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-2.1.0.tgz#f65328259305927392c938ed44eb0a5c9b2bd303" integrity sha512-0rSmRBzXgDzIsD6mGdJgevzgezI534Cer5L/vyMX0kHzT/jiB43jRhd9YUlMGYLQy2zprNmoT8qasCGtY+QaKw== eslint-visitor-keys@^3.3.0: version "3.3.0" - resolved "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-3.3.0.tgz" + resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-3.3.0.tgz#f6480fa6b1f30efe2d1968aa8ac745b862469826" integrity sha512-mQ+suqKJVyeuwGYHAdjMFqjCyfl8+Ldnxuyp3ldiMBFKkvytrXUZWaiPCEav8qDHKty44bD+qV1IP4T+w+xXRA== eslint@^8.20.0: - version "8.20.0" - resolved "https://registry.yarnpkg.com/eslint/-/eslint-8.20.0.tgz#048ac56aa18529967da8354a478be4ec0a2bc81b" - integrity sha512-d4ixhz5SKCa1D6SCPrivP7yYVi7nyD6A4vs6HIAul9ujBzcEmZVM3/0NN/yu5nKhmO1wjp5xQ46iRfmDGlOviA== + version "8.29.0" + resolved "https://registry.yarnpkg.com/eslint/-/eslint-8.29.0.tgz#d74a88a20fb44d59c51851625bc4ee8d0ec43f87" + integrity sha512-isQ4EEiyUjZFbEKvEGJKKGBwXtvXX+zJbkVKCgTuB9t/+jUBcy8avhkEwWJecI15BkRkOYmvIM5ynbhRjEkoeg== dependencies: - "@eslint/eslintrc" "^1.3.0" - "@humanwhocodes/config-array" "^0.9.2" + "@eslint/eslintrc" "^1.3.3" + "@humanwhocodes/config-array" "^0.11.6" + "@humanwhocodes/module-importer" "^1.0.1" + "@nodelib/fs.walk" "^1.2.8" ajv "^6.10.0" chalk "^4.0.0" cross-spawn "^7.0.2" @@ -522,18 +766,21 @@ eslint@^8.20.0: eslint-scope "^7.1.1" eslint-utils "^3.0.0" eslint-visitor-keys "^3.3.0" - espree "^9.3.2" + espree "^9.4.0" esquery "^1.4.0" esutils "^2.0.2" fast-deep-equal "^3.1.3" file-entry-cache "^6.0.1" - functional-red-black-tree "^1.0.1" - glob-parent "^6.0.1" + find-up "^5.0.0" + glob-parent "^6.0.2" globals "^13.15.0" + grapheme-splitter "^1.0.4" ignore "^5.2.0" import-fresh "^3.0.0" imurmurhash "^0.1.4" is-glob "^4.0.0" + is-path-inside "^3.0.3" + js-sdsl "^4.1.4" js-yaml "^4.1.0" json-stable-stringify-without-jsonify "^1.0.1" levn "^0.4.1" @@ -545,44 +792,48 @@ eslint@^8.20.0: strip-ansi "^6.0.1" strip-json-comments "^3.1.0" text-table "^0.2.0" - v8-compile-cache "^2.0.3" -espree@^9.3.2: - version "9.3.2" - resolved "https://registry.yarnpkg.com/espree/-/espree-9.3.2.tgz#f58f77bd334731182801ced3380a8cc859091596" - integrity sha512-D211tC7ZwouTIuY5x9XnS0E9sWNChB7IYKX/Xp5eQj3nFXhqmiUDB9q27y76oFl8jTg3pXcQx/bpxMfs3CIZbA== +espree@^9.4.0: + version "9.4.1" + resolved "https://registry.yarnpkg.com/espree/-/espree-9.4.1.tgz#51d6092615567a2c2cff7833445e37c28c0065bd" + integrity sha512-XwctdmTO6SIvCzd9810yyNzIrOrqNYV9Koizx4C/mRhf9uq0o4yHoCEU/670pOxOL/MSraektvSAji79kX90Vg== dependencies: - acorn "^8.7.1" + acorn "^8.8.0" acorn-jsx "^5.3.2" eslint-visitor-keys "^3.3.0" esquery@^1.4.0: version "1.4.0" - resolved "https://registry.npmjs.org/esquery/-/esquery-1.4.0.tgz" + resolved "https://registry.yarnpkg.com/esquery/-/esquery-1.4.0.tgz#2148ffc38b82e8c7057dfed48425b3e61f0f24a5" integrity sha512-cCDispWt5vHHtwMY2YrAQ4ibFkAL8RbH5YGBnZBc90MolvvfkkQcJro/aZiAQUlQ3qgrYS6D6v8Gc5G5CQsc9w== dependencies: estraverse "^5.1.0" esrecurse@^4.3.0: version "4.3.0" - resolved "https://registry.npmjs.org/esrecurse/-/esrecurse-4.3.0.tgz" + resolved "https://registry.yarnpkg.com/esrecurse/-/esrecurse-4.3.0.tgz#7ad7964d679abb28bee72cec63758b1c5d2c9921" integrity sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag== dependencies: estraverse "^5.2.0" estraverse@^4.1.1: version "4.3.0" - resolved "https://registry.npmjs.org/estraverse/-/estraverse-4.3.0.tgz" + resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-4.3.0.tgz#398ad3f3c5a24948be7725e83d11a7de28cdbd1d" integrity sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw== estraverse@^5.1.0, estraverse@^5.2.0: version "5.3.0" - resolved "https://registry.npmjs.org/estraverse/-/estraverse-5.3.0.tgz" + resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-5.3.0.tgz#2eea5290702f26ab8fe5370370ff86c965d21123" integrity sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA== +estree-walker@^2.0.2: + version "2.0.2" + resolved "https://registry.yarnpkg.com/estree-walker/-/estree-walker-2.0.2.tgz#52f010178c2a4c117a7757cfe942adb7d2da4cac" + integrity sha512-Rfkk/Mp/DL7JVje3u18FxFujQlTNR2q6QfMSMB7AvCBx91NGj/ba3kCfza0f6dVDbw7YlRf/nDrn7pQrCCyQ/w== + esutils@^2.0.2: version "2.0.3" - resolved "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz" + resolved "https://registry.yarnpkg.com/esutils/-/esutils-2.0.3.tgz#74d2eb4de0b8da1293711910d50775b9b710ef64" integrity sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g== eventemitter3@^3.1.0: @@ -592,13 +843,13 @@ eventemitter3@^3.1.0: fast-deep-equal@^3.1.1, fast-deep-equal@^3.1.3: version "3.1.3" - resolved "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz" + resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz#3a7d56b559d6cbc3eb512325244e619a65c6c525" integrity sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q== fast-glob@^3.2.9: - version "3.2.11" - resolved "https://registry.npmjs.org/fast-glob/-/fast-glob-3.2.11.tgz" - integrity sha512-xrO3+1bxSo3ZVHAnqzyuewYT6aMFHRAd4Kcs92MAonjwQZLsK9d0SF1IyQ3k5PoirxTW0Oe/RqFgMQ6TcNE5Ew== + version "3.2.12" + resolved "https://registry.yarnpkg.com/fast-glob/-/fast-glob-3.2.12.tgz#7f39ec99c2e6ab030337142da9e0c18f37afae80" + integrity sha512-DVj4CQIYYow0BlaelwK1pHl5n5cRSJfM60UA0zK891sVInoPri2Ekj7+e1CT3/3qxXenpI+nBBmQAcJPJgaj4w== dependencies: "@nodelib/fs.stat" "^2.0.2" "@nodelib/fs.walk" "^1.2.3" @@ -608,57 +859,70 @@ fast-glob@^3.2.9: fast-json-stable-stringify@^2.0.0: version "2.1.0" - resolved "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz" + resolved "https://registry.yarnpkg.com/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz#874bf69c6f404c2b5d99c481341399fd55892633" integrity sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw== fast-levenshtein@^2.0.6: version "2.0.6" - resolved "https://registry.npmjs.org/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz" - integrity sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc= + resolved "https://registry.yarnpkg.com/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz#3d8a5c66883a16a30ca8643e851f19baa7797917" + integrity sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw== fastq@^1.6.0: - version "1.13.0" - resolved "https://registry.npmjs.org/fastq/-/fastq-1.13.0.tgz" - integrity sha512-YpkpUnK8od0o1hmeSc7UUs/eB/vIPWJYjKck2QKIzAf71Vm1AAQ3EbuZB3g2JIy+pg+ERD0vqI79KyZiB2e2Nw== + version "1.14.0" + resolved "https://registry.yarnpkg.com/fastq/-/fastq-1.14.0.tgz#107f69d7295b11e0fccc264e1fc6389f623731ce" + integrity sha512-eR2D+V9/ExcbF9ls441yIuN6TI2ED1Y2ZcA5BmMtJsOkWOFRJQ0Jt0g1UwqXJJVAb+V+umH5Dfr8oh4EVP7VVg== dependencies: reusify "^1.0.4" file-entry-cache@^6.0.1: version "6.0.1" - resolved "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-6.0.1.tgz" + resolved "https://registry.yarnpkg.com/file-entry-cache/-/file-entry-cache-6.0.1.tgz#211b2dd9659cb0394b073e7323ac3c933d522027" integrity sha512-7Gps/XWymbLk2QLYK4NzpMOrYjMhdIxXuIvy2QBsLE6ljuodKvdkWs/cpyJJ3CVIVpH0Oi1Hvg1ovbMzLdFBBg== dependencies: flat-cache "^3.0.4" fill-range@^7.0.1: version "7.0.1" - resolved "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz" + resolved "https://registry.yarnpkg.com/fill-range/-/fill-range-7.0.1.tgz#1919a6a7c75fe38b2c7c77e5198535da9acdda40" integrity sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ== dependencies: to-regex-range "^5.0.1" +find-up@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/find-up/-/find-up-5.0.0.tgz#4c92819ecb7083561e4f4a240a86be5198f536fc" + integrity sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng== + dependencies: + locate-path "^6.0.0" + path-exists "^4.0.0" + flat-cache@^3.0.4: version "3.0.4" - resolved "https://registry.npmjs.org/flat-cache/-/flat-cache-3.0.4.tgz" + resolved "https://registry.yarnpkg.com/flat-cache/-/flat-cache-3.0.4.tgz#61b0338302b2fe9f957dcc32fc2a87f1c3048b11" integrity sha512-dm9s5Pw7Jc0GvMYbshN6zchCA9RgQlzzEZX3vylR9IqFfS8XciblUXOKfW6SiuJ0e13eDYZoZV5wdrev7P3Nwg== dependencies: flatted "^3.1.0" rimraf "^3.0.2" flatted@^3.1.0: - version "3.2.5" - resolved "https://registry.npmjs.org/flatted/-/flatted-3.2.5.tgz" - integrity sha512-WIWGi2L3DyTUvUrwRKgGi9TwxQMUEqPOPQBVi71R96jZXJdFskXEmf54BoZaS1kknGODoIGASGEzBUYdyMCBJg== + version "3.2.7" + resolved "https://registry.yarnpkg.com/flatted/-/flatted-3.2.7.tgz#609f39207cb614b89d0765b477cb2d437fbf9787" + integrity sha512-5nqDSxl8nn5BSNxyR3n4I6eDmbolI6WT+QqR547RwxQapgjQBmtktdP+HTBb/a/zLsbzERTONyUB5pefh5TtjQ== fs.realpath@^1.0.0: version "1.0.0" - resolved "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz" - integrity sha1-FQStJSMVjKpA20onh8sBQRmU6k8= + resolved "https://registry.yarnpkg.com/fs.realpath/-/fs.realpath-1.0.0.tgz#1504ad2523158caa40db4a2787cb01411994ea4f" + integrity sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw== -functional-red-black-tree@^1.0.1: - version "1.0.1" - resolved "https://registry.npmjs.org/functional-red-black-tree/-/functional-red-black-tree-1.0.1.tgz" - integrity sha1-GwqzvVU7Kg1jmdKcDj6gslIHgyc= +fsevents@~2.3.2: + version "2.3.2" + resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-2.3.2.tgz#8a526f78b8fdf4623b709e0b975c52c24c02fd1a" + integrity sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA== + +function-bind@^1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.1.tgz#a56899d3ea3c9bab874bb9773b7c5ede92f4895d" + integrity sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A== gifuct-js@^2.1.2: version "2.1.2" @@ -669,34 +933,34 @@ gifuct-js@^2.1.2: glob-parent@^5.1.2: version "5.1.2" - resolved "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz" + resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-5.1.2.tgz#869832c58034fe68a4093c17dc15e8340d8401c4" integrity sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow== dependencies: is-glob "^4.0.1" -glob-parent@^6.0.1: +glob-parent@^6.0.2: version "6.0.2" - resolved "https://registry.npmjs.org/glob-parent/-/glob-parent-6.0.2.tgz" + resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-6.0.2.tgz#6d237d99083950c79290f24c7642a3de9a28f9e3" integrity sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A== dependencies: is-glob "^4.0.3" glob@^7.1.3: - version "7.2.0" - resolved "https://registry.npmjs.org/glob/-/glob-7.2.0.tgz" - integrity sha512-lmLf6gtyrPq8tTjSmrO94wBeQbFR3HbLHbuyD69wuyQkImp2hWqMGB47OX65FBkPffO641IP9jWa1z4ivqG26Q== + version "7.2.3" + resolved "https://registry.yarnpkg.com/glob/-/glob-7.2.3.tgz#b8df0fb802bbfa8e89bd1d938b4e16578ed44f2b" + integrity sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q== dependencies: fs.realpath "^1.0.0" inflight "^1.0.4" inherits "2" - minimatch "^3.0.4" + minimatch "^3.1.1" once "^1.3.0" path-is-absolute "^1.0.0" globals@^13.15.0: - version "13.16.0" - resolved "https://registry.yarnpkg.com/globals/-/globals-13.16.0.tgz#9be4aca28f311aaeb974ea54978ebbb5e35ce46a" - integrity sha512-A1lrQfpNF+McdPOnnFqY3kSN0AFTy485bTi1bkLk4mVPODIUEcSfhHgRqA+QdXPksrSTTztYXx37NFV+GpGk3Q== + version "13.19.0" + resolved "https://registry.yarnpkg.com/globals/-/globals-13.19.0.tgz#7a42de8e6ad4f7242fbcca27ea5b23aca367b5c8" + integrity sha512-dkQ957uSRWHw7CFXLUtUHQI3g3aWApYhfNR2O6jn/907riyTYKVBmxYVROkBcY614FSSeSJh7Xm7SrUWCxvJMQ== dependencies: type-fest "^0.20.2" @@ -712,24 +976,54 @@ globby@^11.1.0: merge2 "^1.4.1" slash "^3.0.0" +grapheme-splitter@^1.0.4: + version "1.0.4" + resolved "https://registry.yarnpkg.com/grapheme-splitter/-/grapheme-splitter-1.0.4.tgz#9cf3a665c6247479896834af35cf1dbb4400767e" + integrity sha512-bzh50DW9kTPM00T8y4o8vQg89Di9oLJVLW/KaOGIXJWP/iqCN6WKYkbNOF04vFLJhwcpYUh9ydh/+5vpOqV4YQ== + has-flag@^4.0.0: version "4.0.0" - resolved "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz" + resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-4.0.0.tgz#944771fd9c81c81265c4d6941860da06bb59479b" integrity sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ== +has@^1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/has/-/has-1.0.3.tgz#722d7cbfc1f6aa8241f16dd814e011e1f41e8796" + integrity sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw== + dependencies: + function-bind "^1.1.1" + +he@^1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/he/-/he-1.2.0.tgz#84ae65fa7eafb165fddb61566ae14baf05664f0f" + integrity sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw== + howler@^2.2.3: version "2.2.3" resolved "https://registry.yarnpkg.com/howler/-/howler-2.2.3.tgz#a2eff9b08b586798e7a2ee17a602a90df28715da" integrity sha512-QM0FFkw0LRX1PR8pNzJVAY25JhIWvbKMBFM4gqk+QdV+kPXOhleWGCB6AiAF/goGjIHK2e/nIElplvjQwhr0jg== +html-minifier-terser@^6.1.0: + version "6.1.0" + resolved "https://registry.yarnpkg.com/html-minifier-terser/-/html-minifier-terser-6.1.0.tgz#bfc818934cc07918f6b3669f5774ecdfd48f32ab" + integrity sha512-YXxSlJBZTP7RS3tWnQw74ooKa6L9b9i9QYXY21eUEvhZ3u9XLfv6OnFsQq6RxkhHygsaUMvYsZRV5rU/OVNZxw== + dependencies: + camel-case "^4.1.2" + clean-css "^5.2.2" + commander "^8.3.0" + he "^1.2.0" + param-case "^3.0.4" + relateurl "^0.2.7" + terser "^5.10.0" + ignore@^5.2.0: - version "5.2.0" - resolved "https://registry.npmjs.org/ignore/-/ignore-5.2.0.tgz" - integrity sha512-CmxgYGiEPCLhfLnpPp1MoRmifwEIOgjcHXxOBjv7mY96c+eWScsOP9c112ZyLdWHi0FxHjI+4uVhKYp/gcdRmQ== + version "5.2.1" + resolved "https://registry.yarnpkg.com/ignore/-/ignore-5.2.1.tgz#c2b1f76cb999ede1502f3a226a9310fdfe88d46c" + integrity sha512-d2qQLzTJ9WxQftPAuEQpSPmKqzxePjzVbpAVv62AQ64NTL+wR4JkrVqR/LqFsFEUsHDAiId52mJteHDFuDkElA== import-fresh@^3.0.0, import-fresh@^3.2.1: version "3.3.0" - resolved "https://registry.npmjs.org/import-fresh/-/import-fresh-3.3.0.tgz" + resolved "https://registry.yarnpkg.com/import-fresh/-/import-fresh-3.3.0.tgz#37162c25fcb9ebaa2e6e53d5b4d88ce17d9e0c2b" integrity sha512-veYYhQa+D1QBKznvhUHxb8faxlrwUnxseDAbAp457E0wLNio2bOSKnjYDhMj+YiAq61xrMGhQk9iXVk5FzgQMw== dependencies: parent-module "^1.0.0" @@ -737,136 +1031,180 @@ import-fresh@^3.0.0, import-fresh@^3.2.1: imurmurhash@^0.1.4: version "0.1.4" - resolved "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz" - integrity sha1-khi5srkoojixPcT7a21XbyMUU+o= + resolved "https://registry.yarnpkg.com/imurmurhash/-/imurmurhash-0.1.4.tgz#9218b9b2b928a238b13dc4fb6b6d576f231453ea" + integrity sha512-JmXMZ6wuvDmLiHEml9ykzqO6lwFbof0GG4IkcGaENdCRDDmMVnny7s5HsIgHCbaq0w2MyPhDqkhTUgS2LU2PHA== inflight@^1.0.4: version "1.0.6" - resolved "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz" - integrity sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk= + resolved "https://registry.yarnpkg.com/inflight/-/inflight-1.0.6.tgz#49bd6331d7d02d0c09bc910a1075ba8165b56df9" + integrity sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA== dependencies: once "^1.3.0" wrappy "1" inherits@2: version "2.0.4" - resolved "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz" + resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.4.tgz#0fa2c64f932917c3433a0ded55363aae37416b7c" integrity sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ== +is-core-module@^2.9.0: + version "2.11.0" + resolved "https://registry.yarnpkg.com/is-core-module/-/is-core-module-2.11.0.tgz#ad4cb3e3863e814523c96f3f58d26cc570ff0144" + integrity sha512-RRjxlvLDkD1YJwDbroBHMb+cukurkDWNyHx7D3oNB5x9rb5ogcksMC5wHCadcXoo67gVr/+3GFySh3134zi6rw== + dependencies: + has "^1.0.3" + is-extglob@^2.1.1: version "2.1.1" - resolved "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz" - integrity sha1-qIwCU1eR8C7TfHahueqXc8gz+MI= + resolved "https://registry.yarnpkg.com/is-extglob/-/is-extglob-2.1.1.tgz#a88c02535791f02ed37c76a1b9ea9773c833f8c2" + integrity sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ== is-glob@^4.0.0, is-glob@^4.0.1, is-glob@^4.0.3: version "4.0.3" - resolved "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz" + resolved "https://registry.yarnpkg.com/is-glob/-/is-glob-4.0.3.tgz#64f61e42cbbb2eec2071a9dac0b28ba1e65d5084" integrity sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg== dependencies: is-extglob "^2.1.1" is-number@^7.0.0: version "7.0.0" - resolved "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz" + resolved "https://registry.yarnpkg.com/is-number/-/is-number-7.0.0.tgz#7535345b896734d5f80c4d06c50955527a14f12b" integrity sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng== +is-path-inside@^3.0.3: + version "3.0.3" + resolved "https://registry.yarnpkg.com/is-path-inside/-/is-path-inside-3.0.3.tgz#d231362e53a07ff2b0e0ea7fed049161ffd16283" + integrity sha512-Fd4gABb+ycGAmKou8eMftCupSir5lRxqf4aD/vd0cD2qc4HL07OjCeuHMr8Ro4CoMaeCKDB0/ECBOVWjTwUvPQ== + isexe@^2.0.0: version "2.0.0" - resolved "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz" - integrity sha1-6PvzdNxVb/iUehDcsFctYz8s+hA= - -ismobilejs@^1.1.0: - version "1.1.1" - resolved "https://registry.yarnpkg.com/ismobilejs/-/ismobilejs-1.1.1.tgz#c56ca0ae8e52b24ca0f22ba5ef3215a2ddbbaa0e" - integrity sha512-VaFW53yt8QO61k2WJui0dHf4SlL8lxBofUuUmwBo0ljPk0Drz2TiuDW4jo3wDcv41qy/SxrJ+VAzJ/qYqsmzRw== + resolved "https://registry.yarnpkg.com/isexe/-/isexe-2.0.0.tgz#e8fbf374dc556ff8947a10dcb0572d633f2cfa10" + integrity sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw== js-binary-schema-parser@^2.0.3: version "2.0.3" resolved "https://registry.yarnpkg.com/js-binary-schema-parser/-/js-binary-schema-parser-2.0.3.tgz#3d7848748e8586e63b34e8911b643f59cfb6396e" integrity sha512-xezGJmOb4lk/M1ZZLTR/jaBHQ4gG/lqQnJqdIv4721DMggsa1bDVlHXNeHYogaIEHD9vCRv0fcL4hMA+Coarkg== +js-sdsl@^4.1.4: + version "4.2.0" + resolved "https://registry.yarnpkg.com/js-sdsl/-/js-sdsl-4.2.0.tgz#278e98b7bea589b8baaf048c20aeb19eb7ad09d0" + integrity sha512-dyBIzQBDkCqCu+0upx25Y2jGdbTGxE9fshMsCdK0ViOongpV+n5tXRcZY9v7CaVQ79AGS9KA1KHtojxiM7aXSQ== + js-yaml@^4.1.0: version "4.1.0" - resolved "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz" + resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-4.1.0.tgz#c1fb65f8f5017901cdd2c951864ba18458a10602" integrity sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA== dependencies: argparse "^2.0.1" json-schema-traverse@^0.4.1: version "0.4.1" - resolved "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz" + resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz#69f6a87d9513ab8bb8fe63bdb0979c448e684660" integrity sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg== json-stable-stringify-without-jsonify@^1.0.1: version "1.0.1" - resolved "https://registry.npmjs.org/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz" - integrity sha1-nbe1lJatPzz+8wp1FC0tkwrXJlE= + resolved "https://registry.yarnpkg.com/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz#9db7b59496ad3f3cfef30a75142d2d930ad72651" + integrity sha512-Bdboy+l7tA3OGW6FjyFHWkP5LuByj1Tk33Ljyq0axyzdk9//JSi2u3fP1QSmd1KNwq6VOKYGlAu87CisVir6Pw== levn@^0.4.1: version "0.4.1" - resolved "https://registry.npmjs.org/levn/-/levn-0.4.1.tgz" + resolved "https://registry.yarnpkg.com/levn/-/levn-0.4.1.tgz#ae4562c007473b932a6200d403268dd2fffc6ade" integrity sha512-+bT2uH4E5LGE7h/n3evcS/sQlJXCpIp6ym8OWJ5eV6+67Dsql/LaaT7qJBAt2rzfoa/5QBGBhxDix1dMt2kQKQ== dependencies: prelude-ls "^1.2.1" type-check "~0.4.0" +locate-path@^6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/locate-path/-/locate-path-6.0.0.tgz#55321eb309febbc59c4801d931a72452a681d286" + integrity sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw== + dependencies: + p-locate "^5.0.0" + lodash.merge@^4.6.2: version "4.6.2" - resolved "https://registry.npmjs.org/lodash.merge/-/lodash.merge-4.6.2.tgz" + resolved "https://registry.yarnpkg.com/lodash.merge/-/lodash.merge-4.6.2.tgz#558aa53b43b661e1925a0afdfa36a9a1085fe57a" integrity sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ== +lower-case@^2.0.2: + version "2.0.2" + resolved "https://registry.yarnpkg.com/lower-case/-/lower-case-2.0.2.tgz#6fa237c63dbdc4a82ca0fd882e4722dc5e634e28" + integrity sha512-7fm3l3NAF9WfN6W3JOmf5drwpVqX78JtoGJ3A6W0a6ZnldM41w2fV5D490psKFTpMds8TJse/eHLFFsNHHjHgg== + dependencies: + tslib "^2.0.3" + lru-cache@^6.0.0: version "6.0.0" - resolved "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz" + resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-6.0.0.tgz#6d6fe6570ebd96aaf90fcad1dafa3b2566db3a94" integrity sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA== dependencies: yallist "^4.0.0" merge2@^1.3.0, merge2@^1.4.1: version "1.4.1" - resolved "https://registry.npmjs.org/merge2/-/merge2-1.4.1.tgz" + resolved "https://registry.yarnpkg.com/merge2/-/merge2-1.4.1.tgz#4368892f885e907455a6fd7dc55c0c9d404990ae" integrity sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg== micromatch@^4.0.4: - version "4.0.4" - resolved "https://registry.npmjs.org/micromatch/-/micromatch-4.0.4.tgz" - integrity sha512-pRmzw/XUcwXGpD9aI9q/0XOwLNygjETJ8y0ao0wdqprrzDa4YnxLcz7fQRZr8voh8V10kGhABbNcHVk5wHgWwg== + version "4.0.5" + resolved "https://registry.yarnpkg.com/micromatch/-/micromatch-4.0.5.tgz#bc8999a7cbbf77cdc89f132f6e467051b49090c6" + integrity sha512-DMy+ERcEW2q8Z2Po+WNXuw3c5YaUSFjAO5GsJqfEl7UjvtIuFKO6ZrKvcItdy98dwFI2N1tg3zNIdKaQT+aNdA== dependencies: - braces "^3.0.1" - picomatch "^2.2.3" + braces "^3.0.2" + picomatch "^2.3.1" -minimatch@^3.0.4, minimatch@^3.1.2: +minimatch@^3.0.5, minimatch@^3.1.1, minimatch@^3.1.2: version "3.1.2" - resolved "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz" + resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.1.2.tgz#19cd194bfd3e428f049a70817c038d89ab4be35b" integrity sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw== dependencies: brace-expansion "^1.1.7" ms@2.1.2: version "2.1.2" - resolved "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz" + resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.2.tgz#d09d1f357b443f493382a8eb3ccd183872ae6009" integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w== +nanoid@^3.3.4: + version "3.3.4" + resolved "https://registry.yarnpkg.com/nanoid/-/nanoid-3.3.4.tgz#730b67e3cd09e2deacf03c027c81c9d9dbc5e8ab" + integrity sha512-MqBkQh/OHTS2egovRtLk45wEyNXwF+cokD+1YPf9u5VfJiRdAiRwB2froX5Co9Rh20xs4siNPm8naNotSD6RBw== + +natural-compare-lite@^1.4.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/natural-compare-lite/-/natural-compare-lite-1.4.0.tgz#17b09581988979fddafe0201e931ba933c96cbb4" + integrity sha512-Tj+HTDSJJKaZnfiuw+iaF9skdPpTo2GtEly5JHnWV/hfv2Qj/9RKsGISQtLh2ox3l5EAGw487hnBee0sIJ6v2g== + natural-compare@^1.4.0: version "1.4.0" - resolved "https://registry.npmjs.org/natural-compare/-/natural-compare-1.4.0.tgz" - integrity sha1-Sr6/7tdUHywnrPspvbvRXI1bpPc= + resolved "https://registry.yarnpkg.com/natural-compare/-/natural-compare-1.4.0.tgz#4abebfeed7541f2c27acfb29bdbbd15c8d5ba4f7" + integrity sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw== + +no-case@^3.0.4: + version "3.0.4" + resolved "https://registry.yarnpkg.com/no-case/-/no-case-3.0.4.tgz#d361fd5c9800f558551a8369fc0dcd4662b6124d" + integrity sha512-fgAN3jGAh+RoxUGZHTSOLJIqUc2wmoBwGR4tbpNAKmmovFoWq0OdRkb0VkldReO2a2iBT/OEulG9XSUc10r3zg== + dependencies: + lower-case "^2.0.2" + tslib "^2.0.3" object-assign@^4.1.1: version "4.1.1" resolved "https://registry.yarnpkg.com/object-assign/-/object-assign-4.1.1.tgz#2109adc7965887cfc05cbbd442cac8bfbb360863" - integrity sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM= + integrity sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg== once@^1.3.0: version "1.4.0" - resolved "https://registry.npmjs.org/once/-/once-1.4.0.tgz" - integrity sha1-WDsap3WWHUsROsF9nFC6753Xa9E= + resolved "https://registry.yarnpkg.com/once/-/once-1.4.0.tgz#583b1aa775961d4b113ac17d9c50baef9dd76bd1" + integrity sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w== dependencies: wrappy "1" optionator@^0.9.1: version "0.9.1" - resolved "https://registry.npmjs.org/optionator/-/optionator-0.9.1.tgz" + resolved "https://registry.yarnpkg.com/optionator/-/optionator-0.9.1.tgz#4f236a6373dae0566a6d43e1326674f50c291499" integrity sha512-74RlY5FCnhq4jRxVUPKDaRwrVNXMqsGsiW6AJw4XK8hmtm10wC0ypZBLw5IIp85NZMr91+qd1RvvENwg7jjRFw== dependencies: deep-is "^0.1.3" @@ -876,41 +1214,95 @@ optionator@^0.9.1: type-check "^0.4.0" word-wrap "^1.2.3" +p-limit@^3.0.2: + version "3.1.0" + resolved "https://registry.yarnpkg.com/p-limit/-/p-limit-3.1.0.tgz#e1daccbe78d0d1388ca18c64fea38e3e57e3706b" + integrity sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ== + dependencies: + yocto-queue "^0.1.0" + +p-locate@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/p-locate/-/p-locate-5.0.0.tgz#83c8315c6785005e3bd021839411c9e110e6d834" + integrity sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw== + dependencies: + p-limit "^3.0.2" + pako@^2.0.4: - version "2.0.4" - resolved "https://registry.npmjs.org/pako/-/pako-2.0.4.tgz" - integrity sha512-v8tweI900AUkZN6heMU/4Uy4cXRc2AYNRggVmTR+dEncawDJgCdLMximOVA2p4qO57WMynangsfGRb5WD6L1Bg== + version "2.1.0" + resolved "https://registry.yarnpkg.com/pako/-/pako-2.1.0.tgz#266cc37f98c7d883545d11335c00fbd4062c9a86" + integrity sha512-w+eufiZ1WuJYgPXbV/PO3NCMEc3xqylkKHzp8bxp1uW4qaSNQUkwmLLEc3kKsfz8lpV1F8Ht3U1Cm+9Srog2ug== + +param-case@^3.0.4: + version "3.0.4" + resolved "https://registry.yarnpkg.com/param-case/-/param-case-3.0.4.tgz#7d17fe4aa12bde34d4a77d91acfb6219caad01c5" + integrity sha512-RXlj7zCYokReqWpOPH9oYivUzLYZ5vAPIfEmCTNViosC78F8F0H9y7T7gG2M39ymgutxF5gcFEsyZQSph9Bp3A== + dependencies: + dot-case "^3.0.4" + tslib "^2.0.3" parent-module@^1.0.0: version "1.0.1" - resolved "https://registry.npmjs.org/parent-module/-/parent-module-1.0.1.tgz" + resolved "https://registry.yarnpkg.com/parent-module/-/parent-module-1.0.1.tgz#691d2709e78c79fae3a156622452d00762caaaa2" integrity sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g== dependencies: callsites "^3.0.0" +pascal-case@^3.1.2: + version "3.1.2" + resolved "https://registry.yarnpkg.com/pascal-case/-/pascal-case-3.1.2.tgz#b48e0ef2b98e205e7c1dae747d0b1508237660eb" + integrity sha512-uWlGT3YSnK9x3BQJaOdcZwrnV6hPpd8jFH1/ucpiLRPh/2zCVJKS19E4GvYHvaCcACn3foXZ0cLB9Wrx1KGe5g== + dependencies: + no-case "^3.0.4" + tslib "^2.0.3" + +path-exists@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/path-exists/-/path-exists-4.0.0.tgz#513bdbe2d3b95d7762e8c1137efa195c6c61b5b3" + integrity sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w== + path-is-absolute@^1.0.0: version "1.0.1" - resolved "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz" - integrity sha1-F0uSaHNVNP+8es5r9TpanhtcX18= + resolved "https://registry.yarnpkg.com/path-is-absolute/-/path-is-absolute-1.0.1.tgz#174b9268735534ffbc7ace6bf53a5a9e1b5c5f5f" + integrity sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg== path-key@^3.1.0: version "3.1.1" - resolved "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz" + resolved "https://registry.yarnpkg.com/path-key/-/path-key-3.1.1.tgz#581f6ade658cbba65a0d3380de7753295054f375" integrity sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q== +path-parse@^1.0.7: + version "1.0.7" + resolved "https://registry.yarnpkg.com/path-parse/-/path-parse-1.0.7.tgz#fbc114b60ca42b30d9daf5858e4bd68bbedb6735" + integrity sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw== + path-type@^4.0.0: version "4.0.0" - resolved "https://registry.npmjs.org/path-type/-/path-type-4.0.0.tgz" + resolved "https://registry.yarnpkg.com/path-type/-/path-type-4.0.0.tgz#84ed01c0a7ba380afe09d90a8c180dcd9d03043b" integrity sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw== -picomatch@^2.2.3: +picocolors@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/picocolors/-/picocolors-1.0.0.tgz#cb5bdc74ff3f51892236eaf79d68bc44564ab81c" + integrity sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ== + +picomatch@^2.3.1: version "2.3.1" - resolved "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz" + resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-2.3.1.tgz#3ba3833733646d9d3e4995946c1365a67fb07a42" integrity sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA== +postcss@^8.4.20: + version "8.4.20" + resolved "https://registry.yarnpkg.com/postcss/-/postcss-8.4.20.tgz#64c52f509644cecad8567e949f4081d98349dc56" + integrity sha512-6Q04AXR1212bXr5fh03u8aAwbLxAQNGQ/Q1LNa0VfOI06ZAlhPHtQvE4OIdpj4kLThXilalPnmDSOD65DcHt+g== + dependencies: + nanoid "^3.3.4" + picocolors "^1.0.0" + source-map-js "^1.0.2" + prelude-ls@^1.2.1: version "1.2.1" - resolved "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.2.1.tgz" + resolved "https://registry.yarnpkg.com/prelude-ls/-/prelude-ls-1.2.1.tgz#debc6489d7a6e6b0e7611888cec880337d316396" integrity sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g== promise-polyfill@^8.2.0: @@ -921,144 +1313,198 @@ promise-polyfill@^8.2.0: punycode@1.3.2: version "1.3.2" resolved "https://registry.yarnpkg.com/punycode/-/punycode-1.3.2.tgz#9653a036fb7c1ee42342f2325cceefea3926c48d" - integrity sha1-llOgNvt8HuQjQvIyXM7v6jkmxI0= + integrity sha512-RofWgt/7fL5wP1Y7fxE7/EmTLzQVnB0ycyibJ0OOHIlJqTNzglYFxVwETOcIoJqJmpDXJ9xImDv+Fq34F/d4Dw== punycode@^2.1.0: version "2.1.1" - resolved "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz" + resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.1.1.tgz#b58b010ac40c22c5657616c8d2c2c02c7bf479ec" integrity sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A== querystring@0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/querystring/-/querystring-0.2.0.tgz#b209849203bb25df820da756e747005878521620" - integrity sha1-sgmEkgO7Jd+CDadW50cAWHhSFiA= + integrity sha512-X/xY82scca2tau62i9mDyU9K+I+djTMUsvwf7xnUX5GLvVzgJybOJf4Y6o9Zx3oJK/LSXg5tTZBjwzqVPaPO2g== queue-microtask@^1.2.2: version "1.2.3" - resolved "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz" + resolved "https://registry.yarnpkg.com/queue-microtask/-/queue-microtask-1.2.3.tgz#4929228bbc724dfac43e0efb058caf7b6cfb6243" integrity sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A== regexpp@^3.2.0: version "3.2.0" - resolved "https://registry.npmjs.org/regexpp/-/regexpp-3.2.0.tgz" + resolved "https://registry.yarnpkg.com/regexpp/-/regexpp-3.2.0.tgz#0425a2768d8f23bad70ca4b90461fa2f1213e1b2" integrity sha512-pq2bWo9mVD43nbts2wGv17XLiNLya+GklZ8kaDLV2Z08gDCsGpnKn9BFMepvWuHCbyVvY7J5o5+BVvoQbmlJLg== +relateurl@^0.2.7: + version "0.2.7" + resolved "https://registry.yarnpkg.com/relateurl/-/relateurl-0.2.7.tgz#54dbf377e51440aca90a4cd274600d3ff2d888a9" + integrity sha512-G08Dxvm4iDN3MLM0EsP62EDV9IuhXPR6blNz6Utcp7zyV3tr4HVNINt6MpaRWbxoOHT3Q7YN2P+jaHX8vUbgog== + resolve-from@^4.0.0: version "4.0.0" - resolved "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz" + resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-4.0.0.tgz#4abcd852ad32dd7baabfe9b40e00a36db5f392e6" integrity sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g== +resolve@^1.22.1: + version "1.22.1" + resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.22.1.tgz#27cb2ebb53f91abb49470a928bba7558066ac177" + integrity sha512-nBpuuYuY5jFsli/JIs1oldw6fOQCBioohqWZg/2hiaOybXOft4lonv85uDOKXdf8rhyK159cxU5cDcK/NKk8zw== + dependencies: + is-core-module "^2.9.0" + path-parse "^1.0.7" + supports-preserve-symlinks-flag "^1.0.0" + reusify@^1.0.4: version "1.0.4" - resolved "https://registry.npmjs.org/reusify/-/reusify-1.0.4.tgz" + resolved "https://registry.yarnpkg.com/reusify/-/reusify-1.0.4.tgz#90da382b1e126efc02146e90845a88db12925d76" integrity sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw== rimraf@^3.0.2: version "3.0.2" - resolved "https://registry.npmjs.org/rimraf/-/rimraf-3.0.2.tgz" + resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-3.0.2.tgz#f1a5402ba6220ad52cc1282bac1ae3aa49fd061a" integrity sha512-JZkJMZkAGFFPP2YqXZXPbMlMBgsxzE8ILs4lMIX/2o0L9UBw9O/Y3o6wFw/i9YLapcUJWwqbi3kdxIPdC62TIA== dependencies: glob "^7.1.3" +rollup@^3.7.0: + version "3.7.5" + resolved "https://registry.yarnpkg.com/rollup/-/rollup-3.7.5.tgz#db580f8eda50237b0721ddea301fb981cd992933" + integrity sha512-z0ZbqHBtS/et2EEUKMrAl2CoSdwN7ZPzL17UMiKN9RjjqHShTlv7F9J6ZJZJNREYjBh3TvBrdfjkFDIXFNeuiQ== + optionalDependencies: + fsevents "~2.3.2" + run-parallel@^1.1.9: version "1.2.0" - resolved "https://registry.npmjs.org/run-parallel/-/run-parallel-1.2.0.tgz" + resolved "https://registry.yarnpkg.com/run-parallel/-/run-parallel-1.2.0.tgz#66d1368da7bdf921eb9d95bd1a9229e7f21a43ee" integrity sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA== dependencies: queue-microtask "^1.2.2" semver@^7.3.7: - version "7.3.7" - resolved "https://registry.yarnpkg.com/semver/-/semver-7.3.7.tgz#12c5b649afdbf9049707796e22a4028814ce523f" - integrity sha512-QlYTucUYOews+WeEujDoEGziz4K6c47V/Bd+LjSSYcA94p+DmINdf7ncaUinThfvZyu13lN9OY1XDxt8C0Tw0g== + version "7.3.8" + resolved "https://registry.yarnpkg.com/semver/-/semver-7.3.8.tgz#07a78feafb3f7b32347d725e33de7e2a2df67798" + integrity sha512-NB1ctGL5rlHrPJtFDVIVzTyQylMLu9N9VICA6HSFJo8MCGVTMW6gfpicwKmmK/dAjTOrqu5l63JJOpDSrAis3A== dependencies: lru-cache "^6.0.0" shebang-command@^2.0.0: version "2.0.0" - resolved "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz" + resolved "https://registry.yarnpkg.com/shebang-command/-/shebang-command-2.0.0.tgz#ccd0af4f8835fbdc265b82461aaf0c36663f34ea" integrity sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA== dependencies: shebang-regex "^3.0.0" shebang-regex@^3.0.0: version "3.0.0" - resolved "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz" + resolved "https://registry.yarnpkg.com/shebang-regex/-/shebang-regex-3.0.0.tgz#ae16f1644d873ecad843b0307b143362d4c42172" integrity sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A== slash@^3.0.0: version "3.0.0" - resolved "https://registry.npmjs.org/slash/-/slash-3.0.0.tgz" + resolved "https://registry.yarnpkg.com/slash/-/slash-3.0.0.tgz#6539be870c165adbd5240220dbe361f1bc4d4634" integrity sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q== +source-map-js@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/source-map-js/-/source-map-js-1.0.2.tgz#adbc361d9c62df380125e7f161f71c826f1e490c" + integrity sha512-R0XvVJ9WusLiqTCEiGCmICCMplcCkIwwR11mOSD9CR5u+IXYdiseeEuXCVAjS54zqwkLcPNnmU4OeJ6tUrWhDw== + +source-map-support@~0.5.20: + version "0.5.21" + resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.5.21.tgz#04fe7c7f9e1ed2d662233c28cb2b35b9f63f6e4f" + integrity sha512-uBHU3L3czsIyYXKX88fdrGovxdSCoTGDRZ6SYXtSRxLZUzHg5P/66Ht6uoUlHu9EZod+inXhKo3qQgwXUT/y1w== + dependencies: + buffer-from "^1.0.0" + source-map "^0.6.0" + +source-map@^0.6.0, source-map@~0.6.0: + version "0.6.1" + resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.6.1.tgz#74722af32e9614e9c287a8d0bbde48b5e2f1a263" + integrity sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g== + strip-ansi@^6.0.1: version "6.0.1" - resolved "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz" + resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-6.0.1.tgz#9e26c63d30f53443e9489495b2105d37b67a85d9" integrity sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A== dependencies: ansi-regex "^5.0.1" strip-json-comments@^3.1.0, strip-json-comments@^3.1.1: version "3.1.1" - resolved "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.1.1.tgz" + resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-3.1.1.tgz#31f1281b3832630434831c310c01cccda8cbe006" integrity sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig== supports-color@^7.1.0: version "7.2.0" - resolved "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz" + resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-7.2.0.tgz#1b7dcdcb32b8138801b3e478ba6a51caa89648da" integrity sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw== dependencies: has-flag "^4.0.0" +supports-preserve-symlinks-flag@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz#6eda4bd344a3c94aea376d4cc31bc77311039e09" + integrity sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w== + +terser@^5.10.0: + version "5.16.1" + resolved "https://registry.yarnpkg.com/terser/-/terser-5.16.1.tgz#5af3bc3d0f24241c7fb2024199d5c461a1075880" + integrity sha512-xvQfyfA1ayT0qdK47zskQgRZeWLoOQ8JQ6mIgRGVNwZKdQMU+5FkCBjmv4QjcrTzyZquRw2FVtlJSRUmMKQslw== + dependencies: + "@jridgewell/source-map" "^0.3.2" + acorn "^8.5.0" + commander "^2.20.0" + source-map-support "~0.5.20" + text-table@^0.2.0: version "0.2.0" - resolved "https://registry.npmjs.org/text-table/-/text-table-0.2.0.tgz" - integrity sha1-f17oI66AUgfACvLfSoTsP8+lcLQ= + resolved "https://registry.yarnpkg.com/text-table/-/text-table-0.2.0.tgz#7f5ee823ae805207c00af2df4a84ec3fcfa570b4" + integrity sha512-N+8UisAXDGk8PFXP4HAzVR9nbfmVJ3zYLAWiTIoqC5v5isinhr+r5uaO8+7r3BMfuNIufIsA7RdpVgacC2cSpw== to-regex-range@^5.0.1: version "5.0.1" - resolved "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz" + resolved "https://registry.yarnpkg.com/to-regex-range/-/to-regex-range-5.0.1.tgz#1648c44aae7c8d988a326018ed72f5b4dd0392e4" integrity sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ== dependencies: is-number "^7.0.0" tslib@^1.8.1: version "1.14.1" - resolved "https://registry.npmjs.org/tslib/-/tslib-1.14.1.tgz" + resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.14.1.tgz#cf2d38bdc34a134bcaf1091c41f6619e2f672d00" integrity sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg== -tslib@^2.3.1: - version "2.3.1" - resolved "https://registry.npmjs.org/tslib/-/tslib-2.3.1.tgz" - integrity sha512-77EbyPPpMz+FRFRuAFlWMtmgUWGe9UOG2Z25NqCwiIjRhOf5iKGuzSe5P2w1laq+FkRy4p+PCuVkJSGkzTEKVw== +tslib@^2.0.3, tslib@^2.3.1: + version "2.4.1" + resolved "https://registry.yarnpkg.com/tslib/-/tslib-2.4.1.tgz#0d0bfbaac2880b91e22df0768e55be9753a5b17e" + integrity sha512-tGyy4dAjRIEwI7BzsB0lynWgOpfqjUdq91XXAlIWD2OwKBH7oCl/GZG/HT4BOHrTlPMOASlMQ7veyTqpmRcrNA== tsutils@^3.21.0: version "3.21.0" - resolved "https://registry.npmjs.org/tsutils/-/tsutils-3.21.0.tgz" + resolved "https://registry.yarnpkg.com/tsutils/-/tsutils-3.21.0.tgz#b48717d394cea6c1e096983eed58e9d61715b623" integrity sha512-mHKK3iUXL+3UF6xL5k0PEhKRUBKPBCv/+RkEOpjRWxxx27KKRBmmA60A9pgOUvMi8GKhRMPEmjBRPzs2W7O1OA== dependencies: tslib "^1.8.1" type-check@^0.4.0, type-check@~0.4.0: version "0.4.0" - resolved "https://registry.npmjs.org/type-check/-/type-check-0.4.0.tgz" + resolved "https://registry.yarnpkg.com/type-check/-/type-check-0.4.0.tgz#07b8203bfa7056c0657050e3ccd2c37730bab8f1" integrity sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew== dependencies: prelude-ls "^1.2.1" type-fest@^0.20.2: version "0.20.2" - resolved "https://registry.npmjs.org/type-fest/-/type-fest-0.20.2.tgz" + resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-0.20.2.tgz#1bf207f4b28f91583666cb5fbd327887301cd5f4" integrity sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ== typescript@~4.4.4: version "4.4.4" - resolved "https://registry.npmjs.org/typescript/-/typescript-4.4.4.tgz" + resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.4.4.tgz#2cd01a1a1f160704d3101fd5a58ff0f9fcb8030c" integrity sha512-DqGhF5IKoBl8WNf8C1gu8q0xZSInh9j1kJJMqT3a94w1JzVaBU4EXOSMrz9yDqMT0xt3selp83fuFMQ0uzv6qA== uri-js@^4.2.2: version "4.4.1" - resolved "https://registry.npmjs.org/uri-js/-/uri-js-4.4.1.tgz" + resolved "https://registry.yarnpkg.com/uri-js/-/uri-js-4.4.1.tgz#9b1a52595225859e55f669d928f88c6c57f2a77e" integrity sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg== dependencies: punycode "^2.1.0" @@ -1066,34 +1512,53 @@ uri-js@^4.2.2: url@^0.11.0: version "0.11.0" resolved "https://registry.yarnpkg.com/url/-/url-0.11.0.tgz#3838e97cfc60521eb73c525a8e55bfdd9e2e28f1" - integrity sha1-ODjpfPxgUh63PFJajlW/3Z4uKPE= + integrity sha512-kbailJa29QrtXnxgq+DdCEGlbTeYM2eJUxsz6vjZavrCYPMIFHMKQmSKYAIuUK2i7hgPm28a8piX5NTUtM/LKQ== dependencies: punycode "1.3.2" querystring "0.2.0" -v8-compile-cache@^2.0.3: - version "2.3.0" - resolved "https://registry.npmjs.org/v8-compile-cache/-/v8-compile-cache-2.3.0.tgz" - integrity sha512-l8lCEmLcLYZh4nbunNZvQCJc5pv7+RCwa8q/LdUx8u7lsWvPDKmpodJAJNwkAhJC//dFY48KuIEmjtd4RViDrA== +vite-plugin-minify@^1.5.2: + version "1.5.2" + resolved "https://registry.yarnpkg.com/vite-plugin-minify/-/vite-plugin-minify-1.5.2.tgz#4a331686361cd71b54c28dc149c0a952f354e830" + integrity sha512-clf3THHlet1jD35y8+mbw/xgACbdUQ1Eyc9zZFiqaxVOZLSC3UbrkOYOG+Nf4cleRjWgb8czbXrnQiWZICVh3Q== + dependencies: + html-minifier-terser "^6.1.0" + +vite@^4.0.2: + version "4.0.2" + resolved "https://registry.yarnpkg.com/vite/-/vite-4.0.2.tgz#909beb07995048fe5a83b35b5e827d79627457c4" + integrity sha512-QJaY3R+tFlTagH0exVqbgkkw45B+/bXVBzF2ZD1KB5Z8RiAoiKo60vSUf6/r4c2Vh9jfGBKM4oBI9b4/1ZJYng== + dependencies: + esbuild "^0.16.3" + postcss "^8.4.20" + resolve "^1.22.1" + rollup "^3.7.0" + optionalDependencies: + fsevents "~2.3.2" which@^2.0.1: version "2.0.2" - resolved "https://registry.npmjs.org/which/-/which-2.0.2.tgz" + resolved "https://registry.yarnpkg.com/which/-/which-2.0.2.tgz#7c6a8dd0a636a0327e10b59c9286eee93f3f51b1" integrity sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA== dependencies: isexe "^2.0.0" word-wrap@^1.2.3: version "1.2.3" - resolved "https://registry.npmjs.org/word-wrap/-/word-wrap-1.2.3.tgz" + resolved "https://registry.yarnpkg.com/word-wrap/-/word-wrap-1.2.3.tgz#610636f6b1f703891bd34771ccb17fb93b47079c" integrity sha512-Hz/mrNwitNRh/HUAtM/VT/5VH+ygD6DV7mYKZAtHOrbs8U7lvPS6xf7EJKMF0uW1KJCl0H701g3ZGus+muE5vQ== wrappy@1: version "1.0.2" - resolved "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz" - integrity sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8= + resolved "https://registry.yarnpkg.com/wrappy/-/wrappy-1.0.2.tgz#b5243d8f3ec1aa35f1364605bc0d1036e30ab69f" + integrity sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ== yallist@^4.0.0: version "4.0.0" - resolved "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz" + resolved "https://registry.yarnpkg.com/yallist/-/yallist-4.0.0.tgz#9bb92790d9c0effec63be73519e11a35019a3a72" integrity sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A== + +yocto-queue@^0.1.0: + version "0.1.0" + resolved "https://registry.yarnpkg.com/yocto-queue/-/yocto-queue-0.1.0.tgz#0294eb3dee05028d31ee1a5fa2c556a6aaf10a1b" + integrity sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==