@soonspacejs/plugin-cps-soonmanager 2.14.34 → 2.14.35
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.esm.js +57 -29
- package/dist/semantic.types.d.ts +30 -20
- package/package.json +8 -8
package/dist/index.esm.js
CHANGED
|
@@ -42479,36 +42479,64 @@ function convertToPlaneIVector2(v) {
|
|
|
42479
42479
|
return e;
|
|
42480
42480
|
}
|
|
42481
42481
|
function loadSemanticObjects(v, e) {
|
|
42482
|
-
e.Buildings
|
|
42482
|
+
e.Buildings?.forEach((_) => {
|
|
42483
42483
|
_.Stories.forEach((A) => {
|
|
42484
|
-
const R = e.Stories[A]
|
|
42485
|
-
|
|
42486
|
-
const
|
|
42487
|
-
|
|
42488
|
-
|
|
42489
|
-
|
|
42490
|
-
|
|
42491
|
-
|
|
42492
|
-
|
|
42493
|
-
|
|
42494
|
-
|
|
42495
|
-
|
|
42496
|
-
|
|
42497
|
-
|
|
42498
|
-
|
|
42499
|
-
|
|
42500
|
-
|
|
42501
|
-
|
|
42502
|
-
|
|
42503
|
-
|
|
42504
|
-
|
|
42505
|
-
|
|
42506
|
-
|
|
42507
|
-
|
|
42508
|
-
|
|
42509
|
-
|
|
42510
|
-
|
|
42511
|
-
|
|
42484
|
+
const R = e.Stories?.[A];
|
|
42485
|
+
if (R && R.ID) {
|
|
42486
|
+
const E = v.getObjectById(R.ID);
|
|
42487
|
+
E && (R.Walls?.forEach((B) => {
|
|
42488
|
+
const q = e.Walls?.[B];
|
|
42489
|
+
if (!q) return;
|
|
42490
|
+
const P = v.createCanvas3D({
|
|
42491
|
+
id: q.ID,
|
|
42492
|
+
polygons: [
|
|
42493
|
+
{
|
|
42494
|
+
id: `${q.ID}/polygon`,
|
|
42495
|
+
points: convertToPlaneIVector2(q.Polygon.shape),
|
|
42496
|
+
yHeight: q.Elevation,
|
|
42497
|
+
depth: q.Height,
|
|
42498
|
+
color: randomColor(),
|
|
42499
|
+
opacity: 0.5
|
|
42500
|
+
}
|
|
42501
|
+
]
|
|
42502
|
+
});
|
|
42503
|
+
E.attach(P);
|
|
42504
|
+
}), R.Windows?.forEach((B) => {
|
|
42505
|
+
const q = e.Windows?.[B];
|
|
42506
|
+
if (!q) return;
|
|
42507
|
+
const P = v.createCanvas3D({
|
|
42508
|
+
id: q.ID,
|
|
42509
|
+
polygons: [
|
|
42510
|
+
{
|
|
42511
|
+
id: `${q.ID}/polygon`,
|
|
42512
|
+
points: convertToPlaneIVector2(q.Polygon.shape),
|
|
42513
|
+
yHeight: q.Elevation,
|
|
42514
|
+
depth: q.Height,
|
|
42515
|
+
color: randomColor(),
|
|
42516
|
+
opacity: 0.5
|
|
42517
|
+
}
|
|
42518
|
+
]
|
|
42519
|
+
});
|
|
42520
|
+
E.attach(P);
|
|
42521
|
+
}), R.Columns?.forEach((B) => {
|
|
42522
|
+
const q = e.Columns?.[B];
|
|
42523
|
+
if (!q) return;
|
|
42524
|
+
const P = v.createCanvas3D({
|
|
42525
|
+
id: q.ID,
|
|
42526
|
+
polygons: [
|
|
42527
|
+
{
|
|
42528
|
+
id: `${q.ID}/polygon`,
|
|
42529
|
+
points: convertToPlaneIVector2(q.Polygon.shape),
|
|
42530
|
+
yHeight: q.Elevation,
|
|
42531
|
+
depth: q.Height,
|
|
42532
|
+
color: randomColor(),
|
|
42533
|
+
opacity: 0.5
|
|
42534
|
+
}
|
|
42535
|
+
]
|
|
42536
|
+
});
|
|
42537
|
+
E.attach(P);
|
|
42538
|
+
}));
|
|
42539
|
+
}
|
|
42512
42540
|
});
|
|
42513
42541
|
});
|
|
42514
42542
|
}
|
package/dist/semantic.types.d.ts
CHANGED
|
@@ -17,6 +17,15 @@ export interface Door {
|
|
|
17
17
|
export interface Polygon {
|
|
18
18
|
shape: number[];
|
|
19
19
|
}
|
|
20
|
+
export interface Column {
|
|
21
|
+
ID: string;
|
|
22
|
+
Elevation: number;
|
|
23
|
+
Height: number;
|
|
24
|
+
Polygon: Polygon;
|
|
25
|
+
}
|
|
26
|
+
export interface Polygon {
|
|
27
|
+
shape: number[];
|
|
28
|
+
}
|
|
20
29
|
export interface Space {
|
|
21
30
|
CeilingHeight: number;
|
|
22
31
|
GroundHeight: number;
|
|
@@ -34,19 +43,19 @@ export interface Polygon {
|
|
|
34
43
|
shape: number[];
|
|
35
44
|
}
|
|
36
45
|
export interface Story {
|
|
37
|
-
Columns
|
|
38
|
-
Doors
|
|
39
|
-
Elevation
|
|
40
|
-
Facilities
|
|
46
|
+
Columns?: any[];
|
|
47
|
+
Doors?: number[];
|
|
48
|
+
Elevation?: number;
|
|
49
|
+
Facilities?: any[];
|
|
41
50
|
FloorIndex?: any;
|
|
42
|
-
Height
|
|
43
|
-
ID
|
|
44
|
-
Name
|
|
45
|
-
Polygon
|
|
46
|
-
Spaces
|
|
47
|
-
Staircases
|
|
48
|
-
Walls
|
|
49
|
-
Windows
|
|
51
|
+
Height?: number;
|
|
52
|
+
ID?: string;
|
|
53
|
+
Name?: string;
|
|
54
|
+
Polygon?: Polygon;
|
|
55
|
+
Spaces?: number[];
|
|
56
|
+
Staircases?: number[];
|
|
57
|
+
Walls?: number[];
|
|
58
|
+
Windows?: number[];
|
|
50
59
|
}
|
|
51
60
|
export interface Polygon {
|
|
52
61
|
shape: number[];
|
|
@@ -81,12 +90,13 @@ export interface Asset {
|
|
|
81
90
|
UBuilder?: any;
|
|
82
91
|
}
|
|
83
92
|
export interface SemanticObject {
|
|
84
|
-
Buildings
|
|
85
|
-
Doors
|
|
86
|
-
Spaces
|
|
87
|
-
Staircases
|
|
88
|
-
Stories
|
|
89
|
-
Walls
|
|
90
|
-
Windows
|
|
91
|
-
|
|
93
|
+
Buildings?: Building[];
|
|
94
|
+
Doors?: Door[];
|
|
95
|
+
Spaces?: Space[];
|
|
96
|
+
Staircases?: Staircase[];
|
|
97
|
+
Stories?: Story[];
|
|
98
|
+
Walls?: Wall[];
|
|
99
|
+
Windows?: Window[];
|
|
100
|
+
Columns?: Column[];
|
|
101
|
+
Asset?: Asset;
|
|
92
102
|
}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@soonspacejs/plugin-cps-soonmanager",
|
|
3
3
|
"pluginName": "CpsSoonmanagerPlugin",
|
|
4
|
-
"version": "2.14.
|
|
4
|
+
"version": "2.14.35",
|
|
5
5
|
"description": "Sync cps soonmanager data plugin for SoonSpace.js",
|
|
6
6
|
"main": "dist/index.esm.js",
|
|
7
7
|
"module": "dist/index.esm.js",
|
|
@@ -35,13 +35,13 @@
|
|
|
35
35
|
"socket.io-client": "^4.7.2"
|
|
36
36
|
},
|
|
37
37
|
"peerDependencies": {
|
|
38
|
-
"@soonspacejs/plugin-atmosphere": "2.14.
|
|
39
|
-
"@soonspacejs/plugin-effect": "2.14.
|
|
40
|
-
"@soonspacejs/plugin-flow": "2.14.
|
|
41
|
-
"@soonspacejs/plugin-gs3d-loader": "2.14.
|
|
42
|
-
"@soonspacejs/plugin-poi-renderer": "2.14.
|
|
43
|
-
"@soonspacejs/plugin-tiles": "2.14.
|
|
44
|
-
"soonspacejs": "2.14.
|
|
38
|
+
"@soonspacejs/plugin-atmosphere": "2.14.35",
|
|
39
|
+
"@soonspacejs/plugin-effect": "2.14.35",
|
|
40
|
+
"@soonspacejs/plugin-flow": "2.14.35",
|
|
41
|
+
"@soonspacejs/plugin-gs3d-loader": "2.14.35",
|
|
42
|
+
"@soonspacejs/plugin-poi-renderer": "2.14.35",
|
|
43
|
+
"@soonspacejs/plugin-tiles": "2.14.35",
|
|
44
|
+
"soonspacejs": "2.14.35",
|
|
45
45
|
"umanager-animation-parser": "^0.0.6"
|
|
46
46
|
}
|
|
47
47
|
}
|