Bump dependencies
This commit is contained in:
parent
52ca1b8844
commit
913abb7642
40 changed files with 6200 additions and 19785 deletions
|
|
@ -13,14 +13,14 @@
|
|||
"try-build-before": "npx webpack --mode production"
|
||||
},
|
||||
"devDependencies": {
|
||||
"clean-webpack-plugin": "^3.0.0",
|
||||
"file-loader": "^6.1.0",
|
||||
"gl-matrix": "3.3.0",
|
||||
"prettier": "^2.0.5",
|
||||
"terser-webpack-plugin": "^2.3.8",
|
||||
"ts-loader": "^8.0.3",
|
||||
"typescript": "^4.0.3",
|
||||
"webpack": "^4.43.0",
|
||||
"webpack-cli": "^3.3.12"
|
||||
"clean-webpack-plugin": "^4.0.0",
|
||||
"file-loader": "^6.2.0",
|
||||
"gl-matrix": "^3.3.0",
|
||||
"prettier": "^3.8.3",
|
||||
"terser-webpack-plugin": "^5.6.1",
|
||||
"ts-loader": "^9.6.0",
|
||||
"typescript": "^6.0.3",
|
||||
"webpack": "^5.107.2",
|
||||
"webpack-cli": "^7.0.3"
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -4,7 +4,10 @@ import { Command } from '../command';
|
|||
|
||||
@serializable
|
||||
export class RemoteCallsForObject {
|
||||
constructor(public readonly id: Id, public readonly calls: Array<RemoteCall>) {}
|
||||
constructor(
|
||||
public readonly id: Id,
|
||||
public readonly calls: Array<RemoteCall>,
|
||||
) {}
|
||||
|
||||
public toArray(): Array<any> {
|
||||
return [this.id, this.calls];
|
||||
|
|
|
|||
|
|
@ -3,7 +3,10 @@ import { serializable } from '../serialization/serializable';
|
|||
|
||||
@serializable
|
||||
export class Circle {
|
||||
constructor(public center: vec2, public radius: number) {}
|
||||
constructor(
|
||||
public center: vec2,
|
||||
public radius: number,
|
||||
) {}
|
||||
|
||||
public distance(target: vec2): number {
|
||||
return vec2.distance(this.center, target) - this.radius;
|
||||
|
|
|
|||
|
|
@ -3,7 +3,10 @@ import { serializable } from '../serialization/serializable';
|
|||
|
||||
@serializable
|
||||
export class Rectangle {
|
||||
constructor(public topLeft = vec2.create(), public size = vec2.create()) {}
|
||||
constructor(
|
||||
public topLeft = vec2.create(),
|
||||
public size = vec2.create(),
|
||||
) {}
|
||||
|
||||
public toArray(): Array<any> {
|
||||
return [this.topLeft, this.size];
|
||||
|
|
|
|||
|
|
@ -5,7 +5,10 @@ import { serializable } from '../serialization/serializable';
|
|||
|
||||
@serializable
|
||||
export class RemoteCall {
|
||||
constructor(public readonly functionName: string, public readonly args: Array<any>) {}
|
||||
constructor(
|
||||
public readonly functionName: string,
|
||||
public readonly args: Array<any>,
|
||||
) {}
|
||||
|
||||
public toArray(): Array<any> {
|
||||
return [this.functionName, this.args];
|
||||
|
|
@ -48,9 +51,9 @@ export abstract class GameObject extends CommandReceiver {
|
|||
|
||||
public processRemoteCalls(remoteCalls: Array<RemoteCall>) {
|
||||
remoteCalls.forEach((r) =>
|
||||
((this[r.functionName as keyof this] as unknown) as (
|
||||
...args: Array<any>
|
||||
) => unknown)(...r.args),
|
||||
(this[r.functionName as keyof this] as unknown as (...args: Array<any>) => unknown)(
|
||||
...r.args,
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -4,7 +4,12 @@ import { GameObject } from '../game-object';
|
|||
|
||||
@serializable
|
||||
export class LampBase extends GameObject {
|
||||
constructor(id: Id, public center: vec2, public color: vec3, public lightness: number) {
|
||||
constructor(
|
||||
id: Id,
|
||||
public center: vec2,
|
||||
public color: vec3,
|
||||
public lightness: number,
|
||||
) {
|
||||
super(id);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -8,8 +8,8 @@
|
|||
"esModuleInterop": true,
|
||||
"strict": true,
|
||||
"experimentalDecorators": true,
|
||||
"downlevelIteration": true,
|
||||
"moduleResolution": "node",
|
||||
"ignoreDeprecations": "6.0",
|
||||
"module": "commonjs",
|
||||
"skipLibCheck": true,
|
||||
"composite": true,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue