blockbench-types 5.1.0 → 5.2.0-beta.0-next.2
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/README.md +30 -30
- package/custom/animation.d.ts +257 -256
- package/custom/animation_controller.d.ts +124 -124
- package/custom/blockbench.d.ts +73 -73
- package/custom/canvas.d.ts +324 -307
- package/custom/codec.d.ts +182 -182
- package/custom/copy_paste.d.ts +43 -42
- package/custom/cube.d.ts +151 -151
- package/custom/desktop.d.ts +61 -73
- package/custom/display_mode.d.ts +141 -137
- package/custom/edit_session.d.ts +38 -37
- package/custom/global.d.ts +181 -168
- package/custom/group.d.ts +113 -113
- package/custom/interface.d.ts +88 -78
- package/custom/io.d.ts +12 -12
- package/custom/{toolbars.d.ts → keybind.d.ts} +150 -221
- package/custom/keyframe.d.ts +94 -94
- package/custom/libs.d.ts +13 -13
- package/custom/menu_bar.d.ts +66 -0
- package/custom/mesh.d.ts +196 -196
- package/custom/misc.d.ts +196 -199
- package/custom/molang.d.ts +159 -159
- package/custom/outliner.d.ts +158 -158
- package/custom/painter.d.ts +102 -69
- package/custom/preview_scene.d.ts +120 -120
- package/custom/screencam.d.ts +71 -71
- package/custom/spline_mesh.d.ts +190 -189
- package/custom/texture_group.d.ts +68 -68
- package/custom/textures.d.ts +526 -515
- package/custom/timeline.d.ts +66 -66
- package/custom/undo.d.ts +209 -208
- package/custom/util/version_util.d.ts +32 -32
- package/custom/util.d.ts +235 -235
- package/custom/uveditor.d.ts +3 -3
- package/custom/validator.d.ts +99 -99
- package/documentation.md +12 -12
- package/generated/animations/mirror_animating.d.ts +7 -0
- package/generated/animations/timeline_animators.d.ts +1 -1
- package/generated/api.d.ts +8 -1
- package/generated/file_system.d.ts +2 -1
- package/generated/find_replace.d.ts +6 -0
- package/generated/formats/standards/obj.d.ts +9 -11
- package/generated/interface/actions.d.ts +16 -12
- package/generated/interface/form.d.ts +2 -1
- package/generated/interface/main_tools.d.ts +23 -0
- package/generated/interface/menu.d.ts +141 -0
- package/generated/interface/menu_bar.d.ts +2 -3
- package/generated/interface/resize_lines.d.ts +2 -0
- package/generated/interface/settings.d.ts +6 -2
- package/generated/interface/shared_actions.d.ts +5 -0
- package/generated/interface/start_screen.d.ts +62 -42
- package/generated/interface/toolbars.d.ts +146 -46
- package/generated/io/format.d.ts +1 -0
- package/generated/io/project.d.ts +10 -2
- package/generated/lib/CanvasFrame.d.ts +1 -0
- package/generated/main.d.ts +4 -1
- package/generated/modeling/mesh/add_mesh.d.ts +6 -0
- package/generated/modeling/mesh/proportional_edit.d.ts +15 -13
- package/generated/modeling/mesh/util.d.ts +8 -2
- package/generated/modeling/mirror_modeling.d.ts +4 -0
- package/generated/modeling/weight_paint.d.ts +11 -0
- package/generated/modes.d.ts +2 -2
- package/generated/native_apis.d.ts +3 -0
- package/generated/outliner/abstract/outliner_element.d.ts +1 -0
- package/generated/outliner/abstract/outliner_node.d.ts +1 -0
- package/generated/outliner/types/armature.d.ts +1 -1
- package/generated/outliner/types/armature_bone.d.ts +1 -1
- package/generated/outliner/types/billboard.d.ts +1 -1
- package/generated/outliner/types/bounding_box.d.ts +1 -1
- package/generated/outliner/types/cube.d.ts +1 -1
- package/generated/outliner/types/group.d.ts +1 -1
- package/generated/outliner/types/locator.d.ts +1 -1
- package/generated/outliner/types/mesh.d.ts +1 -1
- package/generated/outliner/types/null_object.d.ts +1 -1
- package/generated/outliner/types/spline_mesh.d.ts +1 -2
- package/generated/outliner/types/texture_mesh.d.ts +1 -1
- package/generated/plugin_loader.d.ts +1 -1
- package/generated/preview/preview.d.ts +280 -0
- package/generated/preview/reference_images.d.ts +1 -1
- package/generated/texturing/layers.d.ts +140 -0
- package/generated/util/gif.d.ts +12 -3
- package/generated/util/state_memory.d.ts +3 -11
- package/index.d.ts +2 -2
- package/package.json +39 -39
- package/tsconfig.json +19 -19
- package/type_config.json +43 -46
- package/custom/menu.d.ts +0 -136
- package/custom/preview.d.ts +0 -137
- package/custom/start_screen.d.ts +0 -15
- package/custom/texture_layers.d.ts +0 -117
- package/generated/global_types.d.ts +0 -47
- package/generated/io/formats/bedrock.d.ts +0 -4
- package/generated/io/formats/bedrock_old.d.ts +0 -4
- package/generated/io/formats/collada.d.ts +0 -4
- package/generated/io/formats/fbx.d.ts +0 -17
- package/generated/io/formats/gltf.d.ts +0 -6
- package/generated/io/formats/java_block.d.ts +0 -4
- package/generated/io/formats/modded_entity.d.ts +0 -139
- package/generated/io/formats/obj.d.ts +0 -12
- package/generated/io/formats/optifine_jem.d.ts +0 -3
- package/generated/io/formats/optifine_jpm.d.ts +0 -3
- package/generated/io/formats/skin.d.ts +0 -22
package/custom/spline_mesh.d.ts
CHANGED
|
@@ -1,189 +1,190 @@
|
|
|
1
|
-
/// <reference types="./blockbench"/>
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
constructor(mesh: any, spline: any, data: any);
|
|
6
|
-
get element(): SplineMesh;
|
|
7
|
-
getTexture(): Texture;
|
|
8
|
-
}
|
|
9
|
-
interface SplineCurveOptions {
|
|
10
|
-
start_handle: any
|
|
11
|
-
end_handle: any
|
|
12
|
-
start: any
|
|
13
|
-
end: any
|
|
14
|
-
start_ctrl: any
|
|
15
|
-
end_ctrl: any
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
constructor(spline: SplineMesh, data: SplineCurveOptions);
|
|
19
|
-
get element(): SplineMesh;
|
|
20
|
-
extend(data: SplineCurveOptions): this;
|
|
21
|
-
getCurveKey(): string | undefined;
|
|
22
|
-
isSelected(): boolean;
|
|
23
|
-
getSaveCopy(): {
|
|
24
|
-
start_handle: any;
|
|
25
|
-
end_handle: any;
|
|
26
|
-
start: any;
|
|
27
|
-
start_ctrl: any;
|
|
28
|
-
end_ctrl: any;
|
|
29
|
-
end: any;
|
|
30
|
-
};
|
|
31
|
-
getUndoCopy(): any;
|
|
32
|
-
/**
|
|
33
|
-
* Splits a curve in two distinct paths using De Casteljau's algorithm.
|
|
34
|
-
* The split happens at the corresponding T (time) on the initial curve.
|
|
35
|
-
*
|
|
36
|
-
* @param {float} time Point at which the split occurs (in % from 0 to 1)
|
|
37
|
-
* @returns {array} Adjusted and new points for our two new curves, as two Objects, one per curve.
|
|
38
|
-
*/
|
|
39
|
-
split(time: any): {
|
|
40
|
-
start: any;
|
|
41
|
-
start_ctrl: any;
|
|
42
|
-
middle_ctrl1: any;
|
|
43
|
-
middle: any;
|
|
44
|
-
middle_ctrl2: any;
|
|
45
|
-
end_ctrl: any;
|
|
46
|
-
end: any;
|
|
47
|
-
};
|
|
48
|
-
}
|
|
49
|
-
interface SplineHandle {
|
|
50
|
-
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
constructor(spline: SplineMesh, data: SplineHandle);
|
|
54
|
-
get element(): SplineMesh;
|
|
55
|
-
extend(data: SplineHandle): this;
|
|
56
|
-
getHandleKey(): string | undefined;
|
|
57
|
-
isSelected(): boolean;
|
|
58
|
-
getSaveCopy(): {
|
|
59
|
-
control1: any;
|
|
60
|
-
joint: any;
|
|
61
|
-
control2: any;
|
|
62
|
-
tilt: any;
|
|
63
|
-
size: any;
|
|
64
|
-
};
|
|
65
|
-
getUndoCopy(): any;
|
|
66
|
-
}
|
|
67
|
-
interface SplineMeshOptions {
|
|
68
|
-
|
|
69
|
-
}
|
|
70
|
-
|
|
71
|
-
constructor(data: any, uuid: any);
|
|
72
|
-
get vertices(): Record<string, ArrayVector3>;
|
|
73
|
-
get handles(): Record<string, SplineHandle>;
|
|
74
|
-
get curves(): Record<string, SplineCurve>;
|
|
75
|
-
set vertices(v: Record<string, ArrayVector3>);
|
|
76
|
-
set handles(v: Record<string, SplineHandle>);
|
|
77
|
-
set curves(v: Record<string, SplineCurve>);
|
|
78
|
-
get position(): ArrayVector3;
|
|
79
|
-
get vertice_list(): any[];
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
*
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
*
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
*
|
|
132
|
-
* @param {*}
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
*
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
1
|
+
/// <reference types="./blockbench"/>
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
declare class SplineTubeFace extends MeshFace {
|
|
5
|
+
constructor(mesh: any, spline: any, data: any);
|
|
6
|
+
get element(): SplineMesh;
|
|
7
|
+
getTexture(): Texture;
|
|
8
|
+
}
|
|
9
|
+
interface SplineCurveOptions {
|
|
10
|
+
start_handle: any
|
|
11
|
+
end_handle: any
|
|
12
|
+
start: any
|
|
13
|
+
end: any
|
|
14
|
+
start_ctrl: any
|
|
15
|
+
end_ctrl: any
|
|
16
|
+
}
|
|
17
|
+
declare class SplineCurve {
|
|
18
|
+
constructor(spline: SplineMesh, data: SplineCurveOptions);
|
|
19
|
+
get element(): SplineMesh;
|
|
20
|
+
extend(data: SplineCurveOptions): this;
|
|
21
|
+
getCurveKey(): string | undefined;
|
|
22
|
+
isSelected(): boolean;
|
|
23
|
+
getSaveCopy(): {
|
|
24
|
+
start_handle: any;
|
|
25
|
+
end_handle: any;
|
|
26
|
+
start: any;
|
|
27
|
+
start_ctrl: any;
|
|
28
|
+
end_ctrl: any;
|
|
29
|
+
end: any;
|
|
30
|
+
};
|
|
31
|
+
getUndoCopy(): any;
|
|
32
|
+
/**
|
|
33
|
+
* Splits a curve in two distinct paths using De Casteljau's algorithm.
|
|
34
|
+
* The split happens at the corresponding T (time) on the initial curve.
|
|
35
|
+
*
|
|
36
|
+
* @param {float} time Point at which the split occurs (in % from 0 to 1)
|
|
37
|
+
* @returns {array} Adjusted and new points for our two new curves, as two Objects, one per curve.
|
|
38
|
+
*/
|
|
39
|
+
split(time: any): {
|
|
40
|
+
start: any;
|
|
41
|
+
start_ctrl: any;
|
|
42
|
+
middle_ctrl1: any;
|
|
43
|
+
middle: any;
|
|
44
|
+
middle_ctrl2: any;
|
|
45
|
+
end_ctrl: any;
|
|
46
|
+
end: any;
|
|
47
|
+
};
|
|
48
|
+
}
|
|
49
|
+
interface SplineHandle {
|
|
50
|
+
|
|
51
|
+
}
|
|
52
|
+
declare class SplineHandle {
|
|
53
|
+
constructor(spline: SplineMesh, data: SplineHandle);
|
|
54
|
+
get element(): SplineMesh;
|
|
55
|
+
extend(data: SplineHandle): this;
|
|
56
|
+
getHandleKey(): string | undefined;
|
|
57
|
+
isSelected(): boolean;
|
|
58
|
+
getSaveCopy(): {
|
|
59
|
+
control1: any;
|
|
60
|
+
joint: any;
|
|
61
|
+
control2: any;
|
|
62
|
+
tilt: any;
|
|
63
|
+
size: any;
|
|
64
|
+
};
|
|
65
|
+
getUndoCopy(): any;
|
|
66
|
+
}
|
|
67
|
+
interface SplineMeshOptions {
|
|
68
|
+
|
|
69
|
+
}
|
|
70
|
+
declare class SplineMesh extends OutlinerElement {
|
|
71
|
+
constructor(data: any, uuid: any);
|
|
72
|
+
get vertices(): Record<string, ArrayVector3>;
|
|
73
|
+
get handles(): Record<string, SplineHandle>;
|
|
74
|
+
get curves(): Record<string, SplineCurve>;
|
|
75
|
+
set vertices(v: Record<string, ArrayVector3>);
|
|
76
|
+
set handles(v: Record<string, SplineHandle>);
|
|
77
|
+
set curves(v: Record<string, SplineCurve>);
|
|
78
|
+
get position(): ArrayVector3;
|
|
79
|
+
get vertice_list(): any[];
|
|
80
|
+
faces: Record<string, SplineTubeFace>
|
|
81
|
+
cyclic: boolean
|
|
82
|
+
export: boolean
|
|
83
|
+
display_space: boolean
|
|
84
|
+
radial_resolution: number
|
|
85
|
+
radius_multiplier: number
|
|
86
|
+
tubular_resolution: number
|
|
87
|
+
uv_mode: 'length_accurate' |'uniform' | 'per_segment'
|
|
88
|
+
render_mode: 'mesh' | 'path'
|
|
89
|
+
render_order: 'default' | 'behind' | 'in_front'
|
|
90
|
+
shading: 'flat' | 'smooth'
|
|
91
|
+
|
|
92
|
+
addVertices(...vectors: ArrayVector3[]): any[];
|
|
93
|
+
addHandles(...handles: SplineHandle[]): any[];
|
|
94
|
+
addCurves(...curves: SplineCurve[]): any[];
|
|
95
|
+
extend(data: SplineMeshOptions): this;
|
|
96
|
+
overwrite(data: SplineMeshOptions): this;
|
|
97
|
+
getUndoCopy(aspects?: {}): {};
|
|
98
|
+
getSaveCopy(): {};
|
|
99
|
+
setColor(index: number): void;
|
|
100
|
+
roll(axis: axisNumber, steps: number, origin_arg?: ArrayVector3): this;
|
|
101
|
+
flip(axis: axisNumber, center?: number): this;
|
|
102
|
+
/**
|
|
103
|
+
* Refresh the dummy face object of this spline, allowing us to paint on it, or to convert it to a Mesh.
|
|
104
|
+
*/
|
|
105
|
+
refreshTubeFaces(): void;
|
|
106
|
+
getSelectedVertices(make: boolean = false): any;
|
|
107
|
+
/**
|
|
108
|
+
* Readonly list of selected handles, based on selected vertices.
|
|
109
|
+
* @param {*} loose Tells the handle selection if it should count controls being selected without their joint.
|
|
110
|
+
**/
|
|
111
|
+
getSelectedHandles(loose?: boolean): string[];
|
|
112
|
+
/**
|
|
113
|
+
* Readonly list of selected curves, based on selected handles. See {@link getSelectedHandles()} for handle selection.
|
|
114
|
+
* @param {*} loose Tells the handle selection if it should count controls being selected without their joint.
|
|
115
|
+
**/
|
|
116
|
+
getSelectedCurves(loose?: boolean): string[];
|
|
117
|
+
getCurvesOfHandle(hKey: string): string[];
|
|
118
|
+
getCurvesOfPoint(vKey: string): string[];
|
|
119
|
+
getHandleOfPoint(vKey: string): string | undefined;
|
|
120
|
+
getLastSelected(): SplineMesh | undefined;
|
|
121
|
+
getLastHandle(): {
|
|
122
|
+
data: SplineHandle;
|
|
123
|
+
key: string;
|
|
124
|
+
};
|
|
125
|
+
getFirstHandle(): {
|
|
126
|
+
data: SplineHandle;
|
|
127
|
+
key: string;
|
|
128
|
+
};
|
|
129
|
+
getSize(axis?: axisNumber, selection_only?: any): number;
|
|
130
|
+
/**
|
|
131
|
+
* Gather control point transform data, primarily to orient the handleGizmos correctly, but also for normal transform space.
|
|
132
|
+
* @param {*} hKey Key of the handle we want the transform of.
|
|
133
|
+
* @param {*} euler re-orientation Euler in case we need to re-orient the result of this to match another direction.
|
|
134
|
+
*/
|
|
135
|
+
getHandleEuler(hKey: string, euler?: THREE.Euler): {
|
|
136
|
+
c1: any;
|
|
137
|
+
c2: any;
|
|
138
|
+
combined: any;
|
|
139
|
+
};
|
|
140
|
+
getWorldCenter(ignore_mesh_selection: any): THREE.Vector3;
|
|
141
|
+
moveVector(arr: ArrayVector3, axis: axisNumber, update?: boolean): void;
|
|
142
|
+
getCenter(global?: boolean): ArrayVector3;
|
|
143
|
+
transferOrigin(origin: any, update?: boolean): this | undefined;
|
|
144
|
+
/**
|
|
145
|
+
* Applies the effects of Handle selection mode to the sibling vertex of this vKey. (Mirrored or Aligned)
|
|
146
|
+
* @param {*} vkey The Key of the reference vertex, from which the result will be copied over to its sibling (if applicable).
|
|
147
|
+
*/
|
|
148
|
+
applyHandleModeOnVertex(vkey: string): void;
|
|
149
|
+
resize(val: any, axis: any, negative: any, allow_negative: any, bidirectional: any): void;
|
|
150
|
+
getTubeMesh(removeDoubles?: boolean, mesh?: {
|
|
151
|
+
faces: {};
|
|
152
|
+
vertices: {};
|
|
153
|
+
}): {
|
|
154
|
+
faces: {};
|
|
155
|
+
vertices: {};
|
|
156
|
+
};
|
|
157
|
+
getTubeGeo(shadeSmooth: any): {
|
|
158
|
+
vertices: any[];
|
|
159
|
+
normals: any[];
|
|
160
|
+
indices: number[];
|
|
161
|
+
uvs: number[];
|
|
162
|
+
};
|
|
163
|
+
getBézierPath(keepDoubles?: boolean): {
|
|
164
|
+
tangents: any[];
|
|
165
|
+
normals: any[];
|
|
166
|
+
points: any[];
|
|
167
|
+
sizes: any[];
|
|
168
|
+
connections: boolean[];
|
|
169
|
+
lengths: any[];
|
|
170
|
+
accumulatedLengths: number[];
|
|
171
|
+
pathLength: number;
|
|
172
|
+
};
|
|
173
|
+
getBézierNormal(tangent: any, up?: null): any;
|
|
174
|
+
getBézierForCurve(time: any, key: string): {
|
|
175
|
+
point: any;
|
|
176
|
+
tangent: any;
|
|
177
|
+
};
|
|
178
|
+
getBézierForPoints(time: any, p1k: any, p2k: any, p3k: any, p4k: any): {
|
|
179
|
+
point: any;
|
|
180
|
+
tangent: any;
|
|
181
|
+
};
|
|
182
|
+
cubicBézier(time: any, point1: any, point2: any, point3: any, point4: any): {
|
|
183
|
+
point: any;
|
|
184
|
+
tangent: any;
|
|
185
|
+
};
|
|
186
|
+
getTexture(): Texture | undefined;
|
|
187
|
+
applyTexture(texture: Texture): void;
|
|
188
|
+
updateShading(shade_smooth: boolean): void;
|
|
189
|
+
}
|
|
190
|
+
|
|
@@ -1,68 +1,68 @@
|
|
|
1
|
-
/// <reference types="./blockbench"/>
|
|
2
|
-
|
|
3
|
-
interface TextureGroupOptions {
|
|
4
|
-
uuid?: string
|
|
5
|
-
name?: string
|
|
6
|
-
is_material?: boolean
|
|
7
|
-
material_config?: TextureGroupMaterialConfigData
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
/**
|
|
11
|
-
* A way to group textures. Texture groups can also be used to represent materials in enabled formats
|
|
12
|
-
*/
|
|
13
|
-
declare class TextureGroup {
|
|
14
|
-
static all: TextureGroup[]
|
|
15
|
-
|
|
16
|
-
constructor(data?: Omit<TextureGroupOptions, 'uuid'>, uuid?: string)
|
|
17
|
-
uuid: string
|
|
18
|
-
name: string
|
|
19
|
-
folded: boolean
|
|
20
|
-
/**
|
|
21
|
-
* If true, the texture group works as a material
|
|
22
|
-
*/
|
|
23
|
-
is_material: boolean
|
|
24
|
-
/**
|
|
25
|
-
* Material configuration
|
|
26
|
-
*/
|
|
27
|
-
material_config: TextureGroupMaterialConfig
|
|
28
|
-
get material(): THREE.MeshStandardMaterial
|
|
29
|
-
extend(data: TextureGroupOptions): this
|
|
30
|
-
add(): this
|
|
31
|
-
select(): this
|
|
32
|
-
remove(): void
|
|
33
|
-
showContextMenu(event: Event): void
|
|
34
|
-
rename(): this
|
|
35
|
-
getTextures(): Texture[]
|
|
36
|
-
getUndoCopy(): Required<TextureGroupOptions>
|
|
37
|
-
getSaveCopy(): Omit<TextureGroupOptions, 'is_material' | 'uuid'>
|
|
38
|
-
updateMaterial(): void
|
|
39
|
-
getMaterial(): THREE.MeshStandardMaterial
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
interface TextureGroupMaterialConfigData {
|
|
43
|
-
color_value?: [number, number, number, number]
|
|
44
|
-
mer_value?: [number, number, number]
|
|
45
|
-
saved?: boolean
|
|
46
|
-
}
|
|
47
|
-
declare class TextureGroupMaterialConfig {
|
|
48
|
-
constructor(texture_group: TextureGroup, data: TextureGroupMaterialConfigData)
|
|
49
|
-
color_value: [number, number, number, number]
|
|
50
|
-
mer_value: [number, number, number]
|
|
51
|
-
saved: boolean
|
|
52
|
-
menu: Menu
|
|
53
|
-
texture_group: TextureGroup
|
|
54
|
-
|
|
55
|
-
extend(data: TextureGroupMaterialConfigData): this
|
|
56
|
-
getUndoCopy(): {}
|
|
57
|
-
getSaveCopy(): {}
|
|
58
|
-
compileForBedrock(): {
|
|
59
|
-
format_version: string
|
|
60
|
-
'minecraft:texture_set': {}
|
|
61
|
-
}
|
|
62
|
-
getFilePath(): string
|
|
63
|
-
getFileName(extension?: boolean): string
|
|
64
|
-
save(): void
|
|
65
|
-
showContextMenu(event: Event): void
|
|
66
|
-
propertiesDialog(): void
|
|
67
|
-
}
|
|
68
|
-
declare function importTextureSet(file: any): void
|
|
1
|
+
/// <reference types="./blockbench"/>
|
|
2
|
+
|
|
3
|
+
interface TextureGroupOptions {
|
|
4
|
+
uuid?: string
|
|
5
|
+
name?: string
|
|
6
|
+
is_material?: boolean
|
|
7
|
+
material_config?: TextureGroupMaterialConfigData
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
* A way to group textures. Texture groups can also be used to represent materials in enabled formats
|
|
12
|
+
*/
|
|
13
|
+
declare class TextureGroup {
|
|
14
|
+
static all: TextureGroup[]
|
|
15
|
+
|
|
16
|
+
constructor(data?: Omit<TextureGroupOptions, 'uuid'>, uuid?: string)
|
|
17
|
+
uuid: string
|
|
18
|
+
name: string
|
|
19
|
+
folded: boolean
|
|
20
|
+
/**
|
|
21
|
+
* If true, the texture group works as a material
|
|
22
|
+
*/
|
|
23
|
+
is_material: boolean
|
|
24
|
+
/**
|
|
25
|
+
* Material configuration
|
|
26
|
+
*/
|
|
27
|
+
material_config: TextureGroupMaterialConfig
|
|
28
|
+
get material(): THREE.MeshStandardMaterial
|
|
29
|
+
extend(data: TextureGroupOptions): this
|
|
30
|
+
add(): this
|
|
31
|
+
select(): this
|
|
32
|
+
remove(): void
|
|
33
|
+
showContextMenu(event: Event): void
|
|
34
|
+
rename(): this
|
|
35
|
+
getTextures(): Texture[]
|
|
36
|
+
getUndoCopy(): Required<TextureGroupOptions>
|
|
37
|
+
getSaveCopy(): Omit<TextureGroupOptions, 'is_material' | 'uuid'>
|
|
38
|
+
updateMaterial(): void
|
|
39
|
+
getMaterial(): THREE.MeshStandardMaterial
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
interface TextureGroupMaterialConfigData {
|
|
43
|
+
color_value?: [number, number, number, number]
|
|
44
|
+
mer_value?: [number, number, number]
|
|
45
|
+
saved?: boolean
|
|
46
|
+
}
|
|
47
|
+
declare class TextureGroupMaterialConfig {
|
|
48
|
+
constructor(texture_group: TextureGroup, data: TextureGroupMaterialConfigData)
|
|
49
|
+
color_value: [number, number, number, number]
|
|
50
|
+
mer_value: [number, number, number]
|
|
51
|
+
saved: boolean
|
|
52
|
+
menu: Menu
|
|
53
|
+
texture_group: TextureGroup
|
|
54
|
+
|
|
55
|
+
extend(data: TextureGroupMaterialConfigData): this
|
|
56
|
+
getUndoCopy(): {}
|
|
57
|
+
getSaveCopy(): {}
|
|
58
|
+
compileForBedrock(): {
|
|
59
|
+
format_version: string
|
|
60
|
+
'minecraft:texture_set': {}
|
|
61
|
+
}
|
|
62
|
+
getFilePath(): string
|
|
63
|
+
getFileName(extension?: boolean): string
|
|
64
|
+
save(): void
|
|
65
|
+
showContextMenu(event: Event): void
|
|
66
|
+
propertiesDialog(): void
|
|
67
|
+
}
|
|
68
|
+
declare function importTextureSet(file: any): void
|