@dcl/protocol 1.0.0-6314457636.commit-a9a962a → 1.0.0-6590614146.commit-db4a595
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/sdk/components/tween.gen.d.ts +125 -0
- package/out-js/decentraland/sdk/components/tween.gen.js +598 -0
- package/out-js/decentraland/sdk/components/tween.gen.js.map +1 -0
- package/out-js/decentraland/sdk/components/tween_sequence.gen.d.ts +39 -0
- package/out-js/decentraland/sdk/components/tween_sequence.gen.js +122 -0
- package/out-js/decentraland/sdk/components/tween_sequence.gen.js.map +1 -0
- package/out-js/decentraland/sdk/components/tween_state.gen.d.ts +40 -0
- package/out-js/decentraland/sdk/components/tween_state.gen.js +122 -0
- package/out-js/decentraland/sdk/components/tween_state.gen.js.map +1 -0
- package/out-js/decentraland/sdk/components/ui_transform.gen.d.ts +9 -0
- package/out-js/decentraland/sdk/components/ui_transform.gen.js +51 -2
- package/out-js/decentraland/sdk/components/ui_transform.gen.js.map +1 -1
- package/out-ts/decentraland/sdk/components/tween.gen.ts +648 -0
- package/out-ts/decentraland/sdk/components/tween_sequence.gen.ts +134 -0
- package/out-ts/decentraland/sdk/components/tween_state.gen.ts +136 -0
- package/out-ts/decentraland/sdk/components/ui_transform.gen.ts +52 -0
- package/package.json +2 -2
- package/proto/decentraland/common/texture.proto +8 -8
- package/proto/decentraland/sdk/components/tween.proto +74 -0
- package/proto/decentraland/sdk/components/tween_sequence.proto +18 -0
- package/proto/decentraland/sdk/components/tween_state.proto +18 -0
- package/proto/decentraland/sdk/components/ui_transform.proto +7 -0
- package/public/sdk-components.proto +3 -0
|
@@ -0,0 +1,134 @@
|
|
|
1
|
+
/* eslint-disable */
|
|
2
|
+
import _m0 from "protobufjs/minimal";
|
|
3
|
+
import { PBTween } from "./tween.gen";
|
|
4
|
+
|
|
5
|
+
export const protobufPackage = "decentraland.sdk.components";
|
|
6
|
+
|
|
7
|
+
export enum TweenLoop {
|
|
8
|
+
TL_RESTART = 0,
|
|
9
|
+
TL_YOYO = 1,
|
|
10
|
+
UNRECOGNIZED = -1,
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
export function tweenLoopFromJSON(object: any): TweenLoop {
|
|
14
|
+
switch (object) {
|
|
15
|
+
case 0:
|
|
16
|
+
case "TL_RESTART":
|
|
17
|
+
return TweenLoop.TL_RESTART;
|
|
18
|
+
case 1:
|
|
19
|
+
case "TL_YOYO":
|
|
20
|
+
return TweenLoop.TL_YOYO;
|
|
21
|
+
case -1:
|
|
22
|
+
case "UNRECOGNIZED":
|
|
23
|
+
default:
|
|
24
|
+
return TweenLoop.UNRECOGNIZED;
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
export function tweenLoopToJSON(object: TweenLoop): string {
|
|
29
|
+
switch (object) {
|
|
30
|
+
case TweenLoop.TL_RESTART:
|
|
31
|
+
return "TL_RESTART";
|
|
32
|
+
case TweenLoop.TL_YOYO:
|
|
33
|
+
return "TL_YOYO";
|
|
34
|
+
case TweenLoop.UNRECOGNIZED:
|
|
35
|
+
default:
|
|
36
|
+
return "UNRECOGNIZED";
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
export interface PBTweenSequence {
|
|
41
|
+
sequence: PBTween[];
|
|
42
|
+
loop?: TweenLoop | undefined;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
function createBasePBTweenSequence(): PBTweenSequence {
|
|
46
|
+
return { sequence: [], loop: undefined };
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
export namespace PBTweenSequence {
|
|
50
|
+
export function encode(message: PBTweenSequence, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer {
|
|
51
|
+
for (const v of message.sequence) {
|
|
52
|
+
PBTween.encode(v!, writer.uint32(10).fork()).ldelim();
|
|
53
|
+
}
|
|
54
|
+
if (message.loop !== undefined) {
|
|
55
|
+
writer.uint32(16).int32(message.loop);
|
|
56
|
+
}
|
|
57
|
+
return writer;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
export function decode(input: _m0.Reader | Uint8Array, length?: number): PBTweenSequence {
|
|
61
|
+
const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
|
|
62
|
+
let end = length === undefined ? reader.len : reader.pos + length;
|
|
63
|
+
const message = createBasePBTweenSequence();
|
|
64
|
+
while (reader.pos < end) {
|
|
65
|
+
const tag = reader.uint32();
|
|
66
|
+
switch (tag >>> 3) {
|
|
67
|
+
case 1:
|
|
68
|
+
if (tag !== 10) {
|
|
69
|
+
break;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
message.sequence.push(PBTween.decode(reader, reader.uint32()));
|
|
73
|
+
continue;
|
|
74
|
+
case 2:
|
|
75
|
+
if (tag !== 16) {
|
|
76
|
+
break;
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
message.loop = reader.int32() as any;
|
|
80
|
+
continue;
|
|
81
|
+
}
|
|
82
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
83
|
+
break;
|
|
84
|
+
}
|
|
85
|
+
reader.skipType(tag & 7);
|
|
86
|
+
}
|
|
87
|
+
return message;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
export function fromJSON(object: any): PBTweenSequence {
|
|
91
|
+
return {
|
|
92
|
+
sequence: Array.isArray(object?.sequence) ? object.sequence.map((e: any) => PBTween.fromJSON(e)) : [],
|
|
93
|
+
loop: isSet(object.loop) ? tweenLoopFromJSON(object.loop) : undefined,
|
|
94
|
+
};
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
export function toJSON(message: PBTweenSequence): unknown {
|
|
98
|
+
const obj: any = {};
|
|
99
|
+
if (message.sequence) {
|
|
100
|
+
obj.sequence = message.sequence.map((e) => e ? PBTween.toJSON(e) : undefined);
|
|
101
|
+
} else {
|
|
102
|
+
obj.sequence = [];
|
|
103
|
+
}
|
|
104
|
+
message.loop !== undefined && (obj.loop = message.loop !== undefined ? tweenLoopToJSON(message.loop) : undefined);
|
|
105
|
+
return obj;
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
export function create<I extends Exact<DeepPartial<PBTweenSequence>, I>>(base?: I): PBTweenSequence {
|
|
109
|
+
return PBTweenSequence.fromPartial(base ?? {});
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
export function fromPartial<I extends Exact<DeepPartial<PBTweenSequence>, I>>(object: I): PBTweenSequence {
|
|
113
|
+
const message = createBasePBTweenSequence();
|
|
114
|
+
message.sequence = object.sequence?.map((e) => PBTween.fromPartial(e)) || [];
|
|
115
|
+
message.loop = object.loop ?? undefined;
|
|
116
|
+
return message;
|
|
117
|
+
}
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
|
|
121
|
+
|
|
122
|
+
export type DeepPartial<T> = T extends Builtin ? T
|
|
123
|
+
: T extends Array<infer U> ? Array<DeepPartial<U>> : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>>
|
|
124
|
+
: T extends { $case: string } ? { [K in keyof Omit<T, "$case">]?: DeepPartial<T[K]> } & { $case: T["$case"] }
|
|
125
|
+
: T extends {} ? { [K in keyof T]?: DeepPartial<T[K]> }
|
|
126
|
+
: Partial<T>;
|
|
127
|
+
|
|
128
|
+
type KeysOfUnion<T> = T extends T ? keyof T : never;
|
|
129
|
+
export type Exact<P, I extends P> = P extends Builtin ? P
|
|
130
|
+
: P & { [K in keyof P]: Exact<P[K], I[K]> } & { [K in Exclude<keyof I, KeysOfUnion<P>>]: never };
|
|
131
|
+
|
|
132
|
+
function isSet(value: any): boolean {
|
|
133
|
+
return value !== null && value !== undefined;
|
|
134
|
+
}
|
|
@@ -0,0 +1,136 @@
|
|
|
1
|
+
/* eslint-disable */
|
|
2
|
+
import _m0 from "protobufjs/minimal";
|
|
3
|
+
|
|
4
|
+
export const protobufPackage = "decentraland.sdk.components";
|
|
5
|
+
|
|
6
|
+
export enum TweenStateStatus {
|
|
7
|
+
TS_ACTIVE = 0,
|
|
8
|
+
TS_COMPLETED = 1,
|
|
9
|
+
TS_PAUSED = 2,
|
|
10
|
+
UNRECOGNIZED = -1,
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
export function tweenStateStatusFromJSON(object: any): TweenStateStatus {
|
|
14
|
+
switch (object) {
|
|
15
|
+
case 0:
|
|
16
|
+
case "TS_ACTIVE":
|
|
17
|
+
return TweenStateStatus.TS_ACTIVE;
|
|
18
|
+
case 1:
|
|
19
|
+
case "TS_COMPLETED":
|
|
20
|
+
return TweenStateStatus.TS_COMPLETED;
|
|
21
|
+
case 2:
|
|
22
|
+
case "TS_PAUSED":
|
|
23
|
+
return TweenStateStatus.TS_PAUSED;
|
|
24
|
+
case -1:
|
|
25
|
+
case "UNRECOGNIZED":
|
|
26
|
+
default:
|
|
27
|
+
return TweenStateStatus.UNRECOGNIZED;
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
export function tweenStateStatusToJSON(object: TweenStateStatus): string {
|
|
32
|
+
switch (object) {
|
|
33
|
+
case TweenStateStatus.TS_ACTIVE:
|
|
34
|
+
return "TS_ACTIVE";
|
|
35
|
+
case TweenStateStatus.TS_COMPLETED:
|
|
36
|
+
return "TS_COMPLETED";
|
|
37
|
+
case TweenStateStatus.TS_PAUSED:
|
|
38
|
+
return "TS_PAUSED";
|
|
39
|
+
case TweenStateStatus.UNRECOGNIZED:
|
|
40
|
+
default:
|
|
41
|
+
return "UNRECOGNIZED";
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
export interface PBTweenState {
|
|
46
|
+
state: TweenStateStatus;
|
|
47
|
+
/** between 0 and 1 */
|
|
48
|
+
currentTime: number;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
function createBasePBTweenState(): PBTweenState {
|
|
52
|
+
return { state: 0, currentTime: 0 };
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
export namespace PBTweenState {
|
|
56
|
+
export function encode(message: PBTweenState, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer {
|
|
57
|
+
if (message.state !== 0) {
|
|
58
|
+
writer.uint32(8).int32(message.state);
|
|
59
|
+
}
|
|
60
|
+
if (message.currentTime !== 0) {
|
|
61
|
+
writer.uint32(21).float(message.currentTime);
|
|
62
|
+
}
|
|
63
|
+
return writer;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
export function decode(input: _m0.Reader | Uint8Array, length?: number): PBTweenState {
|
|
67
|
+
const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
|
|
68
|
+
let end = length === undefined ? reader.len : reader.pos + length;
|
|
69
|
+
const message = createBasePBTweenState();
|
|
70
|
+
while (reader.pos < end) {
|
|
71
|
+
const tag = reader.uint32();
|
|
72
|
+
switch (tag >>> 3) {
|
|
73
|
+
case 1:
|
|
74
|
+
if (tag !== 8) {
|
|
75
|
+
break;
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
message.state = reader.int32() as any;
|
|
79
|
+
continue;
|
|
80
|
+
case 2:
|
|
81
|
+
if (tag !== 21) {
|
|
82
|
+
break;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
message.currentTime = reader.float();
|
|
86
|
+
continue;
|
|
87
|
+
}
|
|
88
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
89
|
+
break;
|
|
90
|
+
}
|
|
91
|
+
reader.skipType(tag & 7);
|
|
92
|
+
}
|
|
93
|
+
return message;
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
export function fromJSON(object: any): PBTweenState {
|
|
97
|
+
return {
|
|
98
|
+
state: isSet(object.state) ? tweenStateStatusFromJSON(object.state) : 0,
|
|
99
|
+
currentTime: isSet(object.currentTime) ? Number(object.currentTime) : 0,
|
|
100
|
+
};
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
export function toJSON(message: PBTweenState): unknown {
|
|
104
|
+
const obj: any = {};
|
|
105
|
+
message.state !== undefined && (obj.state = tweenStateStatusToJSON(message.state));
|
|
106
|
+
message.currentTime !== undefined && (obj.currentTime = message.currentTime);
|
|
107
|
+
return obj;
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
export function create<I extends Exact<DeepPartial<PBTweenState>, I>>(base?: I): PBTweenState {
|
|
111
|
+
return PBTweenState.fromPartial(base ?? {});
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
export function fromPartial<I extends Exact<DeepPartial<PBTweenState>, I>>(object: I): PBTweenState {
|
|
115
|
+
const message = createBasePBTweenState();
|
|
116
|
+
message.state = object.state ?? 0;
|
|
117
|
+
message.currentTime = object.currentTime ?? 0;
|
|
118
|
+
return message;
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
|
|
123
|
+
|
|
124
|
+
export type DeepPartial<T> = T extends Builtin ? T
|
|
125
|
+
: T extends Array<infer U> ? Array<DeepPartial<U>> : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>>
|
|
126
|
+
: T extends { $case: string } ? { [K in keyof Omit<T, "$case">]?: DeepPartial<T[K]> } & { $case: T["$case"] }
|
|
127
|
+
: T extends {} ? { [K in keyof T]?: DeepPartial<T[K]> }
|
|
128
|
+
: Partial<T>;
|
|
129
|
+
|
|
130
|
+
type KeysOfUnion<T> = T extends T ? keyof T : never;
|
|
131
|
+
export type Exact<P, I extends P> = P extends Builtin ? P
|
|
132
|
+
: P & { [K in keyof P]: Exact<P[K], I[K]> } & { [K in Exclude<keyof I, KeysOfUnion<P>>]: never };
|
|
133
|
+
|
|
134
|
+
function isSet(value: any): boolean {
|
|
135
|
+
return value !== null && value !== undefined;
|
|
136
|
+
}
|
|
@@ -438,6 +438,39 @@ export function yGEdgeToJSON(object: YGEdge): string {
|
|
|
438
438
|
}
|
|
439
439
|
}
|
|
440
440
|
|
|
441
|
+
export enum PointerFilterMode {
|
|
442
|
+
PFM_NONE = 0,
|
|
443
|
+
PFM_BLOCK = 1,
|
|
444
|
+
UNRECOGNIZED = -1,
|
|
445
|
+
}
|
|
446
|
+
|
|
447
|
+
export function pointerFilterModeFromJSON(object: any): PointerFilterMode {
|
|
448
|
+
switch (object) {
|
|
449
|
+
case 0:
|
|
450
|
+
case "PFM_NONE":
|
|
451
|
+
return PointerFilterMode.PFM_NONE;
|
|
452
|
+
case 1:
|
|
453
|
+
case "PFM_BLOCK":
|
|
454
|
+
return PointerFilterMode.PFM_BLOCK;
|
|
455
|
+
case -1:
|
|
456
|
+
case "UNRECOGNIZED":
|
|
457
|
+
default:
|
|
458
|
+
return PointerFilterMode.UNRECOGNIZED;
|
|
459
|
+
}
|
|
460
|
+
}
|
|
461
|
+
|
|
462
|
+
export function pointerFilterModeToJSON(object: PointerFilterMode): string {
|
|
463
|
+
switch (object) {
|
|
464
|
+
case PointerFilterMode.PFM_NONE:
|
|
465
|
+
return "PFM_NONE";
|
|
466
|
+
case PointerFilterMode.PFM_BLOCK:
|
|
467
|
+
return "PFM_BLOCK";
|
|
468
|
+
case PointerFilterMode.UNRECOGNIZED:
|
|
469
|
+
default:
|
|
470
|
+
return "UNRECOGNIZED";
|
|
471
|
+
}
|
|
472
|
+
}
|
|
473
|
+
|
|
441
474
|
export interface PBUiTransform {
|
|
442
475
|
parent: number;
|
|
443
476
|
rightOf: number;
|
|
@@ -527,6 +560,8 @@ export interface PBUiTransform {
|
|
|
527
560
|
/** YGUnit.YGU_UNDEFINED */
|
|
528
561
|
paddingBottomUnit: YGUnit;
|
|
529
562
|
paddingBottom: number;
|
|
563
|
+
/** default: PointerFilterMode.PFM_NONE */
|
|
564
|
+
pointerFilter?: PointerFilterMode | undefined;
|
|
530
565
|
}
|
|
531
566
|
|
|
532
567
|
function createBasePBUiTransform(): PBUiTransform {
|
|
@@ -582,6 +617,7 @@ function createBasePBUiTransform(): PBUiTransform {
|
|
|
582
617
|
paddingRight: 0,
|
|
583
618
|
paddingBottomUnit: 0,
|
|
584
619
|
paddingBottom: 0,
|
|
620
|
+
pointerFilter: undefined,
|
|
585
621
|
};
|
|
586
622
|
}
|
|
587
623
|
|
|
@@ -740,6 +776,9 @@ export namespace PBUiTransform {
|
|
|
740
776
|
if (message.paddingBottom !== 0) {
|
|
741
777
|
writer.uint32(413).float(message.paddingBottom);
|
|
742
778
|
}
|
|
779
|
+
if (message.pointerFilter !== undefined) {
|
|
780
|
+
writer.uint32(416).int32(message.pointerFilter);
|
|
781
|
+
}
|
|
743
782
|
return writer;
|
|
744
783
|
}
|
|
745
784
|
|
|
@@ -1107,6 +1146,13 @@ export namespace PBUiTransform {
|
|
|
1107
1146
|
|
|
1108
1147
|
message.paddingBottom = reader.float();
|
|
1109
1148
|
continue;
|
|
1149
|
+
case 52:
|
|
1150
|
+
if (tag !== 416) {
|
|
1151
|
+
break;
|
|
1152
|
+
}
|
|
1153
|
+
|
|
1154
|
+
message.pointerFilter = reader.int32() as any;
|
|
1155
|
+
continue;
|
|
1110
1156
|
}
|
|
1111
1157
|
if ((tag & 7) === 4 || tag === 0) {
|
|
1112
1158
|
break;
|
|
@@ -1169,6 +1215,7 @@ export namespace PBUiTransform {
|
|
|
1169
1215
|
paddingRight: isSet(object.paddingRight) ? Number(object.paddingRight) : 0,
|
|
1170
1216
|
paddingBottomUnit: isSet(object.paddingBottomUnit) ? yGUnitFromJSON(object.paddingBottomUnit) : 0,
|
|
1171
1217
|
paddingBottom: isSet(object.paddingBottom) ? Number(object.paddingBottom) : 0,
|
|
1218
|
+
pointerFilter: isSet(object.pointerFilter) ? pointerFilterModeFromJSON(object.pointerFilter) : undefined,
|
|
1172
1219
|
};
|
|
1173
1220
|
}
|
|
1174
1221
|
|
|
@@ -1228,6 +1275,10 @@ export namespace PBUiTransform {
|
|
|
1228
1275
|
message.paddingRight !== undefined && (obj.paddingRight = message.paddingRight);
|
|
1229
1276
|
message.paddingBottomUnit !== undefined && (obj.paddingBottomUnit = yGUnitToJSON(message.paddingBottomUnit));
|
|
1230
1277
|
message.paddingBottom !== undefined && (obj.paddingBottom = message.paddingBottom);
|
|
1278
|
+
message.pointerFilter !== undefined &&
|
|
1279
|
+
(obj.pointerFilter = message.pointerFilter !== undefined
|
|
1280
|
+
? pointerFilterModeToJSON(message.pointerFilter)
|
|
1281
|
+
: undefined);
|
|
1231
1282
|
return obj;
|
|
1232
1283
|
}
|
|
1233
1284
|
|
|
@@ -1288,6 +1339,7 @@ export namespace PBUiTransform {
|
|
|
1288
1339
|
message.paddingRight = object.paddingRight ?? 0;
|
|
1289
1340
|
message.paddingBottomUnit = object.paddingBottomUnit ?? 0;
|
|
1290
1341
|
message.paddingBottom = object.paddingBottom ?? 0;
|
|
1342
|
+
message.pointerFilter = object.pointerFilter ?? undefined;
|
|
1291
1343
|
return message;
|
|
1292
1344
|
}
|
|
1293
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-6590614146.commit-db4a595",
|
|
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": "db4a595738be80534c946b7c7615fd4b270a161e"
|
|
33
33
|
}
|
|
@@ -14,9 +14,9 @@ enum TextureFilterMode {
|
|
|
14
14
|
}
|
|
15
15
|
|
|
16
16
|
message Texture {
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
17
|
+
string src = 1;
|
|
18
|
+
optional TextureWrapMode wrap_mode = 2; // default = TextureWrapMode.Clamp
|
|
19
|
+
optional TextureFilterMode filter_mode = 3; // default = FilterMode.Bilinear
|
|
20
20
|
}
|
|
21
21
|
|
|
22
22
|
message AvatarTexture {
|
|
@@ -32,9 +32,9 @@ message VideoTexture {
|
|
|
32
32
|
}
|
|
33
33
|
|
|
34
34
|
message TextureUnion {
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
35
|
+
oneof tex {
|
|
36
|
+
Texture texture = 1; // default = null
|
|
37
|
+
AvatarTexture avatar_texture = 2; // default = null
|
|
38
|
+
VideoTexture video_texture = 3; // default = null
|
|
39
|
+
}
|
|
40
40
|
}
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
syntax = "proto3";
|
|
2
|
+
|
|
3
|
+
package decentraland.sdk.components;
|
|
4
|
+
|
|
5
|
+
import "decentraland/common/vectors.proto";
|
|
6
|
+
import "decentraland/sdk/components/common/id.proto";
|
|
7
|
+
|
|
8
|
+
option (common.ecs_component_id) = 1102;
|
|
9
|
+
|
|
10
|
+
message PBTween {
|
|
11
|
+
float duration = 1; // in milliseconds
|
|
12
|
+
EasingFunction easing_function = 2;
|
|
13
|
+
|
|
14
|
+
oneof mode {
|
|
15
|
+
Move move = 3;
|
|
16
|
+
Rotate rotate = 4;
|
|
17
|
+
Scale scale = 5;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
optional bool playing = 6; // default true (pause or running)
|
|
21
|
+
optional float current_time = 7; // between 0 and 1
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
message Move {
|
|
25
|
+
decentraland.common.Vector3 start = 1;
|
|
26
|
+
decentraland.common.Vector3 end = 2;
|
|
27
|
+
optional bool face_direction = 3;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
message Rotate {
|
|
31
|
+
decentraland.common.Quaternion start = 1;
|
|
32
|
+
decentraland.common.Quaternion end = 2;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
message Scale {
|
|
36
|
+
decentraland.common.Vector3 start = 1;
|
|
37
|
+
decentraland.common.Vector3 end = 2;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
// Implementation guidelines for these easing functions can be found
|
|
41
|
+
// at https://github.com/ai/easings.net/blob/6fcd5f852a470bf1a7890e8178afa0f471d5f2ec/src/easings/easingsFunctions.ts
|
|
42
|
+
enum EasingFunction {
|
|
43
|
+
EF_LINEAR = 0; // default
|
|
44
|
+
EF_EASEINQUAD = 1;
|
|
45
|
+
EF_EASEOUTQUAD = 2;
|
|
46
|
+
EF_EASEQUAD = 3;
|
|
47
|
+
EF_EASEINSINE = 4;
|
|
48
|
+
EF_EASEOUTSINE = 5;
|
|
49
|
+
EF_EASESINE = 6;
|
|
50
|
+
EF_EASEINEXPO = 7;
|
|
51
|
+
EF_EASEOUTEXPO = 8;
|
|
52
|
+
EF_EASEEXPO = 9;
|
|
53
|
+
EF_EASEINELASTIC = 10;
|
|
54
|
+
EF_EASEOUTELASTIC = 11;
|
|
55
|
+
EF_EASEELASTIC = 12;
|
|
56
|
+
EF_EASEINBOUNCE = 13;
|
|
57
|
+
EF_EASEOUTBOUNCE = 14;
|
|
58
|
+
EF_EASEBOUNCE = 15;
|
|
59
|
+
EF_EASEINCUBIC = 16;
|
|
60
|
+
EF_EASEOUTCUBIC = 17;
|
|
61
|
+
EF_EASECUBIC = 18;
|
|
62
|
+
EF_EASEINQUART = 19;
|
|
63
|
+
EF_EASEOUTQUART = 20;
|
|
64
|
+
EF_EASEQUART = 21;
|
|
65
|
+
EF_EASEINQUINT = 22;
|
|
66
|
+
EF_EASEOUTQUINT = 23;
|
|
67
|
+
EF_EASEQUINT = 24;
|
|
68
|
+
EF_EASEINCIRC = 25;
|
|
69
|
+
EF_EASEOUTCIRC = 26;
|
|
70
|
+
EF_EASECIRC = 27;
|
|
71
|
+
EF_EASEINBACK = 28;
|
|
72
|
+
EF_EASEOUTBACK = 29;
|
|
73
|
+
EF_EASEBACK = 30;
|
|
74
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
syntax = "proto3";
|
|
2
|
+
|
|
3
|
+
package decentraland.sdk.components;
|
|
4
|
+
|
|
5
|
+
import "decentraland/sdk/components/common/id.proto";
|
|
6
|
+
import "decentraland/sdk/components/tween.proto";
|
|
7
|
+
|
|
8
|
+
option (common.ecs_component_id) = 1104;
|
|
9
|
+
|
|
10
|
+
message PBTweenSequence {
|
|
11
|
+
repeated PBTween sequence = 1;
|
|
12
|
+
optional TweenLoop loop = 2;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
enum TweenLoop {
|
|
16
|
+
TL_RESTART = 0;
|
|
17
|
+
TL_YOYO = 1;
|
|
18
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
syntax = "proto3";
|
|
2
|
+
|
|
3
|
+
package decentraland.sdk.components;
|
|
4
|
+
|
|
5
|
+
import "decentraland/sdk/components/common/id.proto";
|
|
6
|
+
|
|
7
|
+
option (common.ecs_component_id) = 1103;
|
|
8
|
+
|
|
9
|
+
message PBTweenState {
|
|
10
|
+
TweenStateStatus state = 1;
|
|
11
|
+
float current_time = 2; // between 0 and 1
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
enum TweenStateStatus {
|
|
15
|
+
TS_ACTIVE = 0;
|
|
16
|
+
TS_COMPLETED = 1;
|
|
17
|
+
TS_PAUSED= 2;
|
|
18
|
+
}
|
|
@@ -74,6 +74,11 @@ enum YGEdge {
|
|
|
74
74
|
YGE_ALL = 8;
|
|
75
75
|
}
|
|
76
76
|
|
|
77
|
+
enum PointerFilterMode {
|
|
78
|
+
PFM_NONE = 0;
|
|
79
|
+
PFM_BLOCK = 1;
|
|
80
|
+
}
|
|
81
|
+
|
|
77
82
|
message PBUiTransform {
|
|
78
83
|
int32 parent = 1;
|
|
79
84
|
int32 right_of = 2;
|
|
@@ -138,4 +143,6 @@ message PBUiTransform {
|
|
|
138
143
|
float padding_right = 49;
|
|
139
144
|
YGUnit padding_bottom_unit = 50; // YGUnit.YGU_UNDEFINED
|
|
140
145
|
float padding_bottom = 51;
|
|
146
|
+
|
|
147
|
+
optional PointerFilterMode pointer_filter = 52; // default: PointerFilterMode.PFM_NONE
|
|
141
148
|
}
|
|
@@ -27,6 +27,9 @@ import public "decentraland/sdk/components/pointer_lock.proto";
|
|
|
27
27
|
import public "decentraland/sdk/components/raycast_result.proto";
|
|
28
28
|
import public "decentraland/sdk/components/raycast.proto";
|
|
29
29
|
import public "decentraland/sdk/components/text_shape.proto";
|
|
30
|
+
import public "decentraland/sdk/components/tween.proto";
|
|
31
|
+
import public "decentraland/sdk/components/tween_state.proto";
|
|
32
|
+
import public "decentraland/sdk/components/tween_sequence.proto";
|
|
30
33
|
import public "decentraland/sdk/components/ui_background.proto";
|
|
31
34
|
import public "decentraland/sdk/components/ui_dropdown_result.proto";
|
|
32
35
|
import public "decentraland/sdk/components/ui_dropdown.proto";
|