@dcl/protocol 1.0.0-9127033568.commit-26c5ae7 → 1.0.0-9466805132.commit-365e0bb
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/out-js/decentraland/kernel/apis/testing.gen.d.ts +0 -2
- package/out-js/decentraland/kernel/apis/testing.gen.js.map +1 -1
- package/out-js/decentraland/sdk/components/avatar_modifier_area.gen.d.ts +0 -41
- package/out-js/decentraland/sdk/components/avatar_modifier_area.gen.js +3 -241
- package/out-js/decentraland/sdk/components/avatar_modifier_area.gen.js.map +1 -1
- package/out-js/decentraland/sdk/components/camera_mode_area.gen.d.ts +1 -35
- package/out-js/decentraland/sdk/components/camera_mode_area.gen.js +3 -172
- package/out-js/decentraland/sdk/components/camera_mode_area.gen.js.map +1 -1
- package/out-js/decentraland/sdk/components/ui_text.gen.d.ts +10 -5
- package/out-js/decentraland/sdk/components/ui_text.gen.js +43 -25
- package/out-js/decentraland/sdk/components/ui_text.gen.js.map +1 -1
- package/out-js/decentraland/sdk/components/ui_transform.gen.d.ts +0 -2
- package/out-js/decentraland/sdk/components/ui_transform.gen.js +1 -14
- package/out-js/decentraland/sdk/components/ui_transform.gen.js.map +1 -1
- package/out-ts/decentraland/kernel/apis/testing.gen.ts +0 -2
- package/out-ts/decentraland/sdk/components/avatar_modifier_area.gen.ts +1 -292
- package/out-ts/decentraland/sdk/components/camera_mode_area.gen.ts +2 -218
- package/out-ts/decentraland/sdk/components/ui_text.gen.ts +45 -32
- package/out-ts/decentraland/sdk/components/ui_transform.gen.ts +1 -19
- package/package.json +2 -2
- package/proto/decentraland/kernel/apis/testing.proto +0 -2
- package/proto/decentraland/sdk/components/avatar_modifier_area.proto +0 -21
- package/proto/decentraland/sdk/components/camera_mode_area.proto +3 -22
- package/proto/decentraland/sdk/components/ui_text.proto +7 -3
- package/proto/decentraland/sdk/components/ui_transform.proto +0 -1
|
@@ -7,7 +7,7 @@ export const protobufPackage = "decentraland.sdk.components";
|
|
|
7
7
|
|
|
8
8
|
/**
|
|
9
9
|
* The CameraModeArea component can be attached to an Entity to define a region of space where
|
|
10
|
-
* the player's camera mode (1st-person
|
|
10
|
+
* the player's camera mode (1st-person or 3rd-person) is overridden.
|
|
11
11
|
*
|
|
12
12
|
* The Entity's Transform position determines the center-point of the region, while its size is
|
|
13
13
|
* given as a vector in the `area` property below. The Transform rotation is applied, but the scale
|
|
@@ -17,8 +17,6 @@ export const protobufPackage = "decentraland.sdk.components";
|
|
|
17
17
|
*
|
|
18
18
|
* Note that, while commonly used to delineate a 2D area in a scene (hence the name), the region
|
|
19
19
|
* is actually a 3D volume.
|
|
20
|
-
*
|
|
21
|
-
* When mode is set to CtCinematic, the cinematic_settings field must also be provided.
|
|
22
20
|
*/
|
|
23
21
|
export interface PBCameraModeArea {
|
|
24
22
|
/** the 3D size of the region */
|
|
@@ -27,47 +25,10 @@ export interface PBCameraModeArea {
|
|
|
27
25
|
| undefined;
|
|
28
26
|
/** the camera mode to enforce */
|
|
29
27
|
mode: CameraType;
|
|
30
|
-
cinematicSettings?:
|
|
31
|
-
| CinematicSettings
|
|
32
|
-
| undefined;
|
|
33
|
-
/** if true, the player will be considered inside the area when they are within 0.3m of the area. default true */
|
|
34
|
-
useColliderRange?: boolean | undefined;
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
export interface CinematicSettings {
|
|
38
|
-
/** Entity that defines the cinematic camera transform. */
|
|
39
|
-
cameraEntity: number;
|
|
40
|
-
/**
|
|
41
|
-
* Position -> camera's position
|
|
42
|
-
* Rotation -> camera's direction
|
|
43
|
-
* scale.z -> zoom level
|
|
44
|
-
* scale.x and scale.y -> unused
|
|
45
|
-
*/
|
|
46
|
-
allowManualRotation?:
|
|
47
|
-
| boolean
|
|
48
|
-
| undefined;
|
|
49
|
-
/** how far the camera can rotate around the y-axis / look left/right, in radians. default unrestricted */
|
|
50
|
-
yawRange?:
|
|
51
|
-
| number
|
|
52
|
-
| undefined;
|
|
53
|
-
/** how far the camera can rotate around the x-axis / look up-down, in radians. default unrestricted */
|
|
54
|
-
pitchRange?:
|
|
55
|
-
| number
|
|
56
|
-
| undefined;
|
|
57
|
-
/** note: cameras can never look up/down further than Vec3::Y */
|
|
58
|
-
rollRange?:
|
|
59
|
-
| number
|
|
60
|
-
| undefined;
|
|
61
|
-
/** minimum zoom level. must be greater than 0. defaults to the input zoom level */
|
|
62
|
-
zoomMin?:
|
|
63
|
-
| number
|
|
64
|
-
| undefined;
|
|
65
|
-
/** maximum zoom level. must be greater than 0. defaults to the input zoom level */
|
|
66
|
-
zoomMax?: number | undefined;
|
|
67
28
|
}
|
|
68
29
|
|
|
69
30
|
function createBasePBCameraModeArea(): PBCameraModeArea {
|
|
70
|
-
return { area: undefined, mode: 0
|
|
31
|
+
return { area: undefined, mode: 0 };
|
|
71
32
|
}
|
|
72
33
|
|
|
73
34
|
export namespace PBCameraModeArea {
|
|
@@ -78,12 +39,6 @@ export namespace PBCameraModeArea {
|
|
|
78
39
|
if (message.mode !== 0) {
|
|
79
40
|
writer.uint32(16).int32(message.mode);
|
|
80
41
|
}
|
|
81
|
-
if (message.cinematicSettings !== undefined) {
|
|
82
|
-
CinematicSettings.encode(message.cinematicSettings, writer.uint32(26).fork()).ldelim();
|
|
83
|
-
}
|
|
84
|
-
if (message.useColliderRange !== undefined) {
|
|
85
|
-
writer.uint32(32).bool(message.useColliderRange);
|
|
86
|
-
}
|
|
87
42
|
return writer;
|
|
88
43
|
}
|
|
89
44
|
|
|
@@ -108,20 +63,6 @@ export namespace PBCameraModeArea {
|
|
|
108
63
|
|
|
109
64
|
message.mode = reader.int32() as any;
|
|
110
65
|
continue;
|
|
111
|
-
case 3:
|
|
112
|
-
if (tag !== 26) {
|
|
113
|
-
break;
|
|
114
|
-
}
|
|
115
|
-
|
|
116
|
-
message.cinematicSettings = CinematicSettings.decode(reader, reader.uint32());
|
|
117
|
-
continue;
|
|
118
|
-
case 4:
|
|
119
|
-
if (tag !== 32) {
|
|
120
|
-
break;
|
|
121
|
-
}
|
|
122
|
-
|
|
123
|
-
message.useColliderRange = reader.bool();
|
|
124
|
-
continue;
|
|
125
66
|
}
|
|
126
67
|
if ((tag & 7) === 4 || tag === 0) {
|
|
127
68
|
break;
|
|
@@ -135,10 +76,6 @@ export namespace PBCameraModeArea {
|
|
|
135
76
|
return {
|
|
136
77
|
area: isSet(object.area) ? Vector3.fromJSON(object.area) : undefined,
|
|
137
78
|
mode: isSet(object.mode) ? cameraTypeFromJSON(object.mode) : 0,
|
|
138
|
-
cinematicSettings: isSet(object.cinematicSettings)
|
|
139
|
-
? CinematicSettings.fromJSON(object.cinematicSettings)
|
|
140
|
-
: undefined,
|
|
141
|
-
useColliderRange: isSet(object.useColliderRange) ? Boolean(object.useColliderRange) : undefined,
|
|
142
79
|
};
|
|
143
80
|
}
|
|
144
81
|
|
|
@@ -146,11 +83,6 @@ export namespace PBCameraModeArea {
|
|
|
146
83
|
const obj: any = {};
|
|
147
84
|
message.area !== undefined && (obj.area = message.area ? Vector3.toJSON(message.area) : undefined);
|
|
148
85
|
message.mode !== undefined && (obj.mode = cameraTypeToJSON(message.mode));
|
|
149
|
-
message.cinematicSettings !== undefined &&
|
|
150
|
-
(obj.cinematicSettings = message.cinematicSettings
|
|
151
|
-
? CinematicSettings.toJSON(message.cinematicSettings)
|
|
152
|
-
: undefined);
|
|
153
|
-
message.useColliderRange !== undefined && (obj.useColliderRange = message.useColliderRange);
|
|
154
86
|
return obj;
|
|
155
87
|
}
|
|
156
88
|
|
|
@@ -162,154 +94,6 @@ export namespace PBCameraModeArea {
|
|
|
162
94
|
const message = createBasePBCameraModeArea();
|
|
163
95
|
message.area = (object.area !== undefined && object.area !== null) ? Vector3.fromPartial(object.area) : undefined;
|
|
164
96
|
message.mode = object.mode ?? 0;
|
|
165
|
-
message.cinematicSettings = (object.cinematicSettings !== undefined && object.cinematicSettings !== null)
|
|
166
|
-
? CinematicSettings.fromPartial(object.cinematicSettings)
|
|
167
|
-
: undefined;
|
|
168
|
-
message.useColliderRange = object.useColliderRange ?? undefined;
|
|
169
|
-
return message;
|
|
170
|
-
}
|
|
171
|
-
}
|
|
172
|
-
|
|
173
|
-
function createBaseCinematicSettings(): CinematicSettings {
|
|
174
|
-
return {
|
|
175
|
-
cameraEntity: 0,
|
|
176
|
-
allowManualRotation: undefined,
|
|
177
|
-
yawRange: undefined,
|
|
178
|
-
pitchRange: undefined,
|
|
179
|
-
rollRange: undefined,
|
|
180
|
-
zoomMin: undefined,
|
|
181
|
-
zoomMax: undefined,
|
|
182
|
-
};
|
|
183
|
-
}
|
|
184
|
-
|
|
185
|
-
export namespace CinematicSettings {
|
|
186
|
-
export function encode(message: CinematicSettings, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer {
|
|
187
|
-
if (message.cameraEntity !== 0) {
|
|
188
|
-
writer.uint32(8).uint32(message.cameraEntity);
|
|
189
|
-
}
|
|
190
|
-
if (message.allowManualRotation !== undefined) {
|
|
191
|
-
writer.uint32(16).bool(message.allowManualRotation);
|
|
192
|
-
}
|
|
193
|
-
if (message.yawRange !== undefined) {
|
|
194
|
-
writer.uint32(29).float(message.yawRange);
|
|
195
|
-
}
|
|
196
|
-
if (message.pitchRange !== undefined) {
|
|
197
|
-
writer.uint32(37).float(message.pitchRange);
|
|
198
|
-
}
|
|
199
|
-
if (message.rollRange !== undefined) {
|
|
200
|
-
writer.uint32(45).float(message.rollRange);
|
|
201
|
-
}
|
|
202
|
-
if (message.zoomMin !== undefined) {
|
|
203
|
-
writer.uint32(53).float(message.zoomMin);
|
|
204
|
-
}
|
|
205
|
-
if (message.zoomMax !== undefined) {
|
|
206
|
-
writer.uint32(61).float(message.zoomMax);
|
|
207
|
-
}
|
|
208
|
-
return writer;
|
|
209
|
-
}
|
|
210
|
-
|
|
211
|
-
export function decode(input: _m0.Reader | Uint8Array, length?: number): CinematicSettings {
|
|
212
|
-
const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
|
|
213
|
-
let end = length === undefined ? reader.len : reader.pos + length;
|
|
214
|
-
const message = createBaseCinematicSettings();
|
|
215
|
-
while (reader.pos < end) {
|
|
216
|
-
const tag = reader.uint32();
|
|
217
|
-
switch (tag >>> 3) {
|
|
218
|
-
case 1:
|
|
219
|
-
if (tag !== 8) {
|
|
220
|
-
break;
|
|
221
|
-
}
|
|
222
|
-
|
|
223
|
-
message.cameraEntity = reader.uint32();
|
|
224
|
-
continue;
|
|
225
|
-
case 2:
|
|
226
|
-
if (tag !== 16) {
|
|
227
|
-
break;
|
|
228
|
-
}
|
|
229
|
-
|
|
230
|
-
message.allowManualRotation = reader.bool();
|
|
231
|
-
continue;
|
|
232
|
-
case 3:
|
|
233
|
-
if (tag !== 29) {
|
|
234
|
-
break;
|
|
235
|
-
}
|
|
236
|
-
|
|
237
|
-
message.yawRange = reader.float();
|
|
238
|
-
continue;
|
|
239
|
-
case 4:
|
|
240
|
-
if (tag !== 37) {
|
|
241
|
-
break;
|
|
242
|
-
}
|
|
243
|
-
|
|
244
|
-
message.pitchRange = reader.float();
|
|
245
|
-
continue;
|
|
246
|
-
case 5:
|
|
247
|
-
if (tag !== 45) {
|
|
248
|
-
break;
|
|
249
|
-
}
|
|
250
|
-
|
|
251
|
-
message.rollRange = reader.float();
|
|
252
|
-
continue;
|
|
253
|
-
case 6:
|
|
254
|
-
if (tag !== 53) {
|
|
255
|
-
break;
|
|
256
|
-
}
|
|
257
|
-
|
|
258
|
-
message.zoomMin = reader.float();
|
|
259
|
-
continue;
|
|
260
|
-
case 7:
|
|
261
|
-
if (tag !== 61) {
|
|
262
|
-
break;
|
|
263
|
-
}
|
|
264
|
-
|
|
265
|
-
message.zoomMax = reader.float();
|
|
266
|
-
continue;
|
|
267
|
-
}
|
|
268
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
269
|
-
break;
|
|
270
|
-
}
|
|
271
|
-
reader.skipType(tag & 7);
|
|
272
|
-
}
|
|
273
|
-
return message;
|
|
274
|
-
}
|
|
275
|
-
|
|
276
|
-
export function fromJSON(object: any): CinematicSettings {
|
|
277
|
-
return {
|
|
278
|
-
cameraEntity: isSet(object.cameraEntity) ? Number(object.cameraEntity) : 0,
|
|
279
|
-
allowManualRotation: isSet(object.allowManualRotation) ? Boolean(object.allowManualRotation) : undefined,
|
|
280
|
-
yawRange: isSet(object.yawRange) ? Number(object.yawRange) : undefined,
|
|
281
|
-
pitchRange: isSet(object.pitchRange) ? Number(object.pitchRange) : undefined,
|
|
282
|
-
rollRange: isSet(object.rollRange) ? Number(object.rollRange) : undefined,
|
|
283
|
-
zoomMin: isSet(object.zoomMin) ? Number(object.zoomMin) : undefined,
|
|
284
|
-
zoomMax: isSet(object.zoomMax) ? Number(object.zoomMax) : undefined,
|
|
285
|
-
};
|
|
286
|
-
}
|
|
287
|
-
|
|
288
|
-
export function toJSON(message: CinematicSettings): unknown {
|
|
289
|
-
const obj: any = {};
|
|
290
|
-
message.cameraEntity !== undefined && (obj.cameraEntity = Math.round(message.cameraEntity));
|
|
291
|
-
message.allowManualRotation !== undefined && (obj.allowManualRotation = message.allowManualRotation);
|
|
292
|
-
message.yawRange !== undefined && (obj.yawRange = message.yawRange);
|
|
293
|
-
message.pitchRange !== undefined && (obj.pitchRange = message.pitchRange);
|
|
294
|
-
message.rollRange !== undefined && (obj.rollRange = message.rollRange);
|
|
295
|
-
message.zoomMin !== undefined && (obj.zoomMin = message.zoomMin);
|
|
296
|
-
message.zoomMax !== undefined && (obj.zoomMax = message.zoomMax);
|
|
297
|
-
return obj;
|
|
298
|
-
}
|
|
299
|
-
|
|
300
|
-
export function create<I extends Exact<DeepPartial<CinematicSettings>, I>>(base?: I): CinematicSettings {
|
|
301
|
-
return CinematicSettings.fromPartial(base ?? {});
|
|
302
|
-
}
|
|
303
|
-
|
|
304
|
-
export function fromPartial<I extends Exact<DeepPartial<CinematicSettings>, I>>(object: I): CinematicSettings {
|
|
305
|
-
const message = createBaseCinematicSettings();
|
|
306
|
-
message.cameraEntity = object.cameraEntity ?? 0;
|
|
307
|
-
message.allowManualRotation = object.allowManualRotation ?? undefined;
|
|
308
|
-
message.yawRange = object.yawRange ?? undefined;
|
|
309
|
-
message.pitchRange = object.pitchRange ?? undefined;
|
|
310
|
-
message.rollRange = object.rollRange ?? undefined;
|
|
311
|
-
message.zoomMin = object.zoomMin ?? undefined;
|
|
312
|
-
message.zoomMax = object.zoomMax ?? undefined;
|
|
313
97
|
return message;
|
|
314
98
|
}
|
|
315
99
|
}
|
|
@@ -12,8 +12,41 @@ import {
|
|
|
12
12
|
|
|
13
13
|
export const protobufPackage = "decentraland.sdk.components";
|
|
14
14
|
|
|
15
|
+
export enum TextWrap {
|
|
16
|
+
TW_WRAP = 0,
|
|
17
|
+
TW_NO_WRAP = 1,
|
|
18
|
+
UNRECOGNIZED = -1,
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
export function textWrapFromJSON(object: any): TextWrap {
|
|
22
|
+
switch (object) {
|
|
23
|
+
case 0:
|
|
24
|
+
case "TW_WRAP":
|
|
25
|
+
return TextWrap.TW_WRAP;
|
|
26
|
+
case 1:
|
|
27
|
+
case "TW_NO_WRAP":
|
|
28
|
+
return TextWrap.TW_NO_WRAP;
|
|
29
|
+
case -1:
|
|
30
|
+
case "UNRECOGNIZED":
|
|
31
|
+
default:
|
|
32
|
+
return TextWrap.UNRECOGNIZED;
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
export function textWrapToJSON(object: TextWrap): string {
|
|
37
|
+
switch (object) {
|
|
38
|
+
case TextWrap.TW_WRAP:
|
|
39
|
+
return "TW_WRAP";
|
|
40
|
+
case TextWrap.TW_NO_WRAP:
|
|
41
|
+
return "TW_NO_WRAP";
|
|
42
|
+
case TextWrap.UNRECOGNIZED:
|
|
43
|
+
default:
|
|
44
|
+
return "UNRECOGNIZED";
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
|
|
15
48
|
export interface PBUiText {
|
|
16
|
-
/** the text content */
|
|
49
|
+
/** the text content, tag <b> and <i> are supported */
|
|
17
50
|
value: string;
|
|
18
51
|
/** RGBA color (default: opaque white) */
|
|
19
52
|
color?:
|
|
@@ -31,12 +64,8 @@ export interface PBUiText {
|
|
|
31
64
|
fontSize?:
|
|
32
65
|
| number
|
|
33
66
|
| undefined;
|
|
34
|
-
/**
|
|
35
|
-
|
|
36
|
-
| number
|
|
37
|
-
| undefined;
|
|
38
|
-
/** RGBA color of the outline (default: opaque black) */
|
|
39
|
-
outlineColor?: Color4 | undefined;
|
|
67
|
+
/** wrap text when the border is reached (default: TW_WRAP) */
|
|
68
|
+
textWrap?: TextWrap | undefined;
|
|
40
69
|
}
|
|
41
70
|
|
|
42
71
|
function createBasePBUiText(): PBUiText {
|
|
@@ -46,8 +75,7 @@ function createBasePBUiText(): PBUiText {
|
|
|
46
75
|
textAlign: undefined,
|
|
47
76
|
font: undefined,
|
|
48
77
|
fontSize: undefined,
|
|
49
|
-
|
|
50
|
-
outlineColor: undefined,
|
|
78
|
+
textWrap: undefined,
|
|
51
79
|
};
|
|
52
80
|
}
|
|
53
81
|
|
|
@@ -68,11 +96,8 @@ export namespace PBUiText {
|
|
|
68
96
|
if (message.fontSize !== undefined) {
|
|
69
97
|
writer.uint32(40).int32(message.fontSize);
|
|
70
98
|
}
|
|
71
|
-
if (message.
|
|
72
|
-
writer.uint32(
|
|
73
|
-
}
|
|
74
|
-
if (message.outlineColor !== undefined) {
|
|
75
|
-
Color4.encode(message.outlineColor, writer.uint32(58).fork()).ldelim();
|
|
99
|
+
if (message.textWrap !== undefined) {
|
|
100
|
+
writer.uint32(48).int32(message.textWrap);
|
|
76
101
|
}
|
|
77
102
|
return writer;
|
|
78
103
|
}
|
|
@@ -120,18 +145,11 @@ export namespace PBUiText {
|
|
|
120
145
|
message.fontSize = reader.int32();
|
|
121
146
|
continue;
|
|
122
147
|
case 6:
|
|
123
|
-
if (tag !==
|
|
124
|
-
break;
|
|
125
|
-
}
|
|
126
|
-
|
|
127
|
-
message.outlineWidth = reader.float();
|
|
128
|
-
continue;
|
|
129
|
-
case 7:
|
|
130
|
-
if (tag !== 58) {
|
|
148
|
+
if (tag !== 48) {
|
|
131
149
|
break;
|
|
132
150
|
}
|
|
133
151
|
|
|
134
|
-
message.
|
|
152
|
+
message.textWrap = reader.int32() as any;
|
|
135
153
|
continue;
|
|
136
154
|
}
|
|
137
155
|
if ((tag & 7) === 4 || tag === 0) {
|
|
@@ -149,8 +167,7 @@ export namespace PBUiText {
|
|
|
149
167
|
textAlign: isSet(object.textAlign) ? textAlignModeFromJSON(object.textAlign) : undefined,
|
|
150
168
|
font: isSet(object.font) ? fontFromJSON(object.font) : undefined,
|
|
151
169
|
fontSize: isSet(object.fontSize) ? Number(object.fontSize) : undefined,
|
|
152
|
-
|
|
153
|
-
outlineColor: isSet(object.outlineColor) ? Color4.fromJSON(object.outlineColor) : undefined,
|
|
170
|
+
textWrap: isSet(object.textWrap) ? textWrapFromJSON(object.textWrap) : undefined,
|
|
154
171
|
};
|
|
155
172
|
}
|
|
156
173
|
|
|
@@ -162,9 +179,8 @@ export namespace PBUiText {
|
|
|
162
179
|
(obj.textAlign = message.textAlign !== undefined ? textAlignModeToJSON(message.textAlign) : undefined);
|
|
163
180
|
message.font !== undefined && (obj.font = message.font !== undefined ? fontToJSON(message.font) : undefined);
|
|
164
181
|
message.fontSize !== undefined && (obj.fontSize = Math.round(message.fontSize));
|
|
165
|
-
message.
|
|
166
|
-
|
|
167
|
-
(obj.outlineColor = message.outlineColor ? Color4.toJSON(message.outlineColor) : undefined);
|
|
182
|
+
message.textWrap !== undefined &&
|
|
183
|
+
(obj.textWrap = message.textWrap !== undefined ? textWrapToJSON(message.textWrap) : undefined);
|
|
168
184
|
return obj;
|
|
169
185
|
}
|
|
170
186
|
|
|
@@ -181,10 +197,7 @@ export namespace PBUiText {
|
|
|
181
197
|
message.textAlign = object.textAlign ?? undefined;
|
|
182
198
|
message.font = object.font ?? undefined;
|
|
183
199
|
message.fontSize = object.fontSize ?? undefined;
|
|
184
|
-
message.
|
|
185
|
-
message.outlineColor = (object.outlineColor !== undefined && object.outlineColor !== null)
|
|
186
|
-
? Color4.fromPartial(object.outlineColor)
|
|
187
|
-
: undefined;
|
|
200
|
+
message.textWrap = object.textWrap ?? undefined;
|
|
188
201
|
return message;
|
|
189
202
|
}
|
|
190
203
|
}
|
|
@@ -561,11 +561,7 @@ export interface PBUiTransform {
|
|
|
561
561
|
paddingBottomUnit: YGUnit;
|
|
562
562
|
paddingBottom: number;
|
|
563
563
|
/** default: PointerFilterMode.PFM_NONE */
|
|
564
|
-
pointerFilter?:
|
|
565
|
-
| PointerFilterMode
|
|
566
|
-
| undefined;
|
|
567
|
-
/** default: 1 */
|
|
568
|
-
opacity?: number | undefined;
|
|
564
|
+
pointerFilter?: PointerFilterMode | undefined;
|
|
569
565
|
}
|
|
570
566
|
|
|
571
567
|
function createBasePBUiTransform(): PBUiTransform {
|
|
@@ -622,7 +618,6 @@ function createBasePBUiTransform(): PBUiTransform {
|
|
|
622
618
|
paddingBottomUnit: 0,
|
|
623
619
|
paddingBottom: 0,
|
|
624
620
|
pointerFilter: undefined,
|
|
625
|
-
opacity: undefined,
|
|
626
621
|
};
|
|
627
622
|
}
|
|
628
623
|
|
|
@@ -784,9 +779,6 @@ export namespace PBUiTransform {
|
|
|
784
779
|
if (message.pointerFilter !== undefined) {
|
|
785
780
|
writer.uint32(416).int32(message.pointerFilter);
|
|
786
781
|
}
|
|
787
|
-
if (message.opacity !== undefined) {
|
|
788
|
-
writer.uint32(429).float(message.opacity);
|
|
789
|
-
}
|
|
790
782
|
return writer;
|
|
791
783
|
}
|
|
792
784
|
|
|
@@ -1161,13 +1153,6 @@ export namespace PBUiTransform {
|
|
|
1161
1153
|
|
|
1162
1154
|
message.pointerFilter = reader.int32() as any;
|
|
1163
1155
|
continue;
|
|
1164
|
-
case 53:
|
|
1165
|
-
if (tag !== 429) {
|
|
1166
|
-
break;
|
|
1167
|
-
}
|
|
1168
|
-
|
|
1169
|
-
message.opacity = reader.float();
|
|
1170
|
-
continue;
|
|
1171
1156
|
}
|
|
1172
1157
|
if ((tag & 7) === 4 || tag === 0) {
|
|
1173
1158
|
break;
|
|
@@ -1231,7 +1216,6 @@ export namespace PBUiTransform {
|
|
|
1231
1216
|
paddingBottomUnit: isSet(object.paddingBottomUnit) ? yGUnitFromJSON(object.paddingBottomUnit) : 0,
|
|
1232
1217
|
paddingBottom: isSet(object.paddingBottom) ? Number(object.paddingBottom) : 0,
|
|
1233
1218
|
pointerFilter: isSet(object.pointerFilter) ? pointerFilterModeFromJSON(object.pointerFilter) : undefined,
|
|
1234
|
-
opacity: isSet(object.opacity) ? Number(object.opacity) : undefined,
|
|
1235
1219
|
};
|
|
1236
1220
|
}
|
|
1237
1221
|
|
|
@@ -1295,7 +1279,6 @@ export namespace PBUiTransform {
|
|
|
1295
1279
|
(obj.pointerFilter = message.pointerFilter !== undefined
|
|
1296
1280
|
? pointerFilterModeToJSON(message.pointerFilter)
|
|
1297
1281
|
: undefined);
|
|
1298
|
-
message.opacity !== undefined && (obj.opacity = message.opacity);
|
|
1299
1282
|
return obj;
|
|
1300
1283
|
}
|
|
1301
1284
|
|
|
@@ -1357,7 +1340,6 @@ export namespace PBUiTransform {
|
|
|
1357
1340
|
message.paddingBottomUnit = object.paddingBottomUnit ?? 0;
|
|
1358
1341
|
message.paddingBottom = object.paddingBottom ?? 0;
|
|
1359
1342
|
message.pointerFilter = object.pointerFilter ?? undefined;
|
|
1360
|
-
message.opacity = object.opacity ?? undefined;
|
|
1361
1343
|
return message;
|
|
1362
1344
|
}
|
|
1363
1345
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dcl/protocol",
|
|
3
|
-
"version": "1.0.0-
|
|
3
|
+
"version": "1.0.0-9466805132.commit-365e0bb",
|
|
4
4
|
"description": "",
|
|
5
5
|
"repository": "decentraland/protocol.git",
|
|
6
6
|
"homepage": "https://github.com/decentraland/protocol#readme",
|
|
@@ -29,5 +29,5 @@
|
|
|
29
29
|
"out-js",
|
|
30
30
|
"public"
|
|
31
31
|
],
|
|
32
|
-
"commit": "
|
|
32
|
+
"commit": "365e0bb9331c562ac1889e73c878d6a52ced003e"
|
|
33
33
|
}
|
|
@@ -16,7 +16,6 @@ service TestingService {
|
|
|
16
16
|
rpc TakeAndCompareScreenshot (TakeAndCompareScreenshotRequest) returns (TakeAndCompareScreenshotResponse) {}
|
|
17
17
|
}
|
|
18
18
|
|
|
19
|
-
// @internal
|
|
20
19
|
message TakeAndCompareScreenshotRequest {
|
|
21
20
|
// the source path in the scene where the screenshot is stored,
|
|
22
21
|
// the snapshot taken is compared with the stored one
|
|
@@ -46,7 +45,6 @@ message TakeAndCompareScreenshotRequest {
|
|
|
46
45
|
}
|
|
47
46
|
|
|
48
47
|
|
|
49
|
-
// @internal
|
|
50
48
|
message TakeAndCompareScreenshotResponse {
|
|
51
49
|
bool stored_snapshot_found = 1;
|
|
52
50
|
oneof comparison_method_result {
|
|
@@ -23,8 +23,6 @@ message PBAvatarModifierArea {
|
|
|
23
23
|
decentraland.common.Vector3 area = 1; // the 3D size of the region
|
|
24
24
|
repeated string exclude_ids = 2; // user IDs that can enter and remain unaffected
|
|
25
25
|
repeated AvatarModifierType modifiers = 3; // list of modifiers to apply
|
|
26
|
-
optional AvatarMovementSettings movement_settings = 4;
|
|
27
|
-
optional bool use_collider_range = 5; // if true, the player will be considered inside the area when they are within 0.3m of the area. default true
|
|
28
26
|
}
|
|
29
27
|
|
|
30
28
|
// AvatarModifierType is an effect that should be applied to avatars inside the region.
|
|
@@ -32,22 +30,3 @@ enum AvatarModifierType {
|
|
|
32
30
|
AMT_HIDE_AVATARS = 0; // avatars are invisible
|
|
33
31
|
AMT_DISABLE_PASSPORTS = 1; // selecting (e.g. clicking) an avatar will not bring up their profile.
|
|
34
32
|
}
|
|
35
|
-
|
|
36
|
-
message AvatarMovementSettings {
|
|
37
|
-
optional AvatarControlType control_mode = 1;
|
|
38
|
-
// if not explicitly set, the following properties default to user's preference settings
|
|
39
|
-
optional float run_speed = 2; // speed the player moves at, in m/s
|
|
40
|
-
optional float friction = 3; // how fast the player gets up to speed or comes to rest. higher = more responsive
|
|
41
|
-
optional float gravity = 4; // how fast the player accelerates vertically when not on a solid surface, in m/s. should normally be negative
|
|
42
|
-
optional float jump_height = 5; // how high the player can jump, in meters. should normally be positive. gravity must have the same sign for jumping to be possible
|
|
43
|
-
optional float max_fall_speed = 6; // max fall speed in m/s. should normally be negative
|
|
44
|
-
optional float turn_speed = 7; // speed the player turns in tank mode, in radians/s
|
|
45
|
-
optional float walk_speed = 8; // speed the player walks at, in m/s
|
|
46
|
-
optional bool allow_weighted_movement = 9; // whether to allow player to move at a slower speed (e.g. with a walk-key or when using a gamepad/joystick). defaults to true
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
enum AvatarControlType {
|
|
50
|
-
CCT_NONE = 0; // avatar cannot move
|
|
51
|
-
CCT_RELATIVE = 1; // avatar moves relative to the camera origin
|
|
52
|
-
CCT_TANK = 2; // avatar moves like a tank: left/right rotate the player, forward/backward advance/retreat the player
|
|
53
|
-
}
|
|
@@ -9,7 +9,7 @@ import "decentraland/sdk/components/common/id.proto";
|
|
|
9
9
|
option (common.ecs_component_id) = 1071;
|
|
10
10
|
|
|
11
11
|
// The CameraModeArea component can be attached to an Entity to define a region of space where
|
|
12
|
-
// the player's camera mode (1st-person
|
|
12
|
+
// the player's camera mode (1st-person or 3rd-person) is overridden.
|
|
13
13
|
//
|
|
14
14
|
// The Entity's Transform position determines the center-point of the region, while its size is
|
|
15
15
|
// given as a vector in the `area` property below. The Transform rotation is applied, but the scale
|
|
@@ -19,26 +19,7 @@ option (common.ecs_component_id) = 1071;
|
|
|
19
19
|
//
|
|
20
20
|
// Note that, while commonly used to delineate a 2D area in a scene (hence the name), the region
|
|
21
21
|
// is actually a 3D volume.
|
|
22
|
-
//
|
|
23
|
-
// When mode is set to CtCinematic, the cinematic_settings field must also be provided.
|
|
24
22
|
message PBCameraModeArea {
|
|
25
|
-
decentraland.common.Vector3 area = 1;
|
|
26
|
-
common.CameraType mode = 2;
|
|
27
|
-
optional CinematicSettings cinematic_settings = 3;
|
|
28
|
-
optional bool use_collider_range = 4; // if true, the player will be considered inside the area when they are within 0.3m of the area. default true
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
message CinematicSettings {
|
|
32
|
-
uint32 camera_entity = 1; // Entity that defines the cinematic camera transform.
|
|
33
|
-
// Position -> camera's position
|
|
34
|
-
// Rotation -> camera's direction
|
|
35
|
-
// scale.z -> zoom level
|
|
36
|
-
// scale.x and scale.y -> unused
|
|
37
|
-
optional bool allow_manual_rotation = 2; // whether the user can move the camera's rotation. default false
|
|
38
|
-
optional float yaw_range = 3; // how far the camera can rotate around the y-axis / look left/right, in radians. default unrestricted
|
|
39
|
-
optional float pitch_range = 4; // how far the camera can rotate around the x-axis / look up-down, in radians. default unrestricted
|
|
40
|
-
// note: cameras can never look up/down further than Vec3::Y
|
|
41
|
-
optional float roll_range = 5; // how far the camera can rotate around the z-axis / tilt, in radians. default unrestricted
|
|
42
|
-
optional float zoom_min = 6; // minimum zoom level. must be greater than 0. defaults to the input zoom level
|
|
43
|
-
optional float zoom_max = 7; // maximum zoom level. must be greater than 0. defaults to the input zoom level
|
|
23
|
+
decentraland.common.Vector3 area = 1; // the 3D size of the region
|
|
24
|
+
common.CameraType mode = 2; // the camera mode to enforce
|
|
44
25
|
}
|
|
@@ -8,15 +8,19 @@ import "decentraland/sdk/components/common/texts.proto";
|
|
|
8
8
|
|
|
9
9
|
option (common.ecs_component_id) = 1052;
|
|
10
10
|
|
|
11
|
+
enum TextWrap {
|
|
12
|
+
TW_WRAP = 0;
|
|
13
|
+
TW_NO_WRAP = 1;
|
|
14
|
+
}
|
|
15
|
+
|
|
11
16
|
// The UiText component creates a text widget inside a UI component tree. Its position and
|
|
12
17
|
// layout properties can be specified in a UiTransform component on the same Entity.
|
|
13
18
|
|
|
14
19
|
message PBUiText {
|
|
15
|
-
string value = 1; // the text content
|
|
20
|
+
string value = 1; // the text content, tag <b> and <i> are supported
|
|
16
21
|
optional decentraland.common.Color4 color = 2; // RGBA color (default: opaque white)
|
|
17
22
|
optional common.TextAlignMode text_align = 3; // alignment within the bounds (default: center)
|
|
18
23
|
optional common.Font font = 4; // font for the text (default: sans-serif)
|
|
19
24
|
optional int32 font_size = 5; // size of the text (default: 10)
|
|
20
|
-
optional
|
|
21
|
-
optional decentraland.common.Color4 outline_color = 7; // RGBA color of the outline (default: opaque black)
|
|
25
|
+
optional TextWrap text_wrap = 6; // wrap text when the border is reached (default: TW_WRAP)
|
|
22
26
|
}
|